code: function() {
        if (_.isUndefined(this.ids)) {
          throw new Error('Torso Data Behavior constructed without a way to identify the ids for this data.  Please define either id, ids.');
        }
  
        var idsIsArray = _.isArray(this.ids);
        var idsIsSingleId = _.isString(this.ids) || _.isNumber(this.ids);
        var idsIsFunction = _.isFunction(this.ids);
        var idsIsObjectWithStringProperty = _.isString(this.ids.property);
        var idsIsObject = _.isObject(this.ids);
        var idsIsValid = idsIsArray || idsIsSingleId || idsIsFunction || idsIsObjectWithStringProperty;
        if (!idsIsValid && idsIsObject) {
          throw new Error('Data Behavior ids invalid definition.  It is an object, but the property field is not defined or is not a string: ' + JSON.stringify(this.ids));
        } else if (!idsIsValid) {
          throw new Error('Data Behavior ids invalid definition.  Not a string, number, object, array or function: ' + JSON.stringify(this.ids));
        }
  
        if (idsIsObjectWithStringProperty) {
          var propertyNameContainsIdContainer = containsContainerDefinition(this.ids.property);
          var hasIdContainerProperty = !_.isUndefined(this.ids.idContainer);
  
          if (hasIdContainerProperty && propertyNameContainsIdContainer) {
            throw new Error('Data Behavior ids invalid definition.  Id container defined on both ids.property and ids.idContainer: ', JSON.stringify(this.ids));
          }
        }
      }
docs: Validates that the ids property is valid and if not throws an error describing why its not valid.
  A side effect of this method is copying id into the ids location (if id is set).  Ids is what is used by the rest of the code.
  This is done as part of validation because we first validate that both are not set.
  @method __normalizeAndValidateIds
  @private