Project JXTA

net.jxta.impl.proxy
Class ProxyService

java.lang.Object
  extended bynet.jxta.impl.proxy.ProxyService
All Implemented Interfaces:
CacheEntryListener, EndpointListener, EventListener, Module, OutputPipeListener, PipeMsgListener, Service

public class ProxyService
extends Object
implements Service, EndpointListener, PipeMsgListener, OutputPipeListener, CacheEntryListener


Nested Class Summary
(package private)  class ProxyService.ClientMessage
           
(package private)  class ProxyService.PendingPipe
           
(package private) static class ProxyService.PipeListenerList
           
 
Field Summary
(package private) static String ARG_TAG
           
(package private) static String ATTRIBUTE_TAG
           
static int DEFAULT_LIFETIME
           
static int DEFAULT_THRESHOLD
           
(package private) static String ERROR_MESSAGE_TAG
           
(package private) static String ID_TAG
           
protected static boolean LOG_MESSAGES
           
(package private) static String NAME_TAG
           
(package private) static String PROXYNS
           
static String REQUEST_CLOSE
           
static String REQUEST_CREATE
           
static String REQUEST_JOIN
          Define the proxy request types
static String REQUEST_LISTEN
           
static String REQUEST_SEARCH
           
static String REQUEST_SEND
           
static String REQUEST_TAG
          Define the proxy message tags
(package private) static String REQUESTID_TAG
           
static String RESPONSE_ERROR
           
static String RESPONSE_INFO
           
static String RESPONSE_MESSAGE
           
static String RESPONSE_RESULT
           
static String RESPONSE_SUCCESS
          Define the proxy response types
static String RESPONSE_TAG
           
(package private) static String THRESHOLD_TAG
           
static String TYPE_GROUP
           
static String TYPE_PEER
          Define the proxy type tags
static String TYPE_PIPE
           
(package private) static String TYPE_TAG
           
(package private) static String VALUE_TAG
           
 
Fields inherited from interface net.jxta.platform.Module
START_AGAIN_PROGRESS, START_AGAIN_STALLED, START_OK
 
Constructor Summary
ProxyService()
           
 
Method Summary
 void discoveryEvent(DiscoveryEvent event)
           
 Advertisement getImplAdvertisement()
           
 Service getInterface()
          Methods that are part of the Service Interface
 void init(PeerGroup group, ID assignedID, Advertisement implAdv)
           
protected static void logMessage(Message message, Logger log)
           
 void outputPipeEvent(OutputPipeEvent event)
           
 void pipeMsgEvent(PipeMsgEvent event)
           
 void processIncomingMessage(Message message, EndpointAddress srcAddr, EndpointAddress dstAddr)
           
 void purged(CacheEntry ce)
          Implement the CacheEntryListener *
 int startApp(String[] args)
           
 void stopApp()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOG_MESSAGES

protected static final boolean LOG_MESSAGES
See Also:
Constant Field Values

DEFAULT_THRESHOLD

public static final int DEFAULT_THRESHOLD
See Also:
Constant Field Values

DEFAULT_LIFETIME

public static final int DEFAULT_LIFETIME
See Also:
Constant Field Values

REQUEST_TAG

public static final String REQUEST_TAG
Define the proxy message tags

See Also:
Constant Field Values

RESPONSE_TAG

public static final String RESPONSE_TAG
See Also:
Constant Field Values

REQUESTID_TAG

static final String REQUESTID_TAG
See Also:
Constant Field Values

TYPE_TAG

static final String TYPE_TAG
See Also:
Constant Field Values

NAME_TAG

static final String NAME_TAG
See Also:
Constant Field Values

ID_TAG

static final String ID_TAG
See Also:
Constant Field Values

ARG_TAG

static final String ARG_TAG
See Also:
Constant Field Values

ATTRIBUTE_TAG

static final String ATTRIBUTE_TAG
See Also:
Constant Field Values

VALUE_TAG

static final String VALUE_TAG
See Also:
Constant Field Values

THRESHOLD_TAG

static final String THRESHOLD_TAG
See Also:
Constant Field Values

ERROR_MESSAGE_TAG

static final String ERROR_MESSAGE_TAG
See Also:
Constant Field Values

PROXYNS

static final String PROXYNS
See Also:
Constant Field Values

REQUEST_JOIN

public static final String REQUEST_JOIN
Define the proxy request types

See Also:
Constant Field Values

REQUEST_CREATE

public static final String REQUEST_CREATE
See Also:
Constant Field Values

REQUEST_SEARCH

public static final String REQUEST_SEARCH
See Also:
Constant Field Values

REQUEST_LISTEN

public static final String REQUEST_LISTEN
See Also:
Constant Field Values

REQUEST_CLOSE

public static final String REQUEST_CLOSE
See Also:
Constant Field Values

REQUEST_SEND

public static final String REQUEST_SEND
See Also:
Constant Field Values

RESPONSE_SUCCESS

public static final String RESPONSE_SUCCESS
Define the proxy response types

See Also:
Constant Field Values

RESPONSE_ERROR

public static final String RESPONSE_ERROR
See Also:
Constant Field Values

RESPONSE_INFO

public static final String RESPONSE_INFO
See Also:
Constant Field Values

RESPONSE_RESULT

public static final String RESPONSE_RESULT
See Also:
Constant Field Values

RESPONSE_MESSAGE

public static final String RESPONSE_MESSAGE
See Also:
Constant Field Values

TYPE_PEER

public static final String TYPE_PEER
Define the proxy type tags

See Also:
Constant Field Values

TYPE_GROUP

public static final String TYPE_GROUP
See Also:
Constant Field Values

TYPE_PIPE

public static final String TYPE_PIPE
See Also:
Constant Field Values
Constructor Detail

ProxyService

public ProxyService()
Method Detail

getInterface

public Service getInterface()
Methods that are part of the Service Interface

Specified by:
getInterface in interface Service

getImplAdvertisement

public Advertisement getImplAdvertisement()
Specified by:
getImplAdvertisement in interface Service

init

public void init(PeerGroup group,
                 ID assignedID,
                 Advertisement implAdv)
          throws PeerGroupException
Specified by:
init in interface Module
Throws:
PeerGroupException

startApp

public int startApp(String[] args)
Specified by:
startApp in interface Module

stopApp

public void stopApp()
Specified by:
stopApp in interface Module

processIncomingMessage

public void processIncomingMessage(Message message,
                                   EndpointAddress srcAddr,
                                   EndpointAddress dstAddr)
Specified by:
processIncomingMessage in interface EndpointListener

discoveryEvent

public void discoveryEvent(DiscoveryEvent event)

pipeMsgEvent

public void pipeMsgEvent(PipeMsgEvent event)
Specified by:
pipeMsgEvent in interface PipeMsgListener

outputPipeEvent

public void outputPipeEvent(OutputPipeEvent event)
Specified by:
outputPipeEvent in interface OutputPipeListener

logMessage

protected static void logMessage(Message message,
                                 Logger log)

purged

public void purged(CacheEntry ce)
Implement the CacheEntryListener *

Specified by:
purged in interface CacheEntryListener

JXTA J2SE