edu.bonn.cs.iv.bonnmotion
Class RandomSpeedBase

java.lang.Object
  extended by edu.bonn.cs.iv.bonnmotion.App
      extended by edu.bonn.cs.iv.bonnmotion.Scenario
          extended by edu.bonn.cs.iv.bonnmotion.RandomSpeedBase
All Implemented Interfaces:
Model, ScenarioLink
Direct Known Subclasses:
RandomWaypoint, RPGM

public abstract class RandomSpeedBase
extends Scenario

Base class for those models that needs three parameters minimum speed, maximum speed maximum pause time.


Field Summary
protected  double maxpause
           
protected  double maxspeed
           
protected  double minspeed
           
 
Fields inherited from class edu.bonn.cs.iv.bonnmotion.Scenario
aField, aFieldParams, buildings, circular, duration, ignore, isTransition, modelName, node, predecessorScenario, rand, randomSeed, transitionMode, x, y
 
Fields inherited from interface edu.bonn.cs.iv.bonnmotion.ScenarioLink
LINKMODE_FAST, LINKMODE_MOVE
 
Constructor Summary
RandomSpeedBase()
           
RandomSpeedBase(int nodes, double x, double y, double duration, double ignore, long randomSeed, double minspeed, double maxspeed, double maxpause)
           
 
Method Summary
protected  boolean parseArg(char key, java.lang.String val)
           
protected  boolean parseArg(java.lang.String key, java.lang.String val)
           
static void printHelp()
           
 void write(java.lang.String basename, java.lang.String[] params)
          Writes the generated scenario and the scenario parameters to files.
 
Methods inherited from class edu.bonn.cs.iv.bonnmotion.Scenario
cut, getBuilding, getDuration, getIgnore, getModelName, getNode, getNode, getRandomSeed, getX, getY, go, nodeCount, paramFromFile, paramFromFile, postGeneration, preGeneration, randomNextDouble, randomNextGaussian, randomNextPosition, randomNextPosition, read, setDuration, setModelName, setNode, transition, transitionWaypointFast, transitionWaypointMove, write
 
Methods inherited from class edu.bonn.cs.iv.bonnmotion.App
exceptionHandler, openPrintWriter, parse, parseArg, parseDoubleArray, parseIntArray, parseStringArray, stringArrayConcat
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

minspeed

protected double minspeed

maxspeed

protected double maxspeed

maxpause

protected double maxpause
Constructor Detail

RandomSpeedBase

public RandomSpeedBase(int nodes,
                       double x,
                       double y,
                       double duration,
                       double ignore,
                       long randomSeed,
                       double minspeed,
                       double maxspeed,
                       double maxpause)

RandomSpeedBase

public RandomSpeedBase()
Method Detail

write

public void write(java.lang.String basename,
                  java.lang.String[] params)
           throws java.io.FileNotFoundException,
                  java.io.IOException
Description copied from class: Scenario
Writes the generated scenario and the scenario parameters to files.

Overrides:
write in class Scenario
Parameters:
basename - Basename of the output files
Throws:
java.io.FileNotFoundException
java.io.IOException

parseArg

protected boolean parseArg(char key,
                           java.lang.String val)
Overrides:
parseArg in class Scenario

parseArg

protected boolean parseArg(java.lang.String key,
                           java.lang.String val)
Overrides:
parseArg in class Scenario

printHelp

public static void printHelp()