Show / Hide Table of Contents

Class TimeLimit

Represents time limit which may be checked for expiration and overtime.

Inheritance
System.Object
TimeLimit
Namespace: Eco.Shared.Time
Assembly: Eco.Shared.dll
Syntax
public sealed class TimeLimit : ValueType

Properties

Expired

Declaration
public bool Expired { get; }
Property Value
Type Description
System.Boolean

Overtime

Declaration
public TimeSpan Overtime { get; }
Property Value
Type Description
System.TimeSpan

OvertimeTicks

Declaration
public long OvertimeTicks { get; }
Property Value
Type Description
System.Int64

Methods

FromMilliseconds(Double)

Declaration
public static TimeLimit FromMilliseconds(double ms)
Parameters
Type Name Description
System.Double ms
Returns
Type Description
TimeLimit

FromSeconds(Double)

Declaration
public static TimeLimit FromSeconds(double seconds)
Parameters
Type Name Description
System.Double seconds
Returns
Type Description
TimeLimit

FromTicks(Int64)

Declaration
public static TimeLimit FromTicks(long ticks)
Parameters
Type Name Description
System.Int64 ticks
Returns
Type Description
TimeLimit

FromTimeSpan(TimeSpan)

Declaration
public static TimeLimit FromTimeSpan(TimeSpan timeSpan)
Parameters
Type Name Description
System.TimeSpan timeSpan
Returns
Type Description
TimeLimit

SubLimitFromTicks(Int64, out Int64)

Creates new limit with upper bound set to current limit.

Declaration
public TimeLimit SubLimitFromTicks(long ticks, out long truncatedTicks)
Parameters
Type Name Description
System.Int64 ticks

new limit ticks.

System.Int64 truncatedTicks

number of ticks truncated to match current limit.

Returns
Type Description
TimeLimit

new TimeLimit object.

Extension Methods

CommandLine.FeedFromCommandLine(Object)
CommandLine.ToCommandLineArgs(Object, Func<Object, Boolean>)
ListUtil.DepthFirstTraversal<T>(T, Func<T, IEnumerable<T>>)
EnumerableExtensions.SingleItemAsEnumerable<T>(T)
EventUtils.RaiseEvent<TEventArgs>(Object, String, TEventArgs)
PredicateUtils.MatchesAll<TEnumerable, T>(T, TEnumerable)
PredicateUtils.MatchesAll<T>(T, Func<T, Boolean>[])
PredicateUtils.MatchesAny<TEnumerable, T>(T, TEnumerable)
ReflectionUtils.PropertyValue<T>(Object, PropertyInfo)
ReflectionUtils.TryGetPropertyValueByName<T>(Object, String, out T)
ReflectionUtils.GetPropertyValueByName<T>(Object, String)
ReflectionUtils.SetPropertyByName(Object, String, Object)
ReflectionUtils.GetStructPropertyByName<T>(Object, String)
ReflectionUtils.GetStringPropertyByName(Object, String)
ReflectionUtils.ZipByProperty<T>(Object, Object, Object, Func<T, T, T>)
☀
☾
In This Article
Back to top
Copyright (c) Strange Loop Games 2021
☀
☾