Convenience methods for Timer.DelayCall( callback[,..] ) equivalent to calling a Timer.DelayCall( TimeSpan.Zero, callback[,..] )
This commit is contained in:
parent
6bd4e084c7
commit
2eff293be9
1 changed files with 15 additions and 0 deletions
|
|
@ -465,6 +465,11 @@ namespace Server
|
|||
|
||||
#region DelayCall(..)
|
||||
|
||||
public static Timer DelayCall( TimerCallback callback )
|
||||
{
|
||||
return DelayCall( TimeSpan.Zero, TimeSpan.Zero, 1, callback );
|
||||
}
|
||||
|
||||
public static Timer DelayCall( TimeSpan delay, TimerCallback callback )
|
||||
{
|
||||
return DelayCall( delay, TimeSpan.Zero, 1, callback );
|
||||
|
|
@ -489,6 +494,11 @@ namespace Server
|
|||
return t;
|
||||
}
|
||||
|
||||
public static Timer DelayCall( TimerStateCallback callback, object state )
|
||||
{
|
||||
return DelayCall( TimeSpan.Zero, TimeSpan.Zero, 1, callback, state );
|
||||
}
|
||||
|
||||
public static Timer DelayCall( TimeSpan delay, TimerStateCallback callback, object state )
|
||||
{
|
||||
return DelayCall( delay, TimeSpan.Zero, 1, callback, state );
|
||||
|
|
@ -515,6 +525,11 @@ namespace Server
|
|||
#endregion
|
||||
|
||||
#region DelayCall<T>(..)
|
||||
public static Timer DelayCall<T>( TimerStateCallback<T> callback, T state )
|
||||
{
|
||||
return DelayCall( TimeSpan.Zero, TimeSpan.Zero, 1, callback, state );
|
||||
}
|
||||
|
||||
public static Timer DelayCall<T>( TimeSpan delay, TimerStateCallback<T> callback, T state )
|
||||
{
|
||||
return DelayCall( delay, TimeSpan.Zero, 1, callback, state );
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue