GetTable()
Returns the table synchronously if it is already loaded.
読み終わるまでの所要時間 1 分最終更新 1ヶ月前
Definition
- Type: Method
- Namespace: Unity.Localization
- Assembly: UnityEngine.LocalizationRuntimeModule
public ResourceTable GetTable()
Returns
Type | Description |
|---|---|
| ResourceTable | The resolved table, or null when it is not available synchronously. |
Remarks
Does not trigger a load. The result is null when the table is not loaded yet, the reference is empty, or no resource database is configured. Use LocalizedTable.GetTableAsync to load the table on demand instead.
Read an already-loaded table.
Examples
using Unity.Localization;using UnityEngine;namespace Unity.Localization.Samples{ public class LocalizedTableGetTableExample { public void Read() { var localizedTable = new LocalizedTable(); localizedTable.TableReference = "My Strings"; ResourceTable table = localizedTable.GetTable(); if (table != null) Debug.Log(table.name); } }}