Aspose.Tasks for C++
LevelingOptions.h
1 #pragma once
2 //-----------------------------------------------------------------------
3 // <copyright file="LevelingOptions.cs" company="Aspose Pty Ltd">
4 // Copyright (c) 2002-2024 Aspose Pty Ltd. All Rights Reserved.
5 // </copyright>
6 //-----------------------------------------------------------------------
7 
8 #include <system/object.h>
9 #include <system/nullable.h>
10 #include <system/date_time.h>
11 
12 #include "aspose.tasks.cpp/aspose_tasks_api_defs.h"
13 
14 namespace Aspose
15 {
16 namespace Tasks
17 {
18 class ICancellationTracker;
19 class IMessageHandler;
20 namespace Leveling
21 {
22 class LevelingAlgorithm;
23 enum class LevelingOrder;
24 } // namespace Leveling
25 enum class MessageLevel;
26 class Project;
27 class Resource;
28 } // namespace Tasks
29 } // namespace Aspose
30 namespace System
31 {
32 namespace Collections
33 {
34 namespace Generic
35 {
36 template <typename> class IList;
37 } // namespace Generic
38 } // namespace Collections
39 } // namespace System
40 
41 namespace Aspose {
42 
43 namespace Tasks {
44 
45 namespace Leveling {
46 
47 /// <summary>
48 /// Allows to specify parameters of resource leveling.
49 /// </summary>
50 class ASPOSE_TASKS_SHARED_CLASS LevelingOptions final : public System::Object
51 {
52  typedef LevelingOptions ThisType;
53  typedef System::Object BaseType;
54 
55  typedef ::System::BaseTypesInfo<BaseType> ThisTypeBaseTypesInfo;
56  ASPOSE_TASKS_SHARED_RTTI_INFO_DECL();
57 
58  friend class Aspose::Tasks::Leveling::LevelingAlgorithm;
59 
60 public:
61 
62  /// <summary>
63  /// Gets leveling period start date. The default value is the project`s start date.
64  /// </summary>
65  ASPOSE_TASKS_SHARED_API System::Nullable<System::DateTime> get_StartDate() const;
66  /// <summary>
67  /// Sets leveling period start date. The default value is the project`s start date.
68  /// </summary>
69  ASPOSE_TASKS_SHARED_API void set_StartDate(System::Nullable<System::DateTime> value);
70  /// <summary>
71  /// Gets leveling period end date. The default value is the project`s finish date.
72  /// </summary>
73  ASPOSE_TASKS_SHARED_API System::Nullable<System::DateTime> get_FinishDate() const;
74  /// <summary>
75  /// Sets leveling period end date. The default value is the project`s finish date.
76  /// </summary>
77  ASPOSE_TASKS_SHARED_API void set_FinishDate(System::Nullable<System::DateTime> value);
78  /// <summary>
79  /// Gets the list of the resources which will be leveled. If null is set, all project resources will be leveled.
80  /// </summary>
81  ASPOSE_TASKS_SHARED_API const System::SharedPtr<System::Collections::Generic::IList<System::SharedPtr<Resource>>>& get_Resources() const;
82  /// <summary>
83  /// Sets the list of the resources which will be leveled. If null is set, all project resources will be leveled.
84  /// </summary>
85  ASPOSE_TASKS_SHARED_API void set_Resources(const System::SharedPtr<System::Collections::Generic::IList<System::SharedPtr<Resource>>>& value);
86  /// <summary>
87  /// Gets the order in which the leveling algorithm delays tasks that have overallocations.
88  /// After determination of tasks causing the overallocation and which tasks can be delayed, the specified order is used which task should be delayed first.
89  /// </summary>
90  ASPOSE_TASKS_SHARED_API Aspose::Tasks::Leveling::LevelingOrder get_LevelingOrder() const;
91  /// <summary>
92  /// Gets the order in which the leveling algorithm delays tasks that have overallocations.
93  /// After determination of tasks causing the overallocation and which tasks can be delayed, the specified order is used which task should be delayed first.
94  /// </summary>
95  ASPOSE_TASKS_SHARED_API void set_LevelingOrder(Aspose::Tasks::Leveling::LevelingOrder value);
96  /// <summary>
97  /// Gets level of log messages emitted by Aspose.Tasks during resource leveling.
98  /// </summary>
99  ASPOSE_TASKS_SHARED_API Aspose::Tasks::MessageLevel get_MessageLevel() const;
100  /// <summary>
101  /// Sets level of log messages emitted by Aspose.Tasks during resource leveling.
102  /// </summary>
103  ASPOSE_TASKS_SHARED_API void set_MessageLevel(Aspose::Tasks::MessageLevel value);
104  /// <summary>
105  /// Gets message handler callback which can be used to intercept log messages produced by Aspose.Tasks during resource leveling.
106  /// </summary>
107  ASPOSE_TASKS_SHARED_API const System::SharedPtr<IMessageHandler>& get_MessageHandler() const;
108  /// <summary>
109  /// Sets message handler callback which can be used to intercept log messages produced by Aspose.Tasks during resource leveling.
110  /// </summary>
111  ASPOSE_TASKS_SHARED_API void set_MessageHandler(const System::SharedPtr<IMessageHandler>& value);
112 
113  /// <summary>
114  /// Initializes a new instance of the <see cref="LevelingOptions"></see> class.
115  /// </summary>
116  ASPOSE_TASKS_SHARED_API LevelingOptions();
117 
118 protected:
119 
120  ASPOSE_TASKS_SHARED_API System::SharedPtr<ICancellationTracker> GetCancellationTracker();
121  ASPOSE_TASKS_SHARED_API void Validate(const System::SharedPtr<Project>& project);
122  #ifdef ASPOSE_GET_SHARED_MEMBERS
123  ASPOSE_TASKS_SHARED_API void GetSharedMembers(System::Object::shared_members_type& result) const override;
124  #endif
125 
126 
127 private:
128 
129  System::Nullable<System::DateTime> pr_StartDate;
130  System::Nullable<System::DateTime> pr_FinishDate;
131  System::SharedPtr<System::Collections::Generic::IList<System::SharedPtr<Resource>>> pr_Resources;
132  Aspose::Tasks::Leveling::LevelingOrder pr_LevelingOrder;
133  Aspose::Tasks::MessageLevel pr_MessageLevel;
134  System::SharedPtr<IMessageHandler> pr_MessageHandler;
135 
136 };
137 
138 } // namespace Leveling
139 } // namespace Tasks
140 } // namespace Aspose
141 
142 
Allows to specify parameters of resource leveling.
Definition: LevelingOptions.h:51
void set_Resources(const System::SharedPtr< System::Collections::Generic::IList< System::SharedPtr< Resource >>> &value)
Sets the list of the resources which will be leveled. If null is set, all project resources will be l...
const System::SharedPtr< System::Collections::Generic::IList< System::SharedPtr< Resource > > > & get_Resources() const
Gets the list of the resources which will be leveled. If null is set, all project resources will be l...
void set_LevelingOrder(Aspose::Tasks::Leveling::LevelingOrder value)
Gets the order in which the leveling algorithm delays tasks that have overallocations....
Aspose::Tasks::Leveling::LevelingOrder get_LevelingOrder() const
Gets the order in which the leveling algorithm delays tasks that have overallocations....
void set_FinishDate(System::Nullable< System::DateTime > value)
Sets leveling period end date. The default value is the project`s finish date.
const System::SharedPtr< IMessageHandler > & get_MessageHandler() const
Gets message handler callback which can be used to intercept log messages produced by Aspose....
System::Nullable< System::DateTime > get_FinishDate() const
Gets leveling period end date. The default value is the project`s finish date.
void set_StartDate(System::Nullable< System::DateTime > value)
Sets leveling period start date. The default value is the project`s start date.
LevelingOptions()
Initializes a new instance of the LevelingOptions class.
void set_MessageLevel(Aspose::Tasks::MessageLevel value)
Sets level of log messages emitted by Aspose.Tasks during resource leveling.
void set_MessageHandler(const System::SharedPtr< IMessageHandler > &value)
Sets message handler callback which can be used to intercept log messages produced by Aspose....
Aspose::Tasks::MessageLevel get_MessageLevel() const
Gets level of log messages emitted by Aspose.Tasks during resource leveling.
System::Nullable< System::DateTime > get_StartDate() const
Gets leveling period start date. The default value is the project`s start date.
Definition: Asn.h:13