ServiceConfiguration

Structure used to define a service

Members

Functions

load
void load(Json data)

Load configuration from a Json object

Variables

loginTimeoutSeconds
ulong loginTimeoutSeconds;

Login cookie expiration time

name
string name;

The service name

paths
Paths paths;
style
string style;

A custom style file embedded in the auth html files

templates
Templates templates;

Examples

load configuration

auto config = `{
  "name": "demo",
  "style": "some style",
  "loginTimeoutSeconds": 100,
  "paths": {
    "location": "location"
  }
}`.parseJsonString;

ServiceConfiguration configuration;
configuration.load(config);

configuration.name.should.equal("demo");
configuration.style.should.equal("some style");
configuration.loginTimeoutSeconds.should.equal(100);
configuration.paths.location.should.equal("location");

Meta