Class Timer
Represents a timer that executes an action every certain time.
Inherited Members
Namespace: Evergine.Framework.Services
Assembly: Evergine.Framework.dll
Syntax
public class Timer
Fields
Action
The action to execute when the interval time passes.
Declaration
public Action Action
Field Value
Type | Description |
---|---|
Action |
InitialInterval
Initial firing interval of this instance.
Declaration
public TimeSpan InitialInterval
Field Value
Type | Description |
---|---|
TimeSpan |
Interval
The time that has passed in this current interval. It is reset to
InitialInterval when it reaches zero unless
Looped is set to true
.
Declaration
public TimeSpan Interval
Field Value
Type | Description |
---|---|
TimeSpan |
Looped
Whether this instance will fire its action once, or more times.
Declaration
public bool Looped
Field Value
Type | Description |
---|---|
bool |
MarkedToDelete
The marked to delete.
Declaration
public bool MarkedToDelete
Field Value
Type | Description |
---|---|
bool |
Name
Name of this instance.
Declaration
public string Name
Field Value
Type | Description |
---|---|
string |
Properties
IsPaused
Gets a value indicating whether the timer is paused.
Declaration
public bool IsPaused { get; }
Property Value
Type | Description |
---|---|
bool |
Methods
Pause()
Pause the timer.
Declaration
public void Pause()
Resume()
Resume the timer.
Declaration
public void Resume()