de.steeringbehaviors.simulation.xml
Class SteeringFactory

java.lang.Object
  extended by de.steeringbehaviors.simulation.xml.SteeringFactory

public class SteeringFactory
extends java.lang.Object

class SteeringFactory Loads a xml file an generates a SteeringBehaviors object model


Constructor Summary
SteeringFactory(java.lang.Object parent)
          Constructor
 
Method Summary
 void createScene(java.lang.String filename)
          Creates a scene as SteeringBehaviors model from the specified filename
 void createSteering()
          Sets global attributes, like scenesize or the background image
 void createVehicle()
          Creates a vehicle
 Geometrie getBackground()
          Returns the background object
 java.util.Vector getObstacles()
          Returns a list of all obstacles of the scene
 int getSceneHeight()
          Returns the scene height
 int getSceneWidth()
          Returns the scene width
 java.util.Vector getVehicles()
          Returns a list of all vehicles of the scene
 void setNeighborhood(Neighborhood n)
          Sets the Neighborhood
 void setObstacles(java.util.Vector obstacles)
          Sets the list of obtacles
 void setVehicles(java.util.Vector vehicles)
          Sets the list of vehicles
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SteeringFactory

public SteeringFactory(java.lang.Object parent)
Constructor

Method Detail

getBackground

public Geometrie getBackground()
Returns the background object

Returns:
Background geometrie object

getVehicles

public java.util.Vector getVehicles()
Returns a list of all vehicles of the scene

Returns:
List of vehicles

getObstacles

public java.util.Vector getObstacles()
Returns a list of all obstacles of the scene

Returns:
List of obstacles

getSceneWidth

public int getSceneWidth()
Returns the scene width

Returns:
The scene width

getSceneHeight

public int getSceneHeight()
Returns the scene height

Returns:
The scene height

setVehicles

public void setVehicles(java.util.Vector vehicles)
Sets the list of vehicles

Parameters:
vehicles - Vehicle list to use

setObstacles

public void setObstacles(java.util.Vector obstacles)
Sets the list of obtacles

Parameters:
obstacles - Obstacle list to use

setNeighborhood

public void setNeighborhood(Neighborhood n)
Sets the Neighborhood

Parameters:
n - The Neighborhood to use

createScene

public void createScene(java.lang.String filename)
Creates a scene as SteeringBehaviors model from the specified filename

Parameters:
filename - Filename of the xml file using for the scene creation

createSteering

public void createSteering()
Sets global attributes, like scenesize or the background image


createVehicle

public void createVehicle()
Creates a vehicle