All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.agora.rtm.UserState Maven / Gradle / Ivy

package io.agora.rtm;

import io.agora.common.internal.CalledByNative;
import io.agora.rtm.StateItem;
import java.util.ArrayList;
import java.util.Arrays;

/**
 *  The states of user.
 */
public class UserState {
  /**
   * The user id.
   */
  private String userId = "";

  /**
   * The user states.
   */
  private ArrayList states;

  /**
   * Constructor for {@code UserState} with default parameters.
   */
  UserState() {}

  public String getUserId() {
    return this.userId;
  }

  public ArrayList getStates() {
    return this.states;
  }

  @CalledByNative
  public UserState(String userId, StateItem[] states) {
    this.userId = userId;
    this.states = new ArrayList(Arrays.asList(states));
  }

  @Override
  public String toString() {
    return "UserState {userId: " + userId + ", states: " + states + "}";
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy