Package org.simpleframework.xml.stream
Class IdentityStyle
- java.lang.Object
-
- org.simpleframework.xml.stream.IdentityStyle
-
- All Implemented Interfaces:
Style
class IdentityStyle extends java.lang.Object implements Style
TheIdentityStyle
object is used to represent a style that does not modify the tokens passed in to it. This is used if there is no style specified or if there is no need to convert the XML elements an attributes to a particular style. This is also the most performant style as it does not require cache lookups.
-
-
Constructor Summary
Constructors Constructor Description IdentityStyle()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getAttribute(java.lang.String name)
This is basically a pass through method.java.lang.String
getElement(java.lang.String name)
This is basically a pass through method.
-
-
-
Method Detail
-
getAttribute
public java.lang.String getAttribute(java.lang.String name)
This is basically a pass through method. It will return the same string as is passed in to it. This ensures the best performant when no styling is required for the XML document.- Specified by:
getAttribute
in interfaceStyle
- Parameters:
name
- this is the token that is to be styled by this- Returns:
- this returns the same string that is passed in
-
getElement
public java.lang.String getElement(java.lang.String name)
This is basically a pass through method. It will return the same string as is passed in to it. This ensures the best performant when no styling is required for the XML document.- Specified by:
getElement
in interfaceStyle
- Parameters:
name
- this is the token that is to be styled by this- Returns:
- this returns the same string that is passed in
-
-