IDLFileHandler

IDLFileHandler

new IDLFileHandler()

The handler, an instance of which is created for every instance of GQLBase.
The handler manages the fetching and decoding of files bearing the IDL
schema associated with the class represented by this instance of GQLBase.

Source:

Classes

⎆⠀constructor

Methods

⌾⠀getFile() → {Buffer|null}

Loads the calculated file determined by the decoding of the meaning of
the Symbol returned by the SCHEMA property of the instance supplied to
the IDLFileHandler upon creation.

Source:
Returns:
Type:
Buffer | null

returns the Buffer containing the file base IDL
schema or null if none was found or a direct string schema is returned
by the SCHEMA property

⌾⠀getSchema() → {string|null}

If getFile() returns a Buffer, this is the string representation of the
underlying file contents. As a means of validating the contents of the
file, the string contents are parsed into an AST and back to a string.

Source:
Returns:
Type:
string | null

the string contents of the Buffer containing the
file based IDL schema.

⌾⠀getSyntaxTree() → {SyntaxTree|null}

If getFile() returns a Buffer, the string contents are passed to a new
instance of SyntaxTree which parses this into an AST for manipulation.

Source:
Returns:
Type:
SyntaxTree | null

a SyntaxTree instance constructed from the IDL
schema contents loaded from disk. Null is returned if a calculated path
cannot be found; always occurs when SCHEMA returns a string.