Chiχ Loader
This is the base component loader for Chiχ.
χio uses node definitions to describe each of it's components.
The loader takes care from loading these definitions and caching them.
On top of the base loaders there are loaders which load the definitions from a remote server or from the file system.
The base loader accepts definitions added manually.
Definitions are indexed by provider url, but the manual loader uses '@' to indicate the definitions are local.
Example usage:
var Loader = ; var loader = ; loader; // retrieve a node definitions from a providerloader; // Checks whether the definition is availableloader; // true // Given a node and it's map, will try and load the (remote) node.// TODO: Explain provider structure within a maploader;
collecting dependencies
It's also the loaders job to collect the dependencies needed to run a graph. This is rather simple if a graph only contains non-composite nodes, but quickly becomes more complex when subgraphs are used and the number of subgraphs are unknown. The loader keeps track of which requires are needed.