messagingfw/deprecate/senduiservices/src_old/TSendingCapabilities.cpp
branchRCL_3
changeset 22 d2c4c66342f3
equal deleted inserted replaced
21:e5b3a2155e1a 22:d2c4c66342f3
       
     1 /*
       
     2 * Copyright (c) 2002-2004 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:   Sending capabilities for sending services. Used by SendUi to
       
    15 *                filter sending services from "Send" pop-up list query.
       
    16 *
       
    17 */
       
    18 
       
    19 
       
    20 
       
    21 
       
    22 // INCLUDE FILES
       
    23 #include <TSendingCapabilities.h>
       
    24 
       
    25 // ============================ MEMBER FUNCTIONS ===============================
       
    26 
       
    27 // -----------------------------------------------------------------------------
       
    28 // TSendingCapabilities::TSendingCapabilities
       
    29 // C++ default constructor can NOT contain any code, that
       
    30 // might leave.
       
    31 // -----------------------------------------------------------------------------
       
    32 //
       
    33 EXPORT_C TSendingCapabilities::TSendingCapabilities()
       
    34         :
       
    35     iBodySize(0),
       
    36     iMessageSize(0),
       
    37     iFlags(0)
       
    38     {
       
    39     }
       
    40 
       
    41 // ---------------------------------------------------------
       
    42 // TSendingCapabilities::TSendingCapabilities
       
    43 // C++ default constructor can NOT contain any code, that
       
    44 // might leave.
       
    45 // ---------------------------------------------------------
       
    46 //
       
    47 EXPORT_C TSendingCapabilities::TSendingCapabilities(
       
    48     TInt aBodySize,
       
    49     TInt aMessageSize,
       
    50     TInt aFlags)
       
    51         :
       
    52     iBodySize(aBodySize),
       
    53     iMessageSize(aMessageSize),
       
    54     iFlags(aFlags)
       
    55     {
       
    56     }
       
    57 
       
    58 // ---------------------------------------------------------
       
    59 // TSendingCapabilities::TSendingCapabilities
       
    60 // Overloaded equal operator
       
    61 // might leave.
       
    62 // ---------------------------------------------------------
       
    63 //
       
    64 EXPORT_C TBool TSendingCapabilities::operator==(
       
    65     const TSendingCapabilities& aSendingCapabilities ) const
       
    66     {
       
    67     TBool ret = EFalse;
       
    68 
       
    69     if ( iBodySize == aSendingCapabilities.iBodySize &&
       
    70          iMessageSize == aSendingCapabilities.iMessageSize &&
       
    71          iFlags == aSendingCapabilities.iFlags )
       
    72         {
       
    73         ret = ETrue;
       
    74         }
       
    75 
       
    76     return ret;
       
    77     }
       
    78 
       
    79 // ---------------------------------------------------------
       
    80 // TSendingCapabilities::TSendingCapabilities
       
    81 // Overloaded not equal operator
       
    82 // might leave.
       
    83 // ---------------------------------------------------------
       
    84 //
       
    85 EXPORT_C TBool TSendingCapabilities::operator!=(
       
    86     const TSendingCapabilities& aSendingCapabilities ) const
       
    87     {
       
    88     return !( operator==( aSendingCapabilities ) );
       
    89     }
       
    90 
       
    91 //  End of File