Open 3D Engine AzCore API Reference 23.10.0
O3DE is an open-source, fully-featured, high-fidelity, modular 3D engine for building games and simulations, available to every industry.
AZ::EBusEnvironmentStoragePolicy< Context > Struct Template Reference

#include <Environment.h>

Static Public Member Functions

static Context * Get ()
 
static Context & GetOrCreate ()
 
static u32 GetVariableId ()
 

Static Public Attributes

static EnvironmentVariable< Context > s_defaultGlobalContext
 

Detailed Description

template<class Context>
struct AZ::EBusEnvironmentStoragePolicy< Context >

A choice of AZ::EBusTraits::StoragePolicy that specifies that EBus data is stored in the AZ::Environment and it also support multiple EBusEnvironment With this policy, a single EBus instance is shared across all modules (DLLs) that attach to the AZ::Environment.

Template Parameters
ContextA class that contains EBus data.
Note
Using separate EBusEnvironment allows you to manage fully independent EBus communication environments, most frequently this is use to remove/reduce contention when we choose to process in parallel unrelated systems.

Member Function Documentation

◆ Get()

template<class Context >
Context * AZ::EBusEnvironmentStoragePolicy< Context >::Get
static

Returns the EBus data if it's already created, else nullptr.

Returns
A pointer to the EBus data.

◆ GetOrCreate()

template<class Context >
Context & AZ::EBusEnvironmentStoragePolicy< Context >::GetOrCreate
static

Returns the EBus data. Creates it if not already created.

Returns
A reference to the EBus data.

Member Data Documentation

◆ s_defaultGlobalContext

template<class Context >
EnvironmentVariable< Context > AZ::EBusEnvironmentStoragePolicy< Context >::s_defaultGlobalContext
static

Environment variable that contains a pointer to the EBus data.


The documentation for this struct was generated from the following file: