Class CSSColorParameter
- java.lang.Object
-
- org.ametys.skinfactory.parameters.AbstractSkinParameter
-
- org.ametys.skinfactory.parameters.CSSParameter
-
- org.ametys.skinfactory.parameters.CSSColorParameter
-
public class CSSColorParameter extends CSSParameter
Implementation ofAbstractSkinParameter
for a CSS property of type color (color, background-color, border-color)
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.ametys.skinfactory.parameters.AbstractSkinParameter
AbstractSkinParameter.SkinParameterType, AbstractSkinParameter.Widget
-
-
Field Summary
Fields Modifier and Type Field Description private static Pattern
__HEX_HASH_LESS_PATTERN
private static Pattern
__HEX_PATTERN
private SkinModel
_model
private SkinFactoryComponent
_skinFactory
-
Fields inherited from class org.ametys.skinfactory.parameters.AbstractSkinParameter
_description, _id, _label
-
-
Constructor Summary
Constructors Constructor Description CSSColorParameter(String id, I18nizableText label, I18nizableText description, Path cssFile, String cssProperty, String defaultValue, SkinModel model, SkinFactoryComponent skinFactory)
Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
apply(Path tempDir, Path modelDir, Object value, String lang)
Apply parameter to the skin-
Methods inherited from class org.ametys.skinfactory.parameters.CSSParameter
addCSSFile, cssFileToString, getCSSFiles, getCSSPattern, getCSSProperty, getDefaultValue, getDefaultValue, getType, toJson, toSAX
-
Methods inherited from class org.ametys.skinfactory.parameters.AbstractSkinParameter
getDescription, getId, getLabel, setDescription, setLabel
-
-
-
-
Field Detail
-
__HEX_HASH_LESS_PATTERN
private static final Pattern __HEX_HASH_LESS_PATTERN
-
__HEX_PATTERN
private static final Pattern __HEX_PATTERN
-
_skinFactory
private SkinFactoryComponent _skinFactory
-
-
Constructor Detail
-
CSSColorParameter
public CSSColorParameter(String id, I18nizableText label, I18nizableText description, Path cssFile, String cssProperty, String defaultValue, SkinModel model, SkinFactoryComponent skinFactory)
Constructor- Parameters:
id
- the unique idlabel
- the labeldescription
- the descriptioncssFile
- the css filecssProperty
- the css propertydefaultValue
- the default valuemodel
- the modelskinFactory
- the skin factory manager
-
-
Method Detail
-
apply
public void apply(Path tempDir, Path modelDir, Object value, String lang) throws SkinParameterException
Description copied from class:AbstractSkinParameter
Apply parameter to the skin- Overrides:
apply
in classCSSParameter
- Parameters:
tempDir
- the work directorymodelDir
- the model directoryvalue
- the valuelang
- The language. Can be null.- Throws:
SkinParameterException
-
-