Class ViewCollection
Namespace: Aspose.Tasks
Assembly: Aspose.Tasks.dll (25.2.0)
Contains a list of Aspose.Tasks.View objects. Implements ICollection<View> interface.
public class ViewCollection : ICollection<view>, IEnumerable<view>, IEnumerable
Inheritance
Implements
ICollection<view>, IEnumerable<view>, IEnumerable
Inherited Members
object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()
Properties
Count
Gets the number of elements contained in this collection.
public int Count { get; }
Property Value
IsReadOnly
Gets a value indicating whether this collection is read-only; otherwise, false.
public bool IsReadOnly { get; }
Property Value
ParentProject
Gets the parent of the View object. Read-only Aspose.Tasks.Project.
public Project ParentProject { get; }
Property Value
Methods
Add(View)
Adds the specified item to this collection.
public void Add(View item)
Parameters
item
View
the specified item to add to this collection.
Clear()
Removes all items from this collection.
public void Clear()
Contains(View)
Returns true if the specified item is found in this collection; otherwise, false.
public bool Contains(View item)
Parameters
item
View
the specified item to find.
Returns
true if the specified item is found in this collection; otherwise, false.
CopyTo(View[], int)
Copies the elements of this collection to the specified array, starting at the specified array index.
public void CopyTo(View[] array, int arrayIndex)
Parameters
array
View[]
the specified one-dimensional array to copy elements to
arrayIndex
int
the zero-based index of the specified array at which copying begins.
GetByName(string)
Searches for a View with the name, and returns the first occurrence within the collection.
public View GetByName(string viewName)
Parameters
viewName
string
Name of the View to search.
Returns
The first View in collection with the specified name, if found; otherwise, null.
GetByViewScreen(ViewScreen)
Searches for a View with the specified Screen property, and returns the first occurrence within the collection.
public View GetByViewScreen(ViewScreen screen)
Parameters
screen
ViewScreen
Aspose.Tasks.ViewScreen enumeration value.
Returns
The first View in collection which Screen property matches the specified screen argument, if found; otherwise, null.
GetEnumerator()
Returns an enumerator for this collection.
public IEnumerator<view> GetEnumerator()
Returns
IEnumerator<View>
an enumerator for this collection.
Remove(View)
Removes the first occurrence of a specific object from this collection.
public bool Remove(View item)
Parameters
item
View
the specified object to remove.
Returns
true if the specified object was successfully removed from this collection; otherwise, false.
ToList()
Converts a view collection to a list of Aspose.Tasks.View objects.
public List<view> ToList()
Returns
Generic list of Aspose.Tasks.View objects. </view></view>