[]
Serializable, Comparable<ValidationType>, Constable将此枚举与数据验证 API 一起使用,以控制单元格或区域中接受哪些类型的值。支持的验证类型包括无限制、整数、小数、列表、日期、时间、文本长度和自定义公式。
worksheet.getRange("D2:E5").getValidation().add(
ValidationType.Whole,
ValidationAlertStyle.Stop,
ValidationOperator.Between,
3,
8);
Enum.EnumDesc<E extends Enum<E>>static ValidationTypeforValue(int value) intgetValue()static ValidationTypestatic ValidationType[]values()name - the name of the enum constant to be returned.IllegalArgumentException - if this enum class has no constant with the specified nameNullPointerException - if the argument is null