public final class MasterSlideCollection extends java.lang.Object implements IMasterSlideCollection
Represents a collection of master slides.
Modifier and Type | Method and Description |
---|---|
IMasterSlide |
addClone(IMasterSlide sourceMaster)
Adds a copy of a specified master slide to the end of the collection.
|
void |
copyTo(com.aspose.ms.System.Array array,
int index)
Copies all elements from the collection to the specified array.
|
IMasterSlide |
get_Item(int index)
Gets the element at the specified index.
|
com.aspose.slides.IDOMObject |
getParent_Immediate()
Returns an enumerator for the entire collection.
|
java.lang.Object |
getSyncRoot()
Returns a synchronization root.
|
IMasterSlide |
insertClone(int index,
IMasterSlide sourceMaster)
Inserts a copy of a specified master slide to specified position of the collection.
|
boolean |
isSynchronized()
Returns a value indicating whether access to the collection is synchronized (thread-safe).
|
com.aspose.ms.System.Collections.Generic.IGenericEnumerator<IMasterSlide> |
iterator()
Returns an enumerator that iterates through the collection.
|
void |
remove(IMasterSlide value)
Removes the first occurrence of a specific object from the collection.
|
void |
removeAt(int index)
Removes the element at the specified index of the collection.
|
void |
removeUnused(boolean ignorePreserveField)
Removes unused master slides.
|
int |
size()
Gets the number of elements actually contained in the collection.
|
public final int size()
Gets the number of elements actually contained in the collection.
Read-only int
.
size
in interface com.aspose.ms.System.Collections.ICollection<IMasterSlide>
public final IMasterSlide get_Item(int index)
Gets the element at the specified index.
Read-only MasterSlide
.
get_Item
in interface IMasterSlideCollection
public final void remove(IMasterSlide value)
Removes the first occurrence of a specific object from the collection.
remove
in interface IMasterSlideCollection
value
- The master slide to remove from the collection.public final void removeAt(int index)
Removes the element at the specified index of the collection.
removeAt
in interface IMasterSlideCollection
index
- The zero-based index of the element to remove.
PptxEditException
- Thrown if the master to remove is used in presentation (its HasDependingSlides property is true).public final void removeUnused(boolean ignorePreserveField)
Removes unused master slides.
removeUnused
in interface IMasterSlideCollection
ignorePreserveField
- Determines, whether this method should remove unused master even if its MasterSlide.Preserve
(MasterSlide.getPreserve()
/MasterSlide.setPreserve(boolean)
) property is set to true.public final IMasterSlide addClone(IMasterSlide sourceMaster)
Adds a copy of a specified master slide to the end of the collection. Linked layout slides will be copied too.
addClone
in interface IMasterSlideCollection
sourceMaster
- Slide to clone.public final IMasterSlide insertClone(int index, IMasterSlide sourceMaster)
Inserts a copy of a specified master slide to specified position of the collection. Linked layout slides will be copied too.
insertClone
in interface IMasterSlideCollection
index
- Index of new slide.sourceMaster
- Slide to clone.public final void copyTo(com.aspose.ms.System.Array array, int index)
Copies all elements from the collection to the specified array.
copyTo
in interface com.aspose.ms.System.Collections.ICollection<IMasterSlide>
array
- Target array.index
- Starting index in the target array.public final boolean isSynchronized()
Returns a value indicating whether access to the collection is synchronized (thread-safe).
Read-only boolean
.
isSynchronized
in interface com.aspose.ms.System.Collections.ICollection<IMasterSlide>
public final java.lang.Object getSyncRoot()
Returns a synchronization root.
Read-only Object
.
getSyncRoot
in interface com.aspose.ms.System.Collections.ICollection<IMasterSlide>
public final com.aspose.ms.System.Collections.Generic.IGenericEnumerator<IMasterSlide> iterator()
Returns an enumerator that iterates through the collection.
iterator
in interface com.aspose.ms.System.Collections.Generic.IGenericEnumerable<IMasterSlide>
iterator
in interface com.aspose.ms.System.Collections.IEnumerable<IMasterSlide>
iterator
in interface java.lang.Iterable<IMasterSlide>
System.Collections.Generic.IEnumerator`1
that can be used to iterate through the collection.public final com.aspose.slides.IDOMObject getParent_Immediate()
Returns an enumerator for the entire collection.
IEnumerator
for the entire collection.