Package com.sun.tools.xjc.generator.util
Class WhitespaceNormalizer
java.lang.Object
com.sun.tools.xjc.generator.util.WhitespaceNormalizer
Generates code that performs the whitespace normalization.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final WhitespaceNormalizer
static final WhitespaceNormalizer
static final WhitespaceNormalizer
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract JExpression
generate
(JCodeModel codeModel, JExpression literal) Generates the expression that normalizes the given expression (which evaluates to java.lang.String).static WhitespaceNormalizer
Parses "preserve","replace" or "collapse" into the corresponding WhitespaceNormalizer object.
-
Field Details
-
PRESERVE
-
REPLACE
-
COLLAPSE
-
-
Constructor Details
-
WhitespaceNormalizer
public WhitespaceNormalizer()
-
-
Method Details
-
generate
Generates the expression that normalizes the given expression (which evaluates to java.lang.String).- Parameters:
codeModel
- The owner code model object under which a new expression will be created.
-
parse
Parses "preserve","replace" or "collapse" into the corresponding WhitespaceNormalizer object.- Parameters:
method
- Either "preserve", "replace", or "collapse"- Throws:
IllegalArgumentException
- when the specified method is invalid.
-