sapi_applicationmanager/appmanagerservice/src/appmanagercommon.cpp
changeset 0 14df0fbfcc4e
equal deleted inserted replaced
-1:000000000000 0:14df0fbfcc4e
       
     1 /*
       
     2 * Copyright (c) 2007-2007 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 the License "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:  It contains the defination filter param class
       
    15 *
       
    16 *
       
    17 */
       
    18 
       
    19 
       
    20 #include "appmanagercommon.h"
       
    21 
       
    22 // -----------------------------------------------------------------------------
       
    23 // MInfoMap::~MInfoMap
       
    24 // Destructor
       
    25 // -----------------------------------------------------------------------------
       
    26 MInfoMap::~MInfoMap(){}
       
    27 
       
    28 // -----------------------------------------------------------------------------
       
    29 // MInfoMap::~MInfoMap
       
    30 // Destructor
       
    31 // -----------------------------------------------------------------------------
       
    32 MIterator::~MIterator(){}
       
    33 
       
    34 
       
    35 // -----------------------------------------------------------------------------
       
    36 // CFilterParam::NewL
       
    37 // Returns the instance of CFilterParam.
       
    38 // -----------------------------------------------------------------------------
       
    39 EXPORT_C  CFilterParam* CFilterParam::NewL()
       
    40 	{
       
    41 	CFilterParam* self = new(ELeave)CFilterParam();
       
    42 	return self;
       
    43 	}
       
    44 
       
    45 
       
    46 // -----------------------------------------------------------------------------
       
    47 // CFilterParam::CFilterParam
       
    48 // C++ Constructor
       
    49 // -----------------------------------------------------------------------------
       
    50 CFilterParam::CFilterParam():iDocumentName(NULL),iMimeType(NULL)
       
    51 	{
       
    52 	}
       
    53 
       
    54 // -----------------------------------------------------------------------------
       
    55 // CFilterParam::~CFilterParam
       
    56 // Destructor
       
    57 // -----------------------------------------------------------------------------
       
    58 CFilterParam::~CFilterParam()
       
    59 	{
       
    60 		delete iMimeType;
       
    61 		delete iDocumentName;
       
    62 	}
       
    63 
       
    64 // -----------------------------------------------------------------------------
       
    65 // CFilterParam::SetDocName
       
    66 // Sets the document name.
       
    67 // -----------------------------------------------------------------------------
       
    68 EXPORT_C void  CFilterParam::SetDocName(const TDesC& aDocName)
       
    69 	{
       
    70 	 iDocumentName = aDocName.Alloc(); 
       
    71 
       
    72 	}
       
    73 
       
    74 
       
    75 // -----------------------------------------------------------------------------
       
    76 // CFilterParam::DocName
       
    77 // Gives the document name.
       
    78 // -----------------------------------------------------------------------------
       
    79 EXPORT_C TPtrC  CFilterParam::DocName() const
       
    80 	{
       
    81 	 if(iDocumentName)
       
    82 	 	return TPtrC(*iDocumentName);
       
    83 	 else
       
    84 	 	return TPtrC();
       
    85 
       
    86 	}
       
    87 
       
    88 
       
    89 // -----------------------------------------------------------------------------
       
    90 // CFilterParam::SetmimeType
       
    91 // Sets the mimetype.
       
    92 // -----------------------------------------------------------------------------
       
    93 EXPORT_C void  CFilterParam::SetmimeType(const TDesC8& aMimeType)
       
    94 	{
       
    95 	 iMimeType = aMimeType.Alloc(); 
       
    96 
       
    97 	}
       
    98 
       
    99 // -----------------------------------------------------------------------------
       
   100 // CFilterParam::MimeType
       
   101 // Gives the mimetype.
       
   102 // -----------------------------------------------------------------------------
       
   103 EXPORT_C TPtrC8  CFilterParam::MimeType() const
       
   104 	{
       
   105 	 if(iMimeType)
       
   106 	 	return TPtrC8(*iMimeType);
       
   107 	 else
       
   108 	 	return TPtrC8();
       
   109 
       
   110 	}