homescreensrv_plat/sapi_homescreenplugin/tsrc/hspsconfigurationif/inc/mt_hspsliwlistprinter.h
changeset 0 79c6a41cd166
equal deleted inserted replaced
-1:000000000000 0:79c6a41cd166
       
     1 /*
       
     2 * Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  Prints liw list to a file.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef _MT_HSPSLIWLISTPRINTER_H_
       
    20 #define _MT_HSPSLIWLISTPRINTER_H_
       
    21 
       
    22 // INCLUDES
       
    23 #include <e32std.h>
       
    24 #include <e32base.h>
       
    25 #include <liwservicehandler.h>
       
    26 
       
    27 // CLASS DECLARATION
       
    28 
       
    29 /**
       
    30  *  CHspsLiwListPrinter
       
    31  */
       
    32 NONSHARABLE_CLASS( CHspsLiwListPrinter ) : public CBase
       
    33 	{
       
    34 
       
    35 // 
       
    36 // Construction
       
    37 //
       
    38 	
       
    39 public:
       
    40 	// Constructors and destructor
       
    41 
       
    42 	/**
       
    43 	 * Destructor.
       
    44 	 */
       
    45 	~CHspsLiwListPrinter();
       
    46 
       
    47 	/**
       
    48 	 * Two-phased constructor.
       
    49 	 */
       
    50 	static CHspsLiwListPrinter* NewL();
       
    51 
       
    52 	/**
       
    53 	 * Two-phased constructor.
       
    54 	 */
       
    55 	static CHspsLiwListPrinter* NewLC();
       
    56 
       
    57 private:
       
    58 	
       
    59 	/**
       
    60 	 * Constructor for performing 1st stage construction
       
    61 	 */
       
    62 	CHspsLiwListPrinter();
       
    63 
       
    64 	/**
       
    65 	 * EPOC default constructor for performing 2nd stage construction
       
    66 	 */
       
    67 	void ConstructL();
       
    68 	
       
    69 //
       
    70 // New methods
       
    71 //
       
    72 public:
       
    73 	
       
    74 	/**
       
    75 	 * Prints LiwGenericParamList to a file.
       
    76 	 * The defaultpath is c:\logs\ + additional folder defined by 
       
    77 	 * KLogFolder.
       
    78 	 * 
       
    79 	 * @param aLiwList A list to be printed.
       
    80 	 */
       
    81 	void PrintLiwListL( CLiwGenericParamList& aLiwList );
       
    82 	
       
    83 private:	
       
    84 	/**
       
    85 	 * Parses the variant type.
       
    86 	 * 
       
    87 	 * @param value Variant to be printed.
       
    88 	 */
       
    89 	void PrintVariantL( TLiwVariant value );
       
    90 	
       
    91 	/**
       
    92 	 * Prints liw map.
       
    93 	 * 
       
    94 	 *  @param value Map variant to be printed.
       
    95 	 */
       
    96 	void PrintMapL( TLiwVariant value );
       
    97 	
       
    98 	/**
       
    99 	 * Prints liw string variant.
       
   100 	 *
       
   101 	 * @param value String variant to be printed.
       
   102 	 */
       
   103 	void PrintStringL( TLiwVariant value );
       
   104 	
       
   105 	/**
       
   106 	 * Prints liw string variant. 8 bit variant.
       
   107 	 *
       
   108 	 * @param value String variant to be printed.
       
   109 	 */
       
   110 	void PrintString8L( TLiwVariant value );
       
   111 	
       
   112 	/**
       
   113 	 * Prints liw list variant.
       
   114 	 * 
       
   115 	 * @param value List variant to be printed.
       
   116 	 */
       
   117 	void PrintListL( TLiwVariant value );
       
   118 	
       
   119 	/**
       
   120 	 * Appends indentation (delimiters) to the line of text. 8 bit variant.
       
   121 	 * 
       
   122 	 * @param aText text to be printed.
       
   123 	 * @param aDepth intendation depth.
       
   124 	 * @param aDelim delimiter character or string.
       
   125 	 */
       
   126 	HBufC8* GetFixedText8LC( const TDesC8& aText, 
       
   127 							const TInt aDepth, 
       
   128 							const TDesC8& aDelim );
       
   129 	
       
   130 	/**
       
   131 	 * Appends indentation (delimiters) to the line of text.
       
   132 	 * 
       
   133 	 * @param aText text to be printed.
       
   134 	 * @param aDepth intendation depth.
       
   135 	 * @param aDelim delimiter character or string.
       
   136 	 */
       
   137 	HBufC* GetFixedTextLC( const TDesC& aText, 
       
   138 					       const TInt aDepth, 
       
   139 						   const TDesC& aDelim );
       
   140 
       
   141 //
       
   142 // Attributes
       
   143 //
       
   144 	
       
   145 private:
       
   146 	/**
       
   147 	 * Depth level of indentation.
       
   148 	 */
       
   149 	TInt iDepth;
       
   150 	};
       
   151 
       
   152 #endif // _MT_HSPSLIWLISTPRINTER_H_