LocalizedTable
class in
Unity.Localization
/
Inherits from:Unity.Localization.LocalizedReference
Suggest a change
Success!
Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.
Close
Submission failed
For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.
Close
Description
A serializable reference to an entire localization table resolved for a locale.
using Unity.Localization;
using UnityEngine;
namespace Unity.Localization.Samples
{
public class LocalizedTableResolveExample
{
public async Awaitable Resolve()
{
var reference = new LocalizedTable();
reference.TableReference = "My Strings";
ResourceTable table = await reference.GetTableAsync();
if (table != null)
Debug.Log(table.name);
}
}
}
Public Methods
| Method |
Description |
| GetTable |
Returns the table synchronously if it is already loaded.
|
| GetTableAsync |
Resolves the table asynchronously for the reference's locale.
|
Inherited Members
Properties
| Property | Description |
| isDirty |
When set to true, the binding instance updates during the next update cycle.
When set to false, the binding instance updates only if a change is detected.
|
| updateTrigger |
When set to BindingUpdateTrigger.EveryUpdate, the binding instance updates in every update, regardless of the
data source version.
|
| EnableFallback |
Whether to walk the locale fallback chain when the resolving locale has no value for this reference.
|
| HasLocaleOverride |
Whether a locale override is set on this reference.
|
| IsEmpty |
Whether this reference is unset and resolves to no value.
|
| LocaleOverride |
The locale used to resolve this reference instead of the locale selected in the project settings.
|
| TableReference |
The localization table collection that this reference resolves against.
|
Public Methods
| Method | Description |
| MarkDirty |
Notifies the binding system to process this binding.
|
| OnActivated |
Called when the binding becomes active for a specific VisualElement.
|
| OnDataSourceChanged |
Called when the resolved data source of a binding changes.
|
| OnDeactivated |
Called when the binding is no longer active for a specific VisualElement.
|
| Update |
Called when the binding system updates the binding.
|
| OnActivated |
Starts resolving the reference when it becomes active on an element.
|
| OnDeactivated |
Stops resolving the reference once it is no longer active on any element.
|
| Update |
Writes the resolved value to the bound field.
|
Protected Methods
| Method | Description |
| ForceUpdate |
Called when the reference changes so subclasses can refresh any live listeners.
|
| ResolveOverrideLocale |
Resolves the override locale from the project settings for subclasses to pass to the resource database.
|