| Package | vegas.net |
| Class | public class HTMLEntities |
| Inheritance | HTMLEntities Object |
| Property | Defined By | ||
|---|---|---|---|
| entities : Array [static]
Determinates all entities. | HTMLEntities | ||
| specialchars : Array [static]
Determinates all special chars. | HTMLEntities | ||
| Method | Defined By | ||
|---|---|---|---|
decode(text:String, removeCRLF:Boolean = false):String [static]
Decodes the specified string. | HTMLEntities | ||
encode(text:String):String [static]
Encodes the specified text passed in argument. | HTMLEntities | ||
getCharToEntity(char:String):String [static]
Returns the entity name of the specified character in argument. | HTMLEntities | ||
getCharToEntityNumber(char:String):String [static]
Returns the entity number string representation of the specified character in argument. | HTMLEntities | ||
getEntityNumberToChar(entityNumber:String):String [static]
Returns the char representation of the specified entity number string value in argument or an empty string value. | HTMLEntities | ||
| entities | property |
public static var entities:ArrayDeterminates all entities.
| specialchars | property |
public static var specialchars:ArrayDeterminates all special chars.
| decode | () | method |
public static function decode(text:String, removeCRLF:Boolean = false):StringDecodes the specified string.
Example :
import vegas.net.HTMLEntities ;
trace( HTMLEntities.decode("<b>hello world</b>" ) ) ; // hello world
Parameters
text:String | |
removeCRLF:Boolean (default = false) |
String — the decode string.
|
| encode | () | method |
public static function encode(text:String):StringEncodes the specified text passed in argument.
Example :
import vegas.net.HTMLEntities ;
trace( HTMLEntities.encode("hello world" ) ) ; // <b>hello world</b>
Parameters
text:String |
String — a string encode text.
|
| getCharToEntity | () | method |
public static function getCharToEntity(char:String):StringReturns the entity name of the specified character in argument. Returns an empty string value if the char passed-in argument isn't a special char to transform in entity string representation.
Example :
import vegas.net.HTMLEntities ;
trace( HTMLEntities.getCharToEntity("<") ) ;
Parameters
char:String |
String — the entity name of the specified character in argument.
|
| getCharToEntityNumber | () | method |
public static function getCharToEntityNumber(char:String):StringReturns the entity number string representation of the specified character in argument.
Example :
import vegas.net.HTMLEntities ;
trace( HTMLEntities.getCharToEntityNumber("<") ) ;
Parameters
char:String |
String — the entity number string representation of the specified character in argument.
|
| getEntityNumberToChar | () | method |
public static function getEntityNumberToChar(entityNumber:String):StringReturns the char representation of the specified entity number string value in argument or an empty string value.
Example :
import vegas.net.HTMLEntities ;
trace( HTMLEntities.getEntityNumberToChar("<")) ; // <
Parameters
entityNumber:String |
String — the char representation of the specified entity number string value in argument or an empty string value.
|