Package io.rong.imkit.usermanage.group.memberselect

## Class GroupMemberSelectionViewModel

- All Implemented Interfaces:

      public class GroupMemberSelectionViewModel

  创建增加群联系人页面 ViewModel

  Since:

    5.12.2

  Author:

    rongcloud

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class | Description
    --- | --- | ---

  - ### Field Summary

    Fields
    Modifier and Type | Field | Description
    --- | --- | ---
    `public final MutableLiveData<List<ContactModel>>` | `filteredContactsLiveData` |

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `GroupMemberSelectionViewModel(Bundle arguments)` |

  - ### Enum Constant Summary

    Enum Constants
    Enum Constant | Description
    --- | ---

  - ### Method Summary

    Modifier and Type | Method | Description
    --- | --- | ---
    `MutableLiveData<List<ContactModel>>` | `getFilteredContactsLiveData()` |
    `LiveData<List<ContactModel>>` | `getSelectedContactsLiveData()` |
    `void` | `updateContact(ContactModel updatedContact)` | 更新联系人状态
    `void` | `queryContacts(String query)` | 查询联系人
    `void` | `)>addGroupManagers(OnDataChangeListener<Boolean> onDataChangeListener)` | 添加群管理员
    `void` | `)>addGroupFollows(OnDataChangeListener<Boolean> onDataChangeListener)` | 添加关注者
    `void` | `)>loadNext(OnDataChangeListener<Boolean> listener)` |
    `boolean` | `hasNext()` |

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

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

- - ### Constructor Detail

    - #### GroupMemberSelectionViewModel

          GroupMemberSelectionViewModel(Bundle arguments)

  - ### Method Detail

    - #### getFilteredContactsLiveData

           MutableLiveData<List<ContactModel>> getFilteredContactsLiveData()

    - #### getSelectedContactsLiveData

           LiveData<List<ContactModel>> getSelectedContactsLiveData()

    - #### updateContact

           void updateContact(ContactModel updatedContact)

      更新联系人状态

      Parameters:
        `updatedContact` - 更新后的联系人

    - #### queryContacts

           void queryContacts(String query)

      查询联系人

      Parameters:
        `query` - 查询关键字

    - #### addGroupManagers

           void )>addGroupManagers(OnDataChangeListener<Boolean> onDataChangeListener)

      添加群管理员

      Parameters:
        `onDataChangeListener` - 数据变化监听器

    - #### addGroupFollows

           void )>addGroupFollows(OnDataChangeListener<Boolean> onDataChangeListener)

      添加关注者

      Parameters:
        `onDataChangeListener` - 数据变化监听器

    - #### loadNext

           void )>loadNext(OnDataChangeListener<Boolean> listener)

    - #### hasNext

           boolean hasNext()