|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectgridiq.simulation.SimulationController
public class SimulationController
This component provides a single interface to the GridIQ system by implementing the Facade design pattern. The SimulationController maintains the current time step of the simulation and interacts with other components in the system to load project and configuration files, execute simulations for the appropriate number of steps, and persist simulation results.
Constructor Summary | |
---|---|
SimulationController()
Creates a new simulation controller, instantiating default classes of NetworkParser , PowerFlowSolver , AgentManager ,
ResultsWriter , and DisturbanceSet to be used for the
simulation. |
Method Summary | |
---|---|
void |
close()
Terminates the agent platform and ends the simulation. |
int |
executeNextTimeStep()
Runs a single time step, executing both power analysis and agent execution phases. |
Network |
getNetwork()
Gets the current network model for the simulation. |
java.lang.String |
getOctavePath()
Gets the Octave path used for the simulation. |
java.lang.String |
getPsatPath()
Gets the path to the PSAT library. |
void |
initialise(Project proj)
Initialises the simulation according to the given project configuration. |
void |
run()
Runs all remaining time steps in the simulation. |
void |
runAgents()
Notifies agents of the most recent simulation results. |
SimResults |
runPowerAnalysis()
Runs a power flow analysis. |
void |
setDisturbanceSet(DisturbanceSet disturbanceSet)
Sets the DisturbanceSet class to use for the simulation. |
void |
setDisturbanceSet(java.lang.String name)
Sets the DisturbanceSet class to use for the simulation. |
void |
setOctavePath(java.lang.String octavePath)
Sets the Octave path used for the simulation. |
void |
setPsatPath(java.lang.String psatPath)
Sets the path to the PSAT library used for the simulation. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SimulationController() throws java.io.IOException
NetworkParser
, PowerFlowSolver
, AgentManager
,
ResultsWriter
, and DisturbanceSet
to be used for the
simulation.
java.io.IOException
Method Detail |
---|
public void initialise(Project proj) throws java.io.IOException, jade.wrapper.StaleProxyException, java.lang.ClassNotFoundException, java.lang.InstantiationException, java.lang.IllegalAccessException
proj
- The project configuration.
java.io.IOException
jade.wrapper.StaleProxyException
java.lang.ClassNotFoundException
java.lang.InstantiationException
java.lang.IllegalAccessException
public Network getNetwork()
public void run() throws java.lang.Exception
java.lang.Exception
public int executeNextTimeStep() throws java.lang.Exception
java.lang.Exception
public SimResults runPowerAnalysis() throws java.lang.Exception
java.lang.Exception
public void runAgents() throws jade.wrapper.StaleProxyException, java.lang.InterruptedException
jade.wrapper.StaleProxyException
java.lang.InterruptedException
public void close()
public java.lang.String getPsatPath()
public void setPsatPath(java.lang.String psatPath)
psatPath
- public java.lang.String getOctavePath()
public void setOctavePath(java.lang.String octavePath)
octavePath
- public void setDisturbanceSet(java.lang.String name) throws java.lang.ClassNotFoundException, java.lang.InstantiationException, java.lang.IllegalAccessException
DisturbanceSet
class to use for the simulation.
name
- The name of the class of the DisturbanceSet to instantiate.
java.lang.ClassNotFoundException
java.lang.InstantiationException
java.lang.IllegalAccessException
public void setDisturbanceSet(DisturbanceSet disturbanceSet)
DisturbanceSet
class to use for the simulation.
disturbanceSet
- The DisturbanceSet instance to use.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |