Package org.jsoup.nodes
Class Entities
- java.lang.Object
-
- org.jsoup.nodes.Entities
-
public class Entities extends java.lang.ObjectHTML entities, and escape routines. Source: W3C HTML named character references.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classEntities.EscapeMode
-
Method Summary
All Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static intcodepointsForName(java.lang.String name, int[] codepoints)static java.lang.StringgetByName(java.lang.String name)Get the character(s) represented by the named entitystatic java.lang.CharactergetCharacterByName(java.lang.String name)Deprecated.does not support characters outside the BMP or multiple character namesstatic booleanisBaseNamedEntity(java.lang.String name)Check if the input is a known named entity in the base entity set.static booleanisNamedEntity(java.lang.String name)Check if the input is a known named entity
-
-
-
Method Detail
-
isNamedEntity
public static boolean isNamedEntity(java.lang.String name)
Check if the input is a known named entity- Parameters:
name- the possible entity name (e.g. "lt" or "amp")- Returns:
- true if a known named entity
-
isBaseNamedEntity
public static boolean isBaseNamedEntity(java.lang.String name)
Check if the input is a known named entity in the base entity set.- Parameters:
name- the possible entity name (e.g. "lt" or "amp")- Returns:
- true if a known named entity in the base set
- See Also:
isNamedEntity(String)
-
getCharacterByName
public static java.lang.Character getCharacterByName(java.lang.String name)
Deprecated.does not support characters outside the BMP or multiple character namesGet the Character value of the named entity- Parameters:
name- named entity (e.g. "lt" or "amp")- Returns:
- the Character value of the named entity (e.g. '<' or '&')
-
getByName
public static java.lang.String getByName(java.lang.String name)
Get the character(s) represented by the named entity- Parameters:
name- entity (e.g. "lt" or "amp")- Returns:
- the string value of the character(s) represented by this entity, or "" if not defined
-
codepointsForName
public static int codepointsForName(java.lang.String name, int[] codepoints)
-
-