public class XSSFDataValidation extends java.lang.Object implements DataValidation
DataValidation.ErrorStyle| Constructor and Description |
|---|
XSSFDataValidation(XSSFDataValidationConstraint constraint,
CellRangeAddressList regions,
org.openxmlformats.schemas.spreadsheetml.x2006.main.CTDataValidation ctDataValidation) |
| Modifier and Type | Method and Description |
|---|---|
void |
createErrorBox(java.lang.String title,
java.lang.String text)
Sets the title and text for the error box .
|
void |
createPromptBox(java.lang.String title,
java.lang.String text)
Sets the title and text for the prompt box .
|
boolean |
getEmptyCellAllowed()
Retrieve the settings for empty cells allowed
|
java.lang.String |
getErrorBoxText() |
java.lang.String |
getErrorBoxTitle() |
int |
getErrorStyle()
o
|
java.lang.String |
getPromptBoxText() |
java.lang.String |
getPromptBoxTitle() |
CellRangeAddressList |
getRegions() |
boolean |
getShowErrorBox() |
boolean |
getShowPromptBox() |
boolean |
getSuppressDropDownArrow()
Useful only list validation objects .
|
DataValidationConstraint |
getValidationConstraint() |
java.lang.String |
prettyPrint() |
void |
setEmptyCellAllowed(boolean allowed)
Sets if this object allows empty as a valid value
|
void |
setErrorStyle(int errorStyle)
Sets the error style for error box
|
void |
setShowErrorBox(boolean show)
Sets the behaviour when an invalid value is entered
|
void |
setShowPromptBox(boolean show)
Sets the behaviour when a cell which belongs to this object is selected
|
void |
setSuppressDropDownArrow(boolean suppress)
Useful for list validation objects .
|
public XSSFDataValidation(XSSFDataValidationConstraint constraint, CellRangeAddressList regions, org.openxmlformats.schemas.spreadsheetml.x2006.main.CTDataValidation ctDataValidation)
public void createErrorBox(java.lang.String title,
java.lang.String text)
DataValidationcreateErrorBox in interface DataValidationtitle - The error box's titletext - The error box's textpublic void createPromptBox(java.lang.String title,
java.lang.String text)
DataValidationcreatePromptBox in interface DataValidationtitle - The prompt box's titletext - The prompt box's textpublic boolean getEmptyCellAllowed()
DataValidationgetEmptyCellAllowed in interface DataValidationpublic java.lang.String getErrorBoxText()
getErrorBoxText in interface DataValidationnullpublic java.lang.String getErrorBoxTitle()
getErrorBoxTitle in interface DataValidationnullpublic int getErrorStyle()
DataValidationgetErrorStyle in interface DataValidationDataValidation.ErrorStylepublic java.lang.String getPromptBoxText()
getPromptBoxText in interface DataValidationnullpublic java.lang.String getPromptBoxTitle()
getPromptBoxTitle in interface DataValidationnullpublic boolean getShowErrorBox()
getShowErrorBox in interface DataValidationtrue if an error box should be displayed , false otherwisepublic boolean getShowPromptBox()
getShowPromptBox in interface DataValidationtrue if an prompt box should be displayed , false otherwisepublic boolean getSuppressDropDownArrow()
DataValidationgetSuppressDropDownArrow in interface DataValidationtrue if a list should display the values into a drop down list ,
false otherwise .public DataValidationConstraint getValidationConstraint()
getValidationConstraint in interface DataValidationpublic void setEmptyCellAllowed(boolean allowed)
DataValidationsetEmptyCellAllowed in interface DataValidationallowed - true if this object should treats empty as valid value , false
otherwisepublic void setErrorStyle(int errorStyle)
DataValidationsetErrorStyle in interface DataValidationDataValidation.ErrorStylepublic void setShowErrorBox(boolean show)
DataValidationsetShowErrorBox in interface DataValidationshow - true if an error box should be displayed , false otherwisepublic void setShowPromptBox(boolean show)
DataValidationsetShowPromptBox in interface DataValidationshow - true if an prompt box should be displayed , false otherwisepublic void setSuppressDropDownArrow(boolean suppress)
DataValidationsetSuppressDropDownArrow in interface DataValidationsuppress - True if a list should display the values into a drop down list ,
false otherwise . In other words , if a list should display
the arrow sign on its right sidepublic CellRangeAddressList getRegions()
getRegions in interface DataValidationpublic java.lang.String prettyPrint()
Copyright 2022 The Apache Software Foundation or its licensors, as applicable.