CARLA
 
载入中...
搜索中...
未找到
Private 属性 | 所有成员列表
carla::client::ActorBlueprint类 参考

包含生成参与者所需的所有必要信息。 更多...

#include <ActorBlueprint.h>

+ carla::client::ActorBlueprint 的协作图:

Public 成员函数

构造函数
 ActorBlueprint (rpc::ActorDefinition actor_definition)
 
Id
const std::string & GetId () const
 
标签
bool ContainsTag (const std::string &tag) const
 
bool MatchTags (const std::string &wildcard_pattern) const
 测试是否有标签满足 wildcard_pattern。
 
std::vector< std::string > GetTags () const
 
属性
bool ContainsAttribute (const std::string &id) const
 
const ActorAttributeGetAttribute (const std::string &id) const
 
void SetAttribute (const std::string &id, std::string value)
 Set the value of the attribute given by id.
 
size_t size () const
 
auto begin () const
 
auto end () const
 
参与者描述 ActorDescription
rpc::ActorDescription MakeActorDescription () const
 

Private 属性

std::unordered_map< std::string, ActorAttribute_attributes
 
std::string _id
 
std::unordered_set< std::string > _tags
 
uint32_t _uid = 0u
 

详细描述

包含生成参与者所需的所有必要信息。

在文件 ActorBlueprint.h23 行定义.

构造及析构函数说明

◆ ActorBlueprint()

carla::client::ActorBlueprint::ActorBlueprint ( rpc::ActorDefinition actor_definition)
explicit

在文件 ActorBlueprint.cpp36 行定义.

引用了 _attributes, _tags, carla::rpc::ActorDefinition::attributes, carla::client::FillMap(), carla::StringUtil::Split() , 以及 carla::rpc::ActorDefinition::tags.

+ 函数调用图:

成员函数说明

◆ begin()

auto carla::client::ActorBlueprint::begin ( ) const
inline

在文件 ActorBlueprint.h92 行定义.

引用了 _attributes , 以及 carla::iterator::make_map_values_const_iterator().

+ 函数调用图:

◆ ContainsAttribute()

bool carla::client::ActorBlueprint::ContainsAttribute ( const std::string & id) const
inline

在文件 ActorBlueprint.h74 行定义.

引用了 _attributes.

◆ ContainsTag()

bool carla::client::ActorBlueprint::ContainsTag ( const std::string & tag) const
inline

在文件 ActorBlueprint.h53 行定义.

引用了 _tags.

◆ end()

auto carla::client::ActorBlueprint::end ( ) const
inline

在文件 ActorBlueprint.h96 行定义.

引用了 _attributes , 以及 carla::iterator::make_map_values_const_iterator().

+ 函数调用图:

◆ GetAttribute()

const ActorAttribute & carla::client::ActorBlueprint::GetAttribute ( const std::string & id) const
异常
如果不存在这种元素,则抛出std::out_of_range 异常。

在文件 ActorBlueprint.cpp68 行定义.

引用了 _attributes , 以及 carla::throw_exception().

被这些函数引用 SetAttribute().

+ 函数调用图:
+ 这是这个函数的调用关系图:

◆ GetId()

const std::string & carla::client::ActorBlueprint::GetId ( ) const
inline

在文件 ActorBlueprint.h41 行定义.

引用了 _id.

◆ GetTags()

std::vector< std::string > carla::client::ActorBlueprint::GetTags ( ) const
inline

在文件 ActorBlueprint.h62 行定义.

引用了 _tags.

◆ MakeActorDescription()

rpc::ActorDescription carla::client::ActorBlueprint::MakeActorDescription ( ) const

在文件 ActorBlueprint.cpp91 行定义.

引用了 _attributes, _id, _uid, carla::rpc::ActorDescription::attributes, carla::rpc::ActorDescription::id , 以及 carla::rpc::ActorDescription::uid.

被这些函数引用 carla::client::detail::Simulator::SpawnActor().

+ 这是这个函数的调用关系图:

◆ MatchTags()

bool carla::client::ActorBlueprint::MatchTags ( const std::string & wildcard_pattern) const

测试是否有标签满足 wildcard_pattern。

wildcard_pattern 遵循 Unix shell 风格的通配符。

在文件 ActorBlueprint.cpp50 行定义.

引用了 _id, _tags , 以及 carla::StringUtil::Match().

+ 函数调用图:

◆ SetAttribute()

void carla::client::ActorBlueprint::SetAttribute ( const std::string & id,
std::string value )

Set the value of the attribute given by id.

异常
如果不存在这样的元素,则抛出std::out_of_range 异常。
如果属性不可修改,则抛出InvalidAttributeValue 异常。
如果格式不匹配属性类型,则抛出InvalidAttributeValue 异常。

在文件 ActorBlueprint.cpp83 行定义.

引用了 GetAttribute().

+ 函数调用图:

◆ size()

size_t carla::client::ActorBlueprint::size ( ) const
inline

在文件 ActorBlueprint.h88 行定义.

引用了 _attributes.

类成员变量说明

◆ _attributes

std::unordered_map<std::string, ActorAttribute> carla::client::ActorBlueprint::_attributes
private

在文件 ActorBlueprint.h120 行定义.

被这些函数引用 ActorBlueprint(), begin(), ContainsAttribute(), end(), GetAttribute(), MakeActorDescription() , 以及 size().

◆ _id

std::string carla::client::ActorBlueprint::_id
private

在文件 ActorBlueprint.h116 行定义.

被这些函数引用 GetId(), MakeActorDescription() , 以及 MatchTags().

◆ _tags

std::unordered_set<std::string> carla::client::ActorBlueprint::_tags
private

在文件 ActorBlueprint.h118 行定义.

被这些函数引用 ActorBlueprint(), ContainsTag(), GetTags() , 以及 MatchTags().

◆ _uid

uint32_t carla::client::ActorBlueprint::_uid = 0u
private

在文件 ActorBlueprint.h114 行定义.

被这些函数引用 MakeActorDescription().


该类的文档由以下文件生成: