Grail (C++)  1.4.0
A multi-platform, modular, universal engine for embedding advanced AI in games.
grail::helpers::ConfigInterpreter Class Reference

The ConfigInterpreter class - used to construct entities and entity groups based on configuration data. More...

#include <ConfigHelpers.h>

Public Member Functions

 ConfigInterpreter (const data::GrailConfiguration &configuration, const std::vector< std::shared_ptr< IReasonerFactory >> &reasonerFactories)
 ConfigInterpreter - Constructs a config interpreter with user-provided reasoner factories. More...
 
std::shared_ptr< EntityGroupCreateEntityGroup (const std::string &entityGroupName) const
 CreateEntityGroup - Creates an entity group based on config data stored in this object and an id. More...
 
std::shared_ptr< AIEntityCreateEntity (const std::string &entityName) const
 CreateEntity - Creates an entity based on config data stored in this object and an id. More...
 
const data::GrailConfigurationGetConfiguration () const
 GetConfiguration - getter for grail's system configuration data stored in this object. More...
 

Detailed Description

The ConfigInterpreter class - used to construct entities and entity groups based on configuration data.

Constructor & Destructor Documentation

◆ ConfigInterpreter()

grail::helpers::ConfigInterpreter::ConfigInterpreter ( const data::GrailConfiguration configuration,
const std::vector< std::shared_ptr< IReasonerFactory >> &  reasonerFactories 
)

ConfigInterpreter - Constructs a config interpreter with user-provided reasoner factories.

Parameters
configuration- grail's system configuration data
reasonerFactories- reasoner factories which can be used to provide entities contained in configuration with produced reasoners

Member Function Documentation

◆ CreateEntity()

std::shared_ptr< AIEntity > grail::helpers::ConfigInterpreter::CreateEntity ( const std::string &  entityName) const

CreateEntity - Creates an entity based on config data stored in this object and an id.

Parameters
entityName- id of entity being produced
Returns
entity

◆ CreateEntityGroup()

std::shared_ptr< EntityGroup > grail::helpers::ConfigInterpreter::CreateEntityGroup ( const std::string &  entityGroupName) const

CreateEntityGroup - Creates an entity group based on config data stored in this object and an id.

Parameters
entityGroupName- id of entity group being produced
Returns
entity group

◆ GetConfiguration()

const data::GrailConfiguration& grail::helpers::ConfigInterpreter::GetConfiguration ( ) const
inline

GetConfiguration - getter for grail's system configuration data stored in this object.

Returns
grail's configuration data

The documentation for this class was generated from the following files: