Class SandboxStreamEvent
- Namespace
- Openshell.V1
- Assembly
- OpenShell.Sdk.dll
One event in a sandbox watch stream.
public sealed class SandboxStreamEvent : IMessage<SandboxStreamEvent>, IEquatable<SandboxStreamEvent>, IDeepCloneable<SandboxStreamEvent>, IBufferMessage, IMessage
- Inheritance
-
SandboxStreamEvent
- Implements
-
IMessage<SandboxStreamEvent>IDeepCloneable<SandboxStreamEvent>IBufferMessageIMessage
- Inherited Members
Constructors
SandboxStreamEvent()
public SandboxStreamEvent()
SandboxStreamEvent(SandboxStreamEvent)
public SandboxStreamEvent(SandboxStreamEvent other)
Parameters
otherSandboxStreamEvent
Fields
CursorFieldNumber
Field number for the "cursor" field.
public const int CursorFieldNumber = 6
Field Value
DraftPolicyUpdateFieldNumber
Field number for the "draft_policy_update" field.
public const int DraftPolicyUpdateFieldNumber = 5
Field Value
EventFieldNumber
Field number for the "event" field.
public const int EventFieldNumber = 3
Field Value
LogFieldNumber
Field number for the "log" field.
public const int LogFieldNumber = 2
Field Value
SandboxFieldNumber
Field number for the "sandbox" field.
public const int SandboxFieldNumber = 1
Field Value
WarningFieldNumber
Field number for the "warning" field.
public const int WarningFieldNumber = 4
Field Value
Properties
Cursor
Opaque position in this sandbox's cursor space, shared across the resumable log and platform event sources. Empty for non-resumable events (status snapshots, warnings).
Do not parse this token; its encoding is not part of the contract. The only supported operation is comparing two non-empty cursors observed on the same stream and keeping the greater one, then passing it as WatchSandboxRequest.resume_after_cursor to resume without loss or duplication. That comparison is a plain byte-wise string comparison. It is well defined only within one stream: a stream never spans two cursor spaces, because a reset ends it.
public string Cursor { get; set; }
Property Value
Descriptor
public static MessageDescriptor Descriptor { get; }
Property Value
- MessageDescriptor
DraftPolicyUpdate
Draft policy update notification.
public DraftPolicyUpdate DraftPolicyUpdate { get; set; }
Property Value
Event
One platform event.
public PlatformEvent Event { get; set; }
Property Value
Log
One server log line/event.
public SandboxLogLine Log { get; set; }
Property Value
Parser
public static MessageParser<SandboxStreamEvent> Parser { get; }
Property Value
- MessageParser<SandboxStreamEvent>
PayloadCase
public SandboxStreamEvent.PayloadOneofCase PayloadCase { get; }
Property Value
Sandbox
Latest sandbox snapshot.
public Sandbox Sandbox { get; set; }
Property Value
Warning
Recoverable warning from the server, e.g. messages dropped because a broadcast receiver lagged. The stream continues after this warning; the client can detect the gap from the warning itself.
public SandboxStreamWarning Warning { get; set; }
Property Value
Methods
CalculateSize()
Calculates the size of this message in Protocol Buffer wire format, in bytes.
public int CalculateSize()
Returns
- int
The number of bytes required to write this message to a coded output stream.
ClearPayload()
public void ClearPayload()
Clone()
Creates a deep clone of this object.
public SandboxStreamEvent Clone()
Returns
- SandboxStreamEvent
A deep clone of this object.
Equals(SandboxStreamEvent)
Indicates whether the current object is equal to another object of the same type.
public bool Equals(SandboxStreamEvent other)
Parameters
otherSandboxStreamEventAn object to compare with this object.
Returns
Equals(object)
Determines whether the specified object is equal to the current object.
public override bool Equals(object other)
Parameters
otherobject
Returns
GetHashCode()
Serves as the default hash function.
public override int GetHashCode()
Returns
- int
A hash code for the current object.
MergeFrom(CodedInputStream)
Merges the data from the specified coded input stream with the current message.
public void MergeFrom(CodedInputStream input)
Parameters
inputCodedInputStream
Remarks
See the user guide for precise merge semantics.
MergeFrom(SandboxStreamEvent)
Merges the given message into this one.
public void MergeFrom(SandboxStreamEvent other)
Parameters
otherSandboxStreamEvent
Remarks
See the user guide for precise merge semantics.
ToString()
Returns a string that represents the current object.
public override string ToString()
Returns
- string
A string that represents the current object.
WriteTo(CodedOutputStream)
Writes the data to the given coded output stream.
public void WriteTo(CodedOutputStream output)
Parameters
outputCodedOutputStreamCoded output stream to write the data to. Must not be null.