Aspose.Tasks for C++
ResourceLeveler.h
1 #pragma once
2 //-----------------------------------------------------------------------
3 // <copyright file="ResourceLeveler.cs" company="Aspose Pty Ltd">
4 // Copyright (c) 2002-2024 Aspose Pty Ltd. All Rights Reserved.
5 // </copyright>
6 //-----------------------------------------------------------------------
7 
8 #include "aspose.tasks.cpp/aspose_tasks_api_defs.h"
9 
10 namespace Aspose
11 {
12 namespace Tasks
13 {
14 namespace Leveling
15 {
16 class LevelingOptions;
17 class LevelingResult;
18 } // namespace Leveling
19 class Project;
20 class Task;
21 } // namespace Tasks
22 } // namespace Aspose
23 namespace System
24 {
25 namespace Collections
26 {
27 namespace Generic
28 {
29 template <typename> class IEnumerable;
30 } // namespace Generic
31 } // namespace Collections
32 template <typename> class SmartPtr;
33 template <typename T0> using SharedPtr = System::SmartPtr<T0>;
34 } // namespace System
35 
36 namespace Aspose {
37 
38 namespace Tasks {
39 
40 namespace Leveling {
41 
42 /// <summary>
43 /// Contains resource leveling methods.
44 /// </summary>
45 class ASPOSE_TASKS_SHARED_CLASS ResourceLeveler
46 {
47  typedef ResourceLeveler ThisType;
48 
49 public:
50 
51  /// <summary>
52  /// Levels tasks for the specified resources using the specified leveling options.
53  /// </summary>
54  /// <param name="project">Project to apply resource leveling.</param>
55  /// <param name="options">Options which specifies how to level resources.</param>
56  /// <returns>Object containing results of resource leveling.</returns>
57  /// <exception cref="ArgumentNullException">if parameter options is null.</exception>
58  static ASPOSE_TASKS_SHARED_API System::SharedPtr<LevelingResult> LevelResources(const System::SharedPtr<Project>& project, const System::SharedPtr<LevelingOptions>& options);
59  /// <summary>
60  /// Levels tasks for all project's resources using default leveling options.
61  /// </summary>
62  /// <param name="project">Project to apply resource leveling.</param>
63  /// <returns>Object containing results of resource leveling.</returns>
64  static ASPOSE_TASKS_SHARED_API System::SharedPtr<LevelingResult> LevelAll(const System::SharedPtr<Project>& project);
65  /// <summary>
66  /// Clears any leveling delay that was previously added to the project during resource leveling.
67  /// </summary>
68  /// <param name="project">Project to clear leveling.</param>
69  static ASPOSE_TASKS_SHARED_API void ClearLeveling(const System::SharedPtr<Project>& project);
70  /// <summary>
71  /// Clears any leveling delay that was previously added to the specified tasks during resource leveling.
72  /// </summary>
73  /// <param name="tasks">The enumerable containing tasks for which leveling delay should be cleared.</param>
74  static ASPOSE_TASKS_SHARED_API void ClearLeveling(const System::SharedPtr<System::Collections::Generic::IEnumerable<System::SharedPtr<Task>>>& tasks);
75 
76 public:
77  ResourceLeveler() = delete;
78 };
79 
80 } // namespace Leveling
81 } // namespace Tasks
82 } // namespace Aspose
83 
84 
Contains resource leveling methods.
Definition: ResourceLeveler.h:46
static void ClearLeveling(const System::SharedPtr< System::Collections::Generic::IEnumerable< System::SharedPtr< Task >>> &tasks)
Clears any leveling delay that was previously added to the specified tasks during resource leveling.
static System::SharedPtr< LevelingResult > LevelAll(const System::SharedPtr< Project > &project)
Levels tasks for all project's resources using default leveling options.
static System::SharedPtr< LevelingResult > LevelResources(const System::SharedPtr< Project > &project, const System::SharedPtr< LevelingOptions > &options)
Levels tasks for the specified resources using the specified leveling options.
static void ClearLeveling(const System::SharedPtr< Project > &project)
Clears any leveling delay that was previously added to the project during resource leveling.
Definition: Asn.h:13