| Parameter | Description |
|---|---|
| cancellationToken | A token that cancels the asynchronous load. The default token never cancels. |
Awaitable<ResourceTable> An awaitable that produces the resolved table, or null when it cannot be resolved.
Resolves the table asynchronously for the reference's locale.
Loads the table through the ResourceDatabase provider chain if needed. The result is null when the
reference is empty, no resource database is configured, or the table cannot be found. When
LocalizationSettings.PreferredLoading is LoadingPreference.Synchronous and the table is
available synchronously, the table resolves without an asynchronous load.
<para>Load a table asynchronously.</para>
using Unity.Localization; using UnityEngine;
namespace Unity.Localization.Samples { public class LocalizedTableGetTableAsyncExample { public async Awaitable Load() { var localizedTable = new LocalizedTable(); localizedTable.TableReference = "My Strings"; ResourceTable table = await localizedTable.GetTableAsync(); if (table != null) Debug.Log(table.name); } } }