public class Birthday extends Object implements Field, Randomize, Serializable
| 构造器和说明 |
|---|
Birthday() |
| 限定符和类型 | 方法和说明 |
|---|---|
String |
asString()
返回属性的中文字符串形式,比如:地址,姓名,性别
属性原有的样子,不需要二次转义的
|
static LocalDate |
choiceByAge(int age) |
static LocalDate |
choiceByAge(int startAgeInclude,
int endAgeExclude) |
LocalDate |
getBirth() |
void |
randomIfNull()
如果类中某个属性数值未被赋值,则对其随机赋值
|
void |
setBirth(LocalDate birth) |
void |
setBirth(String birth) |
public LocalDate getBirth()
public void setBirth(LocalDate birth)
public void setBirth(String birth)
public static LocalDate choiceByAge(int age)
public static LocalDate choiceByAge(int startAgeInclude, int endAgeExclude)
startAgeInclude - 起始年龄 包含,亦是说生成的年龄一定是大於等於此年龄endAgeExclude - 结束年龄 不包含public void randomIfNull()
RandomizerandomIfNull 在接口中 RandomizeCopyright © 2020. All rights reserved.