Interface PEPeerStats

    • Method Detail

      • setPeer

        void setPeer​(PEPeer p)
      • dataBytesSent

        void dataBytesSent​(int num_bytes)
        The given number of data (payload) bytes have been sent to the peer.
        Parameters:
        num_bytes -
      • protocolBytesSent

        void protocolBytesSent​(int num_bytes)
        The given number of protocol (overhead) bytes have been sent to the peer.
        Parameters:
        num_bytes -
      • dataBytesReceived

        void dataBytesReceived​(int num_bytes)
        The given number of data (payload) bytes have been received from the peer.
        Parameters:
        num_bytes -
      • protocolBytesReceived

        void protocolBytesReceived​(int num_bytes)
        The given number of protocol (overhead) bytes have been received from the peer.
        Parameters:
        num_bytes -
      • bytesDiscarded

        void bytesDiscarded​(int num_bytes)
        The given number of bytes received from the peer were discarded.
        Parameters:
        num_bytes -
      • hasNewPiece

        void hasNewPiece​(int piece_size)
        The peer has completed a piece of the given byte size.
        Parameters:
        piece_size -
      • statisticalSentPiece

        void statisticalSentPiece​(int piece_size)
        The peer has statistically sent a piecce of the given byte size.
        Parameters:
        piece_size -
      • getDataReceiveRate

        long getDataReceiveRate()
        Get the the average bytes-per-second speed that we are receiving piece data from the peer.
        Returns:
        average speed.
      • getProtocolReceiveRate

        long getProtocolReceiveRate()
        Get the the average bytes-per-second speed that we are receiving protocol messages from the peer.
        Returns:
        average speed.
      • getTotalDataBytesReceived

        long getTotalDataBytesReceived()
        Get the total number of data (payload) bytes received from the peer.
        Returns:
        total
      • getTotalProtocolBytesReceived

        long getTotalProtocolBytesReceived()
        Get the total number of protocol (overhead) bytes received from the peer.
        Returns:
        total
      • getDataSendRate

        long getDataSendRate()
        Get the the average bytes-per-second speed that we are sending piece data to the peer.
        Returns:
        average speed.
      • getProtocolSendRate

        long getProtocolSendRate()
        Get the the average bytes-per-second speed that we are sending protocol messages to the peer.
        Returns:
        average speed.
      • getTotalDataBytesSent

        long getTotalDataBytesSent()
        Get the total number of data (payload) bytes sent to the peer.
        Returns:
        total
      • getTotalProtocolBytesSent

        long getTotalProtocolBytesSent()
        Get the total number of protocol (overhead) bytes sent to the peer.
        Returns:
        total
      • getSmoothDataReceiveRate

        long getSmoothDataReceiveRate()
        Get the the longer-average bytes-per-second speed at which the peer is uploading data to us.
        Returns:
        average speed
      • getTotalBytesDiscarded

        long getTotalBytesDiscarded()
        Get the total number of discarded bytes received from the peer.
        Returns:
        total discarded
      • getEstimatedDownloadRateOfPeer

        long getEstimatedDownloadRateOfPeer()
        Get the estimated total download rate of the peer.
        Returns:
        estimated rate in bytes-per-second
      • getEstimatedUploadRateOfPeer

        long getEstimatedUploadRateOfPeer()
        Get the estimated total upload rate of the peer.
        Returns:
        estimated rate in bytes-per-second
      • getEstimatedSecondsToCompletion

        long getEstimatedSecondsToCompletion()
      • getTotalBytesDownloadedByPeer

        long getTotalBytesDownloadedByPeer()
        Get the number of bytes downloaded in total by this peer (includes data downloaded from all other peers).
        Returns:
        total download bytes done
      • diskReadComplete

        void diskReadComplete​(long bytes)
        Disk access stats methods
        Parameters:
        bytes -
      • getTotalDiskReadCount

        int getTotalDiskReadCount()
      • getAggregatedDiskReadCount

        int getAggregatedDiskReadCount()
      • getTotalDiskReadBytes

        long getTotalDiskReadBytes()
      • setUploadRateLimitBytesPerSecond

        void setUploadRateLimitBytesPerSecond​(int bytes)
      • setDownloadRateLimitBytesPerSecond

        void setDownloadRateLimitBytesPerSecond​(int bytes)
      • getUploadRateLimitBytesPerSecond

        int getUploadRateLimitBytesPerSecond()
      • getDownloadRateLimitBytesPerSecond

        int getDownloadRateLimitBytesPerSecond()
      • getPermittedBytesToSend

        int getPermittedBytesToSend()
      • permittedSendBytesUsed

        void permittedSendBytesUsed​(int num)
      • getPermittedBytesToReceive

        int getPermittedBytesToReceive()
      • permittedReceiveBytesUsed

        void permittedReceiveBytesUsed​(int num)