Mac Developer Library

Developer

CoreData Framework Reference NSExpressionDescription Class Reference

Options
Deployment Target:

On This Page
Language:

NSExpressionDescription

Inheritance


Conforms To


Import Statement


Swift

import CoreData

Objective-C

@import CoreData;

Availability


Available in OS X v10.6 and later.

Instances of NSExpressionDescription objects represent a special property description type intended for use with the NSFetchRequest propertiesToFetch method.

An NSExpressionDescription describes a column to be returned from a fetch that may not appear directly as an attribute or relationship on an entity. Examples might include upper(attribute) or max(attribute). You cannot set an NSExpressionDescription object as a property of an entity.

  • The expression for the receiver.

    Declaration

    Swift

    var expression: NSExpression?

    Objective-C

    @property(strong) NSExpression *expression

    Special Considerations

    Setting the expression raises an exception if the receiver’€™s model has been used by an object graph manager.

    Import Statement

    Objective-C

    @import CoreData;

    Swift

    import CoreData

    Availability

    Available in OS X v10.6 and later.

  • The type of the receiver.

    Declaration

    Swift

    var expressionResultType: NSAttributeType

    Objective-C

    @property NSAttributeType expressionResultType

    Special Considerations

    Setting the result type raises an exception if the receiver’€™s model has been used by an object graph manager.

    Import Statement

    Objective-C

    @import CoreData;

    Swift

    import CoreData

    Availability

    Available in OS X v10.6 and later.