Global

Members

AsyncFunctionExecutionError

Denotes more sepecifically that the evaluation of the function invoked
occurred when running a known asynchronous function rather than a standard
synchronous version.

Source:

(constant) CHECK_API_DOCS :Symbol

The CHECK_API_DOCS Symbol is part of the CHECKLIST for a constructed
GQLBase extended class. It denotes that the class has had its api docs
defined, processed and setup on the class in a way that it will be
picked up in the build lifecycle.

Source:
Type:
  • Symbol

(constant) CHECK_RESOLVERS :Symbol

The CHECK_RESOLVERS Symbol is part of the CHECKLIST for a constructed
GQLBase extended class. It denotes that the class has had its instance
field resolvers as well as its static Query, Mutation and Subscription
resolvers injected and defined.

Source:
Type:
  • Symbol

(constant) CHECK_SCHEMA :Symbol

The CHECK_SCHEMA Symbol is part of the CHECKLIST for a constructed
GQLBase extended class. It denotes that the class has had its SCHEMA
getter defined.

Source:
Type:
  • Symbol

(constant) CHECKLIST :Symbol

The CHECKLIST Symbol is used as a storage key in the metadata staging
area for each of the GQLBase extended classes. In the LatticeFactory
it is used to determine where in the flow of construction the class
currently is.

Source:
Type:
  • Symbol

FunctionExecutionError

The FunctionExecutionError denotes that the error was invoked
during a runtime evaluation of a function

Source:

types :Array.<String>

A getter that retrieves the array of direct types

Source:
Type:
  • Array.<String>

Methods

applyTags(Class, addTags, fieldName, descriptor)

When applying multiple property getters and setters, knowing some info
about what was applied elsewhere can be important. "Tags" can be applied
that store the fieldName and descriptor applied via one of these decorators.

Multiple "tags" are supported to allow for detecting the difference between
decorators applied by the developer using lattice and something auto
generated such as auto-props.

Source:
Parameters:
Name Type Description
Class GQLBase

an instance of GQLBase to apply the tags tp

addTags Array.<(string|Symbol)>

an array of Symbols or strings to be
wrapped in Symbols that will be used as tag keys

fieldName string

the name of the field being decorated

descriptor Object

the JavaScript descriptor object to associate
with this tagged field.

getChecklist(Class) → {Object}

Peeks into the metadata storage area of a given GQLBase extended
class and fetches the factory checklist if one exists.

Source:
Parameters:
Name Type Description
Class function

a reference to the GQLBase class to peek in

Returns:
Type:
Object

an object setup with at least three booleans keyed by
the constants CHECK_SCHEMA, CHECK_RESOLVERS, and CHECK_API_DOCS or null
if none exists

hasChecklist(Class, …items) → {Boolean}

This function, when invoked with only a class will return true if the
Class has a defined checklist. If one ore more CHECKLIST symbols are
passed, the function will only return true if all the supplied symbols
are set to truthy values.

Source:
Parameters:
Name Type Attributes Description
Class function

a reference to the GQLBase class to set

items Array.<Symbol> <repeatable>

any of CHECK_SCHEMA, CHECK_RESOLVERS, or
CHECK_API_DOCS

Returns:
Type:
Boolean

true if the checklist and/or all items are true and
present.

newChecklist(Class)

Injects and creates a new CHECKLIST object on the supplied GQLBase
extended class. All items are installed and set to false.

Source:
Parameters:
Name Type Description
Class function

a reference to the GQLBase class to set

setChecklist(Class, item, value)

Obtains the checklist from the supplied GQLBase extended class. If the
class has a checklist, its checklist item is set to true or the boolean
value specified.

Source:
Parameters:
Name Type Default Description
Class function

a reference to the GQLBase class to set

item Symbol

one of CHECK_SCHEMA, CHECK_RESOLVERS, or
CHECK_API_DOCS

value Boolean true

the value for the checklist item to set