Search Results for

    Show / Hide Table of Contents

    Class AttachableObject

    Abstract class that represents an object that can be attached to the system. It implements the default life-cycle Detached-Deactivated-Activated-Destroyed.

    Inheritance
    object
    IdentifiableObject
    DependencyObject
    AttachableObject
    SceneManager
    PrefabInstanceObject
    Service
    Implements
    IDependencyObject
    Inherited Members
    DependencyObject.Dependencies
    DependencyObject.OnDependencyRemoved
    IdentifiableObject.Id
    IdentifiableObject.IdHasChanged(Guid)
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Evergine.Framework
    Assembly: Evergine.Framework.dll
    Syntax
    public abstract class AttachableObject : DependencyObject, IDependencyObject

    Constructors

    AttachableObject()

    Initializes a new instance of the AttachableObject class.

    Declaration
    public AttachableObject()

    AttachableObject(AttachableObjectState, bool, bool)

    Initializes a new instance of the AttachableObject class.

    Declaration
    public AttachableObject(AttachableObjectState initialState, bool isLoaded, bool isStarted)
    Parameters
    Type Name Description
    AttachableObjectState initialState

    The initial state.

    bool isLoaded

    IsLoaded value.

    bool isStarted

    IsStarted value.

    Properties

    IsActivated

    Gets a value indicating whether this object is started.

    Declaration
    public virtual bool IsActivated { get; }
    Property Value
    Type Description
    bool

    IsAttached

    Gets a value indicating whether this object is activated.

    Declaration
    public virtual bool IsAttached { get; }
    Property Value
    Type Description
    bool

    IsDestroyed

    Gets a value indicating whether this object is destroyed.

    Declaration
    public virtual bool IsDestroyed { get; }
    Property Value
    Type Description
    bool

    IsEnabled

    Gets or sets a value indicating whether this entity is enabled.

    Declaration
    public virtual bool IsEnabled { get; set; }
    Property Value
    Type Description
    bool

    IsLoaded

    Gets a value indicating whether this object is loaded.

    Declaration
    public virtual bool IsLoaded { get; }
    Property Value
    Type Description
    bool

    IsStarted

    Gets a value indicating whether this object is started.

    Declaration
    public virtual bool IsStarted { get; }
    Property Value
    Type Description
    bool

    ShouldBeActivated

    Gets a value indicating whether this object should be activated.

    Declaration
    protected virtual bool ShouldBeActivated { get; }
    Property Value
    Type Description
    bool

    State

    Gets the current state.

    Declaration
    public AttachableObjectState State { get; }
    Property Value
    Type Description
    AttachableObjectState

    Methods

    DependencyBroken()

    A required dependency of this object has been broken.

    Declaration
    protected override void DependencyBroken()
    Overrides
    DependencyObject.DependencyBroken()

    Destroy()

    Destroy this object.

    Declaration
    public virtual void Destroy()

    OnActivated()

    Invoked when the object is activated once is attached.

    Declaration
    protected abstract void OnActivated()

    OnAttached()

    Invoked when the object is attached to the system.

    Declaration
    protected abstract bool OnAttached()
    Returns
    Type Description
    bool

    True if all is OK.

    OnDeactivated()

    Invoked when the object is deactivated.

    Declaration
    protected abstract void OnDeactivated()

    OnDestroy()

    Invoked when the object is going to be disposed.

    Declaration
    protected abstract void OnDestroy()

    OnDetach()

    Invoked when the object is detached.

    Declaration
    protected abstract void OnDetach()

    OnLoaded()

    Invoked when the object is loaded.

    Declaration
    protected abstract void OnLoaded()

    Start()

    Invoked to start the object.

    Declaration
    protected abstract void Start()

    Events

    AttachableStateChanged

    Event raised when the attachable object has changed its state.

    Declaration
    public event EventHandler<AttachableObjectState> AttachableStateChanged
    Event Type
    Type Description
    EventHandler<AttachableObjectState>

    Implements

    IDependencyObject

    Extension Methods

    ReflectionHelper.GetMemberAssembly(object)
    ReflectionHelper.GetTypeName(object)
    In This Article
    Back to top
    Generated by DocFX