java.lang.Object
io.sf.carte.doc.style.css.om.SupportsConditionFactory
- All Implemented Interfaces:
BooleanConditionFactory,SupportsConditionFactory
Contains factory methods related to
@supports
conditions.-
Constructor Summary
ConstructorsConstructorDescriptionSupportsConditionFactory(SheetContext parentStyleSheet) Construct a new condition factory for rules belonging to the given style sheet context. -
Method Summary
Modifier and TypeMethodDescriptionCreate a boolean condition of theandtype.createFalseCondition(String condition) Create a condition that was not recognized by the parser and therefore will never match.Create a boolean condition of thenottype.Create a boolean condition of the given type (and,or,not).createPredicate(String featureName) Create a declaration (operand) condition.createSelectorFunction(SelectorList selectors) Create a selector function.
-
Constructor Details
-
SupportsConditionFactory
Construct a new condition factory for rules belonging to the given style sheet context.- Parameters:
parentStyleSheet- the style sheet context.
-
-
Method Details
-
createAndCondition
Create a boolean condition of theandtype.- Specified by:
createAndConditionin interfaceBooleanConditionFactory- Returns:
- the condition.
-
createOrCondition
Create a boolean condition of the given type (and,or,not).- Specified by:
createOrConditionin interfaceBooleanConditionFactory- Returns:
- the condition.
-
createNotCondition
Create a boolean condition of thenottype.- Specified by:
createNotConditionin interfaceBooleanConditionFactory- Returns:
- the condition.
-
createPredicate
Create a declaration (operand) condition.The value of the feature can be set later with
DeclarationPredicate.setValue(LexicalUnit).- Specified by:
createPredicatein interfaceBooleanConditionFactory- Parameters:
featureName- the name of the declared feature.- Returns:
- the condition.
-
createSelectorFunction
Create a selector function.- Specified by:
createSelectorFunctionin interfaceSupportsConditionFactory- Parameters:
selectors- the selectors.- Returns:
- the condition.
-
createFalseCondition
Description copied from interface:SupportsConditionFactoryCreate a condition that was not recognized by the parser and therefore will never match.False conditions belong to the
OTHERtype.- Specified by:
createFalseConditionin interfaceSupportsConditionFactory- Parameters:
condition- the condition that was not recognized.- Returns:
- a condition that never matches.
-