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

me.chanjar.weixin.cp.bean.Gender Maven / Gradle / Ivy

There is a newer version: 4.6.7.B
Show newest version
package me.chanjar.weixin.cp.bean;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * 
 *  性别枚举
 *  Created by BinaryWang on 2018/4/22.
 * 
* * @author Binary Wang */ @Getter @AllArgsConstructor public enum Gender { /** * 未定义 */ UNDEFINED("未定义", "0"), /** * 男 */ MALE("男", "1"), /** * 女 */ FEMALE("女", "2"); private final String genderName; private final String code; /** * From code gender. * * @param code the code * @return the gender */ public static Gender fromCode(String code) { for (Gender a : Gender.values()) { if (a.code.equals(code)) { return a; } } return null; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy