com.hazelcast.cluster.memberselector

## Class MemberSelectors

- java.lang.Object
- - com.hazelcast.cluster.memberselector.MemberSelectors

-     public final class MemberSelectors
      extends Object

  A utility class to get `MemberSelector` instances.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static MemberSelector` | `DATA_MEMBER_SELECTOR` A `MemberSelector` instance that selects only data members that own a partition
    `static MemberSelector` | `LITE_MEMBER_SELECTOR` A `MemberSelector` instance that selects only lite members that own no partition
    `static MemberSelector` | `LOCAL_MEMBER_SELECTOR` A `MemberSelector` instance that selects only local members
    `static MemberSelector` | `NON_LOCAL_MEMBER_SELECTOR` A `MemberSelector` instance that selects only remote members

  - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static MemberSelector` | `and(MemberSelector... selectors)` Selects a member when all of the selectors succeed
    `static MemberSelector` | `or(MemberSelector... selectors)` Selects a member when one of the selectors succeed

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

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

- - ### Field Detail

    - #### LITE_MEMBER_SELECTOR

          public static final MemberSelector LITE_MEMBER_SELECTOR

      A `MemberSelector` instance that selects only lite members that own no partition

    - #### DATA_MEMBER_SELECTOR

          public static final MemberSelector DATA_MEMBER_SELECTOR

      A `MemberSelector` instance that selects only data members that own a partition

    - #### LOCAL_MEMBER_SELECTOR

          public static final MemberSelector LOCAL_MEMBER_SELECTOR

      A `MemberSelector` instance that selects only local members

    - #### NON_LOCAL_MEMBER_SELECTOR

          public static final MemberSelector NON_LOCAL_MEMBER_SELECTOR

      A `MemberSelector` instance that selects only remote members

  - ### Method Detail

    - #### or

          public static MemberSelector or(MemberSelector... selectors)

      Selects a member when one of the selectors succeed
      Parameters:
        `selectors` - `MemberSelector` instances to iterate
      Returns:
        a `MemberSelector` that selects a member when one of the sub-selectors succeed

    - #### and

          public static MemberSelector and(MemberSelector... selectors)

      Selects a member when all of the selectors succeed
      Parameters:
        `selectors` - `MemberSelector` instances to iterate
      Returns:
        a `MemberSelector` that selects a member when all of the sub-selectors succeed

Copyright © 2019. All rights reserved.