Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 /*
  * Copyright 2013 Christophe Pollet
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
  * You may obtain a copy of the License at
  *
  *     http://www.apache.org/licenses/LICENSE-2.0
  *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package net.cpollet.jixture.fixtures;
A simple fixture that loads a collection of entities.

Author(s):
Christophe Pollet
	private List<Objectobjects;

Parameters:
objectsToAdd a list of entities to load into database. The entities can be instances of different mapping classes, targeting different tables. Objects are loaded in order.
	public MappingFixture(Object... objectsToAdd) {
		super();
		addObjects(objectsToAdd);
	}

Add entities to the current list of entities to load.

Parameters:
objectsToAdd the list of entities to add. Objects are loaded in order.
Returns:
the current fixture instance.
	public Fixture addObjects(Object... objectsToAdd) {
		if (0 < objectsToAdd.length) {
			Collections.addAll(objectsToAdd);
		}
		return this;
	}

Returns all entities that this fixture has to load into database.

Returns:
the list of entities to load.
	public List<ObjectgetObjects() {
		return ;
	}
New to GrepCode? Check out our FAQ X