vendor/backbone-relational-0.6.0.js
function( attributes, options ) {
			var model = this;

			// 'build' is a possible entrypoint; it's possible no model hierarchy has been determined yet.
			this.initializeModelHierarchy();

			// Determine what type of (sub)model should be built if applicable.
			// Lookup the proper subModelType in 'this._subModels'.
			if ( this._subModels && this.prototype.subModelTypeAttribute in attributes ) {
				var subModelTypeAttribute = attributes[ this.prototype.subModelTypeAttribute ];
				var subModelType = this._subModels[ subModelTypeAttribute ];
				if ( subModelType ) {
					model = subModelType;
				}
			}
			
			return new model( attributes, options );
		}
function( attributes, options ) {
			var model = this;

			// 'build' is a possible entrypoint; it's possible no model hierarchy has been determined yet.
			this.initializeModelHierarchy();

			// Determine what type of (sub)model should be built if applicable.
			// Lookup the proper subModelType in 'this._subModels'.
			if ( this._subModels && this.prototype.subModelTypeAttribute in attributes ) {
				var subModelTypeAttribute = attributes[ this.prototype.subModelTypeAttribute ];
				var subModelType = this._subModels[ subModelTypeAttribute ];
				if ( subModelType ) {
					model = subModelType;
				}
			}
			
			return new model( attributes, options );
		}
function ( attributes , options ) { var model = this ; // 'build' is a possible entrypoint; it's possible no model hierarchy has been determined yet. this . initializeModelHierarchy ( ) ; // Determine what type of (sub)model should be built if applicable. // Lookup the proper subModelType in 'this._subModels'. if ( this . _subModels && this . prototype . subModelTypeAttribute in attributes ) { var subModelTypeAttribute = attributes [ this . prototype . subModelTypeAttribute ] ; var subModelType = this . _subModels [ subModelTypeAttribute ] ; if ( subModelType ) { model = subModelType ; } } return new model ( attributes , options ) ; }
Create a 'Backbone.Model' instance based on 'attributes'.
@param {Object} attributes
@param {Object} [options]
@return {Backbone.Model}
Create a Backbone . Model instance based on attributes .