API Referenceglobal
GlobalStatsclass
object→GlobalStats
Methods5
Showing 5 methods
public Sandbox.Services.Stats.GlobalStats Copy()
Make a copy of this class. Allows you to store the stats from a point in time.
public Sandbox.Services.Stats.GlobalStat Get(string name)
Get a stat by name. Will return an empty stat if not found
| Parameter | Type | Description |
|---|---|---|
| name | string | — |
public virtual sealed System.Collections.Generic.IEnumerator`1<Sandbox.Services.Stats.GlobalStat> GetEnumerator()
public System.Threading.Tasks.Task Refresh()
Refresh these global stats - grab the latest values
Returns:
Task—public bool TryGet(string name, Sandbox.Services.Stats.GlobalStat stat)
Get a stat by name, returns true if found
| Parameter | Type | Description |
|---|---|---|
| name | string | — |
| stat | GlobalStat | — |
Returns:
bool—No results match this filter.
Properties3
Showing 3 properties
public bool Sandbox.Services.Stats.GlobalStats.IsRefreshing { get; set; }
True if we're currently fetching new stats
Returns:
bool—public Sandbox.Services.Stats.GlobalStat Sandbox.Services.Stats.GlobalStats.Item { get; set; }
public System.DateTime Sandbox.Services.Stats.GlobalStats.LastRefresh { get; set; }
The UTC datetime when we last fetched new stats
Returns:
DateTime—No results match this filter.