os/kernelhwsrv/kerneltest/f32test/smassstorage/src/t_cusbmassstoragescheduler.cpp
author sl@SLION-WIN7.fritz.box
Fri, 15 Jun 2012 03:10:57 +0200
changeset 0 bde4ae8d615e
permissions -rw-r--r--
First public contribution.
     1 // Copyright (c) 2004-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 the License "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 #include "cusbmassstoragescheduler.h"
    17 #include "cusbmassstorageserver.h"
    18 
    19 /**
    20  @file
    21  @internalTechnology
    22  
    23  Creates a new Active scheduler
    24  */
    25 CUsbMassStorageScheduler* CUsbMassStorageScheduler::NewL()
    26 	{
    27 	return new(ELeave) CUsbMassStorageScheduler;
    28 	}
    29 
    30 /**
    31  Destructor
    32  
    33  @internalTechnology
    34  */
    35 CUsbMassStorageScheduler::~CUsbMassStorageScheduler()
    36 	{
    37     // Nothing to do
    38 	}
    39 
    40 /**
    41  Give us a reference to the server
    42  
    43  @internalTechnology
    44  @param	aServer	A reference to the server
    45  */
    46 void CUsbMassStorageScheduler::SetServer(CUsbMassStorageServer& aServer)
    47 	{
    48 	iMsServer = &aServer;	
    49 	}
    50 
    51 /**
    52  Inform the server that an error has occurred
    53  
    54  @internalTechnology
    55  @param	aError	Error that has occurred
    56  */
    57 void CUsbMassStorageScheduler::Error(TInt aError) const
    58 	{
    59 	__PRINT1(_L("CUsbMassStorageScheduler::Error aError=%d"), aError);
    60 
    61 	if (iMsServer)
    62 		{
    63 		iMsServer->Error(aError);
    64 		}
    65 	}
    66