@univerjs/sheets-data-validation v0.5.4


Class: ListMultipleValidator

Defined in: sheets-data-validation/src/validators/list-multiple-validator.ts:20

Extends

Constructors

new ListMultipleValidator()

new ListMultipleValidator(localeService, injector): ListMultipleValidator

Defined in: data-validation/src/validators/base-data-validator.ts:79

Parameters

ParameterType
localeServiceLocaleService
injectorInjector

Returns

ListMultipleValidator

Inherited from

ListValidator.constructor

Properties

PropertyModifierTypeDefault valueOverridesInherited fromDefined in
canvasRenderpublicNullable<IBaseDataValidationWidget>null-ListValidator.canvasRenderdata-validation/src/validators/base-data-validator.ts:73
dropdownpublicundefined | stringundefined-ListValidator.dropdowndata-validation/src/validators/base-data-validator.ts:74
formulaInputpublicundefined | stringundefined-ListValidator.formulaInputdata-validation/src/validators/base-data-validator.ts:72
formulaServiceprotectedDataValidationFormulaServiceundefined-ListValidator.formulaServicesheets-data-validation/src/validators/list-validator.ts:92
idpublicstringDataValidationType.LIST_MULTIPLEListValidator.id-sheets-data-validation/src/validators/list-multiple-validator.ts:21
injectorreadonlyInjectorundefined-ListValidator.injectordata-validation/src/validators/base-data-validator.ts:81
localeServicereadonlyLocaleServiceundefined-ListValidator.localeServicedata-validation/src/validators/base-data-validator.ts:80
offsetFormulaByRangereadonlyfalsefalseListValidator.offsetFormulaByRange-sheets-data-validation/src/validators/list-multiple-validator.ts:23
operatorspublicDataValidationOperator[][]-ListValidator.operatorssheets-data-validation/src/validators/list-validator.ts:100
optionsInputpublicundefined | stringundefined-ListValidator.optionsInputdata-validation/src/validators/base-data-validator.ts:75
scopespublicstring | string[]undefined-ListValidator.scopessheets-data-validation/src/validators/list-validator.ts:101
titlepublicstring'dataValidation.listMultiple.title'ListValidator.title-sheets-data-validation/src/validators/list-multiple-validator.ts:22

Accessors

operatorNames

Get Signature

get operatorNames(): string[]

Defined in: data-validation/src/validators/base-data-validator.ts:86

Returns

string[]

Inherited from

ListValidator.operatorNames


titleStr

Get Signature

get titleStr(): string

Defined in: data-validation/src/validators/base-data-validator.ts:90

Returns

string

Inherited from

ListValidator.titleStr

Methods

generateRuleErrorMessage()

generateRuleErrorMessage(): string

Defined in: sheets-data-validation/src/validators/list-validator.ts:176

Returns

string

Inherited from

ListValidator.generateRuleErrorMessage


generateRuleName()

generateRuleName(): string

Defined in: sheets-data-validation/src/validators/list-validator.ts:172

Returns

string

Inherited from

ListValidator.generateRuleName


getExtraStyle()

getExtraStyle(
   rule, 
   value, 
__namedParameters): Nullable<IStyleData>

Defined in: sheets-data-validation/src/validators/list-validator.ts:125

Parameters

ParameterType
ruleIDataValidationRule
valueNullable<CellValue>
__namedParameters{ style: IStyleData; }
__namedParameters.styleIStyleData

Returns

Nullable<IStyleData>

Inherited from

ListValidator.getExtraStyle


getList()

getList(
   rule, 
   currentUnitId?, 
   currentSubUnitId?): string[]

Defined in: sheets-data-validation/src/validators/list-validator.ts:180

Parameters

ParameterType
ruleIDataValidationRule
currentUnitId?string
currentSubUnitId?string

Returns

string[]

Inherited from

ListValidator.getList


getListAsync()

getListAsync(
   rule, 
   currentUnitId?, 
currentSubUnitId?): Promise<string[]>

Defined in: sheets-data-validation/src/validators/list-validator.ts:195

Parameters

ParameterType
ruleIDataValidationRule
currentUnitId?string
currentSubUnitId?string

Returns

Promise<string[]>

Inherited from

ListValidator.getListAsync


getListWithColor()

getListWithColor(
   rule, 
   currentUnitId?, 
   currentSubUnitId?): {
  color: string;
  label: string;
 }[]

Defined in: sheets-data-validation/src/validators/list-validator.ts:210

Parameters

ParameterType
ruleIDataValidationRule
currentUnitId?string
currentSubUnitId?string

Returns

{ color: string; label: string; }[]

Inherited from

ListValidator.getListWithColor


getListWithColorMap()

getListWithColorMap(
   rule, 
   currentUnitId?, 
currentSubUnitId?): Record<string, string>

Defined in: sheets-data-validation/src/validators/list-validator.ts:217

Parameters

ParameterType
ruleIDataValidationRule
currentUnitId?string
currentSubUnitId?string

Returns

Record<string, string>

Inherited from

ListValidator.getListWithColorMap


getRuleFinalError()

getRuleFinalError(rule, position): string

Defined in: data-validation/src/validators/base-data-validator.ts:116

Parameters

ParameterType
ruleIDataValidationRule
positionISheetLocationBase

Returns

string

Inherited from

ListValidator.getRuleFinalError


isEmptyCellValue()

isEmptyCellValue(cellValue): cellValue is undefined | null | void

Defined in: data-validation/src/validators/base-data-validator.ts:124

Parameters

ParameterType
cellValueNullable<CellValue>

Returns

cellValue is undefined | null | void

Inherited from

ListValidator.isEmptyCellValue


isValidType()

isValidType(
   cellInfo, 
   formula, 
rule): Promise<boolean>

Defined in: sheets-data-validation/src/validators/list-validator.ts:163

Parameters

ParameterType
cellInfoIValidatorCellInfo
formulaIFormulaResult<undefined | string[]>
ruleIDataValidationRule

Returns

Promise<boolean>

Inherited from

ListValidator.isValidType


normalizeFormula()

normalizeFormula(
   rule, 
   unitId, 
   subUnitId): {
  formula1: undefined | string;
  formula2: undefined | string;
}

Defined in: data-validation/src/validators/base-data-validator.ts:136

Parameters

ParameterType
ruleIDataValidationRule
unitIdstring
subUnitIdstring

Returns

{
  formula1: undefined | string;
  formula2: undefined | string;
}
NameTypeDefault valueDefined in
formula1undefined | stringrule.formula1data-validation/src/validators/base-data-validator.ts:138
formula2undefined | stringrule.formula2data-validation/src/validators/base-data-validator.ts:139

Inherited from

ListValidator.normalizeFormula


parseCellValue()

parseCellValue(cellValue): string[]

Defined in: sheets-data-validation/src/validators/list-validator.ts:146

Parameters

ParameterType
cellValueCellValue

Returns

string[]

Inherited from

ListValidator.parseCellValue


parseFormula()

parseFormula(
   rule, 
   unitId, 
subUnitId): Promise<IFormulaResult<undefined | number>>

Defined in: sheets-data-validation/src/validators/list-validator.ts:151

Parameters

ParameterType
ruleIDataValidationRule
unitIdstring
subUnitIdstring

Returns

Promise<IFormulaResult<undefined | number>>

Inherited from

ListValidator.parseFormula


skipDefaultFontRender()

skipDefaultFontRender(): boolean

Defined in: sheets-data-validation/src/validators/list-multiple-validator.ts:25

Returns

boolean

Overrides

ListValidator.skipDefaultFontRender


transform()

transform(
   cellInfo, 
   formula, 
rule): IValidatorCellInfo<number>

Defined in: data-validation/src/validators/base-data-validator.ts:147

Parameters

ParameterType
cellInfoIValidatorCellInfo
formulaIFormulaResult
ruleIDataValidationRule

Returns

IValidatorCellInfo<number>

Inherited from

ListValidator.transform


validator()

validator(cellInfo, rule): Promise<boolean>

Defined in: data-validation/src/validators/base-data-validator.ts:224

Parameters

ParameterType
cellInfoIValidatorCellInfo
ruleIDataValidationRule

Returns

Promise<boolean>

Inherited from

ListValidator.validator


validatorFormula()

validatorFormula(
   rule, 
   unitId, 
   subUnitId): IFormulaValidResult

Defined in: sheets-data-validation/src/validators/list-validator.ts:107

Parameters

ParameterType
ruleIDataValidationRule
unitIdstring
subUnitIdstring

Returns

IFormulaValidResult

Inherited from

ListValidator.validatorFormula


validatorIsBetween()

validatorIsBetween(
   cellInfo, 
   formula, 
_rule): Promise<boolean>

Defined in: data-validation/src/validators/base-data-validator.ts:170

Parameters

ParameterType
cellInfoIValidatorCellInfo<number>
formulaIFormulaResult
_ruleIDataValidationRule

Returns

Promise<boolean>

Inherited from

ListValidator.validatorIsBetween


validatorIsEqual()

validatorIsEqual(
   cellInfo, 
   formula, 
rule): Promise<boolean>

Defined in: data-validation/src/validators/base-data-validator.ts:151

Parameters

ParameterType
cellInfoIValidatorCellInfo<CellValue>
formulaIFormulaResult
ruleIDataValidationRule

Returns

Promise<boolean>

Inherited from

ListValidator.validatorIsEqual


validatorIsGreaterThan()

validatorIsGreaterThan(
   cellInfo, 
   formula, 
_rule): Promise<boolean>

Defined in: data-validation/src/validators/base-data-validator.ts:191

Parameters

ParameterType
cellInfoIValidatorCellInfo<number>
formulaIFormulaResult
_ruleIDataValidationRule

Returns

Promise<boolean>

Inherited from

ListValidator.validatorIsGreaterThan


validatorIsGreaterThanOrEqual()

validatorIsGreaterThanOrEqual(
   cellInfo, 
   formula, 
_rule): Promise<boolean>

Defined in: data-validation/src/validators/base-data-validator.ts:199

Parameters

ParameterType
cellInfoIValidatorCellInfo<number>
formulaIFormulaResult
_ruleIDataValidationRule

Returns

Promise<boolean>

Inherited from

ListValidator.validatorIsGreaterThanOrEqual


validatorIsLessThan()

validatorIsLessThan(
   cellInfo, 
   formula, 
_rule): Promise<boolean>

Defined in: data-validation/src/validators/base-data-validator.ts:207

Parameters

ParameterType
cellInfoIValidatorCellInfo<number>
formulaIFormulaResult
_ruleIDataValidationRule

Returns

Promise<boolean>

Inherited from

ListValidator.validatorIsLessThan


validatorIsLessThanOrEqual()

validatorIsLessThanOrEqual(
   cellInfo, 
   formula, 
_rule): Promise<boolean>

Defined in: data-validation/src/validators/base-data-validator.ts:215

Parameters

ParameterType
cellInfoIValidatorCellInfo<number>
formulaIFormulaResult
_ruleIDataValidationRule

Returns

Promise<boolean>

Inherited from

ListValidator.validatorIsLessThanOrEqual


validatorIsNotBetween()

validatorIsNotBetween(
   cellInfo, 
   formula, 
_rule): Promise<boolean>

Defined in: data-validation/src/validators/base-data-validator.ts:181

Parameters

ParameterType
cellInfoIValidatorCellInfo<number>
formulaIFormulaResult
_ruleIDataValidationRule

Returns

Promise<boolean>

Inherited from

ListValidator.validatorIsNotBetween


validatorIsNotEqual()

validatorIsNotEqual(
   cellInfo, 
   formula, 
_rule): Promise<boolean>

Defined in: data-validation/src/validators/base-data-validator.ts:161

Parameters

ParameterType
cellInfoIValidatorCellInfo<number>
formulaIFormulaResult
_ruleIDataValidationRule

Returns

Promise<boolean>

Inherited from

ListValidator.validatorIsNotEqual