Class GssFunctions.DesaturateColor
java.lang.Object
com.google.common.css.compiler.gssfunctions.GssFunctions.BaseHslColorManipulation
com.google.common.css.compiler.gssfunctions.GssFunctions.DesaturateColor
- All Implemented Interfaces:
GssFunction
- Enclosing class:
- GssFunctions
public static class GssFunctions.DesaturateColor
extends GssFunctions.BaseHslColorManipulation
implements GssFunction
Decrease the saturation of the specified color. First argument is the
color, second is the absolute amount of saturation in HSL color space
to substract (from 0 to 100).
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetCallResultNodes(List<CssValueNode> args, ErrorManager errorManager) Processes a list of function call arguments and returns a list of CssNodes representing this call's output, which replace the input nodes in the AST.getCallResultString(List<String> args) Processes a list of strings as function arguments and returns a string result.Returns the number of parsed arguments that this function takes, ornullif the number of arguments may vary.Methods inherited from class com.google.common.css.compiler.gssfunctions.GssFunctions.BaseHslColorManipulation
addHslToCssColor, addHslToCssColor
-
Constructor Details
-
DesaturateColor
public DesaturateColor()
-
-
Method Details
-
getNumExpectedArguments
Description copied from interface:GssFunctionReturns the number of parsed arguments that this function takes, ornullif the number of arguments may vary.- Specified by:
getNumExpectedArgumentsin interfaceGssFunction
-
getCallResultNodes
public List<CssValueNode> getCallResultNodes(List<CssValueNode> args, ErrorManager errorManager) throws GssFunctionException Description copied from interface:GssFunctionProcesses a list of function call arguments and returns a list of CssNodes representing this call's output, which replace the input nodes in the AST. Errors will be reported to the ErrorManager.- Specified by:
getCallResultNodesin interfaceGssFunction- Throws:
GssFunctionException
-
getCallResultString
Description copied from interface:GssFunctionProcesses a list of strings as function arguments and returns a string result. Errors are reported by throwingGssFunctionException.- Specified by:
getCallResultStringin interfaceGssFunction- Throws:
GssFunctionException
-