Property
public struct Property<E, T> where E : Entity, T : EntityPropertyTypeConvertible
Metadata of object properties, used by the framework to determine how to store the values.
These are created by the code generator for you.
-
Entity type that contains the property this object is describing.
Declaration
Swift
public typealias EntityType = E
-
Supported property value type this is describing.
Declaration
Swift
public typealias ValueType = T
-
Undocumented
Declaration
Swift
public init(propertyId: UInt64, isPrimaryKey: Bool = false)
-
Indicates if the property is the entity’s primary key.
Declaration
Swift
public var isPrimaryKey: Bool { get }
-
The internal ID of the property, in terms of the database schema.
Declaration
Swift
public var propertyId: UInt64 { get }
-
Equivalent to the == operator in query blocks.
Declaration
Swift
public func isEqual(to value: EntityId) -> PropertyQueryCondition<EntityType, EntityId>
-
Equivalent to the == operator in query blocks.
Declaration
Swift
public func isEqual(to value: Int32) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the != operator in query blocks.
Declaration
Swift
public func isNotEqual(to value: Int32) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the < operator in query blocks.
Declaration
Swift
public func isLessThan(_ value: Int32) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the > operator in query blocks.
Declaration
Swift
public func isGreaterThan(_ value: Int32) -> PropertyQueryCondition<EntityType, ValueType>
-
Matches all property values between
lowerBound
andupperBound
, including the bounds themselves. The order of the bounds does not matter.Declaration
Swift
public func isBetween(_ lowerBound: Int32, and upperBound: Int32) -> PropertyQueryCondition<EntityType, ValueType>
Parameters
queryProperty
Entity property to compare values of.
lowerBound
Lower limiting value, inclusive.
upperBound
Upper limiting value, inclusive.
Return Value
QueryCondition
describing the property match condition. -
Equivalent to the ∈ operator in query blocks.
Declaration
Swift
public func isIn(_ range: Range<Int32>) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the ∈ operator in query blocks.
Declaration
Swift
public func isIn(_ range: ClosedRange<Int32>) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the ∈ operator in query blocks.
Declaration
Swift
public func isIn(_ collection: [Int32]) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the ∉ operator in query blocks.
Declaration
Swift
public func isNotIn(_ collection: [Int32]) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the == operator in query blocks.
Declaration
Swift
public func isEqual(to value: Int64) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the != operator in query blocks.
Declaration
Swift
public func isNotEqual(to value: Int64) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the < operator in query blocks.
Declaration
Swift
public func isLessThan(_ value: Int64) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the > operator in query blocks.
Declaration
Swift
public func isGreaterThan(_ value: Int64) -> PropertyQueryCondition<EntityType, ValueType>
-
Matches all property values between
lowerBound
andupperBound
, including the bounds themselves. The order of the bounds does not matter.Declaration
Swift
public func isBetween(_ lowerBound: Int64, and upperBound: Int64) -> PropertyQueryCondition<EntityType, ValueType>
Parameters
queryProperty
Entity property to compare values of.
lowerBound
Lower limiting value, inclusive.
upperBound
Upper limiting value, inclusive.
Return Value
QueryCondition
describing the property match condition. -
Equivalent to the ∈ operator in query blocks.
Declaration
Swift
public func isIn(_ range: Range<Int64>) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the ∈ operator in query blocks.
Declaration
Swift
public func isIn(_ range: ClosedRange<Int64>) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the ∈ operator in query blocks.
Declaration
Swift
public func isIn(_ collection: [Int64]) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the ∉ operator in query blocks.
Declaration
Swift
public func isNotIn(_ collection: [Int64]) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the == operator in query blocks.
Declaration
Swift
public func isEqual(to value: Int) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the != operator in query blocks.
Declaration
Swift
public func isNotEqual(to value: Int) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the < operator in query blocks.
Declaration
Swift
public func isLessThan(_ value: Int) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the > operator in query blocks.
Declaration
Swift
public func isGreaterThan(_ value: Int) -> PropertyQueryCondition<EntityType, ValueType>
-
Matches all property values between
lowerBound
andupperBound
, including the bounds themselves. The order of the bounds does not matter.Declaration
Swift
public func isBetween(_ lowerBound: Int, and upperBound: Int) -> PropertyQueryCondition<EntityType, ValueType>
Parameters
queryProperty
Entity property to compare values of.
lowerBound
Lower limiting value, inclusive.
upperBound
Upper limiting value, inclusive.
Return Value
QueryCondition
describing the property match condition. -
Equivalent to the ∈ operator in query blocks.
Declaration
Swift
public func isIn(_ range: Range<Int>) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the ∈ operator in query blocks.
Declaration
Swift
public func isIn(_ range: ClosedRange<Int>) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the ∈ operator in query blocks.
Declaration
Swift
public func isIn(_ collection: [Int]) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the ∉ operator in query blocks.
Declaration
Swift
public func isNotIn(_ collection: [Int]) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the == operator in query blocks.
Declaration
Swift
public func isEqual(to other: Double, tolerance: Double) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the < operator in query blocks.
Declaration
Swift
public func isLessThan(_ double: Double) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the > operator in query blocks.
Declaration
Swift
public func isGreaterThan(_ double: Double) -> PropertyQueryCondition<EntityType, ValueType>
-
Matches all property values between
lowerBound
andupperBound
, including the bounds themselves. The order of the bounds does not matter.Declaration
Swift
public func isBetween(_ lowerBound: Double, and upperBound: Double) -> PropertyQueryCondition<EntityType, ValueType>
Parameters
queryProperty
Entity property to compare values of.
lowerBound
Lower limiting value, inclusive.
upperBound
Upper limiting value, inclusive.
Return Value
QueryCondition
describing the property match condition.
-
Equivalent to the == operator in query blocks.
Declaration
Swift
public func isEqual(to string: String, caseSensitive: Bool = true) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the != operator in query blocks.
Declaration
Swift
public func isNotEqual(to string: String, caseSensitive: Bool = true) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the < operator in query blocks.
Declaration
Swift
public func isLessThan(_ string: String, caseSensitive: Bool = true) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the > operator in query blocks.
Declaration
Swift
public func isGreaterThan(_ string: String, caseSensitive: Bool = true) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the ∈ operator in query blocks.
Declaration
Swift
public func isIn(_ collection: [String], caseSensitive: Bool = true) -> PropertyQueryCondition<EntityType, ValueType>
-
Alternate name for startsWith(_,caseSensitive:).
Declaration
Swift
public func hasPrefix(_ prefix: String, caseSensitive: Bool = true) -> PropertyQueryCondition<EntityType, ValueType>
-
In query blocks, use this to find prefix string matches of a property.
Declaration
Swift
public func startsWith(_ prefix: String, caseSensitive: Bool = true) -> PropertyQueryCondition<EntityType, ValueType>
-
Alternate name for endsWith(_,caseSensitive:).
Declaration
Swift
public func hasSuffix(_ suffix: String, caseSensitive: Bool = true) -> PropertyQueryCondition<EntityType, ValueType>
-
In query blocks, use this to find suffix string matches of a property.
Declaration
Swift
public func endsWith(_ suffix: String, caseSensitive: Bool = true) -> PropertyQueryCondition<EntityType, ValueType>
-
In query blocks, use this to find substring matches of a property.
Declaration
Swift
public func contains(_ substring: String, caseSensitive: Bool = true) -> PropertyQueryCondition<EntityType, ValueType>
-
Undocumented
Declaration
Swift
public func isEqual(to date: Date) -> PropertyQueryCondition<EntityType, ValueType>
-
Undocumented
Declaration
Swift
public func isNotEqual(to date: Date) -> PropertyQueryCondition<EntityType, ValueType>
-
Matches all property values between
lowerBound
andupperBound
, including the bounds themselves. The order of the bounds does not matter.Declaration
Swift
public func isBetween(_ lowerBound: Date, and upperBound: Date) -> PropertyQueryCondition<EntityType, ValueType>
Parameters
lowerBound
Earliest date, inclusive.
upperBound
Latest date, inclusive.
Return Value
QueryCondition
describing the property match condition. -
Equivalent to the ∈ operator in query blocks.
Declaration
Swift
public func isIn(_ range: Range<Date>) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the ∈ operator in query blocks.
Declaration
Swift
public func isIn(_ range: ClosedRange<Date>) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the ∈ operator in query blocks.
Declaration
Swift
public func isIn(_ collection: [Date]) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the ∉ operator in query blocks.
Declaration
Swift
public func isNotIn(_ collection: [Date]) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the < operator in query blocks.
Declaration
Swift
public func isBefore(_ other: Date) -> PropertyQueryCondition<EntityType, ValueType>
-
Equivalent to the > operator in query blocks.
Declaration
Swift
public func isAfter(_ other: Date) -> PropertyQueryCondition<EntityType, ValueType>