aether::ecs::ecs< P, T, U > Class Template Reference

#include <ecs.hh>

Classes

struct  behaviour_adapter
 
struct  const_proxy
 
class  entity_subset
 
class  global_deserialization_context
 
class  global_serialization_context
 
class  opaque_iterator
 
struct  proxy
 
class  update_set
 

Public Types

using agent_reference = typed_entity< false, std::tuple< typename mpl::make_maybe< component_types >::type >>
 
template<typename Cs >
using entity_reference_tuple = typed_entity< false, Cs >
 
template<typename... Cs>
using entity_reference = entity_reference_tuple< std::tuple< Cs... >>
 
template<typename Cs >
using const_entity_reference_tuple = typed_entity< true, Cs >
 
template<typename... Cs>
using const_entity_reference = const_entity_reference_tuple< std::tuple< Cs... >>
 
using message_writer_type = message::writer< octree_traits, container::ring_buffer< char >>
 
using message_reader_type = message::reader< container::ring_buffer< char >>
 
using message_destination_type = typename message_writer_type::destination_type
 
template<typename W >
using serialization_context = global_serialization_context< W >
 
template<typename R >
using deserialization_context = global_deserialization_context< R >
 
template<typename... Cs>
using local_entities_type = local_entities_type_tuple< std::tuple< Cs... >>
 
template<typename... Cs>
using const_local_entities_type = const_local_entities_type_tuple< std::tuple< Cs... >>
 
template<typename... Cs>
using visible_entities_type = visible_entities_type_tuple< std::tuple< Cs... >>
 
template<typename... Cs>
using const_visible_entities_type = const_visible_entities_type_tuple< std::tuple< Cs... >>
 
template<typename... Cs>
using ghost_entities_type = ghost_entities_type_tuple< std::tuple< Cs... >>
 
template<typename... Cs>
using const_ghost_entities_type = const_ghost_entities_type_tuple< std::tuple< Cs... >>
 
using opaque_iterator_type = opaque_iterator
 

Public Member Functions

template<typename... Args>
 ecs (Args &&...args)
 
 ecs (const ecs &)=delete
 
void clear_ghost_agents ()
 
void clear_local_agents ()
 
void clear ()
 
void insert_agent_unclassified (agent_reference agent)
 
size_t num_agents_local () const
 
size_t num_agents_ghost () const
 
opaque_iterator_type iterate_local ()
 
opaque_iterator_type iterate_ghost ()
 
template<typename F >
void reclassify_agents (F is_contained)
 
update_set create_update_set ()
 
template<typename W >
serialization_context< W > create_serialization_context (W &writer)
 
template<typename R >
deserialization_context< R > create_deserialization_context (R &reader)
 
template<typename Writer >
int serialize_entity (agent_reference entity, Writer &writer)
 
template<typename Reader >
agent_reference deserialize_entity (Reader &reader)
 
template<typename... Cs>
local_entities_type< Cs... > local_entities ()
 
template<typename... Cs>
visible_entities_type< Cs... > visible_entities ()
 
template<typename... Cs>
ghost_entities_type< Cs... > ghost_entities ()
 
template<typename... Cs>
const_local_entities_type< Cs... > local_entities () const
 
template<typename... Cs>
const_visible_entities_type< Cs... > visible_entities () const
 
template<typename... Cs>
const_ghost_entities_type< Cs... > ghost_entities () const
 
template<typename System >
void add_system ()
 
template<typename Behaviour >
void add_behaviour ()
 
void tick (const aether::cell_state< octree_traits > &aether_state, double delta_time)
 
template<typename F >
void set_entity_deletion_callback (const F &func)
 
void send_message (const message_destination_type dest, const void *data, const size_t bytes)
 
template<typename W >
void send_messages (message::writer< octree_traits, W > &message_writer)
 
template<typename R >
void receive_messages (message::reader< R > &message_reader)
 
message_reader_typeget_message_reader ()
 
message_writer_typeget_message_writer ()
 
template<typename Cs >
ecs< P, T, U >::template local_entities_type_tuple< Cs > local_entities_tuple ()
 
template<typename Cs >
ecs< P, T, U >::template visible_entities_type_tuple< Cs > visible_entities_tuple ()
 
template<typename Cs >
ecs< P, T, U >::template local_entities_type_tuple< Cs > ghost_entities_tuple ()
 
template<typename Cs >
ecs< P, T, U >::template const_local_entities_type_tuple< Cs > local_entities_tuple () const
 
template<typename Cs >
ecs< P, T, U >::template const_visible_entities_type_tuple< Cs > visible_entities_tuple () const
 
template<typename Cs >
ecs< P, T, U >::template const_ghost_entities_type_tuple< Cs > ghost_entities_tuple () const
 
template<typename... Cs>
ecs< P, T, U >::template local_entities_type< Cs... > local_entities ()
 
template<typename... Cs>
ecs< P, T, U >::template visible_entities_type< Cs... > visible_entities ()
 
template<typename... Cs>
ecs< P, T, U >::template ghost_entities_type< Cs... > ghost_entities ()
 
template<typename... Cs>
ecs< P, T, U >::template const_local_entities_type< Cs... > local_entities () const
 
template<typename... Cs>
ecs< P, T, U >::template const_visible_entities_type< Cs... > visible_entities () const
 
template<typename... Cs>
ecs< P, T, U >::template const_ghost_entities_type< Cs... > ghost_entities () const
 
template<typename R >
auto create_deserialization_context (R &reader) -> deserialization_context< R >
 
template<typename W >
auto create_serialization_context (W &writer) -> serialization_context< W >
 
template<typename C , typename... Args>
ecs< P, T, U >::template proxy< C >::type create_component (const entity_handle &entity, Args &&...args)
 
template<typename C >
ecs< P, T, U >::template proxy< C >::type get_component (const entity_handle &entity)
 
template<typename C >
ecs< P, T, U >::template const_proxy< C >::type get_component (const entity_handle &entity) const
 

Public Attributes

user_data_type user_data
 

Friends

template<typename , typename >
class constrained_ecs
 

Member Typedef Documentation

template<typename P, typename T, typename U = std::monostate>
using aether::ecs::ecs< P, T, U >::agent_reference = typed_entity<false, std::tuple<typename mpl::make_maybe<component_types>::type>>
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
using aether::ecs::ecs< P, T, U >::const_entity_reference = const_entity_reference_tuple<std::tuple<Cs...>>
template<typename P, typename T, typename U = std::monostate>
template<typename Cs >
using aether::ecs::ecs< P, T, U >::const_entity_reference_tuple = typed_entity<true, Cs>
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
using aether::ecs::ecs< P, T, U >::const_ghost_entities_type = const_ghost_entities_type_tuple<std::tuple<Cs...>>
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
using aether::ecs::ecs< P, T, U >::const_local_entities_type = const_local_entities_type_tuple<std::tuple<Cs...>>
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
using aether::ecs::ecs< P, T, U >::const_visible_entities_type = const_visible_entities_type_tuple<std::tuple<Cs...>>
template<typename P, typename T, typename U = std::monostate>
template<typename R >
using aether::ecs::ecs< P, T, U >::deserialization_context = global_deserialization_context<R>
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
using aether::ecs::ecs< P, T, U >::entity_reference = entity_reference_tuple<std::tuple<Cs...>>
template<typename P, typename T, typename U = std::monostate>
template<typename Cs >
using aether::ecs::ecs< P, T, U >::entity_reference_tuple = typed_entity<false, Cs>
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
using aether::ecs::ecs< P, T, U >::ghost_entities_type = ghost_entities_type_tuple<std::tuple<Cs...>>
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
using aether::ecs::ecs< P, T, U >::local_entities_type = local_entities_type_tuple<std::tuple<Cs...>>
template<typename P, typename T, typename U = std::monostate>
using aether::ecs::ecs< P, T, U >::message_destination_type = typename message_writer_type::destination_type
template<typename P, typename T, typename U = std::monostate>
using aether::ecs::ecs< P, T, U >::message_reader_type = message::reader<container::ring_buffer<char>>
template<typename P, typename T, typename U = std::monostate>
using aether::ecs::ecs< P, T, U >::message_writer_type = message::writer<octree_traits, container::ring_buffer<char>>
template<typename P, typename T, typename U = std::monostate>
using aether::ecs::ecs< P, T, U >::opaque_iterator_type = opaque_iterator
template<typename P, typename T, typename U = std::monostate>
template<typename W >
using aether::ecs::ecs< P, T, U >::serialization_context = global_serialization_context<W>
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
using aether::ecs::ecs< P, T, U >::visible_entities_type = visible_entities_type_tuple<std::tuple<Cs...>>

Constructor & Destructor Documentation

template<typename P , typename T , typename U >
template<typename... Args>
aether::ecs::ecs< P, T, U >::ecs ( Args &&...  args)
template<typename P, typename T, typename U = std::monostate>
aether::ecs::ecs< P, T, U >::ecs ( const ecs< P, T, U > &  )
delete

Member Function Documentation

template<typename P , typename T , typename U >
template<typename Behaviour >
void aether::ecs::ecs< P, T, U >::add_behaviour ( )
template<typename P , typename T , typename U >
template<typename System >
void aether::ecs::ecs< P, T, U >::add_system ( )
template<typename P , typename T , typename U >
void aether::ecs::ecs< P, T, U >::clear ( )
template<typename P , typename T , typename U >
void aether::ecs::ecs< P, T, U >::clear_ghost_agents ( )
template<typename P , typename T , typename U >
void aether::ecs::ecs< P, T, U >::clear_local_agents ( )
template<typename P, typename T, typename U = std::monostate>
template<typename C , typename... Args>
ecs<P, T, U>::template proxy<C>::type aether::ecs::ecs< P, T, U >::create_component ( const entity_handle &  entity,
Args &&...  args 
)
template<typename P, typename T, typename U = std::monostate>
template<typename R >
deserialization_context<R> aether::ecs::ecs< P, T, U >::create_deserialization_context ( R &  reader)
template<typename P, typename T, typename U = std::monostate>
template<typename R >
auto aether::ecs::ecs< P, T, U >::create_deserialization_context ( R &  reader) -> deserialization_context<R>
template<typename P, typename T, typename U = std::monostate>
template<typename W >
serialization_context<W> aether::ecs::ecs< P, T, U >::create_serialization_context ( W &  writer)
template<typename P, typename T, typename U = std::monostate>
template<typename W >
auto aether::ecs::ecs< P, T, U >::create_serialization_context ( W &  writer) -> serialization_context<W>
template<typename P , typename T , typename U >
ecs< P, T, U >::update_set aether::ecs::ecs< P, T, U >::create_update_set ( )
template<typename P , typename T , typename U >
template<typename Reader >
ecs< P, T, U >::agent_reference aether::ecs::ecs< P, T, U >::deserialize_entity ( Reader &  reader)
template<typename P, typename T, typename U = std::monostate>
template<typename C >
ecs<P, T, U>::template proxy<C>::type aether::ecs::ecs< P, T, U >::get_component ( const entity_handle &  entity)
template<typename P, typename T, typename U = std::monostate>
template<typename C >
ecs<P, T, U>::template const_proxy<C>::type aether::ecs::ecs< P, T, U >::get_component ( const entity_handle &  entity) const
template<typename P , typename T , typename U >
ecs< P, T, U >::message_reader_type & aether::ecs::ecs< P, T, U >::get_message_reader ( )
template<typename P , typename T , typename U >
ecs< P, T, U >::message_writer_type & aether::ecs::ecs< P, T, U >::get_message_writer ( )
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
ghost_entities_type<Cs...> aether::ecs::ecs< P, T, U >::ghost_entities ( )
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
const_ghost_entities_type<Cs...> aether::ecs::ecs< P, T, U >::ghost_entities ( ) const
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
ecs<P, T, U>::template ghost_entities_type<Cs...> aether::ecs::ecs< P, T, U >::ghost_entities ( )
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
ecs<P, T, U>::template const_ghost_entities_type<Cs...> aether::ecs::ecs< P, T, U >::ghost_entities ( ) const
template<typename P, typename T, typename U = std::monostate>
template<typename Cs >
ecs<P, T, U>::template local_entities_type_tuple<Cs> aether::ecs::ecs< P, T, U >::ghost_entities_tuple ( )
template<typename P, typename T, typename U = std::monostate>
template<typename Cs >
ecs<P, T, U>::template const_ghost_entities_type_tuple<Cs> aether::ecs::ecs< P, T, U >::ghost_entities_tuple ( ) const
template<typename P , typename T , typename U >
void aether::ecs::ecs< P, T, U >::insert_agent_unclassified ( agent_reference  agent)
template<typename P , typename T , typename U >
ecs< P, T, U >::opaque_iterator aether::ecs::ecs< P, T, U >::iterate_ghost ( )
template<typename P , typename T , typename U >
ecs< P, T, U >::opaque_iterator aether::ecs::ecs< P, T, U >::iterate_local ( )
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
local_entities_type<Cs...> aether::ecs::ecs< P, T, U >::local_entities ( )
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
const_local_entities_type<Cs...> aether::ecs::ecs< P, T, U >::local_entities ( ) const
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
ecs<P, T, U>::template local_entities_type<Cs...> aether::ecs::ecs< P, T, U >::local_entities ( )
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
ecs<P, T, U>::template const_local_entities_type<Cs...> aether::ecs::ecs< P, T, U >::local_entities ( ) const
template<typename P, typename T, typename U = std::monostate>
template<typename Cs >
ecs<P, T, U>::template local_entities_type_tuple<Cs> aether::ecs::ecs< P, T, U >::local_entities_tuple ( )
template<typename P, typename T, typename U = std::monostate>
template<typename Cs >
ecs<P, T, U>::template const_local_entities_type_tuple<Cs> aether::ecs::ecs< P, T, U >::local_entities_tuple ( ) const
template<typename P , typename T , typename U >
size_t aether::ecs::ecs< P, T, U >::num_agents_ghost ( ) const
template<typename P , typename T , typename U >
size_t aether::ecs::ecs< P, T, U >::num_agents_local ( ) const
template<typename P , typename T , typename U >
template<typename R >
void aether::ecs::ecs< P, T, U >::receive_messages ( message::reader< R > &  message_reader)
template<typename P , typename T , typename U >
template<typename F >
void aether::ecs::ecs< P, T, U >::reclassify_agents ( is_contained)
template<typename P , typename T , typename U >
void aether::ecs::ecs< P, T, U >::send_message ( const message_destination_type  dest,
const void *  data,
const size_t  bytes 
)
template<typename P , typename T , typename U >
template<typename W >
void aether::ecs::ecs< P, T, U >::send_messages ( message::writer< octree_traits, W > &  message_writer)
template<typename P , typename T , typename U >
template<typename Writer >
int aether::ecs::ecs< P, T, U >::serialize_entity ( agent_reference  entity,
Writer &  writer 
)
template<typename P , typename T , typename U >
template<typename F >
void aether::ecs::ecs< P, T, U >::set_entity_deletion_callback ( const F &  func)
template<typename P , typename T , typename U >
void aether::ecs::ecs< P, T, U >::tick ( const aether::cell_state< octree_traits > &  aether_state,
double  delta_time 
)
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
visible_entities_type<Cs...> aether::ecs::ecs< P, T, U >::visible_entities ( )
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
const_visible_entities_type<Cs...> aether::ecs::ecs< P, T, U >::visible_entities ( ) const
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
ecs<P, T, U>::template visible_entities_type<Cs...> aether::ecs::ecs< P, T, U >::visible_entities ( )
template<typename P, typename T, typename U = std::monostate>
template<typename... Cs>
ecs<P, T, U>::template const_visible_entities_type<Cs...> aether::ecs::ecs< P, T, U >::visible_entities ( ) const
template<typename P, typename T, typename U = std::monostate>
template<typename Cs >
ecs<P, T, U>::template visible_entities_type_tuple<Cs> aether::ecs::ecs< P, T, U >::visible_entities_tuple ( )
template<typename P, typename T, typename U = std::monostate>
template<typename Cs >
ecs<P, T, U>::template const_visible_entities_type_tuple<Cs> aether::ecs::ecs< P, T, U >::visible_entities_tuple ( ) const

Friends And Related Function Documentation

template<typename P, typename T, typename U = std::monostate>
template<typename , typename >
friend class constrained_ecs
friend

Member Data Documentation

template<typename P, typename T, typename U = std::monostate>
user_data_type aether::ecs::ecs< P, T, U >::user_data