Class SpecialEntity

java.lang.Object
org.htmlcleaner.SpecialEntity

public class SpecialEntity extends Object
  • Field Details

    • key

      private final String key
    • intCode

      private final int intCode
    • htmlString

      private final String htmlString
    • htmlSpecialEntity

      private boolean htmlSpecialEntity
    • escapedXmlString

      private final String escapedXmlString
  • Constructor Details

    • SpecialEntity

      public SpecialEntity(String key, int intCode, String htmlString, boolean htmlSpecialEntity)
      Parameters:
      key - value between invalid input: '&' and the ';' example 'amp' for '&'
      intCode -
      htmlString -
      htmlSpecialEntity - entity is affected by translateSpecialEntities property setting.
  • Method Details

    • getKey

      public String getKey()
      Returns:
      the key
    • intValue

      public int intValue()
      Returns:
      the intCode
    • getHtmlString

      public String getHtmlString()
      Returns:
      the domString
    • getEscapedXmlString

      public String getEscapedXmlString()
    • getEscaped

      public String getEscaped(boolean htmlEscaped)
    • isHtmlSpecialEntity

      public boolean isHtmlSpecialEntity()
      Returns:
      the translateSpecialEntities
    • charValue

      public char charValue()
      Returns:
      intValue() cast to an char
    • getDecimalNCR

      public String getDecimalNCR()
      Returns:
      Numeric Character Reference in decimal format
    • getHexNCR

      public String getHexNCR()
      Returns:
      Numeric Character Reference in hex format
    • getEscapedValue

      public String getEscapedValue()
      Returns:
      Escaped value of the entity