NSFetchRequest

  • Mechanica

    Creates a NSFetchRequest.

    Declaration

    Swift

    public convenience init(entity: NSEntityDescription, predicate: NSPredicate? = nil, batchSize: Int = 0)

    Parameters

    entity

    Core Data entity description.

    predicate

    Fetch request predicate.

    batchSize

    Breaks the result set into batches.

    Return Value

    a new NSFetchRequest.

  • Mechanica

    Declaration

    Swift

    public func andPredicate(_ predicate: NSPredicate)

    Parameters

    predicate

    A NSPredicate object. Associates to self a new compound NSPredicate formed by AND-ing the current predicate with a given predicate.

  • Mechanica

    Declaration

    Swift

    public func orPredicate(_ predicate: NSPredicate)

    Parameters

    predicate

    A NSPredicate object. Associates to self a new compound NSPredicate formed by OR-ing the current predicate with a given predicate.

  • Mechanica

    Declaration

    Swift

    public func addSortDescriptors(_ descriptors: [NSSortDescriptor])

    Parameters

    descriptors

    An array of NSSortDescriptor objects. Appends to the current sort descriptors an array of descriptors.