Rice Pastry API

org.mpisws.p2p.transport
Interface TransportLayerListener<Identifier>

Type Parameters:
Identifier -
All Known Subinterfaces:
PriorityTransportLayerListener<Identifier>

public interface TransportLayerListener<Identifier>

Can be installed on a ListenableTransportLayer

Author:
Jeff Hoye

Method Summary
 void read(int bytes, Identifier i, java.util.Map<java.lang.String,java.lang.Object> options, boolean passthrough, boolean socket)
          Called when downstream bandwidth was consumed.
 void wrote(int bytes, Identifier i, java.util.Map<java.lang.String,java.lang.Object> options, boolean passthrough, boolean socket)
          Called when upstream bandwidth was consumed.
 

Method Detail

wrote

void wrote(int bytes,
           Identifier i,
           java.util.Map<java.lang.String,java.lang.Object> options,
           boolean passthrough,
           boolean socket)
Called when upstream bandwidth was consumed.

Parameters:
bytes - how many
i - who
options -
passthrough - for bytes that were written on behalf of another layer, false if it is generated by this layer(overhead)
socket - true if it was on a socket, false if it was a message

read

void read(int bytes,
          Identifier i,
          java.util.Map<java.lang.String,java.lang.Object> options,
          boolean passthrough,
          boolean socket)
Called when downstream bandwidth was consumed.

Parameters:
bytes - how many
i - who
options -
passthrough - for bytes that were written on behalf of another layer, false if it is generated by this layer(overhead)
socket - true if it was on a socket, false if it was a message

Rice Pastry API

Copyright © 2001-2005 - Rice Pastry.


Imprint-Dataprotection