ncdengine/provider/protocol/src/ncd_pp_iconimpl.cpp
changeset 0 ba25891c3a9e
equal deleted inserted replaced
-1:000000000000 0:ba25891c3a9e
       
     1 /*
       
     2 * Copyright (c) 2006 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:   CNcdPreminetProtocolIcon definition
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #include "ncd_pp_iconimpl.h"
       
    20 #include "ncdprotocolutils.h"
       
    21 #include "catalogsdebug.h"
       
    22 
       
    23 CNcdPreminetProtocolIcon* CNcdPreminetProtocolIcon::NewL()
       
    24     {
       
    25     CNcdPreminetProtocolIcon* self = new (ELeave) CNcdPreminetProtocolIcon;
       
    26     CleanupStack::PushL( self );
       
    27     self->ConstructL();
       
    28     CleanupStack::Pop( self );
       
    29     return self;
       
    30     }
       
    31 
       
    32 CNcdPreminetProtocolIcon* CNcdPreminetProtocolIcon::NewLC()
       
    33     {
       
    34     CNcdPreminetProtocolIcon* self = new (ELeave) CNcdPreminetProtocolIcon;
       
    35     CleanupStack::PushL( self );
       
    36     self->ConstructL();
       
    37     return self;
       
    38     }
       
    39 
       
    40 CNcdPreminetProtocolIcon::CNcdPreminetProtocolIcon()
       
    41     {
       
    42     }
       
    43 
       
    44 void CNcdPreminetProtocolIcon::ConstructL()
       
    45     {
       
    46     NcdProtocolUtils::AssignEmptyDesL( iId );
       
    47     NcdProtocolUtils::AssignEmptyDesL( iDataBlock );
       
    48     NcdProtocolUtils::AssignEmptyDesL( iUri );
       
    49     NcdProtocolUtils::AssignEmptyDesL( iData );
       
    50     }
       
    51 
       
    52 CNcdPreminetProtocolIcon::~CNcdPreminetProtocolIcon()
       
    53     {
       
    54     delete iId;
       
    55     delete iDataBlock;
       
    56     delete iUri;
       
    57     delete iData;
       
    58     }
       
    59 
       
    60 const TDesC& CNcdPreminetProtocolIcon::Id() const
       
    61     {
       
    62     DASSERT( iId );
       
    63     return *iId;
       
    64     }
       
    65 
       
    66 const TDesC& CNcdPreminetProtocolIcon::DataBlock() const
       
    67     {
       
    68     DASSERT( iDataBlock );
       
    69     return *iDataBlock;
       
    70     }
       
    71 
       
    72 const TDesC& CNcdPreminetProtocolIcon::Uri() const
       
    73     {
       
    74     DASSERT( iUri );
       
    75     return *iUri;
       
    76     }
       
    77 
       
    78 const TDesC8& CNcdPreminetProtocolIcon::Data() const
       
    79     {
       
    80     //DASSERT( iData );
       
    81     return *iData;
       
    82     }
       
    83