Defines the interface for reading and writing elements in a byte array.
More...
|
int | GetElementHashCode (T element) |
| Calculate the hash code of an element.
|
|
int | GetElementWordCount () |
| Gets the word count of an element.
|
|
T | Read (byte *data, int index) |
| Reads an element from the specified index in the byte array.
|
|
ref T | ReadRef (byte *data, int index) |
| Reads a reference to an element from the specified index in the byte array.
|
|
void | Write (byte *data, int index, T element) |
| Writes an element to the specified index in the byte array.
|
|
Defines the interface for reading and writing elements in a byte array.
- Template Parameters
-
T | The type of the elements. |
◆ GetElementHashCode()
int GetElementHashCode |
( |
T |
element | ) |
|
Calculate the hash code of an element.
- Parameters
-
- Returns
◆ GetElementWordCount()
int GetElementWordCount |
( |
| ) |
|
Gets the word count of an element.
- Returns
- The word count of an element.
◆ Read()
T Read |
( |
byte * |
data, |
|
|
int |
index |
|
) |
| |
Reads an element from the specified index in the byte array.
- Parameters
-
data | The byte array. |
index | The index of the element. |
- Returns
- The element at the specified index.
◆ ReadRef()
ref T ReadRef |
( |
byte * |
data, |
|
|
int |
index |
|
) |
| |
Reads a reference to an element from the specified index in the byte array.
- Parameters
-
data | The byte array. |
index | The index of the element. |
- Returns
- A reference to the element at the specified index.
◆ Write()
void Write |
( |
byte * |
data, |
|
|
int |
index, |
|
|
T |
element |
|
) |
| |
Writes an element to the specified index in the byte array.
- Parameters
-
data | The byte array. |
index | The index at which to write the element. |
element | The element to write. |