Re-exports§
pub use crate::context::Context;pub use crate::entity::events::EntityCreatedEvent;pub use crate::entity::events::PropertyChangeEvent;pub use crate::entity::property::Property;pub use crate::entity::ContextEntitiesExt;pub use crate::entity::Entity;pub use crate::entity::EntityId;pub use crate::error::IxaError;pub use crate::global_properties::ContextGlobalPropertiesExt;pub use crate::network::ContextNetworkExt;pub use crate::random::ContextRandomExt;pub use crate::report::ContextReportExt;pub use crate::PluginContext;
Macros§
- debug
- Logs a message at the debug level.
- define_
data_ plugin - Defines a new type for storing data in Context.
- define_
derived_ property - The “derived” variant of
define_property!for defining simple derived property types. Defines astructorenumwith a standard set of derives and automatically invokesimpl_derived_property!for it. - define_
edge_ type - define_
entity - Defines a zero-sized struct with the right derived traits and implements the
Entitytrait. If you already have a type defined (struct, enum, etc.), you can use theimpl_entity!macro instead. - define_
global_ property - Defines a global property with the following parameters:
- define_
multi_ property - Defines a derived property consisting of a (named) tuple of other properties. The primary use case is for indexing and querying properties jointly.
- define_
property - Defines a
structorenumwith a standard set of derives and automatically invokesimpl_property!for it. This macro provides a concise shorthand for defining simple property types that follow the same derive and implementation pattern. - define_
report - Use this macro to define a unique report type
- define_
rng - Use this to define a unique type which will be used as a key to retrieve
an independent rng instance when calling
Context::get_rng. - error
- Logs a message at the error level.
- impl_
edge_ type - impl_
entity - Implements the
Entitytrait for the given existing type and defines a type alias of the formMyEntityId = EntityId<MyEntity>. For simple zero-sized types, use thedefine_entity!macro instead, which will define the struct and derive all the super traits. - impl_
property - Implements the
Propertytrait for the given property type and entity. - impl_
property_ eq - Implements
PartialEqandEqfor a property type using Ixa’s generated byte-based equality behavior. - impl_
property_ eq_ hash - Implements
PartialEq,Eq, andHashfor a property type using Ixa’s generated byte-based equality and hashing behavior. - impl_
property_ hash - Implements
Hashfor a property type using Ixa’s generated byte-based hashing behavior. - info
- Logs a message at the info level.
- schedule_
relative - Schedules an action after a delay relative to the context’s current time.
- trace
- Logs a message at the trace level.
- track_
periodic_ value_ change_ counts - Tracks periodic value change counts with concise entity, property, and strata syntax.
- warn
- Logs a message at the warn level.
- with
- Creates an entity-scoped bundle of property values for queries and entity initialization.