Class BurstStringWrapper
Helper functions for Burst compatible string operations.
Inherited Members
Namespace: Unity.Logging
Syntax
public static class BurstStringWrapper
Methods
AppendString(ref UnsafeText, String)
Appends string into UnsafeText. In Burst context Unity.Logging.BurstStringWrapper.AppendString__Unmanaged(Unity.Collections.LowLevel.Unsafe.UnsafeText@,System.Byte*,System.Int32) 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 Unity.Logging.BurstStringWrapper.AppendString__Unmanaged(Unity.Collections.LowLevel.Unsafe.UnsafeText@,System.Byte*,System.Int32) will be called instead
Declaration
public static bool IsEmpty(string fieldName)
Parameters
Type | Name | Description |
---|---|---|
String | fieldName |
Returns
Type | Description |
---|---|
Boolean | True if string is null or empty |
IsEmpty__Unmanaged(Byte*, Int32)
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 |
Int32 | utf8Len | UTF8 string length |
Returns
Type | Description |
---|---|
Boolean | True if string is null or empty |