next up previous contents
Next: Sending data to member(s) Up: Channels Previous: Connecting to a channel

Getting the local and group addresses

Method GetLocalAddress returns the local address of the channel. In the case of JChannel, the local address is generated by the bottom-most layer of the protocol stack when the stack is connected to. That means that - depending on the channel implementation - the local address may or may not be available when a channel is in the unconnected state.

        public Object GetLocalAddress();

Method GetGroupAddress returns the address of the group in which the channel is a member:

        public Object GetGroupAddress();

Again, the result in undefined if the channel is in the unconnected or closed state. An implementation is free to return any value. In the case of JChannel, the group address is a string (the name of the group), but channel implementations are free to choose a more sophisticated structure to define groups.




1999-12-13