Simulation engine.
This class is an interface to the simulation engine.
- Examples:
- examples/s4u/launching/s4u_launching.cpp, and examples/s4u/mutex/s4u_mutex.cpp.
#include <engine.hpp>
§ Engine()
simgrid::s4u::Engine::Engine |
( |
int * |
argc, |
|
|
char ** |
argv |
|
) |
| |
Constructor, taking the command line parameters of your main function.
§ shutdown()
void simgrid::s4u::Engine::shutdown |
( |
| ) |
|
|
static |
Finalize the default engine and all its dependencies.
§ loadPlatform()
void simgrid::s4u::Engine::loadPlatform |
( |
const char * |
platf | ) |
|
§ registerFunction() [1/3]
void simgrid::s4u::Engine::registerFunction |
( |
const char * |
name, |
|
|
int(*)(int, char **) |
code |
|
) |
| |
§ registerDefault()
void simgrid::s4u::Engine::registerDefault |
( |
int(*)(int, char **) |
code | ) |
|
Registers a function as the default main function of actors.
It will be used as fallback when the function requested from the deployment file was not registered. It is used for trace-based simulations (see examples/msg/actions).
§ loadDeployment()
void simgrid::s4u::Engine::loadDeployment |
( |
const char * |
deploy | ) |
|
§ run()
void simgrid::s4u::Engine::run |
( |
| ) |
|
§ getClock()
double simgrid::s4u::Engine::getClock |
( |
| ) |
|
|
static |
Retrieve the simulation time.
§ instance()
Engine * simgrid::s4u::Engine::instance |
( |
| ) |
|
|
static |
Retrieve the engine singleton.
§ netRoot()
Retrieve the root netzone, containing all others.
§ netzoneByNameOrNull()
NetZone * simgrid::s4u::Engine::netzoneByNameOrNull |
( |
const char * |
name | ) |
|
Retrieve the netzone of the given name (or nullptr if not found)
Retrieve the NetZone of the given name (or nullptr if not found)
§ netcardByNameOrNull()
Retrieve the netcard of the given name (or nullptr if not found)
§ netcardList()
Fill the provided vector with all existing netcards.
§ netcardRegister()
Register a new netcard to the system.
§ netcardUnregister()
Unregister a given netcard.
§ registerFunction() [2/3]
template<class F >
void simgrid::s4u::Engine::registerFunction |
( |
const char * |
name | ) |
|
|
inline |
§ registerFunction() [3/3]
template<class F >
void simgrid::s4u::Engine::registerFunction |
( |
const char * |
name, |
|
|
F |
code |
|
) |
| |
|
inline |
§ pimpl
The documentation for this class was generated from the following files: