Package com.github.miachm.sods
Class ConditionalFormat
java.lang.Object
com.github.miachm.sods.ConditionalFormat
- All Implemented Interfaces:
Cloneable
This class refers to a specific rule to apply a conditional style.
It's usually composed by a boolean condition and the specific style to be applied.
-
Method Summary
Modifier and TypeMethodDescriptionclone()static ConditionalFormatconditionWhenCellIsEmpty(Style apply) Create a ConditionalFormat rule where the boolean condition is "cell is empty".static ConditionalFormatconditionWhenCellIsNotEmpty(Style apply) Create a ConditionalFormat rule where the boolean condition is "cell is not empty".static ConditionalFormatconditionWhenTextContains(Style apply, String text) Create a ConditionalFormat rule where the boolean condition is "text contains X".static ConditionalFormatconditionWhenTextDoesNotContain(Style apply, String text) Create a ConditionalFormat rule where the boolean condition is "text does not contain X".static ConditionalFormatconditionWhenTextEndsWith(Style apply, String text) Create a ConditionalFormat rule where the boolean condition is "text ends with X".static ConditionalFormatconditionWhenTextStartsWith(Style apply, String text) Create a ConditionalFormat rule where the boolean condition is "text starts with X".static ConditionalFormatconditionWhenValueIsBetween(Style apply, double init, double end) static ConditionalFormatconditionWhenValueIsEqual(Style apply, double value) Create a ConditionalFormat rule where the boolean condition is "values equals to X".static ConditionalFormatconditionWhenValueIsEqual(Style apply, String value) static ConditionalFormatconditionWhenValueIsGreater(Style apply, double value) Create a ConditionalFormat rule where the boolean condition is "values greater than X".static ConditionalFormatconditionWhenValueIsGreaterOrEqual(Style apply, double value) Create a ConditionalFormat rule where the boolean condition is "values greater than or equal to X".static ConditionalFormatconditionWhenValueIsLower(Style apply, double value) Create a ConditionalFormat rule where the boolean condition is "values lower than X".static ConditionalFormatconditionWhenValueIsLowerOrEqual(Style apply, double value) Create a ConditionalFormat rule where the boolean condition is "values lower than or equal to X".static ConditionalFormatconditionWhenValueIsNotEqual(Style apply, double value) Create a ConditionalFormat rule where the boolean condition is "values not equal to X".static ConditionalFormatconditionWhenValueIsNotEqual(Style apply, String value) booleaninthashCode()
-
Method Details
-
getStyleApplied
-
equals
-
hashCode
public int hashCode() -
clone
- Overrides:
clonein classObject- Throws:
CloneNotSupportedException
-
conditionWhenValueIsGreater
Create a ConditionalFormat rule where the boolean condition is "values greater than X".- Parameters:
apply- the style to ble applied if the condition turns truevalue- the value to compare to- Returns:
- The conditionalFormat style
-
conditionWhenValueIsLower
Create a ConditionalFormat rule where the boolean condition is "values lower than X".- Parameters:
apply- the style to ble applied if the condition turns truevalue- the value to compare to- Returns:
- The conditionalFormat style
-
conditionWhenValueIsEqual
Create a ConditionalFormat rule where the boolean condition is "values equals to X".- Parameters:
apply- the style to ble applied if the condition turns truevalue- the value to compare to- Returns:
- The conditionalFormat style
-
conditionWhenValueIsEqual
-
conditionWhenValueIsGreaterOrEqual
Create a ConditionalFormat rule where the boolean condition is "values greater than or equal to X".- Parameters:
apply- the style to be applied if the condition turns truevalue- the value to compare to- Returns:
- The conditionalFormat style
-
conditionWhenValueIsLowerOrEqual
Create a ConditionalFormat rule where the boolean condition is "values lower than or equal to X".- Parameters:
apply- the style to be applied if the condition turns truevalue- the value to compare to- Returns:
- The conditionalFormat style
-
conditionWhenValueIsNotEqual
Create a ConditionalFormat rule where the boolean condition is "values not equal to X".- Parameters:
apply- the style to be applied if the condition turns truevalue- the value to compare to- Returns:
- The conditionalFormat style
-
conditionWhenValueIsNotEqual
-
conditionWhenTextContains
Create a ConditionalFormat rule where the boolean condition is "text contains X".- Parameters:
apply- the style to be applied if the condition turns truetext- the text to search for- Returns:
- The conditionalFormat style
-
conditionWhenTextDoesNotContain
Create a ConditionalFormat rule where the boolean condition is "text does not contain X".- Parameters:
apply- the style to be applied if the condition turns truetext- the text to search for- Returns:
- The conditionalFormat style
-
conditionWhenTextStartsWith
Create a ConditionalFormat rule where the boolean condition is "text starts with X".- Parameters:
apply- the style to be applied if the condition turns truetext- the text prefix to check for- Returns:
- The conditionalFormat style
-
conditionWhenTextEndsWith
Create a ConditionalFormat rule where the boolean condition is "text ends with X".- Parameters:
apply- the style to be applied if the condition turns truetext- the text suffix to check for- Returns:
- The conditionalFormat style
-
conditionWhenCellIsEmpty
Create a ConditionalFormat rule where the boolean condition is "cell is empty".- Parameters:
apply- the style to be applied if the condition turns true- Returns:
- The conditionalFormat style
-
conditionWhenCellIsNotEmpty
Create a ConditionalFormat rule where the boolean condition is "cell is not empty".- Parameters:
apply- the style to be applied if the condition turns true- Returns:
- The conditionalFormat style
-
conditionWhenValueIsBetween
-