gz/sim/ServerConfig.hh
std::string NetworkRole() const
Get the network role. See SetNetworkRole(const std::string &_role) for more information about distrib...
std::string LogRecordCompressPath() const
Get file path to compress log files to.
bool SetSdfString(const std::string &_sdfString)
Set an SDF string to be used by the server.
Configuration parameters for a Server. An instance of this object can be used to construct a Server w...
Definition: gz/sim/ServerConfig.hh:45
void SetLogRecordCompressPath(const std::string &_path)
Set file path to compress log files to.
void AddLogRecordTopic(const std::string &_topic)
Add a topic to record.
void ClearLogRecordTopics()
Clear topics to record. This will remove all topics set using AddLogRecordTopic.
void AddPlugins(const std::list< PluginInfo > &_plugins)
Add multiple plugins to the simulation.
void SetEntityType(const std::string &_entityType)
Set the type of the entity which should receive this plugin. The type is used in conjuction with Enti...
std::optional< std::chrono::steady_clock::duration > UpdatePeriod() const
Get the update period duration.
This library is part of the Gazebo project.
STL class.
std::chrono::steady_clock::duration LogRecordPeriod() const
Get time period to record states.
void SetSdf(const sdf::ElementPtr &_sdf)
Set the plugin XML elements associated with this plugin.
STL class.
const std::string & Filename() const
Get the plugin library filename.
void SetUseLogRecord(const bool _record)
Set whether the server is recording states.
const sdf::Plugin & Plugin() const
Get the SDF plugin information.
const std::string & PhysicsEngine() const
Physics engine plugin library to load.
std::list< ServerConfig::PluginInfo > loadPluginInfo(bool _isPlayback=false)
Load plugin information, following ordering.
STL class.
void SetUpdateRate(const double &_hz)
Set the update rate in Hertz. Value <=0 are ignored.
const std::vector< std::string > & LogRecordTopics() const
Get the topics to record that were added using AddLogRecordTopic.
void SetUseLevels(const bool _levels)
Get whether the server is using the level system.
const std::string LogRecordPath() const
Get path to place recorded states.
const std::chrono::time_point< std::chrono::system_clock > & Timestamp() const
Get the timestamp of this ServerConfig. This is the system time when this ServerConfig was created....
void SetNetworkSecondaries(unsigned int _secondaries)
Set the number of network secondary servers that the primary server should expect....
void SetSdfRoot(const sdf::Root &_root) const
Set the SDF Root DOM object. The sdf::Root object will take precendence over ServerConfig::SdfString(...
ServerConfig & operator=(const ServerConfig &_cfg)
Equal operator.
std::list< ServerConfig::PluginInfo > parsePluginsFromFile(const std::string &_fname)
Parse plugins from XML configuration file.
void SetLogRecordPath(const std::string &_recordPath)
Set path to place recorded states.
void SetRenderEngineServer(const std::string &_renderEngineServer)
Set the render engine server plugin library.
std::chrono::steady_clock::time_point Timestamp
void SetPhysicsEngine(const std::string &_physicsEngine)
Set the physics engine plugin library.
void SetFilename(const std::string &_filename)
Set the type of the entity which should receive this plugin. The type is used in conjuction with Enti...
PluginInfo LogPlaybackPlugin() const
Generate PluginInfo for Log playback based on the internal state of this ServerConfig object:
const std::string & ResourceCache() const
Path to where simulation resources, such as models downloaded from fuel.gazebosim....
void SetHeadlessRendering(const bool _headless)
Set the headless mode.
unsigned int NetworkSecondaries() const
Get the number of secondary servers that a primary server should expect.
bool UseLevels() const
Get whether the server is using the level system.
std::string SdfFile() const
Get the SDF file that has been set. An empty string will be returned if an SDF file has not been set.
const std::string LogPlaybackPath() const
Get path to recorded states to play back.
void SetLogPlaybackPath(const std::string &_playbackPath)
Set path to recorded states to play back.
std::list< ServerConfig::PluginInfo > parsePluginsFromString(const std::string &_str)
Parse plugins from XML configuration string.
void SetLogRecordResources(bool _recordResources)
Set whether meshes and material files are recorded.
PluginInfo LogRecordPlugin() const
Generate PluginInfo for Log recording based on the internal state of this ServerConfig object:
bool HeadlessRendering() const
Get the headless mode.
void SetRenderEngineGui(const std::string &_renderEngineGui)
Set the render engine gui plugin library.
const std::string & RenderEngineGui() const
Render engine plugin library to load.
void SetLogRecordPeriod(const std::chrono::steady_clock::duration &_period)
Set time period to record states.
bool SetSdfFile(const std::string &_file)
Set an SDF file to be used with the server.
void SetName(const std::string &_name)
Set the name of the interface within the plugin library to load.
void AddPlugin(const PluginInfo &_info)
Instruct simulation to attach a plugin to a specific entity when simulation starts.
PluginInfo & operator=(const PluginInfo &_info)
Equal operator.
void SetResourceCache(const std::string &_path)
Set the path to where simulation resources, such as models downloaded from fuel.gazebosim....
const std::string & EntityType() const
Get the entity type which should receive this plugin. The type is used in conjuction with EntityName ...
bool LogRecordResources() const
Get whether meshes and material files are recorded.
void SetPlugin(const sdf::Plugin &_plugin) const
Set the SDF plugin information.
void SetEntityName(const std::string &_entityName)
Set the name of the entity which should receive this plugin. The name is used in conjuction with _ent...
const std::list< PluginInfo > & Plugins() const
Get all the plugins that should be loaded.
const std::string & RenderEngineServer() const
Render engine plugin library to load.
const std::string & EntityName() const
Get the name of the entity which should receive this plugin. The name is used in conjuction with _ent...
const sdf::ElementPtr & Sdf() const
Plugin XML elements associated with this plugin.
Component< std::string, class NameTag, serializers::StringSerializer > Name
This component holds an entity's name. The component has no concept of scoped names nor does it care ...
Definition: gz/sim/components/Name.hh:37
bool UseLogRecord() const
Get whether the server is recording states.
bool UseDistributedSimulation() const
Get whether the server is using the distributed sim system.
Information about a plugin that should be loaded by the server.
Definition: gz/sim/ServerConfig.hh:71
void SetNetworkRole(const std::string &_role)
Set the network role, which is one of [primary, secondary]. If primary is used, then make sure to als...
std::string SdfString() const
Get the SDF String that has been set. An empty string will be returned if an SDF string has not been ...
std::optional< double > UpdateRate() const
Get the update rate in Hertz.
SourceType
Type of SDF source.
Definition: gz/sim/ServerConfig.hh:48
const std::string & Name() const
Name of the interface within the plugin library to load.
std::optional< sdf::Root > & SdfRoot() const
Get the SDF Root DOM object.