GM6000 Digital Heater Controller Branch: main
SDX-1330
Private_.h
Go to the documentation of this file.
1#ifndef Cpl_System_Private_x_h__
2#define Cpl_System_Private_x_h__
3/*-----------------------------------------------------------------------------
4* This file is part of the Colony.Core Project. The Colony.Core Project is an
5* open source project with a BSD type of licensing agreement. See the license
6* agreement (license.txt) in the top/ directory or on the Internet at
7* http://integerfox.com/colony.core/license.txt
8*
9* Copyright (c) 2014-2022 John T. Taylor
10*
11* Redistributions of the source code must retain the above copyright notice.
12*----------------------------------------------------------------------------*/
13/** @file
14
15 This file contains a collection of classes, interfaces, etc. that are
16 are intended to be USE ONLY by Colony.Core sub-system - NOT by clients,
17 consumers of the Colony.Core package.
18*/
19
20#include "Cpl/Text/String.h"
21#include "Cpl/System/Mutex.h"
22#include "Cpl/System/Trace.h"
23#include "Cpl/System/PrivateStartup_.h" // Include hered to maintain backwards compatibility with older projects
24
25
26///
27namespace Cpl {
28///
29namespace System {
30
31
32/** This class provide access to Colony.Core's internal global mutexes.
33 */
34class Locks_
35{
36public:
37 /// Global mutex for use for interfaces/class in the Cpl::System namespace
38 static Mutex& system( void );
39
40 /// Same as 'system', except usage is for 'long' critical sections (i.e. walking lists, printing, etc.)
41 static Mutex& sysLists( void );
42
43 /** Global mutex for use for tracing sub-system. This mutex is to protect
44 the Trace engine's internal/meta data. This mutex is NOT used to guard
45 the Trace output. The Trace engine uses two mutex so that its output
46 can be 'serialized' with the TShell's output (or other sub-systems) BUT
47 not cause high priority threads to block on the trace output when their
48 trace statements are not enabled at run time.
49 */
50 static Mutex& tracing( void );
51
52 /// Global mutex for use for the tracing sub-system OUTPUT (see above for more details)
53 static Mutex& tracingOutput( void );
54};
55
56
57
58
59/** This class defines the interface to the platform specific implementation of the
60 Cpl::System::Trace interface
61 */
63{
64public:
65 /** This method append the 'info' information to the provide String for the
66 specified infoLevel.
67 */
68 static void appendInfo( Cpl::Text::String& dst, Trace::InfoLevel_T info, const char* section, const char* filename, int linenum, const char* funcname );
69
70 /** This method output the string to the logging destination/stream/media
71 */
72 static void output( Cpl::Text::String& src );
73};
74
75
76
77}; // end namespaces
78};
79#endif // end header latch
80
This file contains a collection of classes, interfaces, etc.
This class provide access to Colony.Core's internal global mutexes.
Definition Private_.h:35
static Mutex & system(void)
Global mutex for use for interfaces/class in the Cpl::System namespace.
static Mutex & tracingOutput(void)
Global mutex for use for the tracing sub-system OUTPUT (see above for more details)
static Mutex & sysLists(void)
Same as 'system', except usage is for 'long' critical sections (i.e. walking lists,...
static Mutex & tracing(void)
Global mutex for use for tracing sub-system.
This mutex class defines the interface for a mutex that has "recursive" semantics.
Definition Mutex.h:33
InfoLevel_T
This enum is used to globally control the amount of 'Prologue' information that is prepended to the T...
Definition Trace.h:119
This class defines the interface to the platform specific implementation of the Cpl::System::Trace in...
Definition Private_.h:63
static void appendInfo(Cpl::Text::String &dst, Trace::InfoLevel_T info, const char *section, const char *filename, int linenum, const char *funcname)
This method append the 'info' information to the provide String for the specified infoLevel.
static void output(Cpl::Text::String &src)
This method output the string to the logging destination/stream/media.
This abstract class defines the operations that can be before on a NULL terminated string.
Definition String.h:40
The 'Cpl' namespace is the root name space for the Colony.
Definition Api16.h:20