Methods Summary |
---|
public byte[] | getDomain()
return domain;
|
public org.apache.catalina.tribes.Member | getLocalMember(boolean incAlive)
return super.getLocalMember(incAlive);
|
public org.apache.catalina.tribes.Member | getMember(org.apache.catalina.tribes.Member mbr)
if ( membership == null ) setupMembership();
return membership.getMember(mbr);
|
public org.apache.catalina.tribes.Member[] | getMembers()
if ( membership == null ) setupMembership();
return membership.getMembers();
|
public boolean | hasMembers()
if ( membership == null ) setupMembership();
return membership.hasMembers();
|
public void | memberAdded(org.apache.catalina.tribes.Member member)
if ( membership == null ) setupMembership();
boolean notify = false;
synchronized (membership) {
notify = Arrays.equals(domain,member.getDomain());
if ( notify ) notify = membership.memberAlive((MemberImpl)member);
}
if ( notify ) super.memberAdded(member);
|
public void | memberDisappeared(org.apache.catalina.tribes.Member member)
if ( membership == null ) setupMembership();
boolean notify = false;
synchronized (membership) {
notify = Arrays.equals(domain,member.getDomain());
membership.removeMember((MemberImpl)member);
}
if ( notify ) super.memberDisappeared(member);
|
public void | messageReceived(org.apache.catalina.tribes.ChannelMessage msg)
//should we filter incoming based on domain?
super.messageReceived(msg);
|
public void | setDomain(byte[] domain)
this.domain = domain;
|
protected synchronized void | setupMembership()
if ( membership == null ) {
membership = new Membership((MemberImpl)super.getLocalMember(true));
}
|