Logo Search packages:      
Sourcecode: libjgroups-java version File versions

org::jgroups::stack::Protocol Class Reference

Inheritance diagram for org::jgroups::stack::Protocol:

org::jgroups::protocols::AUTH org::jgroups::protocols::AUTOCONF org::jgroups::protocols::BARRIER org::jgroups::protocols::BSH org::jgroups::protocols::CAUSAL org::jgroups::protocols::COMPRESS org::jgroups::protocols::DELAY org::jgroups::protocols::DELAY_JOIN_REQ org::jgroups::protocols::DISCARD org::jgroups::protocols::DISCARD_PAYLOAD org::jgroups::protocols::Discovery org::jgroups::protocols::DUMMY_TP org::jgroups::protocols::DUPL org::jgroups::protocols::ENCRYPT org::jgroups::protocols::EXAMPLE org::jgroups::protocols::FC org::jgroups::protocols::FD org::jgroups::protocols::FD_ALL org::jgroups::protocols::FD_SIMPLE org::jgroups::protocols::FD_SOCK org::jgroups::protocols::FRAG org::jgroups::protocols::FRAG2 org::jgroups::protocols::HDRS org::jgroups::protocols::HTOTAL org::jgroups::protocols::JMS org::jgroups::protocols::MERGE2 org::jgroups::protocols::MERGE3 org::jgroups::protocols::MERGEFAST org::jgroups::protocols::PARTITION org::jgroups::protocols::pbcast::FLUSH org::jgroups::protocols::pbcast::GMS org::jgroups::protocols::pbcast::NAKACK org::jgroups::protocols::pbcast::STABLE org::jgroups::protocols::pbcast::STATE_TRANSFER org::jgroups::protocols::pbcast::STREAMING_STATE_TRANSFER org::jgroups::protocols::PERF_TP org::jgroups::protocols::SEQUENCER org::jgroups::protocols::SFC org::jgroups::protocols::SHUFFLE org::jgroups::protocols::SIZE org::jgroups::protocols::SMACK org::jgroups::protocols::STATS org::jgroups::protocols::TP org::jgroups::protocols::UNICAST org::jgroups::protocols::VERIFY_SUSPECT org::jgroups::protocols::VIEW_SYNC org::jgroups::stack::ProtocolStack

List of all members.


Detailed Description

The Protocol class provides a set of common services for protocol layers. Each layer has to be a subclass of Protocol and override a number of methods (typically just up(), down() and getName(). Layers are stacked in a certain order to form a protocol stack. Events are passed from lower layers to upper ones and vice versa. E.g. a Message received by the UDP layer at the bottom will be passed to its higher layer as an Event. That layer will in turn pass the Event to its layer and so on, until a layer handles the Message and sends a response or discards it, the former resulting in another Event being passed down the stack.

The important thing to bear in mind is that Events have to passed on between layers in FIFO order which is guaranteed by the Protocol implementation and must be guranteed by subclasses implementing their on Event queuing.

Note that each class implementing interface Protocol MUST provide an empty, public constructor !

Author:
Bela Ban
Version:
Id
Protocol.java,v 1.54.2.1 2008/05/22 13:23:04 belaban Exp

Definition at line 36 of file Protocol.java.


Public Member Functions

void destroy ()
Object down (Event evt)
boolean downThreadEnabled ()
Map< String, Object > dumpStats ()
void enableStats (boolean flag)
Protocol getDownProtocol ()
abstract String getName ()
Properties getProperties ()
ProtocolStack getProtocolStack ()
ThreadFactory getThreadFactory ()
Protocol getUpProtocol ()
void init () throws Exception
String printStats ()
Vector< Integer > providedDownServices ()
Vector< Integer > providedUpServices ()
Vector< Integer > requiredDownServices ()
Vector< Integer > requiredUpServices ()
void resetStats ()
void setDownProtocol (Protocol down_prot)
boolean setProperties (Properties props)
boolean setPropertiesInternal (Properties props)
void setProtocolStack (ProtocolStack stack)
void setUpProtocol (Protocol up_prot)
void start () throws Exception
boolean statsEnabled ()
void stop ()
Object up (Event evt)
boolean upThreadEnabled ()

Protected Member Functions

TP getTransport ()

Protected Attributes

Protocol down_prot = null
final Log log = LogFactory.getLog(this.getClass())
final Properties props = new Properties()
ProtocolStack stack = null
boolean stats = true
Protocol up_prot = null

The documentation for this class was generated from the following file:

Generated by  Doxygen 1.6.0   Back to index