8 #include <system/collections/list.h>
9 #include <system/collections/ilist.h>
10 #include <system/array.h>
13 #include "aspose.tasks.cpp/aspose_tasks_api_defs.h"
14 #include "aspose.tasks.cpp/AvailabilityPeriod.h"
20 namespace Calculations
22 class ResourceOverAllocationCalculator;
28 class MppAvailabilityWriter;
32 class ResourceNodeReader;
44 template <
typename>
class IEnumerator;
60 typedef System::Collections::Generic::IList<System::SharedPtr<AvailabilityPeriod>> BaseType;
62 typedef ::System::BaseTypesInfo<BaseType> ThisTypeBaseTypesInfo;
63 ASPOSE_TASKS_SHARED_RTTI_INFO_DECL();
65 friend class Aspose::Tasks::IO::MSProject::MppAvailabilityWriter;
66 friend class Aspose::Tasks::IO::Xml::ResourceNodeReader;
68 friend class Aspose::Tasks::Calculations::ResourceOverAllocationCalculator;
74 using iterator =
typename iterator_holder_type::iterator;
92 ASPOSE_TASKS_SHARED_API int32_t
get_Count()
const override;
103 ASPOSE_TASKS_SHARED_API System::SharedPtr<AvailabilityPeriod>
idx_get(int32_t index)
const override;
109 ASPOSE_TASKS_SHARED_API
void idx_set(int32_t index, System::SharedPtr<AvailabilityPeriod> value)
override;
115 ASPOSE_TASKS_SHARED_API System::SharedPtr<System::Collections::Generic::IEnumerator<System::SharedPtr<AvailabilityPeriod>>>
GetEnumerator()
override;
120 ASPOSE_TASKS_SHARED_API
void Add(
const System::SharedPtr<AvailabilityPeriod>& item)
override;
124 ASPOSE_TASKS_SHARED_API
void Clear()
override;
130 ASPOSE_TASKS_SHARED_API
bool Contains(
const System::SharedPtr<AvailabilityPeriod>& item)
const override;
136 ASPOSE_TASKS_SHARED_API
void CopyTo(System::ArrayPtr<System::SharedPtr<AvailabilityPeriod>> array, int32_t arrayIndex)
override;
142 ASPOSE_TASKS_SHARED_API
bool Remove(
const System::SharedPtr<AvailabilityPeriod>& item)
override;
148 ASPOSE_TASKS_SHARED_API int32_t
IndexOf(
const System::SharedPtr<AvailabilityPeriod>& item)
const override;
154 ASPOSE_TASKS_SHARED_API
void Insert(int32_t index,
const System::SharedPtr<AvailabilityPeriod>& item)
override;
159 ASPOSE_TASKS_SHARED_API
void RemoveAt(int32_t index)
override;
207 ASPOSE_TASKS_SHARED_API MEMBER_FUNCTION_MAKE_OBJECT_DECLARATION(
AvailabilityPeriodCollection, CODEPORTING_ARGS(const System::SharedPtr<
Resource>& parentRsc, const System::SharedPtr<System::Collections::Generic::List<System::SharedPtr<
AvailabilityPeriod>>>& periods));
209 ASPOSE_TASKS_SHARED_API
double GetMinAvailability(System::DateTime intervalStart, System::DateTime intervalEnd);
210 ASPOSE_TASKS_SHARED_API
void Sort();
214 #ifdef ASPOSE_GET_SHARED_MEMBERS
215 ASPOSE_TASKS_SHARED_API
void GetSharedMembers(System::Object::shared_members_type& result)
const override;
221 System::SharedPtr<System::Collections::Generic::List<System::SharedPtr<AvailabilityPeriod>>> periods;
222 System::WeakPtr<Resource> resource;
224 static int32_t Compare(
const System::SharedPtr<AvailabilityPeriod>& period1,
const System::SharedPtr<AvailabilityPeriod>& period2);
Represents a collection which contains AvailabilityPeriod objects.
Definition: AvailabilityPeriodCollection.h:58
typename iterator_holder_type::const_iterator const_iterator
Const iterator type.
Definition: AvailabilityPeriodCollection.h:76
void Add(const System::SharedPtr< AvailabilityPeriod > &item) override
Adds the specified item to this collection.
void RemoveAt(int32_t index) override
Removes an item at the specified index.
void Clear() override
Removes all items from this collection.
iterator begin() noexcept
System::Collections::Generic::List< System::SharedPtr< AvailabilityPeriod > > iterator_holder_type
A collection type whose iterator types is used as iterator types in the current collection.
Definition: AvailabilityPeriodCollection.h:72
bool Contains(const System::SharedPtr< AvailabilityPeriod > &item) const override
Returns true if the specified item is found in this collection; otherwise, false.
int32_t IndexOf(const System::SharedPtr< AvailabilityPeriod > &item) const override
Determines the index of the specified item in this collection.
System::SharedPtr< System::Collections::Generic::IEnumerator< System::SharedPtr< AvailabilityPeriod > > > GetEnumerator() override
Returns an enumerator for this collection.
bool get_IsReadOnly() const override
Gets a value indicating whether this collection is read-only; otherwise, false.
void CopyTo(System::ArrayPtr< System::SharedPtr< AvailabilityPeriod >> array, int32_t arrayIndex) override
Copies the elements of this collection to the specified array, starting at the specified array index.
void Insert(int32_t index, const System::SharedPtr< AvailabilityPeriod > &item) override
Inserts the specified item at the specified index.
int32_t get_Count() const override
Gets the number of elements contained in this collection.
typename iterator_holder_type::virtualized_iterator_element virtualized_iterator_element
Virtualized element type.
Definition: AvailabilityPeriodCollection.h:78
typename iterator_holder_type::iterator iterator
Iterator type.
Definition: AvailabilityPeriodCollection.h:74
System::SharedPtr< AvailabilityPeriod > idx_get(int32_t index) const override
Returns the element at the specified index.
void idx_set(int32_t index, System::SharedPtr< AvailabilityPeriod > value) override
Sets the element at the specified index.
bool Remove(const System::SharedPtr< AvailabilityPeriod > &item) override
Removes the first occurrence of a specific object from this collection.
typename iterator_holder_type::virtualized_iterator virtualized_iterator
Virtualized type.
Definition: AvailabilityPeriodCollection.h:80
System::SharedPtr< Resource > get_ParentResource() const
Gets the parent Resource for this object. Parent Resource object for this collection.
Represents a period when a resource is available.
Definition: AvailabilityPeriod.h:39
Represents a resource in a project.
Definition: Resource.h:213
/27/10/2004 by Roman Korchagin
Definition: Asn.h:13