telephonyserver/etelsimtoolkit/dtsy/Dsatlog.h
changeset 0 3553901f7fa8
equal deleted inserted replaced
-1:000000000000 0:3553901f7fa8
       
     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 // Dummy SAT TSY logger
       
    15 // 
       
    16 //
       
    17 
       
    18 /**
       
    19  @file
       
    20  @internalComponent
       
    21 */
       
    22 
       
    23 #define __LOGGER__
       
    24 
       
    25 #ifdef __LOGGER__
       
    26 #define LOGTEXT(AAA)	CDTSYLogger::Write(AAA)
       
    27 #else
       
    28 #define LOGTEXT(AAA)
       
    29 #endif
       
    30 
       
    31 #ifdef __LOGGER__
       
    32 #define LOGTEXT2(AAA,BBB)	CDTSYLogger::WriteFormat(TRefByValue<const TDesC8>(AAA),BBB)
       
    33 #else
       
    34 #define LOGTEXT2(AAA,BBB)
       
    35 #endif
       
    36 
       
    37 #ifdef __LOGGER__
       
    38 #define LOGTEXT3(AAA,BBB,CCC)	CDTSYLogger::WriteFormat(TRefByValue<const TDesC8>(AAA),BBB,CCC)
       
    39 #else
       
    40 #define LOGTEXT3(AAA,BBB,CCC)
       
    41 #endif
       
    42 
       
    43 #define LOGTEXTREL(AAA)
       
    44 #define LOGTEXTREL2(AAA,BBB)
       
    45 #define LOGTEXTREL3(AAA,BBB,CCC)
       
    46 
       
    47 
       
    48 #ifdef __LOGGER__
       
    49 #define LOGDESTROY()	CDTSYLogger::Destruct()
       
    50 #else
       
    51 #define LOGDESTROY()
       
    52 #endif
       
    53 
       
    54 
       
    55 #ifndef __SLOGGER_H
       
    56 #define __SLOGGER_H
       
    57 
       
    58 #ifdef __LOGGER__
       
    59 #include <f32file.h>
       
    60 
       
    61 class CDTSYLogger : public CBase
       
    62 	{
       
    63 public:
       
    64 	static CDTSYLogger* NewL();
       
    65 	CDTSYLogger();
       
    66 	void ConstructL();
       
    67 	static void Destruct();
       
    68 	~CDTSYLogger();
       
    69 	static void Write(const TDesC8& aText);
       
    70 	static void WriteFormat(TRefByValue<const TDesC8> aFmt,...);
       
    71 	void WriteRecord(const TDesC8& aText);
       
    72 private:
       
    73 	TBool iValid;
       
    74 	RFs iFs;
       
    75 	RFile iFile;
       
    76 	};
       
    77 
       
    78 #endif	// __LOGGER__
       
    79 
       
    80 #endif	// __SLOGGER_H