Options
All
  • Public
  • Public/Protected
  • All
Menu

Class XmlCharRef<Parent>

Represents a character reference.

A character reference is structured as follows, where {dec} is the decimal representation code point corresponding to a particular Unicode character:

&#{dec};

The corresponding hexadecimal version is structured as follows, where {hex} is the hexadecimal representation code point corresponding to a particular Unicode character:

&#x{hex};

Unicode characters outside of the Basic Multilingual Plane are represented using a surrogate pair consisting of two character references.

The {dec} and {hex} values are defined by the char and hex properties of this node; the former is the character to be represented while the latter indicates whether the decimal or hexadecimal representation should be used.

Type parameters

  • Parent

Hierarchy

  • XmlCharRef

Index

Constructors

Properties

Accessors

Methods

Constructors

constructor

Properties

Private _char

_char: string

Private _hex

_hex: boolean = false

Private _parent

_parent: Parent

Private _validation

_validation: boolean

Accessors

char

  • get char(): string
  • set char(char: string): void
  • Gets the character of this character reference.

    Returns string

  • Sets the character of this character reference.

    Parameters

    • char: string

    Returns void

hex

  • get hex(): boolean
  • set hex(hex: boolean): void
  • Gets whether the decimal or hexadecimal representation should be used for this character reference.

    Returns boolean

  • Sets whether the decimal or hexadecimal representation should be used for this character reference.

    Parameters

    • hex: boolean

    Returns void

Methods

toString

  • toString(): string
  • Returns an XML string representation of this character reference.

    Returns string

up

  • up(): Parent
  • Returns the parent of this character reference.

    Returns Parent

Generated using TypeDoc