|
Project JXTA | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.jxta.peergroup.LightWeightPeerGroup
net.jxta.ext.rdvpeergroup.RdvPeerGroup
public class RdvPeerGroup
RdvPeerGroup is an LightWeighttPeerGroup that uses all the parent PeerGroup's services except for the RendezVous Service which is instantiaded by RdvPeerGroup. RdvPeerGroup allows a set of peers to run as rdv peers (control peers) within the RdvPeerGroup, other peers to be edge peers (primary peers), and other peers to simply keep track of running rdv peers (guest peers).
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface net.jxta.peergroup.PeerGroup |
|---|
PeerGroup.GlobalRegistry |
| Field Summary |
|---|
| Fields inherited from interface net.jxta.platform.Module |
|---|
START_AGAIN_PROGRESS, START_AGAIN_STALLED, START_OK |
| Constructor Summary | |
|---|---|
RdvPeerGroup(PeerGroupAdvertisement adv,
PeerGroup parentPeerGroup)
Constructor All classes that extend RdvPeerGroup must invoke this constructor. |
|
| Method Summary | |
|---|---|
Enumeration |
getControlPeers()
Get an Enumeration of the PeerIDs of the control peers of this RdvPeerGroup. |
RendezVousService |
getRendezVousService()
|
void |
init(PeerGroup group,
ID assignedID,
Advertisement implAdv)
|
boolean |
isRendezvous()
|
boolean |
joinAsControlPeer(RendezvousListener listener)
Joins the RdvPeerGroup as a control peer (rdv peer). |
boolean |
joinAsGuestPeer(RendezvousListener listener)
Joins the RdvPeerGroup as a guest peer (PeerView only). |
boolean |
joinAsPrimaryPeer(RendezvousListener listener)
Joins the RdvPeerGroup as a primary peer (edge peer). |
void |
leave()
Leaves (quit) the RdvPeerGroup |
void |
peerViewEvent(PeerViewEvent event)
peerViewEvent the peerview event |
void |
rendezvousEvent(RendezvousEvent event)
Called when an event occurs for the Rendezvous service |
int |
startApp(String[] args)
|
void |
stopApp()
|
void |
unref()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public RdvPeerGroup(PeerGroupAdvertisement adv,
PeerGroup parentPeerGroup)
adv - PeerGroupAdvertisement of the RdvPeerGroupparaentPeerGroup - PeerGroup object of the parent
PeerGroup.| Method Detail |
|---|
public boolean joinAsPrimaryPeer(RendezvousListener listener)
throws IOException
listener - optional listener allowing the application
to be asynchronously notified of the state of the connection.
IOException
public boolean joinAsControlPeer(RendezvousListener listener)
throws IOException
listener - optional listener allowing the application
to be asynchronously notified of the state of the connection.
IOException
public boolean joinAsGuestPeer(RendezvousListener listener)
throws IOException
listener - optional listener allowing the application
to be asynchronously notified of the state of the connection.
IOExceptionpublic void leave()
public Enumeration getControlPeers()
public void rendezvousEvent(RendezvousEvent event)
rendezvousEvent in interface RendezvousListenerevent - the rendezvous eventpublic void peerViewEvent(PeerViewEvent event)
peerViewEvent in interface PeerViewListenerpeerViewEvent - event
public void init(PeerGroup group,
ID assignedID,
Advertisement implAdv)
init in interface Moduleinit in class LightWeightPeerGrouppublic int startApp(String[] args)
startApp in interface ModulestartApp in class LightWeightPeerGrouppublic void stopApp()
stopApp in interface ModulestopApp in class LightWeightPeerGrouppublic boolean isRendezvous()
isRendezvous in interface PeerGroupisRendezvous in class LightWeightPeerGrouppublic RendezVousService getRendezVousService()
getRendezVousService in interface PeerGroupgetRendezVousService in class LightWeightPeerGrouppublic void unref()
unref in interface PeerGroupunref in class LightWeightPeerGroup
|
JXTA J2SE | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||