java.lang.Object
org.jhotdraw8.css.function.AbstractCssFunction<T>
org.jhotdraw8.css.function.AbstractMathCssFunction<T>
org.jhotdraw8.css.function.CalcCssFunction<T>
org.jhotdraw8.css.function.RoundCssFunction<T>
- Type Parameters:
T- the element type of the DOM
- All Implemented Interfaces:
CssFunction<T>
Processes the
round() function.
round = "round(", [ rounding-strategy , "," ] , calc-sum , [ "," , calc-sum ] ")" ;
rounding-strategy = "nearest" | "up" | "down" | "to-zero" ;
calc-sum = (* see superclass *)
- CSS Values and Units Module Level 4. Paragraph 10.3. Stepped Value Functions: round(), mod(), and rem()
- csswg.org
- CSS Values and Units Module Level 4. Paragraph 10.8. Syntax
- csswg.org
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets localized help text about this function.voidprocess(@NonNull T element, @NonNull CssTokenizer tt, @NonNull SelectorModel<T> model, @NonNull CssFunctionProcessor<T> functionProcessor, @NonNull Consumer<CssToken> out, Deque<CssFunction<T>> recursionStack) Processes the function.Methods inherited from class org.jhotdraw8.css.function.AbstractMathCssFunction
parseCalcProduct, parseCalcSum, parseCalcValue, produceNumberPercentageOrDimensionMethods inherited from class org.jhotdraw8.css.function.AbstractCssFunction
getName
-
Field Details
-
NAME
Function name.- See Also:
-
-
Constructor Details
-
RoundCssFunction
-
RoundCssFunction
public RoundCssFunction()
-
-
Method Details
-
process
public void process(@NonNull T element, @NonNull CssTokenizer tt, @NonNull SelectorModel<T> model, @NonNull CssFunctionProcessor<T> functionProcessor, @NonNull Consumer<CssToken> out, Deque<CssFunction<T>> recursionStack) throws IOException, ParseException Description copied from interface:CssFunctionProcesses the function.- Specified by:
processin interfaceCssFunction<T>- Overrides:
processin classCalcCssFunction<T>- Parameters:
element- the DOM elementtt- the tokenizer providing the unprocessed tokensmodel- the selector modelfunctionProcessor- the function processorout- the consumer for the processed tokensrecursionStack- the recursion stack- Throws:
IOException- on IO failureParseException- on parsing failure
-
getHelpText
Description copied from interface:CssFunctionGets localized help text about this function.- Specified by:
getHelpTextin interfaceCssFunction<T>- Overrides:
getHelpTextin classCalcCssFunction<T>- Returns:
- localized help text
-