demo/mobile/src/app/sync/syncGlobalManager.js
function createGlobalManagerService($http, authService) {
  //Init the sync service
  syncNetworkInit.initSync($http).catch(function(error) {
    logger.getLogger().error("Failed to initialize sync", error);
  });
  var syncManager = new SyncManager();
  authService.setLoginListener(function(profileData) {
    syncManager.syncManagerMap(profileData);
  });

  authService.setLogoutListener(function() {
    syncManager.removeManagers();
  });
  return syncManager;
}
function createGlobalManagerService($http, authService) {
  //Init the sync service
  syncNetworkInit.initSync($http).catch(function(error) {
    logger.getLogger().error("Failed to initialize sync", error);
  });
  var syncManager = new SyncManager();
  authService.setLoginListener(function(profileData) {
    syncManager.syncManagerMap(profileData);
  });

  authService.setLogoutListener(function() {
    syncManager.removeManagers();
  });
  return syncManager;
}
function createGlobalManagerService ( $http , authService ) { //Init the sync service syncNetworkInit . initSync ( $http ) . catch ( function ( error ) { logger . getLogger ( ) . error ( "Failed to initialize sync" , error ) ; } ) ; var syncManager = new SyncManager ( ) ; authService . setLoginListener ( function ( profileData ) { syncManager . syncManagerMap ( profileData ) ; } ) ; authService . setLogoutListener ( function ( ) { syncManager . removeManagers ( ) ; } ) ; return syncManager ; }
Service to manage init all of the sync data sets.

@param $q
@returns {{}}
@constructor
Service to manage init all of the sync data sets .