*
* Dispatches print and data storage requests to the appropriate handler.
*
- * With each request, if a connection to Hatch is established, the
- * request is relayed. If a connection has not been attempted, an
+ * With each top-level request, if a connection to Hatch is established,
+ * the request is relayed. If a connection has not been attempted, an
* attempt is made then the request is handled. If Hatch is known to be
* inaccessible, requests are routed to local handlers.
*
+ * Most handlers also provide direct remote and local variants to the
+ * application can decide to which to use as needed.
+ *
* Printing is handled locally with an egPrintContainer whose contents
* are made visible during printing using CSS print media.
*
- * Storage requests are handled by $window.localStorage.
+ * Local storage requests are handled by $window.localStorage.
*
- * Note that all requests return promises, since any request may be
- * subject to aschronous processing by Hatch.
+ * Note that all top-level and remote requests return promises. All
+ * local requests return immediate values, since local requests are
+ * never asynchronous.
*
*/
angular.module('egCoreMod')
if (service.hatchAvailable === false) { // Hatch is closed
msg.deferred.reject(msg);
- //service.pending.push(msg);
- //service.handleRequestsLocally();
} else if (service.hatchAvailable === true) { // Hatch is open
// Hatch is known to be open