com.hazelcast.instance

## Class AbstractMember

- java.lang.Object
- - com.hazelcast.instance.AbstractMember

- All Implemented Interfaces:
    Endpoint, Member, DataSerializable
  Direct Known Subclasses:
    MemberImpl

      @PrivateApi
      public abstract class AbstractMember
      extends Object
      implements Member

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected Address` | `address`
    `protected Map<String,Object>` | `attributes`
    `protected boolean` | `liteMember`
    `protected String` | `uuid`
    `protected MemberVersion` | `version`

  - ### Constructor Summary

    Constructors
    Modifier | Constructor and Description
    --- | ---
    `protected` | `AbstractMember()`
    `protected` | `AbstractMember(AbstractMember member)`
    `protected` | `AbstractMember(Address address, MemberVersion version, String uuid, Map<String,Object> attributes, boolean liteMember)`

  - ### Method Summary

    All Methods Instance Methods Abstract Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `equals(Object obj)`
    `Address` | `getAddress()` Returns the Address of this Member.
    `protected Object` | `getAttribute(String key)`
    `Map<String,Object>` | `getAttributes()` Returns configured attributes for this member. This method might not be available on all native clients.
    `InetAddress` | `getInetAddress()`
    `InetSocketAddress` | `getInetSocketAddress()` Returns the InetSocketAddress of this member.
    `protected abstract ILogger` | `getLogger()`
    `int` | `getPort()`
    `InetSocketAddress` | `getSocketAddress()` Returns the socket address of this member.
    `String` | `getUuid()` Returns the UUID of this member.
    `MemberVersion` | `getVersion()` Returns the Hazelcast codebase version of this member; this may or may not be different from the version reported by `Cluster.getClusterVersion()`, for example when a node with a different codebase version is added to an existing cluster.
    `int` | `hashCode()`
    `boolean` | `isLiteMember()` Returns true if this member is a lite member.
    `void` | `readData(ObjectDataInput in)` Reads fields from the input stream
    `String` | `toString()`
    `void` | `updateAttribute(MemberAttributeOperationType operationType, String key, Object value)`
    `void` | `writeData(ObjectDataOutput out)` Writes object fields to output stream

    - ### Methods inherited from class java.lang.Object

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

    - ### Methods inherited from interface com.hazelcast.core.Member

      `getBooleanAttribute, getByteAttribute, getDoubleAttribute, getFloatAttribute, getIntAttribute, getLongAttribute, getShortAttribute, getStringAttribute, localMember, removeAttribute, setBooleanAttribute, setByteAttribute, setDoubleAttribute, setFloatAttribute, setIntAttribute, setLongAttribute, setShortAttribute, setStringAttribute`

- - ### Field Detail

    - #### attributes

          protected final Map<String,Object> attributes

    - #### address

          protected Address address

    - #### uuid

          protected String uuid

    - #### liteMember

          protected boolean liteMember

    - #### version

          protected MemberVersion version

  - ### Constructor Detail

    - #### AbstractMember

          protected AbstractMember()

    - #### AbstractMember

          protected AbstractMember(Address address,
                                   MemberVersion version,
                                   String uuid,
                                   Map<String,Object> attributes,
                                   boolean liteMember)

    - #### AbstractMember

          protected AbstractMember(AbstractMember member)

  - ### Method Detail

    - #### getAddress

          public Address getAddress()

      Description copied from interface: `Member`
      Returns the Address of this Member.
      Specified by:
        `getAddress` in interface `Member`
      Returns:
        the address.

    - #### getPort

          public int getPort()

    - #### getInetAddress

          public InetAddress getInetAddress()

    - #### getLogger

          protected abstract ILogger getLogger()

    - #### getInetSocketAddress

          public InetSocketAddress getInetSocketAddress()

      Description copied from interface: `Member`
      Returns the InetSocketAddress of this member.
      Specified by:
        `getInetSocketAddress` in interface `Member`
      Returns:
        InetSocketAddress of this member

    - #### getSocketAddress

          public InetSocketAddress getSocketAddress()

      Description copied from interface: `Member`
      Returns the socket address of this member.
      Specified by:
        `getSocketAddress` in interface `Endpoint`
      Specified by:
        `getSocketAddress` in interface `Member`
      Returns:
        the socket address of this member

    - #### getUuid

          public String getUuid()

      Description copied from interface: `Member`
      Returns the UUID of this member.
      Specified by:
        `getUuid` in interface `Endpoint`
      Specified by:
        `getUuid` in interface `Member`
      Returns:
        the UUID of this member.

    - #### isLiteMember

          public boolean isLiteMember()

      Description copied from interface: `Member`
      Returns true if this member is a lite member.
      Specified by:
        `isLiteMember` in interface `Member`
      Returns:
        `true` if this member is a lite member, `false` otherwise. Lite members do not own any partition.

    - #### getAttributes

          public Map<String,Object> getAttributes()

      Description copied from interface: `Member`
      Returns configured attributes for this member.
      This method might not be available on all native clients.
      Specified by:
        `getAttributes` in interface `Member`
      Returns:
        configured attributes for this member.

    - #### updateAttribute

          public void updateAttribute(MemberAttributeOperationType operationType,
                                      String key,
                                      Object value)

    - #### getAttribute

          protected Object getAttribute(String key)

    - #### getVersion

          public MemberVersion getVersion()

      Description copied from interface: `Member`
      Returns the Hazelcast codebase version of this member; this may or may not be different from the version reported by `Cluster.getClusterVersion()`, for example when a node with a different codebase version is added to an existing cluster. See the documentation for `Cluster.getClusterVersion()` for a more thorough discussion of `Cluster` and `Member` / `Node` version.
      Specified by:
        `getVersion` in interface `Member`
      Returns:
        the `MemberVersion` of this member.

    - #### readData

          public void readData(ObjectDataInput in)
                        throws IOException

      Description copied from interface: `DataSerializable`
      Reads fields from the input stream
      Specified by:
        `readData` in interface `DataSerializable`
      Parameters:
        `in` - input
      Throws:
        `IOException` - if an I/O error occurs. In particular, an `IOException` may be thrown if the input stream has been closed.

    - #### writeData

          public void writeData(ObjectDataOutput out)
                         throws IOException

      Description copied from interface: `DataSerializable`
      Writes object fields to output stream
      Specified by:
        `writeData` in interface `DataSerializable`
      Parameters:
        `out` - output
      Throws:
        `IOException` - if an I/O error occurs. In particular, an `IOException` may be thrown if the output stream has been closed.

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `Object`

    - #### equals

          public boolean equals(Object obj)

      Overrides:
        `equals` in class `Object`

Copyright © 2018. All rights reserved.