Class IdentityStyle

java.lang.Object
org.simpleframework.xml.stream.IdentityStyle
All Implemented Interfaces:
Style

class IdentityStyle extends Object implements Style
The IdentityStyle 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 Details

    • IdentityStyle

      IdentityStyle()
  • Method Details

    • getAttribute

      public String getAttribute(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 interface Style
      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 String getElement(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 interface Style
      Parameters:
      name - this is the token that is to be styled by this
      Returns:
      this returns the same string that is passed in