SelectItem

open class SelectItem: ObjectBase

Encapsulates an OData select item. A select item indicates a property (or expression) that is used in the $select system query option.

  • Obsolete. Use of with unlabeled parameter.

    Declaration

    Swift

    public static func of(property: Property) -> SelectItem
  • A path to be expanded in the query results.

    Declaration

    Swift

    final public var path: DataPath!
  • Default initializer.

    Declaration

    Swift

    override public init()
  • Declaration

    Swift

    open class func of(_ item: PropertyPath) -> SelectItem

    Parameters

    item

    Item to be selected.

    Return Value

    A new select item for the specified property.

  • If this select item references a simple property path, then return the property. Otherwise return nil.

    Declaration

    Swift

    open func toProperty() -> Property?

    Return Value

    The property to be selected, or nil.

  • If this select item references a simple property path, then return the property. Otherwise throw an exception.

    Throws

    UndefinedException if this select item does not reference a simple property path.

    Declaration

    Swift

    open func toRequiredProperty() -> Property

    Return Value

    The property to be selected.

  • Declaration

    Swift

    override open func toString() -> String

    Return Value

    A string representation of this select item.