docs: function CollectionResource(/*data, query, InstanceCtor, dataStore*/) {
  
    var args = Array.prototype.slice.call(arguments);
  
    var data = args[0];
    var dataStore = args[args.length - 1];
    var query = null;
    var InstanceCtor = InstanceResource; // Default for generic resource instances.
  
    // Check if query params supplied.
    if (args[1] instanceof Object && !(args[1] instanceof Function)) {
      query = args[1];
    }
  
    // Check if a type-specific resource constructor function was supplied.
    var secondToLastArg = args[args.length - 2];
    if (secondToLastArg instanceof Function && utils.isAssignableFrom(Resource, secondToLastArg)) {
      InstanceCtor = secondToLastArg;
    }
  
    // Convert raw items array (array of objects) to an array of Instance Resources.
    if (data && data.hasOwnProperty('items') && data.items.length > 0) {
      data.items = ensureInstanceResources(data.items, InstanceCtor, dataStore);
    }
  
    CollectionResource.super_.apply(this, [data, dataStore]);
  
    Object.defineProperty(this, 'instanceConstructor', {
      get: function getInstanceConstructor() {
        return InstanceCtor;
      },
      set: function setInstanceConstructor(TheInstanceCtor) {
        InstanceCtor = TheInstanceCtor;
      }
    });
    this.instanceConstructor = InstanceCtor;
  
    Object.defineProperty(this, 'query', {
      get: function getQuery() {
        return query;
      },
      set: function setQuery(aQuery) {
        query = aQuery;
      }
    });
    this.query = query;
  }