sl@0: // Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies). sl@0: // All rights reserved. sl@0: // This component and the accompanying materials are made available sl@0: // under the terms of "Eclipse Public License v1.0" sl@0: // which accompanies this distribution, and is available sl@0: // at the URL "http://www.eclipse.org/legal/epl-v10.html". sl@0: // sl@0: // Initial Contributors: sl@0: // Nokia Corporation - initial contribution. sl@0: // sl@0: // Contributors: sl@0: // sl@0: // Description: sl@0: // Implementation of the State Accessor class for CDiscoverer sl@0: // sl@0: // sl@0: sl@0: #include "DiscovererStateAccessor.h" sl@0: sl@0: // ______________________________________________________________________________ sl@0: // sl@0: void TDiscoverer_StateAccessor::Notification(TAny* aTestObject) sl@0: { sl@0: CDiscoverer* discoverer = REINTERPRET_CAST(CDiscoverer*, aTestObject); sl@0: __ASSERT_DEBUG(discoverer!=NULL, User::Invariant()); sl@0: discoverer->Notification(KErrNone); sl@0: } sl@0: sl@0: void TDiscoverer_StateAccessor::ScanDirectoryL(TAny* aTestObject) sl@0: { sl@0: CDiscoverer* discoverer = REINTERPRET_CAST(CDiscoverer*, aTestObject); sl@0: __ASSERT_DEBUG(discoverer!=NULL, User::Invariant()); sl@0: discoverer->ScanDirectoryL(); sl@0: } sl@0: sl@0: void TDiscoverer_StateAccessor::ScanDirectoryCancel(TAny* aTestObject) sl@0: { sl@0: CDiscoverer* discoverer = REINTERPRET_CAST(CDiscoverer*, aTestObject); sl@0: __ASSERT_DEBUG(discoverer!=NULL, User::Invariant()); sl@0: discoverer->ScanDirectoryCancel(); sl@0: } sl@0: sl@0: void TDiscoverer_StateAccessor::CompleteNotificationProcessing(TAny* aTestObject) sl@0: { sl@0: CDiscoverer* discoverer = REINTERPRET_CAST(CDiscoverer*, aTestObject); sl@0: __ASSERT_DEBUG(discoverer!=NULL, User::Invariant()); sl@0: discoverer->CompleteNotificationProcessing(); sl@0: } sl@0: sl@0: void TDiscoverer_StateAccessor::ValidateEntryL(TAny* aTestObject, const TEntry& anEntry, const TParse& aPath, TEntry*& anEntryToFill) sl@0: { sl@0: CDiscoverer* discoverer = REINTERPRET_CAST(CDiscoverer*, aTestObject); sl@0: __ASSERT_DEBUG(discoverer!=NULL, User::Invariant()); sl@0: discoverer->ValidateEntryL(anEntry, aPath, anEntryToFill); sl@0: } sl@0: sl@0: void TDiscoverer_StateAccessor::ProcessEntryL(TAny* aTestObject, const TEntry& anEntry) sl@0: { sl@0: CDiscoverer* discoverer = REINTERPRET_CAST(CDiscoverer*, aTestObject); sl@0: __ASSERT_DEBUG(discoverer!=NULL, User::Invariant()); sl@0: discoverer->ProcessEntryL(anEntry); sl@0: } sl@0: sl@0: void TDiscoverer_StateAccessor::DriveMountedL(TAny* aTestObject, TDriveUnit aDrive) sl@0: { sl@0: CDiscoverer* discoverer = REINTERPRET_CAST(CDiscoverer*, aTestObject); sl@0: __ASSERT_DEBUG(discoverer!=NULL, User::Invariant()); sl@0: discoverer->DriveMountedL(aDrive); sl@0: } sl@0: sl@0: void TDiscoverer_StateAccessor::DriveUnmountedL(TAny* aTestObject, TDriveUnit aDrive) sl@0: { sl@0: CDiscoverer* discoverer = REINTERPRET_CAST(CDiscoverer*, aTestObject); sl@0: __ASSERT_DEBUG(discoverer!=NULL, User::Invariant()); sl@0: discoverer->DriveUnmountedL(aDrive); sl@0: }