Class BurstStringWrapper
Helper functions for Burst compatible string operations.
Inherited Members
Namespace: Unity.Logging
Assembly: Unity.Logging.dll
Syntax
public static class BurstStringWrapper
Methods
AppendString(ref UnsafeText, string)
Appends string into UnsafeText. In Burst context AppendString__Unmanaged(ref UnsafeText, byte*, int) will be called instead
Declaration
public static FormatError AppendString(ref UnsafeText output, string str)
Parameters
Type | Name | Description |
---|---|---|
UnsafeText | output | UnsafeText append to |
string | str | String that should be appended |
Returns
Type | Description |
---|---|
FormatError | FormatError from Append operation |
IsEmpty(string)
Checks if the string is empty. In Burst context AppendString__Unmanaged(ref UnsafeText, byte*, int) will be called instead
Declaration
public static bool IsEmpty(string fieldName)
Parameters
Type | Name | Description |
---|---|---|
string | fieldName |
Returns
Type | Description |
---|---|
bool | True if string is null or empty |
IsEmpty__Unmanaged(byte*, int)
Do not call directly! Use IsEmpty(string) - burst will call this automatically if can
Declaration
[RequiredMember]
public static bool IsEmpty__Unmanaged(byte* utf8Bytes, int utf8Len)
Parameters
Type | Name | Description |
---|---|---|
byte* | utf8Bytes | UTF8 string pointer |
int | utf8Len | UTF8 string length |
Returns
Type | Description |
---|---|
bool | True if string is null or empty |