wmdrm/camese/wmdrmdla/src/wmdrmdlaplugincontainer.cpp
changeset 0 95b198f216e5
equal deleted inserted replaced
-1:000000000000 0:95b198f216e5
       
     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:  Implementation class for WMDRM DLA plugin container
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #include <wmdrmdlahttpplugin.h>
       
    20 #include <wmdrmdlauinotifier.h>
       
    21 #include "wmdrmdlaplugincontainer.h"
       
    22 
       
    23 #define _LOGGING_FILE L"wmdrmdla.txt"
       
    24 #include "logfn.h"
       
    25 
       
    26 // ======== LOCAL FUNCTIONS ========
       
    27 
       
    28 // ======== MEMBER FUNCTIONS ========
       
    29 
       
    30 // ---------------------------------------------------------------------------
       
    31 // CWmDrmDlaPluginContainer::ConstructL
       
    32 // ---------------------------------------------------------------------------
       
    33 //
       
    34 void CWmDrmDlaPluginContainer::ConstructL()
       
    35     {
       
    36     }
       
    37 
       
    38 // ---------------------------------------------------------------------------
       
    39 // CWmDrmDlaPluginContainer::CWmDrmDlaPluginContainer
       
    40 // ---------------------------------------------------------------------------
       
    41 //
       
    42 CWmDrmDlaPluginContainer::CWmDrmDlaPluginContainer()
       
    43     {
       
    44     }
       
    45 
       
    46 // ---------------------------------------------------------------------------
       
    47 // CWmDrmDlaPluginContainer::NewL
       
    48 // ---------------------------------------------------------------------------
       
    49 //
       
    50 CWmDrmDlaPluginContainer* CWmDrmDlaPluginContainer::NewL()
       
    51     {
       
    52     LOGFN( "CWmDrmDlaPluginContainer::NewL" );
       
    53     CWmDrmDlaPluginContainer* self = CWmDrmDlaPluginContainer::NewLC();
       
    54     CleanupStack::Pop( self );
       
    55     return self;
       
    56     }
       
    57 
       
    58 
       
    59 // ---------------------------------------------------------------------------
       
    60 // CWmDrmDlaPluginContainer::NewLC
       
    61 // ---------------------------------------------------------------------------
       
    62 //
       
    63 CWmDrmDlaPluginContainer* CWmDrmDlaPluginContainer::NewLC()
       
    64     {
       
    65     LOGFN( "CWmDrmDlaPluginContainer::NewLC" );
       
    66     CWmDrmDlaPluginContainer* self = new( ELeave ) CWmDrmDlaPluginContainer;
       
    67     CleanupStack::PushL( self );
       
    68     self->ConstructL();
       
    69     return self;
       
    70     }
       
    71 
       
    72 
       
    73 // ---------------------------------------------------------------------------
       
    74 // CWmDrmDlaPluginContainer::~CWmDrmDlaPluginContainer
       
    75 // ---------------------------------------------------------------------------
       
    76 //
       
    77 CWmDrmDlaPluginContainer::~CWmDrmDlaPluginContainer()
       
    78     {
       
    79     LOGFN( "CWmDrmDlaPluginContainer::~CWmDrmDlaPluginContainer" );
       
    80     delete iHttpPlugin;
       
    81     delete iUiNotifier;
       
    82     }
       
    83 
       
    84 // ---------------------------------------------------------------------------
       
    85 // CWmDrmDlaPluginContainer::SetHttpPlugin
       
    86 // ---------------------------------------------------------------------------
       
    87 //
       
    88 void CWmDrmDlaPluginContainer::SetHttpPlugin( 
       
    89     CWmDrmDlaHttpPluginIf* aHttpPlugin )
       
    90     {
       
    91     LOGFN( "CWmDrmDlaPluginContainer::SetHttpPlugin" );
       
    92     iHttpPlugin = aHttpPlugin;
       
    93     }
       
    94 
       
    95 // ---------------------------------------------------------------------------
       
    96 // CWmDrmDlaPluginContainer::GetHttpPlugin
       
    97 // ---------------------------------------------------------------------------
       
    98 //
       
    99 void CWmDrmDlaPluginContainer::GetHttpPlugin(
       
   100     CWmDrmDlaHttpPluginIf*& aHttpPlugin )
       
   101     {
       
   102     LOGFN( "CWmDrmDlaPluginContainer::GetHttpPlugin" );
       
   103     aHttpPlugin = iHttpPlugin;
       
   104     iHttpPlugin = NULL;
       
   105     }
       
   106 
       
   107 // ---------------------------------------------------------------------------
       
   108 // CWmDrmDlaPluginContainer::HttpPlugin
       
   109 // ---------------------------------------------------------------------------
       
   110 //
       
   111 CWmDrmDlaHttpPluginIf* CWmDrmDlaPluginContainer::HttpPlugin()
       
   112     {
       
   113     LOGFN( "CWmDrmDlaPluginContainer::HttpPlugin" );
       
   114     return iHttpPlugin;
       
   115     }
       
   116 
       
   117 // ---------------------------------------------------------------------------
       
   118 // CWmDrmDlaPluginContainer::SetUiNotifier
       
   119 // ---------------------------------------------------------------------------
       
   120 //
       
   121 void CWmDrmDlaPluginContainer::SetUiNotifier( 
       
   122     CWmDrmDlaUiNotifier* aUiNotifier )
       
   123     {
       
   124     LOGFN( "CWmDrmDlaPluginContainer::SetUiNotifier" );
       
   125     iUiNotifier = aUiNotifier;
       
   126     }
       
   127 
       
   128 // ---------------------------------------------------------------------------
       
   129 // CWmDrmDlaPluginContainer::UiNotifier
       
   130 // ---------------------------------------------------------------------------
       
   131 //
       
   132 void CWmDrmDlaPluginContainer::GetUiNotifier(
       
   133     CWmDrmDlaUiNotifier*& aUiNotifier )
       
   134     {
       
   135     LOGFN( "CWmDrmDlaPluginContainer::GetUiNotifier" );
       
   136     aUiNotifier = iUiNotifier;
       
   137     iUiNotifier = NULL;
       
   138     }
       
   139     
       
   140 // ---------------------------------------------------------------------------
       
   141 // CWmDrmDlaPluginContainer::SetIndex
       
   142 // ---------------------------------------------------------------------------
       
   143 //
       
   144 void CWmDrmDlaPluginContainer::SetIndex( TInt aIndex )
       
   145     {
       
   146     LOGFN( "CWmDrmDlaPluginContainer::SetIndex" );
       
   147     iIndex = aIndex;
       
   148     LOG2( "iIndex: %d", iIndex );
       
   149     }
       
   150 
       
   151 // ---------------------------------------------------------------------------
       
   152 // CWmDrmDlaPluginContainer::Index
       
   153 // ---------------------------------------------------------------------------
       
   154 //
       
   155 TInt CWmDrmDlaPluginContainer::Index()
       
   156     {
       
   157     LOGFN( "CWmDrmDlaPluginContainer::Index" );
       
   158     LOG2( "iIndex: %d", iIndex );
       
   159     return iIndex;
       
   160     }