PageBoxLib
Interface TokenCallbackIF

All Known Implementing Classes:
ActiveNaming

public interface TokenCallbackIF

Token ring callback interface.

alexis.grandemange@pagebox.net

Copyright (c) 2002-2004 Alexis Grandemange

This program is free software; you can redistribute it and/or
 modify it under the terms of the GNU Lesser General Public License
 as published by the Free Software Foundation; version 2.1 of the
 License.
 This library is distributed in the hope that it will be useful,
 but WITHOUT ANY WARRANTY; without even the implied warranty of
 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 GNU Lesser General Public License for more details.
 A copy of the GNU Lesser General Public License lesser.txt should be
 included in the distribution.

Version:
0, 0, 11
Author:
Alexis Grandemange

Method Summary
 java.io.Serializable call(java.lang.String from, java.lang.String type, int corrid, java.io.Serializable data)
          Method called when a message that targets this (target instance, archive) is received.
 void poll()
          Method called when a frame is received by the PageBox.
 void response(java.lang.String type, int corrid, java.util.Map codes)
          Method called when a message comes back to its sender.
 void setSender(TokenSendIF tsi)
          Method called when a callback is registered
 

Method Detail

setSender

public void setSender(TokenSendIF tsi)
Method called when a callback is registered

Parameters:
tsi - object to use to send messages

call

public java.io.Serializable call(java.lang.String from,
                                 java.lang.String type,
                                 int corrid,
                                 java.io.Serializable data)
Method called when a message that targets this (target instance, archive) is received.

Parameters:
from - issuer URL
type - request type
corrid - correlation ID
data - TokenMsg data
Returns:
response message or null

poll

public void poll()
Method called when a frame is received by the PageBox.


response

public void response(java.lang.String type,
                     int corrid,
                     java.util.Map codes)
Method called when a message comes back to its sender.

Parameters:
type - request type
corrid - correlation ID
codes - map whose key is the issuer URL and value is a Serializable object (response returned by the call method of the issuer TokenCallbackIF)