traceservices/commsdebugutility/INC/comsdbgmessages.h
changeset 0 08ec8eefde2f
equal deleted inserted replaced
-1:000000000000 0:08ec8eefde2f
       
     1 // Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     2 // All rights reserved.
       
     3 // This component and the accompanying materials are made available
       
     4 // under the terms of "Eclipse Public License v1.0"
       
     5 // which accompanies this distribution, and is available
       
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 // Comms debug utility (File and Serial logger) message declaration header
       
    15 // 
       
    16 //
       
    17 
       
    18 /**
       
    19  @file
       
    20  @internalTechnology
       
    21 */
       
    22  
       
    23 #ifndef __COMSDBGMESSAGES_H__
       
    24 #define __COMSDBGMESSAGES_H__
       
    25 
       
    26 
       
    27 #include <e32base.h>
       
    28 #include "comsdbgsvr.h"
       
    29 
       
    30 class MLogMessageProtocol;
       
    31 
       
    32 class CLogMessageBase : public CBase
       
    33 	{
       
    34 public:
       
    35 	void virtual Invoke(MLogMessageProtocol& aProtocol) = 0;
       
    36 	};
       
    37 
       
    38 class CLogStringMessage : public CLogMessageBase
       
    39 	{
       
    40 public:
       
    41 	virtual void Invoke(MLogMessageProtocol& aProtocol);
       
    42 	CLogStringMessage(HBufC8* aString, const TDesC8& aSubSystem, const TDesC8& aComponent, const TThreadId& aThreadId);
       
    43 	~CLogStringMessage();
       
    44 private:
       
    45 	HBufC8* iLogString;
       
    46 	TBufC8<KMaxTagLength> iSubsystem;
       
    47 	TBufC8<KMaxTagLength> iComponent;
       
    48 	TThreadId iThreadId;
       
    49 	};
       
    50 
       
    51 class CLogBinaryString : public CLogMessageBase
       
    52 	{
       
    53 public:
       
    54 	virtual void Invoke(MLogMessageProtocol& aProtocol);
       
    55 	CLogBinaryString(HBufC8* aBinaryString, const TDesC8& aSubSystem, const TDesC8& aComponent);
       
    56 	~CLogBinaryString();
       
    57 private:
       
    58 	HBufC8* iBinaryString;
       
    59 	TBuf8<KMaxTagLength> iSubsystem;
       
    60 	TBuf8<KMaxTagLength> iComponent;
       
    61 	};
       
    62 
       
    63 class CTimeUpdateMessage : public CLogMessageBase
       
    64 	{
       
    65 public:
       
    66 	CTimeUpdateMessage(const TTime& aTime);
       
    67 	virtual void Invoke(MLogMessageProtocol& aProtocol);	
       
    68 private:
       
    69 	TTime iTime;
       
    70 	};
       
    71 
       
    72 class MIniLoggingMediaQuery;
       
    73 
       
    74 class CMediaUpdateMessage : public CLogMessageBase
       
    75 	{
       
    76 public:
       
    77 	CMediaUpdateMessage(MIniLoggingMediaQuery& aQuery);
       
    78 	virtual void Invoke(MLogMessageProtocol& aProtocol);
       
    79 private:
       
    80 	TBuf8<KMaxMediaSettingLength> iLogMediaSetting;
       
    81 	TBool       iForceFlushSetting;
       
    82 	TFilePath iLogPathSetting;
       
    83 	};
       
    84 
       
    85 class CClearLogMessage : public CLogMessageBase
       
    86 	{
       
    87 public:
       
    88 	CClearLogMessage(const TFullName& aName);
       
    89 	virtual void Invoke(MLogMessageProtocol& aProtocol);
       
    90 private:
       
    91 	TFullName iThreadName;
       
    92 	};
       
    93 
       
    94 class CLogCommentMessage : public CLogMessageBase
       
    95 	{
       
    96 public:
       
    97 	static CLogCommentMessage* NewL(const TDesC8& aComment);
       
    98 	virtual void Invoke(MLogMessageProtocol& aProtocol);
       
    99 	~CLogCommentMessage();
       
   100 private:
       
   101 	CLogCommentMessage();
       
   102 private:
       
   103 	HBufC8* iComment;
       
   104 	};
       
   105 
       
   106 class CShutDownMessage : public CLogMessageBase
       
   107 	{
       
   108 public:
       
   109 	virtual void Invoke(MLogMessageProtocol& aProtocol);
       
   110 private:
       
   111 private:
       
   112 	};
       
   113 
       
   114 #endif //__COMSDBGMESSAGES_H__