epoc32/include/logwrap.h
branchSymbian3
changeset 4 837f303aceeb
parent 2 2fe1408b6811
     1.1 --- a/epoc32/include/logwrap.h	Wed Mar 31 12:27:01 2010 +0100
     1.2 +++ b/epoc32/include/logwrap.h	Wed Mar 31 12:33:34 2010 +0100
     1.3 @@ -1,9 +1,9 @@
     1.4  // Copyright (c) 2003-2009 Nokia Corporation and/or its subsidiary(-ies).
     1.5  // All rights reserved.
     1.6  // This component and the accompanying materials are made available
     1.7 -// under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
     1.8 +// under the terms of "Eclipse Public License v1.0"
     1.9  // which accompanies this distribution, and is available
    1.10 -// at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
    1.11 +// at the URL "http://www.eclipse.org/legal/epl-v10.html".
    1.12  //
    1.13  // Initial Contributors:
    1.14  // Nokia Corporation - initial contribution.
    1.15 @@ -19,131 +19,55 @@
    1.16  #include <e32base.h>
    1.17  #include <f32file.h>
    1.18  #include <barsc2.h> // For CResourceFile
    1.19 -#include <logcntdef.h>
    1.20  #include <d32dbms.h>
    1.21 +#include <logwrapconst.h>
    1.22 +
    1.23 +#ifndef SYMBIAN_ENABLE_SPLIT_HEADERS 
    1.24 +	#include <logwraplimits.h>
    1.25 +	#include "logcntdef.h"
    1.26 +#endif
    1.27  
    1.28  #ifndef __WINC__
    1.29  #include <logwrap.rsg>
    1.30  #endif
    1.31  
    1.32 +#ifdef SYMBIAN_ENABLE_SPLIT_HEADERS 
    1.33 +/** 
    1.34 +Contact item ID. These are used to uniquely identify contact items within a contacts database.
    1.35 +@publishedAll
    1.36 +@released 
    1.37 +*/
    1.38 +typedef TInt32 TLogContactItemId;
    1.39 +
    1.40 +#endif
    1.41 +
    1.42  /**
    1.43 -String lengths
    1.44 -@internalAll
    1.45 -*/
    1.46 -const TInt KLogMaxRemotePartyLength = 64;
    1.47 -const TInt KLogMaxDirectionLength = 64;
    1.48 -const TInt KLogMaxStatusLength = 64;
    1.49 -const TInt KLogMaxSubjectLength = 64;
    1.50 -const TInt KLogMaxDescriptionLength = 64;
    1.51 -const TInt KLogMaxSharedStringLength = 64;
    1.52 -const TInt KLogMaxNumberLength = 100;
    1.53 -
    1.54 -/** 
    1.55 -Big enough to contain any of the above strings
    1.56 -Defines a modifiable buffer descriptor into which a standard string from the 
    1.57 -resource in the logwrap.dll resource file can be safely put.
    1.58 -
    1.59 -@see CLogClient::GetString()
    1.60  @publishedAll
    1.61  @released
    1.62  */
    1.63 -typedef TBuf<64> TLogString;
    1.64 -
    1.65 -/** 
    1.66 -Type definitions
    1.67 -The unique event ID associated with a log event.
    1.68 -
    1.69 -@see CLogEvent
    1.70 -@see CLogViewDuplicate
    1.71 -@see CLogViewRecent
    1.72 -@see CLogClient
    1.73 -@see CLogBase 
    1.74 -@publishedAll
    1.75 -@released
    1.76 -*/
    1.77 -typedef TInt32	TLogId;
    1.78 -/** 
    1.79 -The duration type of an event.
    1.80 -
    1.81 -@see CLogEvent
    1.82 -@see CLogFilter
    1.83 -@publishedAll
    1.84 -@released
    1.85 -*/
    1.86 -typedef TInt8	TLogDurationType;
    1.87 -typedef TInt8	TLogRecentList;
    1.88 -typedef TUint16 TLogSize;
    1.89 -typedef TUint8	TLogRecentSize;
    1.90 -/** 
    1.91 -Duration of an event, expressed as the number of seconds since the time of 
    1.92 -the event.
    1.93 -
    1.94 -@see CLogEvent
    1.95 -@publishedAll
    1.96 -@released
    1.97 -*/
    1.98 -typedef TUint32	TLogDuration;
    1.99 -typedef TUint32	TLogAge;
   1.100 -/** 
   1.101 -Link value relating a log event to an entity in another application.
   1.102 -
   1.103 -@see CLogEvent
   1.104 -@publishedAll
   1.105 -@released
   1.106 -*/
   1.107 -typedef TUint32	TLogLink;
   1.108 -typedef TInt16	TLogStringId;
   1.109 -typedef TInt16	TLogTypeId;
   1.110 -/** 
   1.111 -The duration type of an event.
   1.112 -
   1.113 -@see CLogEvent
   1.114 -@see CLogFilter
   1.115 -@publishedAll
   1.116 -@released
   1.117 -*/
   1.118 -typedef TInt8	TLogDurationType;
   1.119 -/** 
   1.120 -Event flags.
   1.121 -
   1.122 -@see CLogEvent
   1.123 -@see CLogFilter
   1.124 -@publishedAll
   1.125 -@released
   1.126 -*/
   1.127 -typedef TUint8	TLogFlags;
   1.128 -
   1.129 -/**
   1.130 -@internalAll
   1.131 -*/
   1.132  typedef TUint32	TLogViewId;
   1.133  
   1.134 -/**
   1.135 -Limits
   1.136 -@internalAll
   1.137 -*/
   1.138 -const TLogId KLogNullId = -1;
   1.139 -const TLogDurationType KLogNullDurationType = -1;
   1.140 -const TLogDuration KLogNullDuration = 0;
   1.141 -const TLogLink KLogNullLink = 0;
   1.142 -const TLogRecentList KLogNullRecentList = -1;
   1.143 -const TLogStringId KLogNullStringId = -1;
   1.144 -const TLogTypeId KLogNullTypeId = -1;
   1.145 +
   1.146  const TLogFlags KLogNullFlags = 0;
   1.147  const TLogFlags KLogFlagsMask = 0xF;
   1.148 -const TInt KLogFlagsCount = 4;
   1.149 -const TInt KLogNeverUsedId = -2;
   1.150  
   1.151 +
   1.152 +#ifndef SYMBIAN_ENABLE_SPLIT_HEADERS 
   1.153  /**
   1.154  @internalAll
   1.155  */
   1.156  const TInt KLogActiveDoNotCompleteIfActive = KMaxTInt-1;
   1.157 +#endif
   1.158 +
   1.159 +//SimId typedef. Probably the final version will import it from different header. 
   1.160 +typedef TUint32 TSimId;
   1.161 +//"Null" SimId value.
   1.162 +const TSimId KLogNullSimId = 0;
   1.163  
   1.164  //**********************************
   1.165  // CLogActive
   1.166  //**********************************
   1.167  
   1.168 -class CLogActive : public CActive
   1.169  /** 
   1.170  Common active object behaviour.
   1.171  
   1.172 @@ -152,6 +76,7 @@
   1.173  @publishedAll
   1.174  @released
   1.175  */
   1.176 +class CLogActive : public CActive
   1.177  	{
   1.178  public:
   1.179  	IMPORT_C ~CLogActive();
   1.180 @@ -176,7 +101,6 @@
   1.181  // CLogEvent
   1.182  //**********************************
   1.183  
   1.184 -class CLogEvent : public CBase
   1.185  /** 
   1.186  Encapsulates the details of an event.
   1.187  
   1.188 @@ -185,6 +109,7 @@
   1.189  @publishedAll
   1.190  @released
   1.191  */
   1.192 +class CLogEvent : public CBase
   1.193  	{
   1.194  public:
   1.195  	IMPORT_C static CLogEvent* NewL();
   1.196 @@ -242,7 +167,9 @@
   1.197  
   1.198  	IMPORT_C void InternalizeL(RReadStream& aStream);
   1.199  	IMPORT_C void ExternalizeL(RWriteStream& aStream) const;
   1.200 -
   1.201 +	//
   1.202 +	IMPORT_C void SetSimId(TSimId aSimId);
   1.203 +	IMPORT_C TSimId SimId() const;
   1.204  	//
   1.205  private:
   1.206  	CLogEvent();
   1.207 @@ -265,13 +192,15 @@
   1.208  	HBufC* iSubject;
   1.209  	HBufC* iNumber;
   1.210  	HBufC8* iData;
   1.211 +#ifdef SYMBIAN_ENABLE_EVENTLOGGER_DUALSIM	
   1.212 +	TSimId	iSimId;
   1.213 +#endif	
   1.214  	};
   1.215  
   1.216  //**********************************
   1.217  // CLogBase
   1.218  //**********************************
   1.219  
   1.220 -class CLogBase : public CLogActive
   1.221  /** 
   1.222  Base class for the log engine implementation.
   1.223  
   1.224 @@ -294,6 +223,7 @@
   1.225  @publishedAll
   1.226  @released
   1.227  */
   1.228 +class CLogBase : public CLogActive
   1.229  	{
   1.230  public:
   1.231  	IMPORT_C CLogBase(TInt aPriority);
   1.232 @@ -326,7 +256,6 @@
   1.233  // CLogWrapper
   1.234  //**********************************
   1.235  
   1.236 -class CLogWrapper : public CBase
   1.237  /** 
   1.238  The log wrapper.
   1.239  
   1.240 @@ -350,6 +279,7 @@
   1.241  @publishedAll
   1.242  @released
   1.243  */
   1.244 +class CLogWrapper : public CBase
   1.245  	{
   1.246  public:
   1.247  	IMPORT_C static CLogWrapper* NewL(RFs& aFs, TInt aPriority = CActive::EPriorityStandard);