javaextensions/pim/framework/src.s60/cpimintvalue.cpp
author Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
Tue, 11 May 2010 16:07:20 +0300
branchRCL_3
changeset 24 0fd27995241b
parent 19 04becd199f91
permissions -rw-r--r--
Revision: v2.1.24 Kit: 201019

/*
* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies).
* All rights reserved.
* This component and the accompanying materials are made available
* under the terms of "Eclipse Public License v1.0"
* which accompanies this distribution, and is available
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
*
* Initial Contributors:
* Nokia Corporation - initial contribution.
*
* Contributors:
*
* Description:  Specialized integer value class
 *
*/


// CLASS HEADER
#include "cpimintvalue.h"
#include "logger.h"

// ======== MEMBER FUNCTIONS ========

// ---------------------------------------------------------------------------
// CPIMIntValue::NewL
// Default two-phase constructor
// ---------------------------------------------------------------------------
//
CPIMIntValue* CPIMIntValue::NewL(TPIMAttribute aAttributes, TInt aIntegerValue)
{
    JELOG2(EPim);
    CPIMIntValue* self = new(ELeave) CPIMIntValue(aAttributes, aIntegerValue);

    CleanupStack::PushL(self);
    self->ConstructL();
    CleanupStack::Pop(self);

    return self;
}

// ---------------------------------------------------------------------------
// CPIMIntValue::NewLC
// Default two-phase constructor. The newly created object is left to the
// cleanup stack
// ---------------------------------------------------------------------------
//
CPIMIntValue* CPIMIntValue::NewLC(TPIMAttribute aAttributes, TInt aIntegerValue)
{
    JELOG2(EPim);
    CPIMIntValue* self = CPIMIntValue::NewL(aAttributes, aIntegerValue);
    CleanupStack::PushL(self);
    return self;
}

// ---------------------------------------------------------------------------
// Destructor
// ---------------------------------------------------------------------------
//
CPIMIntValue::~CPIMIntValue()
{
    JELOG2(EPim);
}

// ---------------------------------------------------------------------------
// CPIMIntValue::SetValue
// (other items were commented in a header)
// ---------------------------------------------------------------------------
//
void CPIMIntValue::SetIntValue(TInt aIntegerValue)
{
    JELOG2(EPim);
    iIntegerValue = aIntegerValue;
}

// ---------------------------------------------------------------------------
// CPIMIntValue::Value
// (other items were commented in a header)
// ---------------------------------------------------------------------------
//
TInt CPIMIntValue::IntValue() const
{
    JELOG2(EPim);
    return iIntegerValue;
}

// ---------------------------------------------------------------------------
// CPIMIntValue::CPIMIntValue
// Default C++ constructor
// ---------------------------------------------------------------------------
//
CPIMIntValue::CPIMIntValue(TPIMAttribute aAttributes, TInt aIntegerValue) :
        CPIMValueBase(aAttributes), iIntegerValue(aIntegerValue)
{
    JELOG2(EPim);
}

// ---------------------------------------------------------------------------
// CPIMIntValue::ConstructL
// Second phase constructor
// ---------------------------------------------------------------------------
//
void CPIMIntValue::ConstructL()
{
    JELOG2(EPim);
}

// End of file