|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectch.elca.el4j.services.remoting.protocol.loadbalancing.policy.AbstractPolicy
public abstract class AbstractPolicy
Abstract class that defines the policy of the protocol selection. Protocol comparison must be done using "=="!
Field Summary | |
---|---|
protected AbstractRemotingProtocol[] |
m_protocols
Array of protocols, each represented by an array of Strings, using a [protocolTag, arg1, arg2, ...] representation. |
Constructor Summary | |
---|---|
AbstractPolicy()
|
Method Summary | |
---|---|
abstract AbstractRemotingProtocol |
getNextProtocol()
Note that protocol comparison must be done using "=="! |
int |
getProtocolCount()
|
void |
notifyFailure(AbstractRemotingProtocol protocol)
This method is called if the use of one of the protocols has failed. |
protected void |
removeProtocol(AbstractRemotingProtocol protocol)
Removes protocol 'pi' from m_protocols . |
void |
setProtocols(AbstractRemotingProtocol[] protocols)
This method is called before any other method is called. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected AbstractRemotingProtocol[] m_protocols
Constructor Detail |
---|
public AbstractPolicy()
Method Detail |
---|
public void setProtocols(AbstractRemotingProtocol[] protocols)
protocols
- Array of currently defined protocols.public void notifyFailure(AbstractRemotingProtocol protocol)
protocol
- The protocol that has lead to a failure.public int getProtocolCount()
public abstract AbstractRemotingProtocol getNextProtocol() throws NoProtocolAvailableRTException
NoProtocolAvailableRTException
- If no protocol is available any moreprotected void removeProtocol(AbstractRemotingProtocol protocol)
m_protocols
. Does nothing if 'pi'
does not exist.
protocol
- Protocol to be removed.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |