Interface IEvent
Interface that represents an event.
Namespace: Fibula.Scheduling.Contracts.Abstractions
Assembly: Fibula.Scheduling.Contracts.dll
Syntax
public interface IEvent
Properties
| Improve this Doc View SourceCanBeCancelled
Gets a value indicating whether the event can be cancelled.
Declaration
bool CanBeCancelled { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
EventId
Gets a unique identifier for this event.
Declaration
string EventId { get; }
Property Value
Type | Description |
---|---|
System.String |
EventType
Gets a string representing this event's type.
Declaration
string EventType { get; }
Property Value
Type | Description |
---|---|
System.String |
ExcludeFromTelemetry
Gets a value indicating whether to exclude this event from telemetry logging.
Declaration
bool ExcludeFromTelemetry { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
RepeatAfter
Gets the time after which this event should be repeated. The event is not repeated if the value is not positive.
Declaration
TimeSpan RepeatAfter { get; }
Property Value
Type | Description |
---|---|
System.TimeSpan |
RequestorId
Gets the id of the requestor of this event, if available.
Declaration
uint RequestorId { get; }
Property Value
Type | Description |
---|---|
System.UInt32 |
State
Gets the event's state.
Declaration
EventState State { get; }
Property Value
Type | Description |
---|---|
EventState |
Methods
| Improve this Doc View SourceCancel()
Attempts to cancel this event.
Declaration
bool Cancel()
Returns
Type | Description |
---|---|
System.Boolean | True if the event is successfully cancelled, false otherwise. |
Delay(TimeSpan)
Attempts to delay this event.
Declaration
bool Delay(TimeSpan byTime)
Parameters
Type | Name | Description |
---|---|---|
System.TimeSpan | byTime | The time by which to delay the event. |
Returns
Type | Description |
---|---|
System.Boolean | True if the event is successfully delayed, false otherwise. |
Execute(IEventContext)
Executes the event logic.
Declaration
void Execute(IEventContext context)
Parameters
Type | Name | Description |
---|---|---|
IEventContext | context | The execution context. |
Expedite()
Attempts to expedite this event, requesting it to be fired immediately.
Declaration
bool Expedite()
Returns
Type | Description |
---|---|
System.Boolean | True if the event is successfully expedited, false otherwise. |
Events
| Improve this Doc View SourceCancelled
Delegate fired when this event is cancelled.
Declaration
event EventCancelledDelegate Cancelled
Event Type
Type | Description |
---|---|
EventCancelledDelegate |
Completed
Fired when this even is processed to completion (after no more repeats).
Declaration
event EventCompletedDelegate Completed
Event Type
Type | Description |
---|---|
EventCompletedDelegate |
Delayed
Delegate fired when this event is delayed.
Declaration
event EventDelayedDelegate Delayed
Event Type
Type | Description |
---|---|
EventDelayedDelegate |
Expedited
Delegate fired when this event is expedited.
Declaration
event EventExpeditedDelegate Expedited
Event Type
Type | Description |
---|---|
EventExpeditedDelegate |