StaticMembershipProvider.MemberMessage (Apache Tomcat 11.0.23 API Documentation)
Description: declaration: package: org.apache.catalina.tribes.membership, class: StaticMembershipProvider, class: MemberMessage

# Class StaticMembershipProvider.MemberMessage

java.lang.Object
org.apache.catalina.tribes.membership.StaticMembershipProvider.MemberMessage

All Implemented Interfaces:
  `Serializable`

Enclosing class:
  `StaticMembershipProvider`

public static class StaticMembershipProvider.MemberMessage extends Object implements Serializable
Message sent between membership providers to coordinate membership state.

See Also:
  - Serialized Form

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static final int`
  `MSG_PING`
  Message type for member ping.
  `static final int`
  `MSG_START`
  Message type for member start.
  `static final int`
  `MSG_STOP`
  Message type for member stop.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `MemberMessage(byte[] membershipId, int msgtype, Member member)`
  Creates a new MemberMessage.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `Member`
  `getMember()`
  Returns the member associated with this message.
  `byte[]`
  `getMembershipId()`
  Returns the membership group identifier.
  `int`
  `getMsgtype()`
  Returns the message type.
  `protected String`
  `getTypeDesc()`
  Returns a human-readable description of the message type.
  `void`
  `setMember(Member local)`
  Sets the member for this message.
  `String`
  `toString()`

  ### Methods inherited from class Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- ## Field Details

  - ### MSG_START

    public static final int MSG_START
    Message type for member start.
    See Also:
      - Constant Field Values

  - ### MSG_STOP

    public static final int MSG_STOP
    Message type for member stop.
    See Also:
      - Constant Field Values

  - ### MSG_PING

    public static final int MSG_PING
    Message type for member ping.
    See Also:
      - Constant Field Values

- ## Constructor Details

  - ### MemberMessage

    public MemberMessage(byte[] membershipId, int msgtype, Member member)
    Creates a new MemberMessage.
    Parameters:
      `membershipId` - the membership group identifier
      `msgtype` - the message type
      `member` - the member associated with this message

- ## Method Details

  - ### getMsgtype

    public int getMsgtype()
    Returns the message type.
    Returns:
      the message type constant

  - ### getMembershipId

    public byte[] getMembershipId()
    Returns the membership group identifier.
    Returns:
      the membership ID byte array

  - ### getMember

    public Member getMember()
    Returns the member associated with this message.
    Returns:
      the member

  - ### setMember

    public void setMember(Member local)
    Sets the member for this message.
    Parameters:
      `local` - the member

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `Object`

  - ### getTypeDesc

    protected String getTypeDesc()
    Returns a human-readable description of the message type.
    Returns:
      the type description string