ドキュメント

Unity Engine

Unity Engine

TemplateContainer

Represents the root VisualElement of UXML file.
読み終わるまでの所要時間 6 分最終更新 1ヶ月前

Definition

[UxmlElement("Instance")]public class TemplateContainer : BindableElement, IEventHandler, IResolvedStyle, ITransform, ITransitionAnimations, IExperimentalFeatures, IVisualElementScheduler, IBindable

Remarks

A TemplateContainer instance is created by Unity to represent the root of the UXML file and acts as the parent for all elements in the file. Users typically don't create TemplateContainer objects directly. When using VisualTreeAsset.Instantiate, a TemplateContainer instance is returned to you to represent the root of the hierarchy. When using UXML templates, a TemplateContainer is generated for the template instance and inserted into the hierarchy of the parent UXML file.

Properties

Property

Description

templateIdThe local ID of the template in the parent UXML file (Read Only).
templateSourceStores the template asset reference, if the generated element is cloned from a VisualTreeAsset as a Template declaration inside another VisualTreeAsset.

Inheritance

Inherited Members