NIMSDK-AOS  9.19.0
GenderEnum.java
浏览该文件的文档.
1 package com.netease.nimlib.sdk.uinfo.constant;
2 
3 /**
4  * Created by huangjun on 2015/9/17.
5  */
6 public enum GenderEnum {
7  UNKNOWN(0),
8  MALE(1),
9  FEMALE(2);
10 
11  private Integer value;
12 
13  GenderEnum(int value) {
14  this.value = value;
15  }
16 
17  public static GenderEnum genderOfValue(int status) {
18  for (GenderEnum e : values()) {
19  if (e.getValue() == status) {
20  return e;
21  }
22  }
23  return UNKNOWN;
24  }
25 
26  public Integer getValue() {
27  return value;
28  }
29 }
static GenderEnum genderOfValue(int status)
Definition: GenderEnum.java:17
Created by huangjun on 2015/9/17.
Definition: GenderEnum.java:6