Class MetricsSnapshot.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<MetricsSnapshot.Builder>
com.google.protobuf.GeneratedMessage.Builder<MetricsSnapshot.Builder>
com.soulfiremc.grpc.generated.MetricsSnapshot.Builder
All Implemented Interfaces:
com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, MetricsSnapshotOrBuilder, Cloneable
Enclosing class:
MetricsSnapshot

public static final class MetricsSnapshot.Builder extends com.google.protobuf.GeneratedMessage.Builder<MetricsSnapshot.Builder> implements MetricsSnapshotOrBuilder
A single time-series data point sampled at a fixed interval.
Protobuf type soulfire.v1.MetricsSnapshot
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<MetricsSnapshot.Builder>
    • clear

      public MetricsSnapshot.Builder clear()
      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessage.Builder<MetricsSnapshot.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessage.Builder<MetricsSnapshot.Builder>
    • getDefaultInstanceForType

      public MetricsSnapshot getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      public MetricsSnapshot build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public MetricsSnapshot buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

      public MetricsSnapshot.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<MetricsSnapshot.Builder>
    • mergeFrom

      public MetricsSnapshot.Builder mergeFrom(MetricsSnapshot other)
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage.Builder<MetricsSnapshot.Builder>
    • mergeFrom

      public MetricsSnapshot.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<MetricsSnapshot.Builder>
      Throws:
      IOException
    • hasTimestamp

      public boolean hasTimestamp()
      When this snapshot was taken.
      
      .google.protobuf.Timestamp timestamp = 1;
      Specified by:
      hasTimestamp in interface MetricsSnapshotOrBuilder
      Returns:
      Whether the timestamp field is set.
    • getTimestamp

      public com.google.protobuf.Timestamp getTimestamp()
      When this snapshot was taken.
      
      .google.protobuf.Timestamp timestamp = 1;
      Specified by:
      getTimestamp in interface MetricsSnapshotOrBuilder
      Returns:
      The timestamp.
    • setTimestamp

      public MetricsSnapshot.Builder setTimestamp(com.google.protobuf.Timestamp value)
      When this snapshot was taken.
      
      .google.protobuf.Timestamp timestamp = 1;
    • setTimestamp

      public MetricsSnapshot.Builder setTimestamp(com.google.protobuf.Timestamp.Builder builderForValue)
      When this snapshot was taken.
      
      .google.protobuf.Timestamp timestamp = 1;
    • mergeTimestamp

      public MetricsSnapshot.Builder mergeTimestamp(com.google.protobuf.Timestamp value)
      When this snapshot was taken.
      
      .google.protobuf.Timestamp timestamp = 1;
    • clearTimestamp

      public MetricsSnapshot.Builder clearTimestamp()
      When this snapshot was taken.
      
      .google.protobuf.Timestamp timestamp = 1;
    • getTimestampBuilder

      public com.google.protobuf.Timestamp.Builder getTimestampBuilder()
      When this snapshot was taken.
      
      .google.protobuf.Timestamp timestamp = 1;
    • getTimestampOrBuilder

      public com.google.protobuf.TimestampOrBuilder getTimestampOrBuilder()
      When this snapshot was taken.
      
      .google.protobuf.Timestamp timestamp = 1;
      Specified by:
      getTimestampOrBuilder in interface MetricsSnapshotOrBuilder
    • getBotsOnline

      public int getBotsOnline()
      Number of bots currently connected to the Minecraft server.
      
      uint32 bots_online = 2;
      Specified by:
      getBotsOnline in interface MetricsSnapshotOrBuilder
      Returns:
      The botsOnline.
    • setBotsOnline

      public MetricsSnapshot.Builder setBotsOnline(int value)
      Number of bots currently connected to the Minecraft server.
      
      uint32 bots_online = 2;
      Parameters:
      value - The botsOnline to set.
      Returns:
      This builder for chaining.
    • clearBotsOnline

      public MetricsSnapshot.Builder clearBotsOnline()
      Number of bots currently connected to the Minecraft server.
      
      uint32 bots_online = 2;
      Returns:
      This builder for chaining.
    • getBotsTotal

      public int getBotsTotal()
      Total number of bots configured in the instance (online + offline).
      
      uint32 bots_total = 3;
      Specified by:
      getBotsTotal in interface MetricsSnapshotOrBuilder
      Returns:
      The botsTotal.
    • setBotsTotal

      public MetricsSnapshot.Builder setBotsTotal(int value)
      Total number of bots configured in the instance (online + offline).
      
      uint32 bots_total = 3;
      Parameters:
      value - The botsTotal to set.
      Returns:
      This builder for chaining.
    • clearBotsTotal

      public MetricsSnapshot.Builder clearBotsTotal()
      Total number of bots configured in the instance (online + offline).
      
      uint32 bots_total = 3;
      Returns:
      This builder for chaining.
    • getPacketsSentTotal

      public long getPacketsSentTotal()
      Cumulative packets sent across all bots since session start.
      
      uint64 packets_sent_total = 4;
      Specified by:
      getPacketsSentTotal in interface MetricsSnapshotOrBuilder
      Returns:
      The packetsSentTotal.
    • setPacketsSentTotal

      public MetricsSnapshot.Builder setPacketsSentTotal(long value)
      Cumulative packets sent across all bots since session start.
      
      uint64 packets_sent_total = 4;
      Parameters:
      value - The packetsSentTotal to set.
      Returns:
      This builder for chaining.
    • clearPacketsSentTotal

      public MetricsSnapshot.Builder clearPacketsSentTotal()
      Cumulative packets sent across all bots since session start.
      
      uint64 packets_sent_total = 4;
      Returns:
      This builder for chaining.
    • getPacketsReceivedTotal

      public long getPacketsReceivedTotal()
      Cumulative packets received across all bots since session start.
      
      uint64 packets_received_total = 5;
      Specified by:
      getPacketsReceivedTotal in interface MetricsSnapshotOrBuilder
      Returns:
      The packetsReceivedTotal.
    • setPacketsReceivedTotal

      public MetricsSnapshot.Builder setPacketsReceivedTotal(long value)
      Cumulative packets received across all bots since session start.
      
      uint64 packets_received_total = 5;
      Parameters:
      value - The packetsReceivedTotal to set.
      Returns:
      This builder for chaining.
    • clearPacketsReceivedTotal

      public MetricsSnapshot.Builder clearPacketsReceivedTotal()
      Cumulative packets received across all bots since session start.
      
      uint64 packets_received_total = 5;
      Returns:
      This builder for chaining.
    • getBytesSentTotal

      public long getBytesSentTotal()
      Cumulative bytes sent across all bots since session start.
      
      uint64 bytes_sent_total = 6;
      Specified by:
      getBytesSentTotal in interface MetricsSnapshotOrBuilder
      Returns:
      The bytesSentTotal.
    • setBytesSentTotal

      public MetricsSnapshot.Builder setBytesSentTotal(long value)
      Cumulative bytes sent across all bots since session start.
      
      uint64 bytes_sent_total = 6;
      Parameters:
      value - The bytesSentTotal to set.
      Returns:
      This builder for chaining.
    • clearBytesSentTotal

      public MetricsSnapshot.Builder clearBytesSentTotal()
      Cumulative bytes sent across all bots since session start.
      
      uint64 bytes_sent_total = 6;
      Returns:
      This builder for chaining.
    • getBytesReceivedTotal

      public long getBytesReceivedTotal()
      Cumulative bytes received across all bots since session start.
      
      uint64 bytes_received_total = 7;
      Specified by:
      getBytesReceivedTotal in interface MetricsSnapshotOrBuilder
      Returns:
      The bytesReceivedTotal.
    • setBytesReceivedTotal

      public MetricsSnapshot.Builder setBytesReceivedTotal(long value)
      Cumulative bytes received across all bots since session start.
      
      uint64 bytes_received_total = 7;
      Parameters:
      value - The bytesReceivedTotal to set.
      Returns:
      This builder for chaining.
    • clearBytesReceivedTotal

      public MetricsSnapshot.Builder clearBytesReceivedTotal()
      Cumulative bytes received across all bots since session start.
      
      uint64 bytes_received_total = 7;
      Returns:
      This builder for chaining.
    • getPacketsSentPerSecond

      public double getPacketsSentPerSecond()
      Current rate of packets sent per second (computed from counter deltas).
      
      double packets_sent_per_second = 8;
      Specified by:
      getPacketsSentPerSecond in interface MetricsSnapshotOrBuilder
      Returns:
      The packetsSentPerSecond.
    • setPacketsSentPerSecond

      public MetricsSnapshot.Builder setPacketsSentPerSecond(double value)
      Current rate of packets sent per second (computed from counter deltas).
      
      double packets_sent_per_second = 8;
      Parameters:
      value - The packetsSentPerSecond to set.
      Returns:
      This builder for chaining.
    • clearPacketsSentPerSecond

      public MetricsSnapshot.Builder clearPacketsSentPerSecond()
      Current rate of packets sent per second (computed from counter deltas).
      
      double packets_sent_per_second = 8;
      Returns:
      This builder for chaining.
    • getPacketsReceivedPerSecond

      public double getPacketsReceivedPerSecond()
      Current rate of packets received per second (computed from counter deltas).
      
      double packets_received_per_second = 9;
      Specified by:
      getPacketsReceivedPerSecond in interface MetricsSnapshotOrBuilder
      Returns:
      The packetsReceivedPerSecond.
    • setPacketsReceivedPerSecond

      public MetricsSnapshot.Builder setPacketsReceivedPerSecond(double value)
      Current rate of packets received per second (computed from counter deltas).
      
      double packets_received_per_second = 9;
      Parameters:
      value - The packetsReceivedPerSecond to set.
      Returns:
      This builder for chaining.
    • clearPacketsReceivedPerSecond

      public MetricsSnapshot.Builder clearPacketsReceivedPerSecond()
      Current rate of packets received per second (computed from counter deltas).
      
      double packets_received_per_second = 9;
      Returns:
      This builder for chaining.
    • getBytesSentPerSecond

      public double getBytesSentPerSecond()
      Current rate of bytes sent per second (computed from counter deltas).
      
      double bytes_sent_per_second = 10;
      Specified by:
      getBytesSentPerSecond in interface MetricsSnapshotOrBuilder
      Returns:
      The bytesSentPerSecond.
    • setBytesSentPerSecond

      public MetricsSnapshot.Builder setBytesSentPerSecond(double value)
      Current rate of bytes sent per second (computed from counter deltas).
      
      double bytes_sent_per_second = 10;
      Parameters:
      value - The bytesSentPerSecond to set.
      Returns:
      This builder for chaining.
    • clearBytesSentPerSecond

      public MetricsSnapshot.Builder clearBytesSentPerSecond()
      Current rate of bytes sent per second (computed from counter deltas).
      
      double bytes_sent_per_second = 10;
      Returns:
      This builder for chaining.
    • getBytesReceivedPerSecond

      public double getBytesReceivedPerSecond()
      Current rate of bytes received per second (computed from counter deltas).
      
      double bytes_received_per_second = 11;
      Specified by:
      getBytesReceivedPerSecond in interface MetricsSnapshotOrBuilder
      Returns:
      The bytesReceivedPerSecond.
    • setBytesReceivedPerSecond

      public MetricsSnapshot.Builder setBytesReceivedPerSecond(double value)
      Current rate of bytes received per second (computed from counter deltas).
      
      double bytes_received_per_second = 11;
      Parameters:
      value - The bytesReceivedPerSecond to set.
      Returns:
      This builder for chaining.
    • clearBytesReceivedPerSecond

      public MetricsSnapshot.Builder clearBytesReceivedPerSecond()
      Current rate of bytes received per second (computed from counter deltas).
      
      double bytes_received_per_second = 11;
      Returns:
      This builder for chaining.
    • getAvgTickDurationMs

      public double getAvgTickDurationMs()
      Average tick duration across all bots in milliseconds.
      
      double avg_tick_duration_ms = 12;
      Specified by:
      getAvgTickDurationMs in interface MetricsSnapshotOrBuilder
      Returns:
      The avgTickDurationMs.
    • setAvgTickDurationMs

      public MetricsSnapshot.Builder setAvgTickDurationMs(double value)
      Average tick duration across all bots in milliseconds.
      
      double avg_tick_duration_ms = 12;
      Parameters:
      value - The avgTickDurationMs to set.
      Returns:
      This builder for chaining.
    • clearAvgTickDurationMs

      public MetricsSnapshot.Builder clearAvgTickDurationMs()
      Average tick duration across all bots in milliseconds.
      
      double avg_tick_duration_ms = 12;
      Returns:
      This builder for chaining.
    • getMaxTickDurationMs

      public double getMaxTickDurationMs()
      Maximum tick duration observed across all bots in milliseconds.
      Reset each sampling interval.
      
      double max_tick_duration_ms = 13;
      Specified by:
      getMaxTickDurationMs in interface MetricsSnapshotOrBuilder
      Returns:
      The maxTickDurationMs.
    • setMaxTickDurationMs

      public MetricsSnapshot.Builder setMaxTickDurationMs(double value)
      Maximum tick duration observed across all bots in milliseconds.
      Reset each sampling interval.
      
      double max_tick_duration_ms = 13;
      Parameters:
      value - The maxTickDurationMs to set.
      Returns:
      This builder for chaining.
    • clearMaxTickDurationMs

      public MetricsSnapshot.Builder clearMaxTickDurationMs()
      Maximum tick duration observed across all bots in milliseconds.
      Reset each sampling interval.
      
      double max_tick_duration_ms = 13;
      Returns:
      This builder for chaining.
    • getAvgHealth

      public double getAvgHealth()
      Average health across all online bots with player data.
      Range: 0 to 20 (Minecraft health points).
      
      double avg_health = 14;
      Specified by:
      getAvgHealth in interface MetricsSnapshotOrBuilder
      Returns:
      The avgHealth.
    • setAvgHealth

      public MetricsSnapshot.Builder setAvgHealth(double value)
      Average health across all online bots with player data.
      Range: 0 to 20 (Minecraft health points).
      
      double avg_health = 14;
      Parameters:
      value - The avgHealth to set.
      Returns:
      This builder for chaining.
    • clearAvgHealth

      public MetricsSnapshot.Builder clearAvgHealth()
      Average health across all online bots with player data.
      Range: 0 to 20 (Minecraft health points).
      
      double avg_health = 14;
      Returns:
      This builder for chaining.
    • getAvgFoodLevel

      public double getAvgFoodLevel()
      Average food level across all online bots with player data.
      Range: 0 to 20 (Minecraft food points).
      
      double avg_food_level = 15;
      Specified by:
      getAvgFoodLevel in interface MetricsSnapshotOrBuilder
      Returns:
      The avgFoodLevel.
    • setAvgFoodLevel

      public MetricsSnapshot.Builder setAvgFoodLevel(double value)
      Average food level across all online bots with player data.
      Range: 0 to 20 (Minecraft food points).
      
      double avg_food_level = 15;
      Parameters:
      value - The avgFoodLevel to set.
      Returns:
      This builder for chaining.
    • clearAvgFoodLevel

      public MetricsSnapshot.Builder clearAvgFoodLevel()
      Average food level across all online bots with player data.
      Range: 0 to 20 (Minecraft food points).
      
      double avg_food_level = 15;
      Returns:
      This builder for chaining.
    • getTotalLoadedChunks

      public int getTotalLoadedChunks()
      Total number of loaded chunks across all online bots.
      
      uint32 total_loaded_chunks = 16;
      Specified by:
      getTotalLoadedChunks in interface MetricsSnapshotOrBuilder
      Returns:
      The totalLoadedChunks.
    • setTotalLoadedChunks

      public MetricsSnapshot.Builder setTotalLoadedChunks(int value)
      Total number of loaded chunks across all online bots.
      
      uint32 total_loaded_chunks = 16;
      Parameters:
      value - The totalLoadedChunks to set.
      Returns:
      This builder for chaining.
    • clearTotalLoadedChunks

      public MetricsSnapshot.Builder clearTotalLoadedChunks()
      Total number of loaded chunks across all online bots.
      
      uint32 total_loaded_chunks = 16;
      Returns:
      This builder for chaining.
    • getTotalTrackedEntities

      public int getTotalTrackedEntities()
      Total number of tracked entities across all online bots.
      
      uint32 total_tracked_entities = 17;
      Specified by:
      getTotalTrackedEntities in interface MetricsSnapshotOrBuilder
      Returns:
      The totalTrackedEntities.
    • setTotalTrackedEntities

      public MetricsSnapshot.Builder setTotalTrackedEntities(int value)
      Total number of tracked entities across all online bots.
      
      uint32 total_tracked_entities = 17;
      Parameters:
      value - The totalTrackedEntities to set.
      Returns:
      This builder for chaining.
    • clearTotalTrackedEntities

      public MetricsSnapshot.Builder clearTotalTrackedEntities()
      Total number of tracked entities across all online bots.
      
      uint32 total_tracked_entities = 17;
      Returns:
      This builder for chaining.
    • getConnections

      public int getConnections()
      Connection events since the previous snapshot.
      
      uint32 connections = 18;
      Specified by:
      getConnections in interface MetricsSnapshotOrBuilder
      Returns:
      The connections.
    • setConnections

      public MetricsSnapshot.Builder setConnections(int value)
      Connection events since the previous snapshot.
      
      uint32 connections = 18;
      Parameters:
      value - The connections to set.
      Returns:
      This builder for chaining.
    • clearConnections

      public MetricsSnapshot.Builder clearConnections()
      Connection events since the previous snapshot.
      
      uint32 connections = 18;
      Returns:
      This builder for chaining.
    • getDisconnections

      public int getDisconnections()
      Disconnection events since the previous snapshot.
      
      uint32 disconnections = 19;
      Specified by:
      getDisconnections in interface MetricsSnapshotOrBuilder
      Returns:
      The disconnections.
    • setDisconnections

      public MetricsSnapshot.Builder setDisconnections(int value)
      Disconnection events since the previous snapshot.
      
      uint32 disconnections = 19;
      Parameters:
      value - The disconnections to set.
      Returns:
      This builder for chaining.
    • clearDisconnections

      public MetricsSnapshot.Builder clearDisconnections()
      Disconnection events since the previous snapshot.
      
      uint32 disconnections = 19;
      Returns:
      This builder for chaining.