Class SessionUsage
Represents a session's traffic since its last report, or its close, as the server sends them to the access manager.
public class SessionUsage
- Inheritance
-
SessionUsage
- Inherited Members
Properties
AdData
Gets or sets a rewarded ad's data, or null.
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingDefault)]
public string? AdData { get; set; }
Property Value
Closed
Gets or sets a value indicating whether the session closed, for older readers.
[Obsolete("Use ErrorCode")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingDefault)]
public bool Closed { get; set; }
Property Value
ErrorCode
Gets or sets the error the session closed with, or Ok where it goes on.
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingDefault)]
public SessionErrorCode ErrorCode { get; set; }
Property Value
Received
Gets or sets the session's received bytes since its last report.
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingDefault)]
public long Received { get; set; }
Property Value
Sent
Gets or sets the session's sent bytes since its last report.
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingDefault)]
public long Sent { get; set; }
Property Value
SessionId
Gets or sets the session's ID.
public required ulong SessionId { get; set; }
Property Value
Methods
ToTraffic()
Gets the usage's bytes as traffic.
public Traffic ToTraffic()
Returns
- Traffic
The sent and received bytes.