UNPKG

knowhow-server

Version:

A personal workflow engine that can manage and use any network connected host

116 lines (115 loc) 11.6 kB
<a href="http://github.com/angular/angular.js/tree/v1.2.9/src/loader.js#L3" class="view-source btn btn-action"><i class="icon-zoom-in"> </i> View source</a><a href="http://github.com/angular/angular.js/edit/master/src/loader.js" class="improve-docs btn btn-primary"><i class="icon-edit"> </i> Improve this doc</a><h1><code ng:non-bindable="">Module</code> <div><span class="hint">Type in module <code ng:non-bindable="">ng</code> </span> </div> </h1> <div><h2 id="description">Description</h2> <div class="description"><div class="angular-module-page"><p>Interface for configuring angular <a href="api/angular.module"><code>modules</code></a>.</p> </div></div> <div class="member method"><h2 id="methods">Methods</h2> <ul class="methods"><li><h3 id="methods_animation">animation(name, animationFactory)</h3> <div class="animation"><div class="angular-module-animation-page"><p><strong>NOTE</strong>: animations take effect only if the <strong>ngAnimate</strong> module is loaded.</p> <p>Defines an animation hook that can be later used with <a href="api/ngAnimate.$animate">$animate</a> service and directives that use this service.</p> <pre class="prettyprint linenums"> module.animation('.animation-name', function($inject1, $inject2) { return { eventName : function(element, done) { //code to run the animation //once complete, then run done() return function cancellationFunction(element) { //code to cancel the animation } } } }) </pre> <p>See <a href="api/ngAnimate.$animateProvider#register">$animateProvider.register()</a> and <a href="api/ngAnimate">ngAnimate module</a> for more information.</p> </div><h5 id="methods_animation_parameters">Parameters</h5><table class="variables-matrix table table-bordered table-striped"><thead><tr><th>Param</th><th>Type</th><th>Details</th></tr></thead><tbody><tr><td>name</td><td><a href="" class="label type-hint type-hint-string">string</a></td><td><div class="angular-module-animation-page"><p>animation name</p> </div></td></tr><tr><td>animationFactory</td><td><a href="" class="label type-hint type-hint-function">Function</a></td><td><div class="angular-module-animation-page"><p>Factory function for creating new instance of an animation.</p> </div></td></tr></tbody></table></div> </li> <li><h3 id="methods_config">config(configFn)</h3> <div class="config"><div class="angular-module-config-page"><p>Use this method to register work which needs to be performed on module loading.</p> </div><h5 id="methods_config_parameters">Parameters</h5><table class="variables-matrix table table-bordered table-striped"><thead><tr><th>Param</th><th>Type</th><th>Details</th></tr></thead><tbody><tr><td>configFn</td><td><a href="" class="label type-hint type-hint-function">Function</a></td><td><div class="angular-module-config-page"><p>Execute this function on module load. Useful for service configuration.</p> </div></td></tr></tbody></table></div> </li> <li><h3 id="methods_constant">constant(name, object)</h3> <div class="constant"><div class="angular-module-constant-page"><p>Because the constant are fixed, they get applied before other provide methods. See <a href="api/AUTO.$provide#constant"><code>$provide.constant()</code></a>.</p> </div><h5 id="methods_constant_parameters">Parameters</h5><table class="variables-matrix table table-bordered table-striped"><thead><tr><th>Param</th><th>Type</th><th>Details</th></tr></thead><tbody><tr><td>name</td><td><a href="" class="label type-hint type-hint-string">string</a></td><td><div class="angular-module-constant-page"><p>constant name</p> </div></td></tr><tr><td>object</td><td><a href="" class="label type-hint type-hint-object">*</a></td><td><div class="angular-module-constant-page"><p>Constant value.</p> </div></td></tr></tbody></table></div> </li> <li><h3 id="methods_controller">controller(name, constructor)</h3> <div class="controller"><div class="angular-module-controller-page"><p>See <a href="api/ng.$controllerProvider#register"><code>$controllerProvider.register()</code></a>.</p> </div><h5 id="methods_controller_parameters">Parameters</h5><table class="variables-matrix table table-bordered table-striped"><thead><tr><th>Param</th><th>Type</th><th>Details</th></tr></thead><tbody><tr><td>name</td><td><a href="" class="label type-hint type-hint-string">string</a><a href="" class="label type-hint type-hint-object">Object</a></td><td><div class="angular-module-controller-page"><p>Controller name, or an object map of controllers where the keys are the names and the values are the constructors.</p> </div></td></tr><tr><td>constructor</td><td><a href="" class="label type-hint type-hint-function">Function</a></td><td><div class="angular-module-controller-page"><p>Controller constructor function.</p> </div></td></tr></tbody></table></div> </li> <li><h3 id="methods_directive">directive(name, directiveFactory)</h3> <div class="directive"><div class="angular-module-directive-page"><p>See <a href="api/ng.$compileProvider#methods_directive"><code>$compileProvider.directive()</code></a>.</p> </div><h5 id="methods_directive_parameters">Parameters</h5><table class="variables-matrix table table-bordered table-striped"><thead><tr><th>Param</th><th>Type</th><th>Details</th></tr></thead><tbody><tr><td>name</td><td><a href="" class="label type-hint type-hint-string">string</a><a href="" class="label type-hint type-hint-object">Object</a></td><td><div class="angular-module-directive-page"><p>Directive name, or an object map of directives where the keys are the names and the values are the factories.</p> </div></td></tr><tr><td>directiveFactory</td><td><a href="" class="label type-hint type-hint-function">Function</a></td><td><div class="angular-module-directive-page"><p>Factory function for creating new instance of directives.</p> </div></td></tr></tbody></table></div> </li> <li><h3 id="methods_factory">factory(name, providerFunction)</h3> <div class="factory"><div class="angular-module-factory-page"><p>See <a href="api/AUTO.$provide#factory"><code>$provide.factory()</code></a>.</p> </div><h5 id="methods_factory_parameters">Parameters</h5><table class="variables-matrix table table-bordered table-striped"><thead><tr><th>Param</th><th>Type</th><th>Details</th></tr></thead><tbody><tr><td>name</td><td><a href="" class="label type-hint type-hint-string">string</a></td><td><div class="angular-module-factory-page"><p>service name</p> </div></td></tr><tr><td>providerFunction</td><td><a href="" class="label type-hint type-hint-function">Function</a></td><td><div class="angular-module-factory-page"><p>Function for creating new instance of the service.</p> </div></td></tr></tbody></table></div> </li> <li><h3 id="methods_filter">filter(name, filterFactory)</h3> <div class="filter"><div class="angular-module-filter-page"><p>See <a href="api/ng.$filterProvider#register"><code>$filterProvider.register()</code></a>.</p> </div><h5 id="methods_filter_parameters">Parameters</h5><table class="variables-matrix table table-bordered table-striped"><thead><tr><th>Param</th><th>Type</th><th>Details</th></tr></thead><tbody><tr><td>name</td><td><a href="" class="label type-hint type-hint-string">string</a></td><td><div class="angular-module-filter-page"><p>Filter name.</p> </div></td></tr><tr><td>filterFactory</td><td><a href="" class="label type-hint type-hint-function">Function</a></td><td><div class="angular-module-filter-page"><p>Factory function for creating new instance of filter.</p> </div></td></tr></tbody></table></div> </li> <li><h3 id="methods_provider">provider(name, providerType)</h3> <div class="provider"><div class="angular-module-provider-page"><p>See <a href="api/AUTO.$provide#provider"><code>$provide.provider()</code></a>.</p> </div><h5 id="methods_provider_parameters">Parameters</h5><table class="variables-matrix table table-bordered table-striped"><thead><tr><th>Param</th><th>Type</th><th>Details</th></tr></thead><tbody><tr><td>name</td><td><a href="" class="label type-hint type-hint-string">string</a></td><td><div class="angular-module-provider-page"><p>service name</p> </div></td></tr><tr><td>providerType</td><td><a href="" class="label type-hint type-hint-function">Function</a></td><td><div class="angular-module-provider-page"><p>Construction function for creating new instance of the service.</p> </div></td></tr></tbody></table></div> </li> <li><h3 id="methods_run">run(initializationFn)</h3> <div class="run"><div class="angular-module-run-page"><p>Use this method to register work which should be performed when the injector is done loading all modules.</p> </div><h5 id="methods_run_parameters">Parameters</h5><table class="variables-matrix table table-bordered table-striped"><thead><tr><th>Param</th><th>Type</th><th>Details</th></tr></thead><tbody><tr><td>initializationFn</td><td><a href="" class="label type-hint type-hint-function">Function</a></td><td><div class="angular-module-run-page"><p>Execute this function after injector creation. Useful for application initialization.</p> </div></td></tr></tbody></table></div> </li> <li><h3 id="methods_service">service(name, constructor)</h3> <div class="service"><div class="angular-module-service-page"><p>See <a href="api/AUTO.$provide#service"><code>$provide.service()</code></a>.</p> </div><h5 id="methods_service_parameters">Parameters</h5><table class="variables-matrix table table-bordered table-striped"><thead><tr><th>Param</th><th>Type</th><th>Details</th></tr></thead><tbody><tr><td>name</td><td><a href="" class="label type-hint type-hint-string">string</a></td><td><div class="angular-module-service-page"><p>service name</p> </div></td></tr><tr><td>constructor</td><td><a href="" class="label type-hint type-hint-function">Function</a></td><td><div class="angular-module-service-page"><p>A constructor function that will be instantiated.</p> </div></td></tr></tbody></table></div> </li> <li><h3 id="methods_value">value(name, object)</h3> <div class="value"><div class="angular-module-value-page"><p>See <a href="api/AUTO.$provide#value"><code>$provide.value()</code></a>.</p> </div><h5 id="methods_value_parameters">Parameters</h5><table class="variables-matrix table table-bordered table-striped"><thead><tr><th>Param</th><th>Type</th><th>Details</th></tr></thead><tbody><tr><td>name</td><td><a href="" class="label type-hint type-hint-string">string</a></td><td><div class="angular-module-value-page"><p>service name</p> </div></td></tr><tr><td>object</td><td><a href="" class="label type-hint type-hint-object">*</a></td><td><div class="angular-module-value-page"><p>Service instance object.</p> </div></td></tr></tbody></table></div> </li> </ul> </div> <div class="member property"><h2 id="properties">Properties</h2> <ul class="properties"><li><h3 id="properties_name">name</h3> <div class="name"><h5 id="properties_name_returns">Returns</h5><table class="variables-matrix"><tr><td><a href="" class="label type-hint type-hint-string">string</a></td><td><div class="angular-module-name-page"><p>Name of the module.</p> </div></td></tr></table></div> </li> <li><h3 id="properties_requires">requires</h3> <div class="requires"><div class="angular-module-requires-page"><p>Holds the list of modules which the injector will load before the current module is loaded.</p> </div><h5 id="properties_requires_returns">Returns</h5><table class="variables-matrix"><tr><td><a href="" class="label type-hint type-hint-array">Array.&lt;string&gt;</a></td><td><div class="angular-module-requires-page"><p>List of module names which must be loaded before this module.</p> </div></td></tr></table></div> </li> </ul> </div> </div>