Skip to main content

RealityEngine

Struct RealityEngine 

Source
pub struct RealityEngine {
    pub deployment_store: DeploymentStore,
    pub environment_store: EnvironmentStore,
    pub resource_store: ResourceStore,
    pub reality_store: RealityStore,
    pub topology_store: TopologyStore,
    pub temporal_store: TemporalStore,
    pub stakes_store: StakesStore,
    pub coherence_store: CoherenceStore,
    pub indexes: RealityIndexes,
    /* private fields */
}
Expand description

The main reality engine combining write and query capabilities.

Fields§

§deployment_store: DeploymentStore§environment_store: EnvironmentStore§resource_store: ResourceStore§reality_store: RealityStore§topology_store: TopologyStore§temporal_store: TemporalStore§stakes_store: StakesStore§coherence_store: CoherenceStore§indexes: RealityIndexes

Implementations§

Source§

impl RealityEngine

Source

pub fn new() -> Self

Create a new empty reality engine.

Source

pub fn writer(&mut self) -> WriteEngine<'_>

Get a write engine handle.

Source

pub fn reader(&self) -> QueryEngine<'_>

Get a query engine handle.

Source

pub fn is_dirty(&self) -> bool

Whether the engine has unsaved changes.

Source

pub fn mark_dirty(&mut self)

Mark the engine as dirty (has unsaved changes).

Source

pub fn mark_clean(&mut self)

Mark the engine as clean (all changes saved).

Source

pub fn incarnation_id(&self) -> Option<IncarnationId>

Get the current incarnation ID if initialized.

Source

pub fn is_initialized(&self) -> bool

Check if the engine has been initialized with a deployment soul.

Trait Implementations§

Source§

impl Default for RealityEngine

Source§

fn default() -> Self

Returns the “default value” for a type. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.