Webcom Android SDK Public API Reference / com.orange.webcom.sdkv2.datasync / Constraint / EndAt

EndAt

class EndAt : Constraint

limit children until endKey: the values of data nodes sent by subscriptions will be limited to the last limit child nodes (or all child nodes if limit is not set) of the actual data nodes whose keys are lesser or equal endKey.

Child nodes are ordered with respect to their keys in a dedicated lexicographic order. For example, if the actual data node to send is {a:9, b:8, c:7}, the EndAt("cba", 2) constraint will send {b:8, c:7} to notification targets.

Constructors

<init>

EndAt(endKey: String, limit: Int? = null)

limit children until endKey: the values of data nodes sent by subscriptions will be limited to the last limit child nodes (or all child nodes if limit is not set) of the actual data nodes whose keys are lesser or equal endKey.

Properties

endKey

val endKey: String

Key that is greater than or equal to (following the lexicographic order) the key of last child that can be sent by subscriptions.

limit

val limit: Int?

If set, maximum number of children that can be sent by subscriptions to the given endKey.