|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.util.AbstractCollection | +--java.util.AbstractList | +--java.util.Vector | +--context.arch.subscriber.Subscribers
This class maintains a list of subscribers, allows additions, removals and updates to individual subscribers.
Subscriber
, Serialized FormFields inherited from class java.util.Vector |
capacityIncrement,
elementCount,
elementData |
Fields inherited from class java.util.AbstractList |
modCount |
Constructor Summary | |
Subscribers(MessageHandler mh,
java.lang.String id)
Basic constructor that takes an object that implements the MessageHandler interface and an id to create a logfile name from. |
Method Summary | |
void |
addSubscriber(java.lang.String id,
java.lang.String hostname,
int port,
java.lang.String callback,
java.lang.String tag,
Conditions conditions,
Attributes attributes)
Adds a subscriber to the subscriber list |
void |
addSubscriber(java.lang.String id,
java.lang.String hostname,
java.lang.String port,
java.lang.String callback,
java.lang.String tag,
Conditions conditions,
Attributes attributes)
Adds a subscriber to the subscriber list |
void |
addSubscriber(Subscriber sub)
Adds a subscriber to the subscriber list |
void |
addSubscriber(Subscriber sub,
boolean log)
Adds a subscriber to the subscriber list |
Subscriber |
getSubscriber(java.lang.String id,
java.lang.String hostname,
int port,
java.lang.String callback,
java.lang.String tag)
Returns the subscriber with the given name. |
Subscriber |
getSubscriber(java.lang.String id,
java.lang.String hostname,
java.lang.String port,
java.lang.String callback,
java.lang.String tag)
Returns the subscriber with the given name. |
Subscriber |
getSubscriberAt(int index)
Returns the subscriber at the given index. |
java.util.Enumeration |
getSubscriberNames()
Returns an enumeration containing all the subscriber names in the list |
java.util.Enumeration |
getSubscribers()
Returns an enumeration containing all the subscribers in the list |
int |
numSubscribers()
Returns the number of subscribers in the list |
boolean |
removeSubscriber(java.lang.String id,
java.lang.String host,
int port,
java.lang.String callback,
java.lang.String tag)
Removes a subscriber from the subscriber list |
boolean |
removeSubscriber(java.lang.String id,
java.lang.String host,
java.lang.String port,
java.lang.String callback,
java.lang.String tag)
Removes a subscriber from the subscriber list |
boolean |
removeSubscriber(Subscriber sub)
Removes a subscriber from the subscriber list |
boolean |
removeSubscriber(Subscriber sub,
boolean log)
Removes a subscriber from the subscriber list |
void |
updateSubscriber(java.lang.String name,
java.lang.String hostname,
int port,
java.lang.String callback,
java.lang.String tag,
Conditions conditions,
Attributes attributes)
Updates a subscriber in the subscriber list. |
void |
updateSubscriber(java.lang.String name,
java.lang.String hostname,
java.lang.String port,
java.lang.String callback,
java.lang.String tag,
Conditions conditions,
Attributes attributes)
Updates a subscriber in the subscriber list. |
void |
updateSubscriber(Subscriber sub)
Updates a subscriber in the subscriber list. |
void |
updateSubscriber(Subscriber sub,
boolean log)
Updates a subscriber in the subscriber list. |
Methods inherited from class java.util.Vector |
add,
add,
addAll,
addAll,
addElement,
capacity,
clear,
clone,
contains,
containsAll,
copyInto,
elementAt,
elements,
ensureCapacity,
equals,
firstElement,
get,
hashCode,
indexOf,
indexOf,
insertElementAt,
isEmpty,
lastElement,
lastIndexOf,
lastIndexOf,
remove,
remove,
removeAll,
removeAllElements,
removeElement,
removeElementAt,
removeRange,
retainAll,
set,
setElementAt,
setSize,
size,
subList,
toArray,
toArray,
toString,
trimToSize |
Methods inherited from class java.util.AbstractList |
iterator,
listIterator,
listIterator |
Methods inherited from class java.lang.Object |
finalize,
getClass,
notify,
notifyAll,
wait,
wait,
wait |
Constructor Detail |
public Subscribers(MessageHandler mh, java.lang.String id)
Method Detail |
public void addSubscriber(java.lang.String id, java.lang.String hostname, int port, java.lang.String callback, java.lang.String tag, Conditions conditions, Attributes attributes)
id
- ID of the subscriberhostname
- Name of the subscriber's host computerport
- Port number to send information tocallback
- Callback the subscriber will implementtag
- Widget callback the subscriber is subscribing toconditions
- Conditions under which subscriber will receive dataattributes
- Attributes to return to subscriberpublic void addSubscriber(java.lang.String id, java.lang.String hostname, java.lang.String port, java.lang.String callback, java.lang.String tag, Conditions conditions, Attributes attributes)
id
- ID of the subscriberhostname
- Name of the subscriber's host computerport
- Port number to send information tocallback
- Callback the subscriber will implementtag
- Widget callback the subscriber is subscribing toconditions
- Conditions under which subscriber will receive dataattributes
- Attributes to return to subscriberpublic void addSubscriber(Subscriber sub, boolean log)
sub
- Subscriber object to addlog
- Whether to log the subscribe or notpublic void addSubscriber(Subscriber sub)
sub
- Subscriber object to addpublic boolean removeSubscriber(java.lang.String id, java.lang.String host, int port, java.lang.String callback, java.lang.String tag)
id
- ID of the subscriberhostname
- Name of the subscriber's host computerport
- Port number to send information tocallback
- Callback the subscriber will implementtag
- Widget callback the subscriber is subscribing topublic boolean removeSubscriber(java.lang.String id, java.lang.String host, java.lang.String port, java.lang.String callback, java.lang.String tag)
id
- ID of the subscriberhostname
- Name of the subscriber's host computerport
- Port number to send information tocallback
- Callback the subscriber will implementtag
- Widget callback the subscriber is subscribing topublic boolean removeSubscriber(Subscriber sub)
sub
- Subscriber object to removepublic boolean removeSubscriber(Subscriber sub, boolean log)
sub
- Subscriber object to removelog
- Whether to log the subscribe or notpublic void updateSubscriber(Subscriber sub)
sub
- Subscriber object to updatepublic void updateSubscriber(Subscriber sub, boolean log)
sub
- Subscriber object to updatelog
- Whether to log the subscribe or notpublic void updateSubscriber(java.lang.String name, java.lang.String hostname, int port, java.lang.String callback, java.lang.String tag, Conditions conditions, Attributes attributes)
name
- Name of the subscriberhostname
- Name of the subscriber's host computerport
- Port number to send information tocallback
- Callback the subscriber will implementtag
- Widget callback the subscriber is subscribing toconditions
- Conditions under which subscriber will receive dataattributes
- Attributes to return to subscriberpublic void updateSubscriber(java.lang.String name, java.lang.String hostname, java.lang.String port, java.lang.String callback, java.lang.String tag, Conditions conditions, Attributes attributes)
name
- Name of the subscriberhostname
- Name of the subscriber's host computerport
- Port number to send information tocallback
- Callback the subscriber will implementtag
- Widget callback the subscriber is subscribing toconditions
- Conditions under which subscriber will receive dataattributes
- Attributes to return to subscriberpublic Subscriber getSubscriberAt(int index)
index
- index value of the Subscriber object to retrievepublic Subscriber getSubscriber(java.lang.String id, java.lang.String hostname, int port, java.lang.String callback, java.lang.String tag)
id
- ID of the Subscriber object to retrievehostname
- Name of the subscriber's host computerport
- Port number to send information tocallback
- Callback the subscriber will implementtag
- Widget callback the subscriber is subscribing topublic Subscriber getSubscriber(java.lang.String id, java.lang.String hostname, java.lang.String port, java.lang.String callback, java.lang.String tag)
id
- ID of the Subscriber object to retrievehostname
- Name of the subscriber's host computerport
- Port number to send information tocallback
- Callback the subscriber will implementtag
- Widget callback the subscriber is subscribing topublic java.util.Enumeration getSubscribers()
public java.util.Enumeration getSubscriberNames()
public int numSubscribers()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |