phonebookengines/VirtualPhonebook/VPbkEng/src/CVPbkTopContactManager.cpp
changeset 0 e686773b3f54
child 13 a6539d1e8e43
equal deleted inserted replaced
-1:000000000000 0:e686773b3f54
       
     1 /*
       
     2 * Copyright (c) 2005-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 "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:  Top Contact management
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 // INCLUDES
       
    20 #include <CVPbkTopContactManager.h>
       
    21 #include "CVPbkTopContactManagerImpl.h"
       
    22 
       
    23 EXPORT_C CVPbkTopContactManager* CVPbkTopContactManager::NewL(
       
    24     CVPbkContactManager& aContactManager )
       
    25     {
       
    26     CVPbkTopContactManager* self =
       
    27         new (ELeave) CVPbkTopContactManager();
       
    28     CleanupStack::PushL( self );
       
    29     self->iImpl = CVPbkTopContactManagerImpl::NewL( aContactManager ); 
       
    30     CleanupStack::Pop( self );
       
    31     return self;
       
    32     }
       
    33 
       
    34 EXPORT_C CVPbkTopContactManager* CVPbkTopContactManager::NewL()
       
    35 	{
       
    36     CVPbkTopContactManager* self =
       
    37         new (ELeave) CVPbkTopContactManager();
       
    38 	CleanupStack::PushL( self );
       
    39     self->iImpl = CVPbkTopContactManagerImpl::NewL(); 
       
    40 	CleanupStack::Pop( self );
       
    41 	return self;
       
    42 	}
       
    43 
       
    44 EXPORT_C CVPbkTopContactManager::~CVPbkTopContactManager()
       
    45     {
       
    46     delete iImpl;
       
    47     }
       
    48 
       
    49 EXPORT_C MVPbkContactOperationBase* CVPbkTopContactManager::GetTopContactsViewL(
       
    50         MVPbkOperationResultObserver<MVPbkContactViewBase*>& aObserver,
       
    51         MVPbkOperationErrorObserver& aErrorObserver )
       
    52     {
       
    53     return iImpl->GetTopContactsViewL( aObserver, aErrorObserver );
       
    54     }    
       
    55 
       
    56 EXPORT_C MVPbkContactOperationBase* CVPbkTopContactManager::GetNonTopContactsViewL(
       
    57         MVPbkOperationResultObserver<MVPbkContactViewBase*>& aObserver,
       
    58         MVPbkOperationErrorObserver& aErrorObserver )
       
    59     {
       
    60     return iImpl->GetNonTopContactsViewL( aObserver, aErrorObserver );
       
    61     }   
       
    62 
       
    63 EXPORT_C MVPbkContactOperationBase* CVPbkTopContactManager::GetTopContactLinksL(
       
    64         MVPbkOperationResultObserver<MVPbkContactLinkArray*>&  aObserver,
       
    65         MVPbkOperationErrorObserver& aErrorObserver )
       
    66     {
       
    67     return iImpl->GetTopContactLinksL( aObserver, aErrorObserver );
       
    68     }
       
    69 
       
    70 EXPORT_C MVPbkContactOperationBase* CVPbkTopContactManager::GetNonTopContactLinksL(
       
    71         MVPbkOperationResultObserver<MVPbkContactLinkArray*>&  aObserver,
       
    72         MVPbkOperationErrorObserver& aErrorObserver )
       
    73     {
       
    74     return iImpl->GetNonTopContactLinksL( aObserver, aErrorObserver );
       
    75     }
       
    76 
       
    77 EXPORT_C MVPbkContactOperationBase* CVPbkTopContactManager::AddToTopL(
       
    78 	const MVPbkContactLink& aContactLink,
       
    79 	MVPbkOperationObserver& aObserver,
       
    80 	MVPbkOperationErrorObserver& aErrorObserver )
       
    81     {
       
    82     return iImpl->AddToTopL( aContactLink, aObserver, aErrorObserver );
       
    83     }
       
    84 
       
    85 EXPORT_C MVPbkContactOperationBase* CVPbkTopContactManager::AddToTopL(
       
    86 	const MVPbkContactLinkArray& aContactLinks,
       
    87 	MVPbkOperationObserver& aObserver,
       
    88 	MVPbkOperationErrorObserver& aErrorObserver )
       
    89     {
       
    90     return iImpl->AddToTopL( aContactLinks, aObserver, aErrorObserver );
       
    91     }
       
    92 
       
    93 EXPORT_C MVPbkContactOperationBase* CVPbkTopContactManager::AddToTopL(
       
    94         const TDesC8& aPackedLinks,
       
    95         MVPbkOperationObserver& aObserver,
       
    96         MVPbkOperationErrorObserver& aErrorObserver )
       
    97     {
       
    98     return iImpl->AddToTopL( aPackedLinks, aObserver, aErrorObserver );
       
    99     }
       
   100 
       
   101 EXPORT_C MVPbkContactOperationBase* CVPbkTopContactManager::RemoveFromTopL(
       
   102 	const MVPbkContactLink& aContactLink,
       
   103 	MVPbkOperationObserver& aObserver,
       
   104 	MVPbkOperationErrorObserver& aErrorObserver )
       
   105     {
       
   106     return iImpl->RemoveFromTopL( aContactLink, aObserver, aErrorObserver );
       
   107     }
       
   108 
       
   109 EXPORT_C MVPbkContactOperationBase* CVPbkTopContactManager::RemoveFromTopL(
       
   110 	const MVPbkContactLinkArray& aContactLinkArray,
       
   111 	MVPbkOperationObserver& aObserver,
       
   112 	MVPbkOperationErrorObserver& aErrorObserver )
       
   113     {
       
   114     return iImpl->RemoveFromTopL( aContactLinkArray, aObserver, aErrorObserver );
       
   115     }
       
   116 
       
   117 EXPORT_C MVPbkContactOperationBase* CVPbkTopContactManager::RemoveFromTopL(
       
   118     const TDesC8& aPackedLinks,
       
   119     MVPbkOperationObserver& aObserver,
       
   120     MVPbkOperationErrorObserver& aErrorObserver )
       
   121     {
       
   122     return iImpl->RemoveFromTopL( aPackedLinks, aObserver, aErrorObserver );
       
   123     }
       
   124 
       
   125 EXPORT_C MVPbkContactOperationBase* CVPbkTopContactManager::SetTopOrderL(
       
   126 	const MVPbkContactLinkArray& aContactLinks,
       
   127 	MVPbkOperationObserver& aObserver,
       
   128 	MVPbkOperationErrorObserver& aErrorObserver )
       
   129 	{
       
   130     return iImpl->SetTopOrderL( aContactLinks, aObserver, aErrorObserver );
       
   131 	}
       
   132 
       
   133 EXPORT_C TBool CVPbkTopContactManager::IsTopContact(
       
   134         const MVPbkBaseContact& aContact )
       
   135     {
       
   136     return CVPbkTopContactManagerImpl::IsTopContact( aContact );
       
   137     }
       
   138 
       
   139 CVPbkTopContactManager::CVPbkTopContactManager()
       
   140     {
       
   141     }
       
   142 
       
   143 // end of file