Data
Types related to the Data service.
-
A value representing the type of events to subscribe to for a node.
It is used for the
DataSubscriptionDescriptor.eventType
property of theDataSubscriptionDescriptor
instance passed:- to the
DataNode.subscribeThroughNotifications(descriptor:file:line:session:queue:then:)
method, - or to the
DataNode.subscribeThroughWebhook(_:context:descriptor:file:line:session:queue:then:)
method.
Declaration
Swift
public enum DataEventType : Codable, Equatable, CustomStringConvertible
- to the
-
An object that represents a reference to a database node.
By abuse of language, the node reference is sometimes assimilate with the referred node itself. This does not usually preclude understanding. Just keep in mind that there may be several references for the same database node.
Instances are created using the
See moreDataService.node(for:)
method of aDataService
instance.Declaration
Swift
public final class DataNode : Hashable, CustomStringConvertible
extension DataNode: WebcomCombinable
-
An object representing the Data service of a
WebcomApplication
instance. This service consists of a database with a tree-like data model (equivalent to a JSON object).To get an object of this type, use the
WebcomApplication.dataService
property of aWebcomApplication
instance. There is only one instance of this class for eachWebcomApplication
instance.This service uses a REST API of the back-end to read and write data. Unlike the
DatasyncService
, it is not real-time and it does not offer local caching. It is a low-level access.This service should only be used when it is not possible to use the
DatasyncService
, especially in extensions where available resources are limited and where therefore the JavaScript SDK cannot be loaded.When possible, it is always best to use the
See moreDatasyncService
.Declaration
-
An object representing a subscription to Data events.
Instances are created by the
See moreDataNode.subscribeThroughNotifications(descriptor:file:line:session:queue:then:)
and theDataNode.subscribeThroughWebhook(_:context:descriptor:file:line:session:queue:then:)
methods.Declaration
Swift
public final class DataSubscription : CustomDebugStringConvertible
extension DataSubscription: WebcomCombinable
-
A value containing the descriptor for a subscription to events of the
DataService
.This value does not depend on a node.
See moreDeclaration
Swift
public struct DataSubscriptionDescriptor : Codable, Equatable, CustomStringConvertible
-
The value of a node.
See moreDeclaration
Swift
public struct DataValue : WebcomValuable, Hashable, CustomStringConvertible