lib/associationmanager.js
function getAssociations(instance, ids, callback) {
  instance.db.find({ _id: { $in: ids } }, function(err, associations) {
    for(var cAssociation = 0; cAssociation < associations.length;
        cAssociation++) {
      associations[cAssociation].deviceId = associations[cAssociation]._id;
    }
    callback(err, associations);
  });
}
function getAssociations(instance, ids, callback) {
  instance.db.find({ _id: { $in: ids } }, function(err, associations) {
    for(var cAssociation = 0; cAssociation < associations.length;
        cAssociation++) {
      associations[cAssociation].deviceId = associations[cAssociation]._id;
    }
    callback(err, associations);
  });
}
function getAssociations ( instance , ids , callback ) { instance . db . find ( { _id : { $in : ids } } , function ( err , associations ) { for ( var cAssociation = 0 ; cAssociation < associations . length ; cAssociation ++ ) { associations [ cAssociation ] . deviceId = associations [ cAssociation ] . _id ; } callback ( err , associations ) ; } ) ; }
Retrieve from the database the associations of the given ids
@param {Object} instance The given Chickadee instance.
@param {Array} ids The given ids.
@param {function} callback Function to call on completion.
Retrieve from the database the associations of the given ids