config

package
v0.1.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 9, 2018 License: MIT Imports: 1 Imported by: 2

Documentation

Overview

Package config contains configuration information that is used by the rest of the SDK.

Index

Constants

This section is empty.

Variables

View Source
var C = &Config{
	Backend: backend.NewAuroraBackend(),
}

C is an instance of the above config (with default values). It's exported so that all packages can use it.

Functions

This section is empty.

Types

type Config

type Config struct {
	// AppID is the value to send as the `X-Application-ID` header
	AppID string

	// AppToken is the value to send as the `X-Application-Token` header
	AppToken string

	// DeviceID is the value to send as the `X-Device-ID` header (optional)
	DeviceID string

	// Backend to use for requests (configurable for testing purposes)
	Backend backend.Backend
}

Config configures the parameters that this SDK will use to operate

func (*Config) GetCredentials

func (c *Config) GetCredentials() *backend.Credentials

GetCredentials converts the client's credentials into a struct that gets passed into the backend.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL