Method | Description | |
---|---|---|
AddToTotals ( |
Add up reporting totals so that a cumulative report can be given to the user via a dialog or other method.
|
|
BeginTick ( int tickNumber, System.Guid guid ) : void |
Begins a game engine tick indicating the tick number and the world state GUID.
|
|
Close ( ) : void |
Closes the PopulationData class and stops in any progress or pending connections.
|
|
CountOrganism ( string speciesName, PopulationChangeReason reason ) : void |
Counts a new organism and adds it to the reporting data.
|
|
CountOrganism ( string speciesName, PopulationChangeReason reason, int count ) : void |
Counts a new organism and adds it to the current dataset.
|
|
CreateReportDataSet ( ) : |
Creates a dataset in the form that the reporting server is expecting.
|
|
Data ( ) : |
Get the current reporting data.
|
|
EndTick ( int tickNumber ) : void |
Ends a game tick.
|
|
FillReportTable ( |
Fill the dataset with data in the format expected by the reporting server.
|
|
GetCurrentReportingStats ( System.Guid peerGuid, int tick ) : |
Gets a dataset of the current reporting statistics. This data can be used to update datagrids, charts, or other reporting facilities.
|
|
InitWebService ( ) : void |
Initializes the web service proxies. These are dynamically generated and so this method only generates them one time to improve memory and performance.
|
|
IsReportingTick ( int tickNumber ) : bool |
Determines if the current tick is a reporting tick. We only report data every so often, and a report tick is the tick when we report data.
|
|
NullToZero ( object value ) : |
Helper function to convert DBNull to 0
|
|
PopulationData ( bool reportData, Terrarium.Forms.TerrariumLed led ) : System |
Creates a new PopulationData class that can be used to report data and update a status LED.
|
|
UncountOrganism ( string speciesName, PopulationChangeReason reason ) : void |
Counts a new organism and removes it from the data.
|
|
UncountOrganism ( string speciesName, PopulationChangeReason reason, int count ) : void |
Counts a new organism and removes it from the reporting data.
|
Method | Description | |
---|---|---|
ReportData ( |
Attemps to report data to the central server.
|
|
ReportServiceCallback ( IAsyncResult asyncResult ) : void |
Callback method used by the reporting service methods to enable Async reporting.
|
|
ResetData ( ) : void |
Resets the data in the PopulationData class to initial values.
|
|
addValues ( object value1, object value2 ) : |
Helper function to add two database values together.
|
public AddToTotals ( |
||
totalsData | The current totals data. | |
newData | The new data to be added. | |
return | void |
public BeginTick ( int tickNumber, System.Guid guid ) : void | ||
tickNumber | int | The current tick number. |
guid | System.Guid | The world state GUID. |
return | void |
public CountOrganism ( string speciesName, PopulationChangeReason reason ) : void | ||
speciesName | string | The name of the species to add. |
reason | PopulationChangeReason | The reason for bing added. |
return | void |
public CountOrganism ( string speciesName, PopulationChangeReason reason, int count ) : void | ||
speciesName | string | The name of the species being added. |
reason | PopulationChangeReason | The reason for being added. |
count | int | The number to add. |
return | void |
public CreateReportDataSet ( ) : |
||
return |
public EndTick ( int tickNumber ) : void | ||
tickNumber | int | The tick number. Should always be the same as the call to BeginTick. |
return | void |
public FillReportTable ( |
||
totalsOnlyTable | A datatable in the reporting server format. | |
peerStateGuid | System.Guid | The current world state GUID. |
tickNumber | int | The current tick number. |
return | void |
public GetCurrentReportingStats ( System.Guid peerGuid, int tick ) : |
||
peerGuid | System.Guid | The world state GUID for this peer. |
tick | int | The current tick number. |
return |
public IsReportingTick ( int tickNumber ) : bool | ||
tickNumber | int | The current tick number. |
return | bool |
public static NullToZero ( object value ) : |
||
value | object | The value to check. |
return |
public PopulationData ( bool reportData, Terrarium.Forms.TerrariumLed led ) : System | ||
reportData | bool | Should data be reported to the server. |
led | Terrarium.Forms.TerrariumLed | An LED used to indicate status. |
return | System |
public UncountOrganism ( string speciesName, PopulationChangeReason reason ) : void | ||
speciesName | string | The name of the species the data is for. |
reason | PopulationChangeReason | The reason the creature is being removed. |
return | void |
public UncountOrganism ( string speciesName, PopulationChangeReason reason, int count ) : void | ||
speciesName | string | The name of the species the data is for. |
reason | PopulationChangeReason | The reason for removing. |
count | int | The number to remove. |
return | void |