session

session

Contains constants and functions for a Griffon Session.

The structure for a Griffon Session is as follows:

{
  annotations: <array>,
  link: <string>,
  firstName: <string>,
  lastName: <string>,
  name: <string>,
  uuid: <string>,
}
Source:

Members

(static, constant) group

A grouping for this object

Source:

(static, constant) label

A label that can be used when describing this object

Source:

(static, constant) parentDepth

Describes the number of parents this object has based off schema references. When checking for matches for example, we want to use a schema that is more specific over a more generic schema

Source:

(static, constant) path :string

Paths for the keys on a Griffon Session

Properties:
Name Type Description
annotations string

Array of SessionAnnotation objects.
Path is annotations.

link string

The base url of the application connected to this session.
Path is link.

firstName string

The first name of the user who created the session.
Path is firstName.

lastName string

The last name of the user who created the session.
Path is lastName.

name string

The name of the session.
Path is name.

sessionId string

Uniquely identifies each session.
Path is uuid.

Source:

Methods

(static) get(alias, data) → {*}

Retrieves a value from the object. You can provide either a path or an alias.

Parameters:
Name Type Description
alias string

Path or alias

data *

Data to search

Source:

(static) getAnnotations(source) → {Array}

Returns the annotations from the Griffon Session. This is the array of SessionAnnotation objects.

Path is annotations.

Parameters:
Name Type Description
source object

The Griffon Session instance

Source:

(static) getFirstName(source) → {string}

Returns the firstName from the Griffon Session. This is the the first name of the user who created the session.

Path is firstName.

Parameters:
Name Type Description
source object

The Griffon Session instance

Source:

(static) getLastName(source) → {string}

Returns the lastName from the Griffon Session. This is the the last name of the user who created the session.

Path is lastName.

Parameters:
Name Type Description
source object

The Griffon Session instance

Source:

Returns the link from the Griffon Session. This is the the base url of the application connected to this session.

Path is link.

Parameters:
Name Type Description
source object

The Griffon Session instance

Source:

(static) getName(source) → {string}

Returns the name from the Griffon Session. This is the the name of the session.

Path is name.

Parameters:
Name Type Description
source object

The Griffon Session instance

Source:

(static) getSessionId(source) → {string}

Returns the sessionId from the Griffon Session. This is the uniquely identifies each session.

Path is uuid.

Parameters:
Name Type Description
source object

The Griffon Session instance

Source:

(static) make(…input) → {object}

Generates a Griffon Session with the const values set. Can be useful in testing. Can provide additional data by providing a flat object of paths and values.

Parameters:
Name Type Attributes Description
input function <repeatable>

Overrides

Source:

(static) mock(…input) → {object}

Generates a Griffon Session with some default values set. Can be useful in testing. Can override defaults and provide additional data by providing a flat object of paths and values.

Parameters:
Name Type Attributes Description
input function <repeatable>

Overrides

Source: