@univerjs/sheets-data-validation v0.5.0-beta.1 • Docs
Class: ListMultipleValidator
Extends
Constructors
new ListMultipleValidator()
new ListMultipleValidator(localeService, injector): ListMultipleValidator
Parameters
Parameter | Type |
---|---|
localeService | LocaleService |
injector | Injector |
Returns
Inherited from
Defined in
data-validation/src/validators/base-data-validator.ts:77
Properties
Property | Modifier | Type | Default value | Overrides | Inherited from | Defined in |
---|---|---|---|---|---|---|
canvasRender | public | Nullable <IBaseDataValidationWidget > | null | - | ListValidator .canvasRender | data-validation/src/validators/base-data-validator.ts:71 |
dropdown | public | undefined | string | undefined | - | ListValidator .dropdown | data-validation/src/validators/base-data-validator.ts:72 |
formulaInput | public | undefined | string | undefined | - | ListValidator .formulaInput | data-validation/src/validators/base-data-validator.ts:70 |
formulaService | protected | DataValidationFormulaService | undefined | - | ListValidator .formulaService | sheets-data-validation/src/validators/list-validator.ts:92 |
id | public | string | DataValidationType.LIST_MULTIPLE | ListValidator .id | - | sheets-data-validation/src/validators/list-multiple-validator.ts:21 |
injector | readonly | Injector | undefined | - | ListValidator .injector | data-validation/src/validators/base-data-validator.ts:79 |
localeService | readonly | LocaleService | undefined | - | ListValidator .localeService | data-validation/src/validators/base-data-validator.ts:78 |
operators | public | DataValidationOperator [] | [] | - | ListValidator .operators | sheets-data-validation/src/validators/list-validator.ts:98 |
optionsInput | public | undefined | string | undefined | - | ListValidator .optionsInput | data-validation/src/validators/base-data-validator.ts:73 |
scopes | public | string | string [] | undefined | - | ListValidator .scopes | sheets-data-validation/src/validators/list-validator.ts:99 |
title | public | string | 'dataValidation.listMultiple.title' | ListValidator .title | - | sheets-data-validation/src/validators/list-multiple-validator.ts:22 |
Accessors
operatorNames
Get Signature
get operatorNames(): string[]
Returns
string
[]
Inherited from
Defined in
data-validation/src/validators/base-data-validator.ts:84
titleStr
Get Signature
get titleStr(): string
Returns
string
Inherited from
Defined in
data-validation/src/validators/base-data-validator.ts:88
Methods
generateRuleErrorMessage()
generateRuleErrorMessage(): string
Returns
string
Inherited from
ListValidator
.generateRuleErrorMessage
Defined in
sheets-data-validation/src/validators/list-validator.ts:173
generateRuleName()
generateRuleName(): string
Returns
string
Inherited from
ListValidator
.generateRuleName
Defined in
sheets-data-validation/src/validators/list-validator.ts:169
getExtraStyle()
getExtraStyle(
rule,
value,
__namedParameters): Nullable<IStyleData>
Parameters
Parameter | Type |
---|---|
rule | IDataValidationRule |
value | Nullable <CellValue > |
__namedParameters | object |
__namedParameters.style | IStyleData |
Returns
Inherited from
Defined in
sheets-data-validation/src/validators/list-validator.ts:123
getList()
getList(
rule,
currentUnitId?,
currentSubUnitId?): string[]
Parameters
Parameter | Type |
---|---|
rule | IDataValidationRule |
currentUnitId ? | string |
currentSubUnitId ? | string |
Returns
string
[]
Inherited from
Defined in
sheets-data-validation/src/validators/list-validator.ts:177
getListAsync()
getListAsync(
rule,
currentUnitId?,
currentSubUnitId?): Promise<string[]>
Parameters
Parameter | Type |
---|---|
rule | IDataValidationRule |
currentUnitId ? | string |
currentSubUnitId ? | string |
Returns
Promise
<string
[]>
Inherited from
Defined in
sheets-data-validation/src/validators/list-validator.ts:192
getListWithColor()
getListWithColor(
rule,
currentUnitId?,
currentSubUnitId?): {
color: string;
label: string;
}[]
Parameters
Parameter | Type |
---|---|
rule | IDataValidationRule |
currentUnitId ? | string |
currentSubUnitId ? | string |
Returns
{
color
: string
;
label
: string
;
}[]
Inherited from
ListValidator
.getListWithColor
Defined in
sheets-data-validation/src/validators/list-validator.ts:207
getListWithColorMap()
getListWithColorMap(
rule,
currentUnitId?,
currentSubUnitId?): Record<string, string>
Parameters
Parameter | Type |
---|---|
rule | IDataValidationRule |
currentUnitId ? | string |
currentSubUnitId ? | string |
Returns
Record
<string
, string
>
Inherited from
ListValidator
.getListWithColorMap
Defined in
sheets-data-validation/src/validators/list-validator.ts:214
getRuleFinalError()
getRuleFinalError(rule, position): string
Parameters
Parameter | Type |
---|---|
rule | IDataValidationRule |
position | ISheetLocationBase |
Returns
string
Inherited from
ListValidator
.getRuleFinalError
Defined in
data-validation/src/validators/base-data-validator.ts:114
isEmptyCellValue()
isEmptyCellValue(cellValue): cellValue is undefined | null | void
Parameters
Parameter | Type |
---|---|
cellValue | Nullable <CellValue > |
Returns
cellValue is undefined | null | void
Inherited from
ListValidator
.isEmptyCellValue
Defined in
data-validation/src/validators/base-data-validator.ts:122
isValidType()
isValidType(
cellInfo,
formula,
rule): Promise<boolean>
Parameters
Parameter | Type |
---|---|
cellInfo | IValidatorCellInfo <Nullable <CellValue >> |
formula | IFormulaResult <undefined | string []> |
rule | IDataValidationRule |
Returns
Promise
<boolean
>
Inherited from
Defined in
sheets-data-validation/src/validators/list-validator.ts:162
normalizeFormula()
normalizeFormula(
rule,
unitId,
subUnitId): {
formula1: rule.formula1;
formula2: rule.formula2;
}
Parameters
Parameter | Type |
---|---|
rule | IDataValidationRule |
unitId | string |
subUnitId | string |
Returns
{
formula1: rule.formula1;
formula2: rule.formula2;
}
Name | Type | Default value | Defined in |
---|---|---|---|
formula1 | undefined | string | rule.formula1 | data-validation/src/validators/base-data-validator.ts:136 |
formula2 | undefined | string | rule.formula2 | data-validation/src/validators/base-data-validator.ts:137 |
Inherited from
ListValidator
.normalizeFormula
Defined in
data-validation/src/validators/base-data-validator.ts:134
parseCellValue()
parseCellValue(cellValue): string[]
Parameters
Parameter | Type |
---|---|
cellValue | CellValue |
Returns
string
[]
Inherited from
Defined in
sheets-data-validation/src/validators/list-validator.ts:144
parseFormula()
parseFormula(
rule,
unitId,
subUnitId): Promise<IFormulaResult<undefined | string[]>>
Parameters
Parameter | Type |
---|---|
rule | IDataValidationRule |
unitId | string |
subUnitId | string |
Returns
Promise
<IFormulaResult
<undefined
| string
[]>>
Inherited from
Defined in
sheets-data-validation/src/validators/list-validator.ts:149
skipDefaultFontRender()
skipDefaultFontRender(): boolean
Returns
boolean
Overrides
ListValidator
.skipDefaultFontRender
Defined in
sheets-data-validation/src/validators/list-multiple-validator.ts:24
transform()
transform(
cellInfo,
formula,
rule): IValidatorCellInfo<CellValue>
Parameters
Parameter | Type |
---|---|
cellInfo | IValidatorCellInfo <Nullable <CellValue >> |
formula | IFormulaResult <any > |
rule | IDataValidationRule |
Returns
Inherited from
Defined in
data-validation/src/validators/base-data-validator.ts:145
validator()
validator(cellInfo, rule): Promise<boolean>
Parameters
Parameter | Type |
---|---|
cellInfo | IValidatorCellInfo <Nullable <CellValue >> |
rule | IDataValidationRule |
Returns
Promise
<boolean
>
Inherited from
Defined in
data-validation/src/validators/base-data-validator.ts:181
validatorFormula()
validatorFormula(
rule,
unitId,
subUnitId): IFormulaValidResult
Parameters
Parameter | Type |
---|---|
rule | IDataValidationRule |
unitId | string |
subUnitId | string |
Returns
Inherited from
ListValidator
.validatorFormula
Defined in
sheets-data-validation/src/validators/list-validator.ts:105
validatorIsBetween()
validatorIsBetween(
cellInfo,
formula,
rule): Promise<boolean>
Parameters
Parameter | Type |
---|---|
cellInfo | IValidatorCellInfo <CellValue > |
formula | IFormulaResult <any > |
rule | IDataValidationRule |
Returns
Promise
<boolean
>
Inherited from
ListValidator
.validatorIsBetween
Defined in
data-validation/src/validators/base-data-validator.ts:157
validatorIsEqual()
validatorIsEqual(
cellInfo,
formula,
rule): Promise<boolean>
Parameters
Parameter | Type |
---|---|
cellInfo | IValidatorCellInfo <CellValue > |
formula | IFormulaResult <any > |
rule | IDataValidationRule |
Returns
Promise
<boolean
>
Inherited from
ListValidator
.validatorIsEqual
Defined in
data-validation/src/validators/base-data-validator.ts:149
validatorIsGreaterThan()
validatorIsGreaterThan(
cellInfo,
formula,
rule): Promise<boolean>
Parameters
Parameter | Type |
---|---|
cellInfo | IValidatorCellInfo <CellValue > |
formula | IFormulaResult <any > |
rule | IDataValidationRule |
Returns
Promise
<boolean
>
Inherited from
ListValidator
.validatorIsGreaterThan
Defined in
data-validation/src/validators/base-data-validator.ts:165
validatorIsGreaterThanOrEqual()
validatorIsGreaterThanOrEqual(
cellInfo,
formula,
rule): Promise<boolean>
Parameters
Parameter | Type |
---|---|
cellInfo | IValidatorCellInfo <CellValue > |
formula | IFormulaResult <any > |
rule | IDataValidationRule |
Returns
Promise
<boolean
>
Inherited from
ListValidator
.validatorIsGreaterThanOrEqual
Defined in
data-validation/src/validators/base-data-validator.ts:169
validatorIsLessThan()
validatorIsLessThan(
cellInfo,
formula,
rule): Promise<boolean>
Parameters
Parameter | Type |
---|---|
cellInfo | IValidatorCellInfo <CellValue > |
formula | IFormulaResult <any > |
rule | IDataValidationRule |
Returns
Promise
<boolean
>
Inherited from
ListValidator
.validatorIsLessThan
Defined in
data-validation/src/validators/base-data-validator.ts:173
validatorIsLessThanOrEqual()
validatorIsLessThanOrEqual(
cellInfo,
formula,
rule): Promise<boolean>
Parameters
Parameter | Type |
---|---|
cellInfo | IValidatorCellInfo <CellValue > |
formula | IFormulaResult <any > |
rule | IDataValidationRule |
Returns
Promise
<boolean
>
Inherited from
ListValidator
.validatorIsLessThanOrEqual
Defined in
data-validation/src/validators/base-data-validator.ts:177
validatorIsNotBetween()
validatorIsNotBetween(
cellInfo,
formula,
rule): Promise<boolean>
Parameters
Parameter | Type |
---|---|
cellInfo | IValidatorCellInfo <CellValue > |
formula | IFormulaResult <any > |
rule | IDataValidationRule |
Returns
Promise
<boolean
>
Inherited from
ListValidator
.validatorIsNotBetween
Defined in
data-validation/src/validators/base-data-validator.ts:161
validatorIsNotEqual()
validatorIsNotEqual(
cellInfo,
formula,
rule): Promise<boolean>
Parameters
Parameter | Type |
---|---|
cellInfo | IValidatorCellInfo <CellValue > |
formula | IFormulaResult <any > |
rule | IDataValidationRule |
Returns
Promise
<boolean
>
Inherited from
ListValidator
.validatorIsNotEqual
Defined in
data-validation/src/validators/base-data-validator.ts:153