Class PeerStats

java.lang.Object
org.stellar.sdk.xdr.PeerStats

public class PeerStats extends Object
PeerStats's original definition in the XDR file is:
 struct PeerStats
 {
     NodeID id;
     string versionStr<100>;
     uint64 messagesRead;
     uint64 messagesWritten;
     uint64 bytesRead;
     uint64 bytesWritten;
     uint64 secondsConnected;

     uint64 uniqueFloodBytesRecv;
     uint64 duplicateFloodBytesRecv;
     uint64 uniqueFetchBytesRecv;
     uint64 duplicateFetchBytesRecv;

     uint64 uniqueFloodMessageRecv;
     uint64 duplicateFloodMessageRecv;
     uint64 uniqueFetchMessageRecv;
     uint64 duplicateFetchMessageRecv;
 };
 
  • Constructor Details

    • PeerStats

      public PeerStats()
    • PeerStats

      public PeerStats(NodeID id, XdrString versionStr, Uint64 messagesRead, Uint64 messagesWritten, Uint64 bytesRead, Uint64 bytesWritten, Uint64 secondsConnected, Uint64 uniqueFloodBytesRecv, Uint64 duplicateFloodBytesRecv, Uint64 uniqueFetchBytesRecv, Uint64 duplicateFetchBytesRecv, Uint64 uniqueFloodMessageRecv, Uint64 duplicateFloodMessageRecv, Uint64 uniqueFetchMessageRecv, Uint64 duplicateFetchMessageRecv)
  • Method Details

    • encode

      public void encode(XdrDataOutputStream stream) throws IOException
      Throws:
      IOException
    • decode

      public static PeerStats decode(XdrDataInputStream stream) throws IOException
      Throws:
      IOException
    • fromXdrBase64

      public static PeerStats fromXdrBase64(String xdr) throws IOException
      Throws:
      IOException
    • fromXdrByteArray

      public static PeerStats fromXdrByteArray(byte[] xdr) throws IOException
      Throws:
      IOException
    • builder

      public static PeerStats.PeerStatsBuilder builder()
    • toBuilder

      public PeerStats.PeerStatsBuilder toBuilder()
    • getId

      public NodeID getId()
    • getVersionStr

      public XdrString getVersionStr()
    • getMessagesRead

      public Uint64 getMessagesRead()
    • getMessagesWritten

      public Uint64 getMessagesWritten()
    • getBytesRead

      public Uint64 getBytesRead()
    • getBytesWritten

      public Uint64 getBytesWritten()
    • getSecondsConnected

      public Uint64 getSecondsConnected()
    • getUniqueFloodBytesRecv

      public Uint64 getUniqueFloodBytesRecv()
    • getDuplicateFloodBytesRecv

      public Uint64 getDuplicateFloodBytesRecv()
    • getUniqueFetchBytesRecv

      public Uint64 getUniqueFetchBytesRecv()
    • getDuplicateFetchBytesRecv

      public Uint64 getDuplicateFetchBytesRecv()
    • getUniqueFloodMessageRecv

      public Uint64 getUniqueFloodMessageRecv()
    • getDuplicateFloodMessageRecv

      public Uint64 getDuplicateFloodMessageRecv()
    • getUniqueFetchMessageRecv

      public Uint64 getUniqueFetchMessageRecv()
    • getDuplicateFetchMessageRecv

      public Uint64 getDuplicateFetchMessageRecv()
    • setId

      public void setId(NodeID id)
    • setVersionStr

      public void setVersionStr(XdrString versionStr)
    • setMessagesRead

      public void setMessagesRead(Uint64 messagesRead)
    • setMessagesWritten

      public void setMessagesWritten(Uint64 messagesWritten)
    • setBytesRead

      public void setBytesRead(Uint64 bytesRead)
    • setBytesWritten

      public void setBytesWritten(Uint64 bytesWritten)
    • setSecondsConnected

      public void setSecondsConnected(Uint64 secondsConnected)
    • setUniqueFloodBytesRecv

      public void setUniqueFloodBytesRecv(Uint64 uniqueFloodBytesRecv)
    • setDuplicateFloodBytesRecv

      public void setDuplicateFloodBytesRecv(Uint64 duplicateFloodBytesRecv)
    • setUniqueFetchBytesRecv

      public void setUniqueFetchBytesRecv(Uint64 uniqueFetchBytesRecv)
    • setDuplicateFetchBytesRecv

      public void setDuplicateFetchBytesRecv(Uint64 duplicateFetchBytesRecv)
    • setUniqueFloodMessageRecv

      public void setUniqueFloodMessageRecv(Uint64 uniqueFloodMessageRecv)
    • setDuplicateFloodMessageRecv

      public void setDuplicateFloodMessageRecv(Uint64 duplicateFloodMessageRecv)
    • setUniqueFetchMessageRecv

      public void setUniqueFetchMessageRecv(Uint64 uniqueFetchMessageRecv)
    • setDuplicateFetchMessageRecv

      public void setDuplicateFetchMessageRecv(Uint64 duplicateFetchMessageRecv)
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • toXdrBase64

      default String toXdrBase64() throws IOException
      Throws:
      IOException
    • toXdrByteArray

      default byte[] toXdrByteArray() throws IOException
      Throws:
      IOException