mtptransports/mtpusbtransport/usbsic_imp/inc/cmtpusbepwatcher.h
changeset 0 d0791faffa3f
equal deleted inserted replaced
-1:000000000000 0:d0791faffa3f
       
     1 // Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     2 // All rights reserved.
       
     3 // This component and the accompanying materials are made available
       
     4 // under the terms of "Eclipse Public License v1.0"
       
     5 // which accompanies this distribution, and is available
       
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 //
       
    15 
       
    16 /**
       
    17  @file
       
    18  @internalComponent
       
    19 */
       
    20 #ifndef CMTPUSBENDPOINTWATCHER_H
       
    21 #define CMTPUSBENDPOINTWATCHER_H
       
    22 
       
    23 #include "mtpdebug.h"
       
    24 
       
    25 class CMTPUsbConnection;
       
    26 
       
    27 /**
       
    28 Implements the USB MTP device class endpoint stall status observer.
       
    29 @internalComponent
       
    30  
       
    31 */
       
    32 class CMTPUsbEpWatcher: public CActive
       
    33     {
       
    34 public:
       
    35 
       
    36     static CMTPUsbEpWatcher* NewL(CMTPUsbConnection& aConnection);
       
    37     ~CMTPUsbEpWatcher();
       
    38     
       
    39     void Start();
       
    40     void Stop();
       
    41     
       
    42 private: // From CActive
       
    43 
       
    44     void DoCancel();
       
    45     TInt RunError(TInt aError);
       
    46     void RunL();
       
    47     
       
    48 private:
       
    49 
       
    50     CMTPUsbEpWatcher(CMTPUsbConnection& aConnection);
       
    51     void ConstructL();
       
    52     
       
    53     void RequestCancel();
       
    54     void RequestIssue();
       
    55       
       
    56 private: // Owned
       
    57 
       
    58     /**
       
    59     FLOGGER debug trace member variable.
       
    60     */
       
    61     __FLOG_DECLARATION_MEMBER;
       
    62 
       
    63     /**
       
    64     The endpoint stall status flags.
       
    65     */
       
    66     TUint               iEndpointStatus;
       
    67       
       
    68 private: // Not owned
       
    69 
       
    70     /**
       
    71     The MTP USB device class connection.
       
    72     */
       
    73     CMTPUsbConnection&  iConnection;
       
    74     };
       
    75     
       
    76 #endif // CMTPUSBENDPOINTWATCHER_H