Class ContentElementCollection
Collection of content elements.
Inheritance
System.Object
ContentElementCollection
Implements
IronSoftware.Abstractions.Word.IWordDocumentObjectCollection
IronSoftware.Abstractions.IDocumentObjectCollection<IronSoftware.Abstractions.Word.IWordDocumentObject>
System.Collections.Generic.IEnumerable<IronSoftware.Abstractions.Word.IWordDocumentObject>
System.Collections.IEnumerable
Namespace: IronWord.Models.Abstract
Assembly: IronWord.dll
Syntax
public class ContentElementCollection : Object, IWordDocumentObjectCollection, IDocumentObjectCollection<IWordDocumentObject>, IEnumerable<IWordDocumentObject>, IEnumerable
Constructors
ContentElementCollection()
Create an empty content element collection.
Declaration
public ContentElementCollection()
ContentElementCollection(IList<IWordDocumentObject>)
Add contents of a list to this collection.
Declaration
public ContentElementCollection(IList<IWordDocumentObject> collection_in)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Collections.Generic.IList<IronSoftware.Abstractions.Word.IWordDocumentObject> | collection_in |
Properties
Count
Number of objects in the collection.
Declaration
public int Count { get; }
Property Value
| Type | Description |
|---|---|
| System.Int32 |
Item[Int32]
Indexer to access content by index.
Declaration
public IWordDocumentObject this[int index] { get; }
Parameters
| Type | Name | Description |
|---|---|---|
| System.Int32 | index |
Property Value
| Type | Description |
|---|---|
| IronSoftware.Abstractions.Word.IWordDocumentObject |
Methods
First()
Get the first element of the collection.
Declaration
public IWordDocumentObject First()
Returns
| Type | Description |
|---|---|
| IronSoftware.Abstractions.Word.IWordDocumentObject |
GetEnumerator()
Get Enumerator for collection.
Declaration
public IEnumerator<IWordDocumentObject> GetEnumerator()
Returns
| Type | Description |
|---|---|
| System.Collections.Generic.IEnumerator<IronSoftware.Abstractions.Word.IWordDocumentObject> |
IndexOf(IWordDocumentObject)
Get index of specified object in collection.
Declaration
public int IndexOf(IWordDocumentObject item)
Parameters
| Type | Name | Description |
|---|---|---|
| IronSoftware.Abstractions.Word.IWordDocumentObject | item |
Returns
| Type | Description |
|---|---|
| System.Int32 |
Last()
Get the last element of the collection.
Declaration
public IWordDocumentObject Last()
Returns
| Type | Description |
|---|---|
| IronSoftware.Abstractions.Word.IWordDocumentObject |
Implements
IronSoftware.Abstractions.Word.IWordDocumentObjectCollection
IronSoftware.Abstractions.IDocumentObjectCollection<>
System.Collections.Generic.IEnumerable<>
System.Collections.IEnumerable