All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class JavaGroups.JavaStack.Protocols.STATE_TRANSFER

java.lang.Object
   |
   +----JavaGroups.JavaStack.Protocol
           |
           +----JavaGroups.JavaStack.Protocols.STATE_TRANSFER

public class STATE_TRANSFER
extends Protocol
implements RequestHandler, Subject
State transfer layer. Upon receiving a GET_STATE event from JChannel, a MAKE_COPY message is sent to all members. When the originator receives MAKE_COPY, it queues all messages to the channel. When another member receives the message, it asks the JChannel to provide it with a copy of the current state (GetStateEvent is received by application, ReturnState() sends state down the stack). Then the current layer sends a unicast RETURN_STATE message to the coordinator, which returns the cached copy. When the state is received by the originator, the GET_STATE sender is unblocked with a GET_STATE_OK event up the stack (unless it already timed out).

Requires QUEUE layer on top.


Constructor Index

 o STATE_TRANSFER()

Method Index

 o Attach(Observer)
 o Detach(Observer)
 o Down(Event)
An event is to be sent down the stack.
 o GetName()
All protocol names have to be unique !
 o Handle(Message)
 o Notify()
 o RequiredUpServices()
List of events that are required to be answered by some layer above
 o SetProperties(Properties)
Configures the protocol initially.
 o Up(Event)
An event was received from the layer below.

Constructors

 o STATE_TRANSFER
 public STATE_TRANSFER()

Methods

 o GetName
 public String GetName()
All protocol names have to be unique !

Overrides:
GetName in class Protocol
 o SetProperties
 public boolean SetProperties(Properties props)
Configures the protocol initially.

Overrides:
SetProperties in class Protocol
 o RequiredUpServices
 public Vector RequiredUpServices()
List of events that are required to be answered by some layer above

Overrides:
RequiredUpServices in class Protocol
 o Up
 public void Up(Event evt)
An event was received from the layer below.

Overrides:
Up in class Protocol
 o Down
 public void Down(Event evt)
An event is to be sent down the stack.

Overrides:
Down in class Protocol
 o Handle
 public Object Handle(Message msg)
 o Attach
 public void Attach(Observer o)
 o Detach
 public void Detach(Observer o)
 o Notify
 public void Notify()

All Packages  Class Hierarchy  This Package  Previous  Next  Index