loggingservices/filelogger/INC/FLOGGER.INL
changeset 0 08ec8eefde2f
child 9 667e88a979d7
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 //
       
    15 
       
    16 /**
       
    17  @file
       
    18  @internalTechnology
       
    19 */
       
    20 
       
    21 #ifndef __FLOGGER_INL__
       
    22 #define __FLOGGER_INL__
       
    23 
       
    24 #include <flogger.h>
       
    25 
       
    26 /**
       
    27 TSignal inline functions
       
    28 */
       
    29 
       
    30 inline FLogger::TSignal::TSignal(TRequestStatus& aStatus)
       
    31 	:iStatus(&aStatus),iId(RThread().Id())
       
    32 /**
       
    33 Sets aStatus with the value KRequestPending.
       
    34 
       
    35 */
       
    36 	{
       
    37 	aStatus=KRequestPending;
       
    38 	}
       
    39 
       
    40 inline TPtrC FLogger::TSignal::Command() const
       
    41 /**
       
    42 */
       
    43 	{
       
    44 	return TPtrC((const TText*)this,sizeof(*this)/sizeof(TText));
       
    45 	}
       
    46 
       
    47 inline TInt FLogger::TSignal::Set(const TDesC& aCommand)
       
    48 /**
       
    49 Sets aCommand with "this" pointer value.
       
    50 
       
    51 @return KErrNone, if successful.
       
    52 */
       
    53 	{
       
    54 	if (aCommand.Size()!=sizeof(*this))
       
    55 		return KErrGeneral;
       
    56 	
       
    57 	return (Mem::Copy(this,aCommand.Ptr(),sizeof(*this)),KErrNone);
       
    58 	}
       
    59 
       
    60 /**
       
    61 TLogFile inline functions
       
    62 */
       
    63 
       
    64 inline TBool TLogFile::Valid() const
       
    65 /**
       
    66 @return EFalse for invalid file name.
       
    67 */
       
    68 	{
       
    69 	return iValid;
       
    70 	}
       
    71 
       
    72 inline TFileName TLogFile::Directory() const
       
    73 /**
       
    74 @return iDirectory the full path of the folder.
       
    75 */
       
    76 	{
       
    77 	return iDirectory;
       
    78 	}
       
    79 	
       
    80 inline TFileName TLogFile::Name() const
       
    81 /**
       
    82 @return iName the file name of the log.
       
    83 */
       
    84 	{
       
    85 	return iName;
       
    86 	}
       
    87 
       
    88 inline TFileLoggingMode TLogFile::Mode() const
       
    89 /**
       
    90 @return iMode the mode of the log file.
       
    91 */
       
    92 	{
       
    93 	return iMode;
       
    94 	}	
       
    95 
       
    96 inline void TLogFile::SetValid(TBool aValid)
       
    97 /**
       
    98 Sets iValid with the value aValid.
       
    99 */
       
   100 	{
       
   101 	iValid=aValid;
       
   102 	}
       
   103 
       
   104 #endif // __FLOGGER_INL__
       
   105