Package com.google.common.css
Class SimpleSplittingSubstitutionMap
- java.lang.Object
-
- com.google.common.css.SimpleSplittingSubstitutionMap
-
- All Implemented Interfaces:
SubstitutionMap
public class SimpleSplittingSubstitutionMap extends java.lang.Object implements SubstitutionMap
This class usesSplittingSubstitutionMapto split css class names to their parts and thenSimpleSubstitutionMapto append an underscore to each part. For example,kd-buttonwould becomekd_-button_.This class is intended for use when debugging your application. This is because the class names will still be readable, but the minimal renaming ensures you'll also spot bugs where you've forgotten to use
goog.getCssName('foo')or{css foo}.To use this, pass the following flags to the CSS compiler:
--css_substitution_map_provider=com.google.common.css.SimpleSplittingSubstitutionMapProvider --output_renaming_map_format=CLOSURE_COMPILED_SPLIT_HYPHENS- See Also:
SimpleSplittingSubstitutionMapProvider
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.google.common.css.SubstitutionMap
SubstitutionMap.Initializable
-
-
Constructor Summary
Constructors Constructor Description SimpleSplittingSubstitutionMap()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Stringget(java.lang.String value)Gets the string that should be substituted forkey.
-
-
-
Method Detail
-
get
public java.lang.String get(java.lang.String value)
Description copied from interface:SubstitutionMapGets the string that should be substituted forkey. The same value must be consistently returned for any particularkey, and the returned value must not be returned for any otherkeyvalue.- Specified by:
getin interfaceSubstitutionMap- Parameters:
value- the text to be replaced (never null)- Returns:
- the value to substitute for
key
-
-