Package org.sim0mq.federatestarter
Class FederateStarter
java.lang.Object
org.sim0mq.federatestarter.FederateStarter
The FederateStarter start listening on the given port for messages to start components. Report back via the call-back port on
the status of the started components. If necessary, the FederateStarter can also forcefully stop a started (sub)process.
Copyright (c) 2016-2024 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See Sim0MQ License.
- Author:
- Alexander Verbraeck
-
Field Summary
Modifier and TypeFieldDescriptionthe running programs this FederateStarter started.(package private) final Properties
the software properties. -
Constructor Summary
ConstructorDescriptionFederateStarter
(int fsPort, Properties softwareProperties, int startPort, int endPort, boolean modelController) -
Method Summary
Modifier and TypeMethodDescriptionboolean
static void
Start listening on the given port for messages to start components.
-
Field Details
-
runningProcessMap
the running programs this FederateStarter started. The String identifies the process (e.g., a UUID or a model id). -
softwareProperties
the software properties.
-
-
Constructor Details
-
FederateStarter
public FederateStarter(int fsPort, Properties softwareProperties, int startPort, int endPort, boolean modelController) throws Sim0MQException, SerializationException - Parameters:
fsPort
- the port number to listen onsoftwareProperties
- the software properties to usestartPort
- first port to be used for the models, inclusiveendPort
- last port to be used for the models, inclusivemodelController
- does the Federate Starter concern models with an MC or just processes?- Throws:
Sim0MQException
- on errorSerializationException
- on error
-
-
Method Details
-
isModelController
public boolean isModelController()- Returns:
- modelController
-
main
Start listening on the given port for messages to start components. Report back via the call-back port on the status of the started components. If necessary, the FederateStarter can also forcefully stop a started (sub)process.- Parameters:
args
- the federation name and port on which the FederateStarter is listening- Throws:
Sim0MQException
- on errorSerializationException
- on error
-