Show / Hide Table of Contents

    Class BaseEvent

    Abstract class that represents the base event for scheduling.

    Inheritance
    System.Object
    Priority_Queue.FastPriorityQueueNode
    Priority_Queue.StablePriorityQueueNode
    BaseEvent
    Condition
    Notification
    Operation
    Implements
    IEvent
    System.IEquatable<BaseEvent>
    Inherited Members
    Priority_Queue.StablePriorityQueueNode.InsertionIndex
    Priority_Queue.FastPriorityQueueNode.Priority
    Priority_Queue.FastPriorityQueueNode.QueueIndex
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.ToString()
    Namespace: Fibula.Scheduling
    Assembly: Fibula.Scheduling.dll
    Syntax
    public abstract class BaseEvent : StablePriorityQueueNode, IEvent, IEquatable<BaseEvent>

    Constructors

    | Improve this Doc View Source

    BaseEvent(UInt32)

    Initializes a new instance of the BaseEvent class.

    Declaration
    public BaseEvent(uint requestorId = 0U)
    Parameters
    Type Name Description
    System.UInt32 requestorId

    Optional. The id of the creature or entity requesting the event. Default is 0.

    Properties

    | Improve this Doc View Source

    CanBeCancelled

    Gets or sets a value indicating whether the event can be cancelled.

    Declaration
    public abstract bool CanBeCancelled { get; protected set; }
    Property Value
    Type Description
    System.Boolean
    | Improve this Doc View Source

    EventId

    Gets a unique identifier for this event.

    Declaration
    public string EventId { get; }
    Property Value
    Type Description
    System.String
    | Improve this Doc View Source

    ExcludeFromTelemetry

    Gets or sets a value indicating whether to exclude this event from telemetry logging.

    Declaration
    public bool ExcludeFromTelemetry { get; protected set; }
    Property Value
    Type Description
    System.Boolean
    | Improve this Doc View Source

    HasCancellationHandler

    Gets a value indicating whether this event has a handler hooked up for it's Cancelled event.

    Declaration
    public bool HasCancellationHandler { get; }
    Property Value
    Type Description
    System.Boolean
    | Improve this Doc View Source

    HasExpeditionHandler

    Gets a value indicating whether this event has a handler hooked up for it's Expedited event.

    Declaration
    public bool HasExpeditionHandler { get; }
    Property Value
    Type Description
    System.Boolean
    | Improve this Doc View Source

    RepeatAfter

    Gets or sets the time after which this event should be repeated. The event is not repeated if the value is not positive.

    Declaration
    public TimeSpan RepeatAfter { get; protected set; }
    Property Value
    Type Description
    System.TimeSpan
    | Improve this Doc View Source

    RequestorId

    Gets the id of the requestor of this event, if available.

    Declaration
    public uint RequestorId { get; }
    Property Value
    Type Description
    System.UInt32
    | Improve this Doc View Source

    State

    Gets or sets the event's state.

    Declaration
    public EventState State { get; set; }
    Property Value
    Type Description
    EventState

    Methods

    | Improve this Doc View Source

    Cancel()

    Attempts to cancel this event.

    Declaration
    public bool Cancel()
    Returns
    Type Description
    System.Boolean

    True if the event is successfully cancelled, false otherwise.

    | Improve this Doc View Source

    Complete(Boolean)

    Marks this event as completed, notifying subscribers of it's Completed event.

    Declaration
    public void Complete(bool asCancelled = false)
    Parameters
    Type Name Description
    System.Boolean asCancelled

    Optional. A value indicating whether the event was cancelled.

    | Improve this Doc View Source

    Equals(BaseEvent)

    Indicates whether the current object is equal to another object of the same type.

    Declaration
    public bool Equals(BaseEvent other)
    Parameters
    Type Name Description
    BaseEvent other

    The other object to compare against.

    Returns
    Type Description
    System.Boolean

    True if the current object is equal to the other parameter, false otherwise.

    | Improve this Doc View Source

    Execute(IEventContext)

    Executes the event logic.

    Declaration
    public abstract void Execute(IEventContext context)
    Parameters
    Type Name Description
    IEventContext context

    The execution context.

    | Improve this Doc View Source

    Expedite()

    Attempts to expedite this event, in other words, requesting it to be fired immediately.

    Declaration
    public bool Expedite()
    Returns
    Type Description
    System.Boolean

    True if the event is successfully expedited, false otherwise.

    Events

    | Improve this Doc View Source

    Cancelled

    Fired when this event is cancelled.

    Declaration
    public event EventCancelledDelegate Cancelled
    Event Type
    Type Description
    EventCancelledDelegate
    | Improve this Doc View Source

    Completed

    Fired when this even is processed to completion (after no more repeats).

    Declaration
    public event EventCompletedDelegate Completed
    Event Type
    Type Description
    EventCompletedDelegate
    | Improve this Doc View Source

    Expedited

    Fired when this event is expedited.

    Declaration
    public event EventExpeditedDelegate Expedited
    Event Type
    Type Description
    EventExpeditedDelegate

    Implements

    IEvent
    System.IEquatable<T>

    Extension Methods

    ObjectExtensions.YieldSingleItem<T>(T)
    ObjectExtensions.GetPropertyValue(Object, String)
    Validate.ThrowIfNull(Object, String)
    • Improve this Doc
    • View Source
    Back to top Copyright © 2018-2020 | The Fibula Project
    Generated using DocFX | Jose L. Nuñez de Caceres et al.