Home Reference Source
import Incarnate from 'incarnate/src/Incarnate.jsx'
public class | source

Incarnate

Extends:

src/HashMatrix.js~HashMatrix → Incarnate

Manage the lifecycle of application dependencies. Use dependencies as application entry-points and keep track of live changes.

Static Member Summary

Static Public Members
public static
public static

ERRORS: *

public static

STANDARD_DEPENDENCY_NAMES: Object<string>

The names of the dependencies supplied with a standard instance of Incarnate.

Constructor Summary

Public Constructor
public

constructor(subMapDeclaration: SubMapDeclaration)

Member Summary

Public Members
public
public
public
public
public

getDependency(path: Array | string): Incarnate | LifePod | HashMatrix: *

Get a dependency by path.

public
public

strict: boolean

If true, LifePod factories will NOT be called until none of the dependencies are undefined.

public

The map of dependency and subMap declarations.

Private Members
private

Method Summary

Public Methods
public

convertDeclaration(name: *, declaration: {}): *

public

createFromMap(map: {}, creator: *): *

public

createIncarnate(name: *, subMapDeclaration: {}): *

public

createLifePod(name: *, dependencyDeclaration: {}): *

public

getDependenciesFromMap(dependencyMap: {}): *

public

getResolvedPath(path: *): *

The same as getPath but triggers LifePod dependency resolution.

public

async getResolvedPathAsync(path: *, timeoutMS: *): *

The same as getPath but triggers LifePod dependency resolution and waits for a value.

Static Public Members

public static DEFAULT_NAME: * source

public static ERRORS: * source

public static STANDARD_DEPENDENCY_NAMES: Object<string> source

The names of the dependencies supplied with a standard instance of Incarnate.

Public Constructors

public constructor(subMapDeclaration: SubMapDeclaration) source

Params:

NameTypeAttributeDescription
subMapDeclaration SubMapDeclaration

The SubMapDeclaration to be managed.

Public Members

public createGetter: * source

public createInvalidator: * source

public createListener: * source

public createSetter: * source

public getDependency(path: Array | string): Incarnate | LifePod | HashMatrix: * source

Get a dependency by path.

Return:

Incarnate | LifePod | HashMatrix

The dependency.

public hashMatrix: {} source

public strict: boolean source

If true, LifePod factories will NOT be called until none of the dependencies are undefined.

public subMap: Object<DependencyDeclaration|SubMapDeclaration|Incarnate|LifePod|HashMatrix> source

The map of dependency and subMap declarations.

Private Members

private _parsedSubMap: * source

Public Methods

public convertDeclaration(name: *, declaration: {}): * source

Params:

NameTypeAttributeDescription
name *
declaration {}
  • optional
  • default: {}

Return:

*

public createFromMap(map: {}, creator: *): * source

Params:

NameTypeAttributeDescription
map {}
  • optional
  • default: {}
creator *

Return:

*

public createIncarnate(name: *, subMapDeclaration: {}): * source

Params:

NameTypeAttributeDescription
name *
subMapDeclaration {}
  • optional
  • default: {}

Return:

*

public createLifePod(name: *, dependencyDeclaration: {}): * source

Params:

NameTypeAttributeDescription
name *
dependencyDeclaration {}
  • optional
  • default: {}

Return:

*

public getDependenciesFromMap(dependencyMap: {}): * source

Params:

NameTypeAttributeDescription
dependencyMap {}
  • optional
  • default: {}

Return:

*

public getResolvedPath(path: *): * source

The same as getPath but triggers LifePod dependency resolution.

Params:

NameTypeAttributeDescription
path *

Return:

*

public async getResolvedPathAsync(path: *, timeoutMS: *): * source

The same as getPath but triggers LifePod dependency resolution and waits for a value.

Params:

NameTypeAttributeDescription
path *
timeoutMS *

Return:

*