Code Examples.
Code Examples.
{
}
if( NULL ==
{
}
if( NULL ==
{
}
{
}
"this is the api reference guide code example");
{
}
ClCharT buffer[0xfff] = {0};
ClUint32T length = 0xfff;
length, buffer);
"This is api reference guide ASCII logging");
{
}
0, NULL, 0, NULL };
filter);
{
}
{
}
ClUint32T ClRcT
Clovis return code type.
Definition: clCommon.h:168
#define CL_OK
Every thing is OK.
Definition: clCommonErrors.h:68
#define CL_HANDLE_INVALID_VALUE
Defines.
Definition: clHandleApi.h:95
ClPtrT clHeapCalloc(CL_IN ClUint32T numChunks, CL_IN ClUint32T chunkSize)
Allocates memory for an array and initializes it to zero.
#define CL_LOG_STREAM_CREATE
This flag specifies the log service that the particular stream should be created, if it does not exis...
Definition: clLogApi.h:181
#define CL_LOG_MSGID_BUFFER
Logging messgae in binary format.
Definition: clLogApi.h:568
ClRcT clLogFinalize(CL_IN ClLogHandleT hLog)
Finalize the Log service for the calling process and ensures to release all the resources.
ClRcT clLogFilterSet(CL_IN ClLogStreamHandleT hStream, CL_IN ClLogFilterFlagsT filterFlags, CL_IN ClLogFilterT filter)
Changes the filter settings of a Log Stream.
#define CL_LOG_TLV_UINT32(var)
TLV for unsigned 32 bit varible(ClUint32T).
Definition: clLogApi.h:626
ClLogSeverityT
Definition: clLogApi.h:252
ClHandleT ClLogHandleT
The type of handle supplied by Log Service during initialization.
Definition: clLogApi.h:57
ClRcT clLogStreamOpen(CL_IN ClLogHandleT hLog, CL_IN ClNameT streamName, CL_IN ClLogStreamScopeT streamScope, CL_IN ClLogStreamAttributesT *pStreamAttr, CL_IN ClLogStreamOpenFlagsT streamOpenFlags, CL_IN ClTimeT timeout, CL_OUT ClLogStreamHandleT *phStream)
Opens the stream for Logging.
#define CL_LOG_TAG_TERMINATE
This tag is used for terminating the TLV type.
Definition: clLogApi.h:578
ClRcT clLogInitialize(CL_OUT ClLogHandleT *phLog, CL_IN const ClLogCallbacksT *pLogCallbacks, CL_INOUT ClVersionT *pVersion)
Initializes the Log service for the calling process and ensures the version compatability.
#define CL_LOG_MSGID_PRINTF_FMT
Logging message in ASCII format.
Definition: clLogApi.h:573
ClHandleT ClLogStreamHandleT
The type of handle supplied by Log Service during log streamOpen and a process register itself as str...
Definition: clLogApi.h:63
ClRcT clLogStreamClose(CL_IN ClLogStreamHandleT hStream)
Close the stream opened for logging.
ClRcT clLogWriteAsync(ClLogStreamHandleT hStream, ClLogSeverityT severity, ClUint16T serviceId, ClUint16T msgId,...)
Logs a Log Record in the specified Log Stream.
#define CL_LOG_FILTER_ASSIGN
Discard the old filter settings and use new settings provided.
Definition: clLogApi.h:357
#define CL_LOG_TLV_UINT8(var)
TLV for unsigned byte variable(ClUint8T).
Definition: clLogApi.h:602
@ CL_LOG_SEV_ALERT
setting severity as ALERT.
Definition: clLogApi.h:260
@ CL_LOG_STREAM_GLOBAL
Flags specifies the streams global to the node.
Definition: clLogApi.h:91
@ CL_LOG_FILE_FULL_ACTION_ROTATE
It directs the Log Service to create a new Log File Unit when the current Log File Unit becomes full.
Definition: clLogApi.h:111
Version Information for various services.
Definition: clCommon.h:250
This structure describes the attributes of the stream.
Definition: clLogApi.h:127
ClUint32T flushFreq
Num of log records after which the log stream records must be flushed.
Definition: clLogApi.h:160
ClTimeT flushInterval
Time after which the log stream records must be flushed.
Definition: clLogApi.h:164
ClBoolT haProperty
Log file replication property.
Definition: clLogApi.h:147
ClUint32T fileUnitSize
Size of the file unit.
Definition: clLogApi.h:139
ClLogFileFullActionT fileFullAction
Action that log service has to take, when the log file unit becomes full.
Definition: clLogApi.h:151
ClUint32T recordSize
Size of the log record.
Definition: clLogApi.h:143
ClCharT * fileLocation
Its the path where the log file unit(s) will be created.
Definition: clLogApi.h:135
ClWaterMarkT waterMark
The water mark for file units.When the size of file reaches this level, the water mark event will be ...
Definition: clLogApi.h:169
ClCharT * fileName
Its the prefix name of file units that are going to be created.
Definition: clLogApi.h:131
ClUint32T maxFilesRotated
If fileAction is CL_LOG_FILE_FULL_ACTION_ROTATE, the maximum num of log file units that will be creat...
Definition: clLogApi.h:156
This structure describes the filter settings for the stream.
Definition: clLogApi.h:379
This structure describes about the callbacks which can be provided by process while initializing with...
Definition: clLogApi.h:543