First public contribution.
1 // Copyright (c) 1995-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".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
15 // WARNING: This file contains some APIs which are internal and are subject
16 // to change without notice. Such APIs should therefore not be used
17 // outside the Kernel and Hardware Services package.
26 #if !defined(__F32FILE_PRIVATE_H__)
27 #define __F32FILE_PRIVATE_H__
32 #include <e32ldr_private.h>
39 Bit mask used when evaluating whether or not a session gets notified of a
42 @see DebugNotifySessions
44 const TUint KDebugNotifyMask=0xFF000000; // Reserved for debug notification
51 The default blocksize value.
53 This value is returned when you query the blocksize for a media type that does not
54 support the concept of 'block' (e.g. NOR flash media).
56 @see TVolumeIOParamInfo
58 const TUint KDefaultVolumeBlockSize = 512;
64 Indicates that a TIpcArg slot 0 contains a descriptor.
65 This shall be ORed with the file server request aFunction.
66 Server should read from the location accordingly.
68 @note This constant is intended for use inside Kernel and Hardware Services only.
70 const TUint KIpcArgSlot0Desc = 0x00010000;
75 Indicates that a TIpcArg slot 1 contains a descriptor.
76 This shall be ORed with the file server request aFunction.
77 Server should read from the location accordingly.
79 @note This constant is intended for use inside Kernel and Hardware Services only.
81 const TUint KIpcArgSlot1Desc = 0x00020000;
86 Indicates that a TIpcArg slot 2 contains a descriptor.
87 This shall be ORed with the file server request aFunction.
88 Server should read from the location accordingly.
90 @note This constant is intended for use inside Kernel and Hardware Services only.
92 const TUint KIpcArgSlot2Desc = 0x00040000;
98 Flag to indicate that the Adopt request is from RFile::Adopt or from RFile::AdoptFromXXX functions
100 @note This constant is intended for use inside Kernel and Hardware Services only.
102 const TInt KFileAdopt32 = 0;
108 Flag to indicates that the Adopt request is from RFile::Duplicate.
110 @note This constant is intended for use inside Kernel and Hardware Services only.
112 const TInt KFileDuplicate = 1;
118 Flag to indicates that the Adopt request is from RFile64::AdoptFromXXX functions
120 @note This constant is intended for use inside Kernel and Hardware Services only.
122 const TInt KFileAdopt64 = 2;
126 enum TStartupConfigurationCmd
131 Command used to set file server configuration at startup.
133 @see RFs::SetStartupConfiguration()
137 Set loader thread priority
142 Set TDrive flags. Value should be ETrue or EFalse
146 Command upper boundary
148 EMaxStartupConfigurationCmd
153 Local drive mapping list - passed as argument to RFs::SetLocalDriveMapping().
158 class TLocalDriveMappingInfo
161 enum TDrvMapOperation {EWriteMappingsAndSet=0,EWriteMappingsNoSet=1,ESwapIntMappingAndSet=2};
163 TInt iDriveMapping[KMaxLocalDrives];
164 TDrvMapOperation iOperation;
172 @note This class is intended for use inside Kernel and Hardware Services only.
174 typedef TPckgBuf<TLocalDriveMappingInfo> TLocalDriveMappingInfoBuf;
178 Client side plugin API.
183 class RPlugin : public RSubSessionBase
186 IMPORT_C TInt Open(RFs& aFs, TInt aPos);
187 IMPORT_C void Close();
189 IMPORT_C void DoRequest(TInt aReqNo,TRequestStatus& aStatus) const;
190 IMPORT_C void DoRequest(TInt aReqNo,TRequestStatus& aStatus,TDes8& a1) const;
191 IMPORT_C void DoRequest(TInt aReqNo,TRequestStatus& aStatus,TDes8& a1,TDes8& a2) const;
192 IMPORT_C TInt DoControl(TInt aFunction) const;
193 IMPORT_C TInt DoControl(TInt aFunction,TDes8& a1) const;
194 IMPORT_C TInt DoControl(TInt aFunction,TDes8& a1,TDes8& a2) const;
195 IMPORT_C void DoCancel(TUint aReqMask) const;
202 Specifies that a plugin should determine for itself which drives it attaches to.
204 @see RFs::MountPlugin
205 @see RFs::DismountPlugin
207 const TInt KPluginAutoAttach = 0x19;
213 Specifies that a plugin should mount on drive Z.
215 @see RFs::MountPlugin
216 @see RFs::DismountPlugin
218 const TInt KPluginMountDriveZ = 0x1A;
225 Specifies that a plugin should be mounted on all drives.
227 @see RFs::MountPlugin
228 @see RFs::DismountPlugin
230 const TInt KPluginSupportAllDrives = 0x3FFFFFF; //All 26 bits (each corrosponding to a drive) are set to one.
236 Used to determine if a plugin is of version 2, meaning it can support drive Z.
239 const TInt KPluginVersionTwo = 0x4000000; //bit 27 is set to one.
245 Specifies that a plugin should determine its own position in the plugin stack.
247 @see RFs::MountPlugin
248 @see RFs::DismountPlugin
250 const TInt KPluginAutoLocate = 0xC8;
257 A set of session specific configuration flags.
259 @note This enum definition is intended for use inside Kernel and Hardware Services only.
263 Notify the user or write failures
265 EFsSessionNotifyUser = KBit0,
268 Notify clients registered for change notification
270 EFsSessionNotifyChange = KBit1,
273 Enables all session flags
275 EFsSessionFlagsAll = KSet32,
281 @note This structure is intended for use inside Kernel and Hardware Services only.
293 Validates the mask used to match drive attributes.
295 @note This function is intended for use inside Kernel and Hardware Services only.
298 @see TFindFile::SetFindMask
300 TInt ValidateMatchMask( TUint aMask);
304 Returns the entire size of the TEntry, including the valid portion of the name string.
305 The returned value is aligned to 4-byte boundary.
306 @param aPacked If ETrue, returns the length including packed iSizeHigh and iReserved.
307 If EFalse, returns the length including only the name.
309 @note This function is intended for use inside Kernel and Hardware Services only.
313 inline TInt EntrySize(const TEntry& anEntry, TBool aPacked = EFalse)
315 return(sizeof(TUint)+sizeof(TInt)+sizeof(TTime)+sizeof(TInt)+sizeof(TUidType)+Align4(anEntry.iName.Size()) + (aPacked ? (2*sizeof(TInt)) : 0));
320 #endif //__F32FILE_PRIVATE_H__