Struct hub_sdk::HubSDKConfig [] [src]

pub struct HubSDKConfig {
    pub api: ThingsApi,
    pub connect_api: ConnectApi,
    pub element_file: PathBuf,
    pub geeny_creds_file: PathBuf,
    pub mqtt_cert_path: PathBuf,
    pub mqtt_host: String,
    pub mqtt_port: u16,
}

Configuration structure for a HubSDK instance

Fields

Connection object for the main Things API, e.g., https://labs.geeny.io

Connection object for the authorization API, e.g., https://connect.geeny.io

Path to a file to store information regarding Things/Elements that have been paired with the SDK. This file stores sensitive information such as Certificate Pairs for each device

Path to a file to store information regarding the user currently authorized to use this Hub. This file stores sensitive information such as the username/email of the current user, as well as the current API token used to make device management requests

Path to a folder to store certificates used to connect via MQTT. This folder stores sensitive information, such as private and public key pairs for each device paired with the SDK

The MQTT host to connect to all devices, e.g., mqtt.geeny.io

The MQTT port to connect to all devices, e.g., 8883

Trait Implementations

impl Debug for HubSDKConfig
[src]

[src]

Formats the value using the given formatter. Read more

impl Clone for HubSDKConfig
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

impl Default for HubSDKConfig
[src]

[src]

Create a Configuration Structure for the HubSDK

Example

use hub_sdk::HubSDKConfig;

let sdk_cfg = HubSDKConfig::default();

Auto Trait Implementations

impl Send for HubSDKConfig

impl Sync for HubSDKConfig