ControlCollection

Inheritance: java.lang.Object

All Implemented Interfaces: com.aspose.slides.IControlCollection, com.aspose.slides.IDOMObject

public class ControlCollection implements IControlCollection, IDOMObject

A collection of ActiveX controls.

Methods

MethodDescription
size()Returns a number of objects in the collection.
addControl(int controlType, float x, float y, float width, float height)Creates and adds a new control to the collection.
remove(IControl item)Removes an ActiveX control from the collection.
removeAt(int index)Removes an ActiveX control stored at specified position from the collection.
clear()Removes all controls from the collection.
get_Item(int index)Returns a control at the specified position.
iterator()Returns an enumerator that iterates through the collection.
iteratorJava()Returns a java iterator for the entire collection.
copyTo(System.Array array, int index)Copies the entire collection to the specified array.
isSynchronized()Returns a value indicating whether access to the collection is synchronized (thread-safe).
getSyncRoot()Returns a synchronization root.
getParent_Immediate()

size()

public final int size()

Returns a number of objects in the collection. Read-only int.

Returns: int

addControl(int controlType, float x, float y, float width, float height)

public final IControl addControl(int controlType, float x, float y, float width, float height)

Creates and adds a new control to the collection.

Parameters:

ParameterTypeDescription
controlTypeintType of a control to add.
xfloatThe X-coordinate for a left side of shape’s frame.
yfloatThe Y-coordinate for a top side of shape’s frame.
widthfloatThe width of shape’s frame.
heightfloatThe height of shape’s frame.

Returns: IControl - Created control.

remove(IControl item)

public final void remove(IControl item)

Removes an ActiveX control from the collection.

Parameters:

ParameterTypeDescription
itemIControlA control to remove.

removeAt(int index)

public final void removeAt(int index)

Removes an ActiveX control stored at specified position from the collection.

Parameters:

ParameterTypeDescription
indexintIndex of a control to remove.

clear()

public final void clear()

Removes all controls from the collection.

get_Item(int index)

public final IControl get_Item(int index)

Returns a control at the specified position.

Parameters:

ParameterTypeDescription
indexintIndex of a control.

Returns: IControl

iterator()

public final System.Collections.Generic.IGenericEnumerator<IControl> iterator()

Returns an enumerator that iterates through the collection.

Returns: com.aspose.ms.System.Collections.Generic.IGenericEnumerator<com.aspose.slides.IControl> - A IGenericEnumerator that can be used to iterate through the collection.

iteratorJava()

public final System.Collections.Generic.IGenericEnumerator<IControl> iteratorJava()

Returns a java iterator for the entire collection.

Returns: com.aspose.ms.System.Collections.Generic.IGenericEnumerator<com.aspose.slides.IControl> - An java.util.Iterator for the entire collection.

copyTo(System.Array array, int index)

public final void copyTo(System.Array array, int index)

Copies the entire collection to the specified array.

Parameters:

ParameterTypeDescription
arraycom.aspose.ms.System.ArrayTarget array
indexintIndex in the target array.

isSynchronized()

public final boolean isSynchronized()

Returns a value indicating whether access to the collection is synchronized (thread-safe). Read-only boolean.

Returns: boolean

getSyncRoot()

public final Object getSyncRoot()

Returns a synchronization root. Read-only Object.

Returns: java.lang.Object

getParent_Immediate()

public final IDOMObject getParent_Immediate()

Returns Parent_Immediate object. Read-only IDOMObject.

Returns: com.aspose.slides.IDOMObject