Package io.keikai.model.impl
Class DataValidationImpl
- java.lang.Object
-
- io.keikai.model.impl.AbstractDataValidationAdv
-
- io.keikai.model.impl.DataValidationImpl
-
- All Implemented Interfaces:
FormulaContent
,LinkedModelObject
,SDataValidation
,Serializable
public class DataValidationImpl extends AbstractDataValidationAdv
- Since:
- 3.5.0
- Author:
- Dennis
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface io.keikai.model.SDataValidation
SDataValidation.AlertStyle, SDataValidation.OperatorType, SDataValidation.ValidationType
-
-
Constructor Summary
Constructors Constructor Description DataValidationImpl(AbstractSheetAdv sheet, AbstractDataValidationAdv copyFrom)
DataValidationImpl(AbstractSheetAdv sheet, String id)
-
Method Summary
-
-
-
Constructor Detail
-
DataValidationImpl
public DataValidationImpl(AbstractSheetAdv sheet, String id)
-
DataValidationImpl
public DataValidationImpl(AbstractSheetAdv sheet, AbstractDataValidationAdv copyFrom)
-
-
Method Detail
-
getId
public String getId()
-
getSheet
public SSheet getSheet()
-
checkOrphan
public void checkOrphan()
-
destroy
public void destroy()
Description copied from interface:LinkedModelObject
Destroy / release this model object, for example all the dependency, parent linking. this method has to be called before remove this linking from parent object
-
getAlertStyle
public SDataValidation.AlertStyle getAlertStyle()
-
setAlertStyle
public void setAlertStyle(SDataValidation.AlertStyle alertStyle)
-
setIgnoreBlank
public void setIgnoreBlank(boolean allowed)
-
isIgnoreBlank
public boolean isIgnoreBlank()
-
setInCellDropdown
public void setInCellDropdown(boolean show)
-
isInCellDropdown
public boolean isInCellDropdown()
-
setShowInput
public void setShowInput(boolean show)
-
isShowInput
public boolean isShowInput()
-
setShowError
public void setShowError(boolean show)
-
isShowError
public boolean isShowError()
-
setInputTitle
public void setInputTitle(String title)
-
setInputMessage
public void setInputMessage(String message)
-
getInputTitle
public String getInputTitle()
-
getInputMessage
public String getInputMessage()
-
setErrorTitle
public void setErrorTitle(String title)
-
setErrorMessage
public void setErrorMessage(String text)
-
getErrorTitle
public String getErrorTitle()
-
getErrorMessage
public String getErrorMessage()
-
getRegions
public Set<CellRegion> getRegions()
-
addRegion
public void addRegion(CellRegion region)
-
removeRegion
public void removeRegion(CellRegion region)
-
setRegions
public void setRegions(Set<CellRegion> regions)
-
getValidationType
public SDataValidation.ValidationType getValidationType()
-
setValidationType
public void setValidationType(SDataValidation.ValidationType type)
-
getOperatorType
public SDataValidation.OperatorType getOperatorType()
-
setOperatorType
public void setOperatorType(SDataValidation.OperatorType type)
-
isFormulaParsingError
public boolean isFormulaParsingError()
Description copied from interface:SDataValidation
Return formula parsing state.- Returns:
- true if has error, false if no error or no formula
-
getNumOfValue
public int getNumOfValue()
-
getValue
public Object getValue(int index)
-
getNumOfValue1
public int getNumOfValue1()
-
getValue1
public Object getValue1(int index)
-
getNumOfValue2
public int getNumOfValue2()
-
getValue2
public Object getValue2(int index)
-
getFormula1
public String getFormula1()
-
getFormula2
public String getFormula2()
-
setFormula1
public void setFormula1(String formula1)
-
setFormula2
public void setFormula2(String formula2)
-
setFormulas
public void setFormulas(String formula1, String formula2)
Description copied from class:AbstractDataValidationAdv
Setup the two formulas.- Specified by:
setFormulas
in classAbstractDataValidationAdv
-
setEscapedFormulas
public void setEscapedFormulas(String formula1, String formula2)
Description copied from class:AbstractDataValidationAdv
Setup the two formulas which are in escaped POI format.- Specified by:
setEscapedFormulas
in classAbstractDataValidationAdv
-
clearFormulaResultCache
public void clearFormulaResultCache()
Description copied from interface:FormulaContent
Clear the formula result cache if there is evaluation result
-
hasReferToCellList
public boolean hasReferToCellList()
-
setFormulas
public void setFormulas(FormulaExpression fe1, FormulaExpression fe2)
- Specified by:
setFormulas
in classAbstractDataValidationAdv
- Parameters:
fe1
-fe2
-- Since:
- 3.6.0
-
getFormulaExpression1
public FormulaExpression getFormulaExpression1()
- Specified by:
getFormulaExpression1
in classAbstractDataValidationAdv
- Returns:
- Since:
- 3.6.0
-
getFormulaExpression2
public FormulaExpression getFormulaExpression2()
- Specified by:
getFormulaExpression2
in classAbstractDataValidationAdv
- Returns:
- Since:
- 3.6.0
-
setFormula1
public void setFormula1(FormulaExpression formula1)
- Specified by:
setFormula1
in classAbstractDataValidationAdv
- Since:
- 3.6.0
-
setFormula2
public void setFormula2(FormulaExpression formula2)
- Specified by:
setFormula2
in classAbstractDataValidationAdv
- Since:
- 3.6.0
-
getValueEval1
public ValueEval getValueEval1()
- Specified by:
getValueEval1
in classAbstractDataValidationAdv
- Returns:
-
getValueEval2
public ValueEval getValueEval2()
- Specified by:
getValueEval2
in classAbstractDataValidationAdv
- Returns:
-
hasReferToRelativeCol
public boolean hasReferToRelativeCol()
Description copied from interface:SDataValidation
Returns whether the referred list formula contains a relative column.- Returns:
-
hasReferToRelativeRow
public boolean hasReferToRelativeRow()
Description copied from interface:SDataValidation
Returns whether the referred list formula contains a relative row.- Returns:
-
getReferToCellList
public List<SCell> getReferToCellList(int row, int col)
Description copied from interface:SDataValidation
Return the referred list relative to the specified row and column.- Returns:
-
addDependency
public void addDependency(int row, int col)
- Specified by:
addDependency
in classAbstractDataValidationAdv
-
getEscapedFormula1
public String getEscapedFormula1()
- Specified by:
getEscapedFormula1
in classAbstractDataValidationAdv
- Returns:
-
getEscapedFormula2
public String getEscapedFormula2()
- Specified by:
getEscapedFormula2
in classAbstractDataValidationAdv
- Returns:
-
-