mmappcomponents/mmmtpdataprovider/mmmtpdprequestprocessor/src/crequestunknown.cpp
changeset 0 a2952bb97e68
child 9 bee149131e4b
equal deleted inserted replaced
-1:000000000000 0:a2952bb97e68
       
     1 /*
       
     2 * Copyright (c) 2009 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: 
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #include <mtp/tmtptyperequest.h>
       
    20 #include "crequestunknown.h"
       
    21 #include "mmmtpdplogger.h"
       
    22 
       
    23 // -----------------------------------------------------------------------------
       
    24 // CRequestUnknown::NewL
       
    25 // Two-phase construction method
       
    26 // -----------------------------------------------------------------------------
       
    27 //
       
    28 EXPORT_C MMmRequestProcessor* CRequestUnknown::NewL( MMTPDataProviderFramework& aFramework,
       
    29     MMTPConnection& aConnection )
       
    30     {
       
    31     CRequestUnknown* self = new (ELeave) CRequestUnknown( aFramework, aConnection );
       
    32     CleanupStack::PushL( self );
       
    33     self->ConstructL();
       
    34     CleanupStack::Pop( self );
       
    35     return self;
       
    36     }
       
    37 
       
    38 // -----------------------------------------------------------------------------
       
    39 // CRequestUnknown::ConstructL
       
    40 // Two-phase construction method
       
    41 // -----------------------------------------------------------------------------
       
    42 //
       
    43 void CRequestUnknown::ConstructL()
       
    44     {
       
    45     
       
    46     }
       
    47 
       
    48 // -----------------------------------------------------------------------------
       
    49 // CRequestUnknown::~CRequestUnknown
       
    50 // Destructor
       
    51 // -----------------------------------------------------------------------------
       
    52 //
       
    53 EXPORT_C CRequestUnknown::~CRequestUnknown()
       
    54     {
       
    55     
       
    56     }
       
    57 
       
    58 // -----------------------------------------------------------------------------
       
    59 // CRequestUnknown::CRequestUnknown
       
    60 // Standard c++ constructor
       
    61 // -----------------------------------------------------------------------------
       
    62 //
       
    63 EXPORT_C CRequestUnknown::CRequestUnknown( MMTPDataProviderFramework& aFramework,
       
    64     MMTPConnection& aConnection ) :
       
    65     CRequestProcessor( aFramework, aConnection, 0, NULL )
       
    66     {
       
    67     PRINT( _L( "Operation: Unknown" ) );
       
    68     }
       
    69 
       
    70 // -----------------------------------------------------------------------------
       
    71 // CRequestUnknown::ServiceL
       
    72 // penSession request handler
       
    73 // -----------------------------------------------------------------------------
       
    74 //
       
    75 EXPORT_C void CRequestUnknown::ServiceL()
       
    76     {
       
    77     SendResponseL( EMTPRespCodeOperationNotSupported );
       
    78     }
       
    79 
       
    80 // -----------------------------------------------------------------------------
       
    81 // CRequestUnknown::Match
       
    82 // Override to match both the unknown requests
       
    83 // -----------------------------------------------------------------------------
       
    84 //
       
    85 EXPORT_C TBool CRequestUnknown::Match( const TMTPTypeRequest& /*aRequest*/,
       
    86     MMTPConnection& /*aConnection*/ ) const
       
    87     {
       
    88     return ETrue;
       
    89     }
       
    90 
       
    91 // end of file