Method Copy
Copy(byte*, out int, int, char*, int)
Copies a buffer of UCS-2 text. The copy is encoded as UTF-8.
Declaration
public static CopyError Copy(byte* dest, out int destLength, int destUTF8MaxLengthInBytes, char* src, int srcLength)
Parameters
Type | Name | Description |
---|---|---|
byte* | dest | The destination buffer for writing UTF-8. |
int | destLength | Outputs the number of bytes written to the destination. |
int | destUTF8MaxLengthInBytes | The max number of bytes that will be written to the destination buffer. |
char* | src | The source buffer for reading UCS-2. |
int | srcLength | The number of chars to read from the source. |
Returns
Type | Description |
---|---|
Copy |
None if the copy fully completes. Otherwise, returns Truncation. |
Remarks
Assumes the source data is valid UCS-2.
Copy(byte*, out ushort, ushort, char*, int)
Copies a buffer of UCS-2 text. The copy is encoded as UTF-8.
Declaration
public static CopyError Copy(byte* dest, out ushort destLength, ushort destUTF8MaxLengthInBytes, char* src, int srcLength)
Parameters
Type | Name | Description |
---|---|---|
byte* | dest | The destination buffer for writing UTF-8. |
ushort | destLength | Outputs the number of bytes written to the destination. |
ushort | destUTF8MaxLengthInBytes | The max number of bytes that will be written to the destination buffer. |
char* | src | The source buffer for reading UCS-2. |
int | srcLength | The number of chars to read from the source. |
Returns
Type | Description |
---|---|
Copy |
None if the copy fully completes. Otherwise, returns Truncation. |
Remarks
Assumes the source data is valid UCS-2.
Copy(byte*, out int, int, byte*, int)
Copies a buffer of UCS-8 text.
Declaration
public static CopyError Copy(byte* dest, out int destLength, int destUTF8MaxLengthInBytes, byte* src, int srcLength)
Parameters
Type | Name | Description |
---|---|---|
byte* | dest | The destination buffer. |
int | destLength | Outputs the number of bytes written to the destination. |
int | destUTF8MaxLengthInBytes | The max number of bytes that will be written to the destination buffer. |
byte* | src | The source buffer. |
int | srcLength | The number of chars to read from the source. |
Returns
Type | Description |
---|---|
Copy |
None if the copy fully completes. Otherwise, returns Truncation. |
Remarks
Assumes the source data is valid UTF-8.
Copy(byte*, out ushort, ushort, byte*, ushort)
Copies a buffer of UCS-8 text.
Declaration
public static CopyError Copy(byte* dest, out ushort destLength, ushort destUTF8MaxLengthInBytes, byte* src, ushort srcLength)
Parameters
Type | Name | Description |
---|---|---|
byte* | dest | The destination buffer. |
ushort | destLength | Outputs the number of bytes written to the destination. |
ushort | destUTF8MaxLengthInBytes | The max number of bytes that will be written to the destination buffer. |
byte* | src | The source buffer. |
ushort | srcLength | The number of chars to read from the source. |
Returns
Type | Description |
---|---|
Copy |
None if the copy fully completes. Otherwise, returns Truncation. |
Remarks
Assumes the source data is valid UTF-8.
Copy(char*, out int, int, byte*, int)
Copies a buffer of UTF-8 text. The copy is encoded as UCS-2.
Declaration
public static CopyError Copy(char* dest, out int destLength, int destUCS2MaxLengthInChars, byte* src, int srcLength)
Parameters
Type | Name | Description |
---|---|---|
char* | dest | The destination buffer for writing UCS-2. |
int | destLength | Outputs the number of chars written to the destination. |
int | destUCS2MaxLengthInChars | The max number of chars that will be written to the destination buffer. |
byte* | src | The source buffer for reading UTF-8. |
int | srcLength | The number of bytes to read from the source. |
Returns
Type | Description |
---|---|
Copy |
None if the copy fully completes. Otherwise, returns Truncation. |
Remarks
Assumes the source data is valid UTF-8.
Copy(char*, out ushort, ushort, byte*, ushort)
Copies a buffer of UTF-8 text. The copy is encoded as UCS-2.
Declaration
public static CopyError Copy(char* dest, out ushort destLength, ushort destUCS2MaxLengthInChars, byte* src, ushort srcLength)
Parameters
Type | Name | Description |
---|---|---|
char* | dest | The destination buffer for writing UCS-2. |
ushort | destLength | Outputs the number of chars written to the destination. |
ushort | destUCS2MaxLengthInChars | The max number of chars that will be written to the destination buffer. |
byte* | src | The source buffer for reading UTF-8. |
ushort | srcLength | The number of bytes to read from the source. |
Returns
Type | Description |
---|---|
Copy |
None if the copy fully completes. Otherwise, returns Truncation. |
Remarks
Assumes the source data is valid UTF-8.