|
static DevelopmentIdentity | Development (std::string app_id="", uint64_t site_id=0, std::string persistence_dir="") |
| Construct a new DevelopmentIdentity. More...
|
|
static OfflinePlaygroundIdentity | OfflinePlayground (std::string app_id="", uint64_t site_id=0, std::string persistence_dir="") |
| Construct a new OfflinePlaygroundIdentity. More...
|
|
static OnlineIdentity | Online (std::string app_id, std::shared_ptr< AuthenticationCallback > callback, bool enable_ditto_cloud_sync=true, std::string custom_auth_url="", std::string persistence_dir="") |
| Construct a new OnlineIdentity. More...
|
|
static OnlineWithAuthenticationIdentity | OnlineWithAuthentication (std::string app_id, std::shared_ptr< AuthenticationCallback > callback, bool enable_ditto_cloud_sync=true, std::string custom_auth_url="", std::string persistence_dir="") |
| Construct a new OnlineWithAuthenticationIdentity. More...
|
|
static OnlinePlaygroundIdentity | OnlinePlayground (std::string app_id, bool enable_ditto_cloud_sync=true, std::string persistence_dir="") |
| Construct a new OnlinePlaygroundIdentity. More...
|
|
static SharedKeyIdentity | SharedKey (std::string app_id, std::string shared_key, uint64_t site_id=0, std::string persistence_dir="") |
| Construct a new SharedKeyIdentity. More...
|
|
static ManualIdentity | Manual (std::string certificate_config) |
| Construct a new ManualIdentity. More...
|
|
The various identity configurations that you can use when initializing a Ditto instance.
The different supported identities and when they should be used are as follows:
- Development: (Deprecated - use
OfflinePlayground
instead) Develop peer-to-peer apps with no cloud connection. This mode offers no security and must only be used for development.
- OfflinePlayground: Develop peer-to-peer apps with no cloud connection. This mode offers no security and must only be used for development.
- Online: (Deprecated - use
OnlineWithAuthentication
instead) Run Ditto in secure production mode, logging on to Ditto Cloud or on on-premises authentication server. User permissions are centrally managed.
- OnlineWithAuthentication: Run Ditto in secure production mode, logging on to Ditto Cloud or on on-premises authentication server. User permissions are centrally managed.
- OnlinePlayground: Test a Ditto Cloud app without authentication ("Playground mode"). This mode offers no security and must only be used for development.
- SharedKey: A mode where any device is trusted provided they know the secret key. This is a simplistic authentication model normally only suitable for private apps where users and devices are both trusted.
- Manual: A manually-provided certificate identity. This accepts a base64-encoded bundle.