Class RateCollection

Class RateCollection

Namespace: Aspose.Tasks
Assembly: Aspose.Tasks.dll (25.2.0)

Represents a collection which contains Aspose.Tasks.Rate objects.

public class RateCollection : IDictionary<ratetype, ratebydatecollection="">, ICollection<keyvaluepair<ratetype, ratebydatecollection="">&gt;, IEnumerable<keyvaluepair<ratetype, ratebydatecollection="">&gt;, IEnumerable

Inheritance

objectRateCollection

Implements

IDictionary<ratetype, ratebydatecollection="">, ICollection<keyvaluepair<ratetype, ratebydatecollection="">&gt;, IEnumerable<keyvaluepair<ratetype, ratebydatecollection="">&gt;, 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 the RateCollection.

public int Count { get; }

Property Value

int

IsReadOnly

Gets a value indicating whether this collection is read only.

public bool IsReadOnly { get; }

Property Value

bool

ParentResource

Gets the parent Aspose.Tasks.Resource object for this collection.

public Resource ParentResource { get; }

Property Value

Resource

this[RateType]

Returns or sets the element at the specified index.

public RateByDateCollection this[RateType key] { get; set; }

Property Value

RateByDateCollection

Methods

Add(DateTime)

Adds a new Aspose.Tasks.Rate instance to this collection.

public Rate Add(DateTime ratesFrom)

Parameters

ratesFrom DateTime

The date the new rate comes into effect.

Returns

Rate

Added Aspose.Tasks.Rate instance.

Add(DateTime, RateType)

Adds a new Aspose.Tasks.Rate instance to this collection.

public Rate Add(DateTime ratesFrom, RateType type)

Parameters

ratesFrom DateTime

The date the new rate comes into effect.

type RateType

The rate table to add into.

Returns

Rate

Added Aspose.Tasks.Rate instance.

GetEnumerator()

Returns an enumerator for this collection.

public IEnumerator GetEnumerator()

Returns

IEnumerator

an enumerator for this collection.

Remove(Rate)

Removes Rate instance from this collection.

public bool Remove(Rate item)

Parameters

item Rate

The item to remove.

Returns

bool

true if the specified Rate was removed successfully; otherwise, false.

ToList()

Converts the Aspose.Tasks.RateCollection object to a list of Aspose.Tasks.Rate objects.

public List<rate> ToList()

Returns

List<Rate&gt;

List of Aspose.Tasks.Rate objects.

ToList(RateType)

Converts the Aspose.Tasks.RateCollection object to a list of Aspose.Tasks.Rate objects filtered by specified Aspose.Tasks.RateType type.

public List<rate> ToList(RateType type)

Parameters

type RateType

The type to filter on.

Returns

List<Rate&gt;

a list of Aspose.Tasks.Rate objects. </keyvaluepair<ratetype,></keyvaluepair<ratetype,></ratetype,></keyvaluepair<ratetype,></keyvaluepair<ratetype,></ratetype,>