GNU Octave
3.8.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
|
A table which stores sequences of unicode characters, referenced by hash keys. More...
#include "Character.h"
Public Member Functions | |
ExtendedCharTable () | |
Constructs a new character table. | |
~ExtendedCharTable () | |
ushort | createExtendedChar (ushort *unicodePoints, ushort length) |
Adds a sequences of unicode characters to the table and returns a hash code which can be used later to look up the sequence using lookupExtendedChar() | |
ushort * | lookupExtendedChar (ushort hash, ushort &length) const |
Looks up and returns a pointer to a sequence of unicode characters which was added to the table using createExtendedChar(). |
Static Public Attributes | |
static ExtendedCharTable | instance |
The global ExtendedCharTable instance. |
Private Member Functions | |
ushort | extendedCharHash (ushort *unicodePoints, ushort length) const |
bool | extendedCharMatch (ushort hash, ushort *unicodePoints, ushort length) const |
Private Attributes | |
QHash< ushort, ushort * > | extendedCharTable |
A table which stores sequences of unicode characters, referenced by hash keys.
The hash key itself is the same size as a unicode character ( ushort ) so that it can occupy the same space in a structure.
Definition at line 159 of file Character.h.
ExtendedCharTable::ExtendedCharTable | ( | ) |
Constructs a new character table.
Definition at line 411 of file Emulation.cpp.
ExtendedCharTable::~ExtendedCharTable | ( | ) |
Definition at line 414 of file Emulation.cpp.
References extendedCharTable.
ushort ExtendedCharTable::createExtendedChar | ( | ushort * | unicodePoints, |
ushort | length | ||
) |
Adds a sequences of unicode characters to the table and returns a hash code which can be used later to look up the sequence using lookupExtendedChar()
If the same sequence already exists in the table, the hash of the existing sequence will be returned.
unicodePoints | An array of unicode character points |
length | Length of unicodePoints |
Definition at line 358 of file Emulation.cpp.
References extendedCharHash(), extendedCharMatch(), extendedCharTable, and jit_convention::length.
|
private |
Definition at line 332 of file Emulation.cpp.
References jit_convention::length.
Referenced by createExtendedChar().
|
private |
Definition at line 341 of file Emulation.cpp.
References extendedCharTable, and jit_convention::length.
Referenced by createExtendedChar().
ushort * ExtendedCharTable::lookupExtendedChar | ( | ushort | hash, |
ushort & | length | ||
) | const |
Looks up and returns a pointer to a sequence of unicode characters which was added to the table using createExtendedChar().
hash | The hash key returned by createExtendedChar() |
length | This variable is set to the length of the character sequence. |
length
. Definition at line 393 of file Emulation.cpp.
References extendedCharTable.
Referenced by TerminalView::drawContents().
|
private |
Definition at line 201 of file Character.h.
Referenced by createExtendedChar(), extendedCharMatch(), lookupExtendedChar(), and ~ExtendedCharTable().
|
static |
The global ExtendedCharTable instance.
Definition at line 191 of file Character.h.
Referenced by TerminalView::drawContents().