Class Container

Definition

Namespace:
Tizen.NUI
Assembly:
Tizen.NUI.dll
API Level:
4

The Container is an abstract class to be inherited from by classes that desire to have views added to them.

C#
Copy
public abstract class Container : Animatable, INotifyPropertyChanged, IDynamicResourceHandler, IElement, INameScope, IElementController, IDisposable
Inheritance
System.Object
Tizen.NUI.Binding.BindableObject
Tizen.NUI.Binding.Element
Container
Derived
Implements
System.ComponentModel.INotifyPropertyChanged
System.IDisposable

Properties

View Source

ChildCount

Gets the number of children for this container. Read only

Declaration
C#
Copy
public uint ChildCount { get; }
Property Value
Type Description
System.UInt32

The number of children.

API Level: 4
Precondition: The container has been initialized.
View Source

Children

List of children of Container.

Declaration
C#
Copy
public List<View> Children { get; }
Property Value
Type Description
System.Collections.Generic.List<View>
API Level: 4
View Source

Parent

Gets the parent container. Read only

Declaration
C#
Copy
public Container Parent { get; }
Property Value
Type Description
Container

The parent container.

API Level: 4
Precondition: The child container has been initialized.

Methods

View Source

Add(View)

Adds a child view to this Container.

Declaration
C#
Copy
public abstract void Add(View view)
Parameters
Type Name Description
View view

The child view to add.

Remarks

If the child already has a parent, it will be removed from the old parent and reparented to this view. This may change child's position, color, scale, etc. as it now inherits them from this view.

API Level: 4
Precondition: This Container (the parent) has been initialized. The child view has been initialized. The child view is not the same as the parent view.
Postcondition: The child will be referenced by its parent. This means that the child will be kept alive, even if the handle passed into this method is reset or destroyed.
View Source

Dispose(DisposeTypes)

Dispose.

Declaration
C#
Copy
protected override void Dispose(DisposeTypes type)
Parameters
Type Name Description
DisposeTypes type
Overrides
API Level: 4
View Source

GetChildAt(UInt32)

Retrieves the child view by the index.

Declaration
C#
Copy
public abstract View GetChildAt(uint index)
Parameters
Type Name Description
System.UInt32 index

The index of the child to retrieve.

Returns
Type Description
View

The view for the given index or empty handle if children are not initialized.

API Level: 4
Precondition: The view has been initialized.
View Source

GetChildCount()

Gets the number of children for this container.

Declaration
C#
Copy
public abstract uint GetChildCount()
Returns
Type Description
System.UInt32

The number of children.

API Level: 4
Precondition: The container has been initialized.
View Source

GetParent()

Gets the parent of this container.

Declaration
C#
Copy
public abstract Container GetParent()
Returns
Type Description
Container

The parent container.

API Level: 4
Precondition: The child container has been initialized.
View Source

Remove(View)

Removes a child view from this view. If the view was not a child of this view, this is a no-op.

Declaration
C#
Copy
public abstract void Remove(View view)
Parameters
Type Name Description
View view

The view to remove

API Level: 4
Precondition: This View(the parent) has been initialized. The child view is not the same as the parent view.

Implements

System.ComponentModel.INotifyPropertyChanged
System.IDisposable