Ocean
|
This class implements functionalities concerning the underlying system performance. More...
Public Types | |
enum | PerformanceLevel : uint32_t { LEVEL_LOW , LEVEL_MEDIUM , LEVEL_HIGH , LEVEL_VERY_HIGH , LEVEL_ULTRA } |
Definition of different system performance levels. More... | |
Public Member Functions | |
PerformanceLevel | performanceLevel () |
Returns the current performance level. More... | |
void | setPerformanceLevel (const PerformanceLevel level) |
Sets the current performance level. More... | |
Protected Member Functions | |
Performance () | |
Creates a new Performance object. More... | |
Protected Member Functions inherited from Ocean::Singleton< Performance > | |
Singleton ()=default | |
Default constructor. More... | |
Protected Attributes | |
PerformanceLevel | performanceLevel_ = LEVEL_MEDIUM |
Current performance level. More... | |
Friends | |
class | Singleton< Performance > |
Additional Inherited Members | |
Static Public Member Functions inherited from Ocean::Singleton< Performance > | |
static Performance & | get () |
Returns a reference to the unique object. More... | |
This class implements functionalities concerning the underlying system performance.
enum Ocean::System::Performance::PerformanceLevel : uint32_t |
Definition of different system performance levels.
Enumerator | |
---|---|
LEVEL_LOW | Performance level for e.g. mobile phones. |
LEVEL_MEDIUM | Performance level for e.g. mobile computers. |
LEVEL_HIGH | Performance level for e.g. desktop computers. |
LEVEL_VERY_HIGH | Performance level for e.g. workstations. |
LEVEL_ULTRA | Performance level for e.g. high performance workstations. |
|
protected |
Creates a new Performance object.
The default medium performance depends on the number of available processor cores.
A system with one processor core has performance value 'medium' as default.
Systems with two processor cores have performance value 'high' as default.
And systems with four or more processor cores have performance value 'ultra' as default.
However the performance value can be changed at any time.
PerformanceLevel Ocean::System::Performance::performanceLevel | ( | ) |
Returns the current performance level.
void Ocean::System::Performance::setPerformanceLevel | ( | const PerformanceLevel | level | ) |
Sets the current performance level.
level | New performance level |
|
friend |
|
protected |
Current performance level.