userlibandfileserver/fileserver/sfat/inc/sl_std.inl
changeset 15 4122176ea935
parent 0 a41df078684a
equal deleted inserted replaced
0:a41df078684a 15:4122176ea935
    13 // Description:
    13 // Description:
    14 // f32\sfat\inc\sl_std.inl
    14 // f32\sfat\inc\sl_std.inl
    15 // 
    15 // 
    16 //
    16 //
    17 
    17 
       
    18 //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
       
    19 //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
       
    20 //!!
       
    21 //!! WARNING!! DO NOT edit this file !! '\sfat' component is obsolete and is not being used. '\sfat32'replaces it
       
    22 //!!
       
    23 //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
       
    24 //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
       
    25 
    18 #ifndef SL_STD_INL
    26 #ifndef SL_STD_INL
    19 #define SL_STD_INL
    27 #define SL_STD_INL
    20 
    28 
    21 
    29 
    22 
    30 
    23 TBool IsPowerOf2(TUint32 aVal)
    31 TBool IsPowerOf2(TUint32 aVal)
    24     {
    32     {
    25 	if (aVal==0)
    33     if (aVal==0)
    26 		return EFalse;
    34         return EFalse;
    27 
    35 
    28     return !(aVal & (aVal-1));
    36     return !(aVal & (aVal-1));
    29     }
    37     }
    30 
    38 
    31 TUint32 Pow2(TUint32 aVal)
    39 TUint32 Pow2(TUint32 aVal)
    66 inline TUint32 CFatMountCB::RootClusterNum() const
    74 inline TUint32 CFatMountCB::RootClusterNum() const
    67     {return iVolParam.RootClusterNum(); }        
    75     {return iVolParam.RootClusterNum(); }        
    68 
    76 
    69 
    77 
    70 inline TInt CFatMountCB::StartCluster(const TFatDirEntry & anEntry) const
    78 inline TInt CFatMountCB::StartCluster(const TFatDirEntry & anEntry) const
    71 	{return anEntry.StartCluster();}
    79     {return anEntry.StartCluster();}
    72 
    80 
    73 
    81 
    74 
    82 
    75 /**
    83 /**
    76 returns true for root dir on Fat12/16 (fixed root dir versions of Fat). 
    84 returns true for root dir on Fat12/16 (fixed root dir versions of Fat). 
    78 
    86 
    79 @param aEntry position on volume being queried
    87 @param aEntry position on volume being queried
    80 @return Whether Root dir position or not
    88 @return Whether Root dir position or not
    81 */
    89 */
    82 TBool CFatMountCB::IsRootDir(const TEntryPos &aEntry) const
    90 TBool CFatMountCB::IsRootDir(const TEntryPos &aEntry) const
    83 	{return((aEntry.iCluster==0) ? (TBool)ETrue : (TBool)EFalse);}
    91     {return((aEntry.iCluster==0) ? (TBool)ETrue : (TBool)EFalse);}
    84 
    92 
    85 /**
    93 /**
    86 Indicates the root directory cluster, For Fat12/16 root is always indicated by cluster number zero
    94 Indicates the root directory cluster, For Fat12/16 root is always indicated by cluster number zero
    87 @return The root cluster indicator
    95 @return The root cluster indicator
    88 */
    96 */
    89 TInt CFatMountCB::RootIndicator() const
    97 TInt CFatMountCB::RootIndicator() const
    90 	{return 0;}
    98     {return 0;}
    91 
    99 
    92    
   100    
    93 TBool CFatMountCB::Is16BitFat() const
   101 TBool CFatMountCB::Is16BitFat() const
    94 	{return(iFatType == EFat16);}
   102     {return(iFatType == EFat16);}
    95 
   103 
    96 /** @return Log2 of cluster size on volume */
   104 /** @return Log2 of cluster size on volume */
    97 TInt CFatMountCB::ClusterSizeLog2() const
   105 TInt CFatMountCB::ClusterSizeLog2() const
    98     {return(iVolParam.ClusterSizeLog2());}
   106     {return(iVolParam.ClusterSizeLog2());}
    99 
   107 
   105 TInt CFatMountCB::SectorsPerCluster() const
   113 TInt CFatMountCB::SectorsPerCluster() const
   106     {return(1<<(iVolParam.ClusterSizeLog2()-iVolParam.SectorSizeLog2()));}
   114     {return(1<<(iVolParam.ClusterSizeLog2()-iVolParam.SectorSizeLog2()));}
   107 
   115 
   108 /** @return the base position of a cluster */
   116 /** @return the base position of a cluster */
   109 TInt CFatMountCB::ClusterBasePosition() const
   117 TInt CFatMountCB::ClusterBasePosition() const
   110 	{return(iFirstFreeByte);}
   118     {return(iFirstFreeByte);}
   111 
   119 
   112 /** @return the offset into a cluster of a byte address */
   120 /** @return the offset into a cluster of a byte address */
   113 TInt CFatMountCB::ClusterRelativePos(TInt aPos) const
   121 TInt CFatMountCB::ClusterRelativePos(TInt aPos) const
   114 	{return(aPos&((1<<ClusterSizeLog2())-1));}
   122     {return(aPos&((1<<ClusterSizeLog2())-1));}
   115 
   123 
   116 /**
   124 /**
   117 Calculates the maximum number of clusters
   125 Calculates the maximum number of clusters
   118 @return  maximum number of clusters
   126 @return  maximum number of clusters
   119 */
   127 */
   132 TUint32 CFatMountCB::FirstFatSector() const
   140 TUint32 CFatMountCB::FirstFatSector() const
   133     {return iVolParam.FirstFatSector();}
   141     {return iVolParam.FirstFatSector();}
   134 
   142 
   135 /** @return the byte offset of the Fat */
   143 /** @return the byte offset of the Fat */
   136 TInt CFatMountCB::StartOfFatInBytes() const
   144 TInt CFatMountCB::StartOfFatInBytes() const
   137 	{return(FirstFatSector()<<SectorSizeLog2());}
   145     {return(FirstFatSector()<<SectorSizeLog2());}
   138 
   146 
   139 /** @return Number of Fats used by the volume */
   147 /** @return Number of Fats used by the volume */
   140 TInt CFatMountCB::NumberOfFats() const
   148 TInt CFatMountCB::NumberOfFats() const
   141     {return iVolParam.NumberOfFats();}
   149     {return iVolParam.NumberOfFats();}
   142 
   150 
   143 
   151 
   144 /** @return refrence to the fat table owned by the mount */
   152 /** @return refrence to the fat table owned by the mount */
   145 CFatTable& CFatMountCB::FAT() const
   153 CFatTable& CFatMountCB::FAT() const
   146 	{return(*iFatTable);}
   154     {return(*iFatTable);}
   147 /**
   155 /**
   148 Returns a refrence to the file system object owned by the coresponding TDrive for a drive used for creating subsession objects
   156 Returns a refrence to the file system object owned by the coresponding TDrive for a drive used for creating subsession objects
   149 @return refrence to file system object
   157 @return refrence to file system object
   150 */
   158 */
   151 CFatFileSystem& CFatMountCB::FatFileSystem() const
   159 CFatFileSystem& CFatMountCB::FatFileSystem() const
   152 	{return((CFatFileSystem&)Drive().FSys());}
   160     {return((CFatFileSystem&)Drive().FSys());}
   153 
   161 
   154 
   162 
   155 /** @return  refrence to a raw disk object owned by the mount */
   163 /** @return  refrence to a raw disk object owned by the mount */
   156 CRawDisk& CFatMountCB::RawDisk() const
   164 CRawDisk& CFatMountCB::RawDisk() const
   157 	{return(*iRawDisk);}
   165     {return(*iRawDisk);}
   158 
   166 
   159 /**
   167 /**
   160 @return ETrue if aCluster value is bad cluster marker defined in FAT specification
   168 @return ETrue if aCluster value is bad cluster marker defined in FAT specification
   161 */
   169 */
   162 TBool CFatMountCB::IsBadCluster(TInt aCluster) const
   170 TBool CFatMountCB::IsBadCluster(TInt aCluster) const
   163 	{return Is16BitFat() ? aCluster==0xFFF7 : aCluster==0xFF7;}
   171     {return Is16BitFat() ? aCluster==0xFFF7 : aCluster==0xFF7;}
   164 
   172 
   165 /**
   173 /**
   166 Returns whether the current mount is running as rugged Fat or not, this is held in the file system object
   174 Returns whether the current mount is running as rugged Fat or not, this is held in the file system object
   167 @return Is rugged fat flag
   175 @return Is rugged fat flag
   168 */
   176 */
   169 TBool CFatMountCB::IsRuggedFSys() const
   177 TBool CFatMountCB::IsRuggedFSys() const
   170 	{return Drive().IsRugged();}
   178     {return Drive().IsRugged();}
   171 
   179 
   172 /**
   180 /**
   173 Sets the rugged flag in the file system object
   181 Sets the rugged flag in the file system object
   174 @param Flag to set or clear the rugged flag
   182 @param Flag to set or clear the rugged flag
   175 */
   183 */
   176 void CFatMountCB::SetRuggedFSys(TBool aVal)
   184 void CFatMountCB::SetRuggedFSys(TBool aVal)
   177 	{Drive().SetRugged(aVal);}
   185     {Drive().SetRugged(aVal);}
   178 
   186 
   179 /** @return the usable clusters count for a volume */
   187 /** @return the usable clusters count for a volume */
   180 TUint32 CFatMountCB::UsableClusters() const
   188 TUint32 CFatMountCB::UsableClusters() const
   181 	{return(iUsableClusters);}
   189     {return(iUsableClusters);}
   182 
   190 
   183 
   191 
   184 TUint CFatMountCB::StartOfRootDirInBytes() const
   192 TUint CFatMountCB::StartOfRootDirInBytes() const
   185     {return iVolParam.RootDirectorySector()<<SectorSizeLog2();}
   193     {return iVolParam.RootDirectorySector()<<SectorSizeLog2();}
   186 
   194 
   190 {
   198 {
   191     return iFatType;
   199     return iFatType;
   192 }
   200 }
   193 
   201 
   194 CAsyncNotifier* CFatMountCB::Notifier() const
   202 CAsyncNotifier* CFatMountCB::Notifier() const
   195 	{return iNotifier;}	
   203     {return iNotifier;} 
   196 
   204 
   197 
   205 
   198 /**
   206 /**
   199     Set or reset Read Only mode for the mount.
   207     Set or reset Read Only mode for the mount.
   200     @param    aReadOnlyMode if ETrue, the mount will be set RO.
   208     @param    aReadOnlyMode if ETrue, the mount will be set RO.
   207     
   215     
   208 /**
   216 /**
   209     @return ETrue if the volume is in Read-Only state
   217     @return ETrue if the volume is in Read-Only state
   210 */
   218 */
   211 TBool CFatMountCB::ReadOnly(void) const
   219 TBool CFatMountCB::ReadOnly(void) const
   212 	{
   220     {
   213     return iReadOnly;
   221     return iReadOnly;
   214 	}
   222     }
   215 
   223 
   216 /** @return state of the CFatMountCB*/
   224 /** @return state of the CFatMountCB*/
   217 CFatMountCB::TFatMntState CFatMountCB::State() const 
   225 CFatMountCB::TFatMntState CFatMountCB::State() const 
   218     {
   226     {
   219     return iState;
   227     return iState;
   243 //---------------------------------------------------------------------------------------------------------------------------------
   251 //---------------------------------------------------------------------------------------------------------------------------------
   244 /** 
   252 /** 
   245 Check if the XFileCreationHelper object is initialised.
   253 Check if the XFileCreationHelper object is initialised.
   246 */
   254 */
   247 TBool CFatMountCB::XFileCreationHelper::IsInitialised() const 
   255 TBool CFatMountCB::XFileCreationHelper::IsInitialised() const 
   248 	{
   256     {
   249 	return isInitialised;
   257     return isInitialised;
   250 	}
   258     }
   251 
   259 
   252 /** 
   260 /** 
   253 Get number of new entries for file creation.
   261 Get number of new entries for file creation.
   254 */
   262 */
   255 TUint16	CFatMountCB::XFileCreationHelper::NumOfAddingEntries() const
   263 TUint16 CFatMountCB::XFileCreationHelper::NumOfAddingEntries() const
   256 	{
   264     {
   257 	ASSERT(isInitialised); 
   265     ASSERT(isInitialised); 
   258 	return iNumOfAddingEntries;
   266     return iNumOfAddingEntries;
   259 	}
   267     }
   260 
   268 
   261 /** 
   269 /** 
   262 Get position of new entries for file creation.
   270 Get position of new entries for file creation.
   263 */
   271 */
   264 TEntryPos CFatMountCB::XFileCreationHelper::EntryAddingPos() const 
   272 TEntryPos CFatMountCB::XFileCreationHelper::EntryAddingPos() const 
   265 	{
   273     {
   266 	ASSERT(isInitialised); 
   274     ASSERT(isInitialised); 
   267 	return iEntryAddingPos;
   275     return iEntryAddingPos;
   268 	}
   276     }
   269 
   277 
   270 /** 
   278 /** 
   271 Check if position of new entries has been found.
   279 Check if position of new entries has been found.
   272 */
   280 */
   273 TBool CFatMountCB::XFileCreationHelper::IsNewEntryPosFound() const 
   281 TBool CFatMountCB::XFileCreationHelper::IsNewEntryPosFound() const 
   274 	{
   282     {
   275 	ASSERT(isInitialised); 
   283     ASSERT(isInitialised); 
   276 	return isNewEntryPosFound;
   284     return isNewEntryPosFound;
   277 	}
   285     }
   278 
   286 
   279 /** 
   287 /** 
   280 Check if file name of the new file is a legal dos name.
   288 Check if file name of the new file is a legal dos name.
   281 */
   289 */
   282 TBool CFatMountCB::XFileCreationHelper::IsTrgNameLegalDosName() const
   290 TBool CFatMountCB::XFileCreationHelper::IsTrgNameLegalDosName() const
   283 	{
   291     {
   284 	ASSERT(isInitialised); 
   292     ASSERT(isInitialised); 
   285 	return isTrgNameLegalDosName;
   293     return isTrgNameLegalDosName;
   286 	}
   294     }
   287 
   295 
   288 /** 
   296 /** 
   289 Set entry position for new entries to be added.
   297 Set entry position for new entries to be added.
   290 */
   298 */
   291 void CFatMountCB::XFileCreationHelper::SetEntryAddingPos(const TEntryPos& aEntryPos) 
   299 void CFatMountCB::XFileCreationHelper::SetEntryAddingPos(const TEntryPos& aEntryPos) 
   292 	{
   300     {
   293 	iEntryAddingPos = aEntryPos;
   301     iEntryAddingPos = aEntryPos;
   294 	}
   302     }
   295 
   303 
   296 /** 
   304 /** 
   297 Set condition if position of new entries has been found.
   305 Set condition if position of new entries has been found.
   298 */
   306 */
   299 void CFatMountCB::XFileCreationHelper::SetIsNewEntryPosFound(TBool aFound) 
   307 void CFatMountCB::XFileCreationHelper::SetIsNewEntryPosFound(TBool aFound) 
   300 	{
   308     {
   301 	isNewEntryPosFound = aFound;
   309     isNewEntryPosFound = aFound;
   302 	}
   310     }
   303 
   311 
   304 
   312 
   305 
   313 
   306 //-------  debug methods
   314 //-------  debug methods
   307 #ifdef  _DEBUG
   315 #ifdef  _DEBUG
   308 /**
   316 /**
   309 Debug function indicates whether write fails are active or not, for test
   317 Debug function indicates whether write fails are active or not, for test
   310 @return ETrue if write fails on or not
   318 @return ETrue if write fails on or not
   311 */
   319 */
   312 TBool CFatMountCB::IsWriteFail()const
   320 TBool CFatMountCB::IsWriteFail()const
   313 	{return(iIsWriteFail);}
   321     {return(iIsWriteFail);}
   314 /**
   322 /**
   315 Switches write fails on or off, for test
   323 Switches write fails on or off, for test
   316 @param aIsWriteFail set true or false to set write fails on or off
   324 @param aIsWriteFail set true or false to set write fails on or off
   317 */
   325 */
   318 void CFatMountCB::SetWriteFail(TBool aIsWriteFail)
   326 void CFatMountCB::SetWriteFail(TBool aIsWriteFail)
   319 	{iIsWriteFail=aIsWriteFail;}
   327     {iIsWriteFail=aIsWriteFail;}
   320 
   328 
   321 /** @return number of write fails to occur, for test */
   329 /** @return number of write fails to occur, for test */
   322 TInt CFatMountCB::WriteFailCount()const
   330 TInt CFatMountCB::WriteFailCount()const
   323 	{return(iWriteFailCount);}
   331     {return(iWriteFailCount);}
   324 
   332 
   325 /**
   333 /**
   326 Set the number of Write fails 
   334 Set the number of Write fails 
   327 @param aFailCount number of write fails, for test
   335 @param aFailCount number of write fails, for test
   328 */
   336 */
   329 void CFatMountCB::SetWriteFailCount(TInt aFailCount)
   337 void CFatMountCB::SetWriteFailCount(TInt aFailCount)
   330 	{iWriteFailCount=aFailCount;}
   338     {iWriteFailCount=aFailCount;}
   331 
   339 
   332 /** Decrement the number of write fails, for test */
   340 /** Decrement the number of write fails, for test */
   333 void CFatMountCB::DecWriteFailCount()
   341 void CFatMountCB::DecWriteFailCount()
   334 	{--iWriteFailCount;}
   342     {--iWriteFailCount;}
   335 
   343 
   336 /** @return Error for a write failure, for test */
   344 /** @return Error for a write failure, for test */
   337 TInt CFatMountCB::WriteFailError()const
   345 TInt CFatMountCB::WriteFailError()const
   338 	{return iWriteFailError;}
   346     {return iWriteFailError;}
   339 
   347 
   340 /**
   348 /**
   341 Set the write fail error code, for test
   349 Set the write fail error code, for test
   342 @param aErrorValue The Error for a write fails
   350 @param aErrorValue The Error for a write fails
   343 */
   351 */
   344 void CFatMountCB::SetWriteFailError(TInt aErrorValue)
   352 void CFatMountCB::SetWriteFailError(TInt aErrorValue)
   345 	{iWriteFailError=aErrorValue;}
   353     {iWriteFailError=aErrorValue;}
   346 
   354 
   347 #endif
   355 #endif
   348 
   356 
   349 
   357 
   350 //---------------------------------------------------------------------------------------------------------------------------------
   358 //---------------------------------------------------------------------------------------------------------------------------------
   352 
   360 
   353 TBool CFatFormatCB::Is16BitFat() const
   361 TBool CFatFormatCB::Is16BitFat() const
   354     {return(iFileSystemName==KFileSystemName16);}
   362     {return(iFileSystemName==KFileSystemName16);}
   355 
   363 
   356 CFatMountCB& CFatFormatCB::FatMount()
   364 CFatMountCB& CFatFormatCB::FatMount()
   357 	{return *(CFatMountCB*)&Mount();}
   365     {return *(CFatMountCB*)&Mount();}
   358 
   366 
   359 /**
   367 /**
   360 Returns the local drive used by the file systems from the owning mount
   368 Returns the local drive used by the file systems from the owning mount
   361 @return Pointer to the local drive 
   369 @return Pointer to the local drive 
   362 */
   370 */
   363 CProxyDrive* CFatFormatCB::LocalDrive()
   371 CProxyDrive* CFatFormatCB::LocalDrive()
   364 	{return(FatMount().LocalDrive());}
   372     {return(FatMount().LocalDrive());}
   365 
   373 
   366 
   374 
   367 //---------------------------------------------------------------------------------------------------------------------------------
   375 //---------------------------------------------------------------------------------------------------------------------------------
   368 // class CFatFileCB
   376 // class CFatFileCB
   369 
   377 
   371 Returns the owning mount from file object
   379 Returns the owning mount from file object
   372 
   380 
   373 @return pointer to the owning mount object
   381 @return pointer to the owning mount object
   374 */
   382 */
   375 CFatMountCB& CFatFileCB::FatMount() const
   383 CFatMountCB& CFatFileCB::FatMount() const
   376 	{return((CFatMountCB&)Mount());}
   384     {return((CFatMountCB&)Mount());}
   377 
   385 
   378 /**
   386 /**
   379 Returns the fat table used by the file system for this mount
   387 Returns the fat table used by the file system for this mount
   380 
   388 
   381 @return Refrence to the Fat table owned by the mount
   389 @return Refrence to the Fat table owned by the mount
   382 */
   390 */
   383 CFatTable& CFatFileCB::FAT()
   391 CFatTable& CFatFileCB::FAT()
   384 	{return(FatMount().FAT());}
   392     {return(FatMount().FAT());}
   385 
   393 
   386 /**
   394 /**
   387 Position with in a cluster for a given address
   395 Position with in a cluster for a given address
   388 
   396 
   389 @param aPos Byte position 
   397 @param aPos Byte position 
   390 */
   398 */
   391 TInt CFatFileCB::ClusterRelativePos(TInt aPos)
   399 TInt CFatFileCB::ClusterRelativePos(TInt aPos)
   392 	{return(FatMount().ClusterRelativePos(aPos));}
   400     {return(FatMount().ClusterRelativePos(aPos));}
   393 /**
   401 /**
   394 Returns Log2 of cluster size from mount
   402 Returns Log2 of cluster size from mount
   395 
   403 
   396 @return cluster size
   404 @return cluster size
   397 */
   405 */
   398 TInt CFatFileCB::ClusterSizeLog2()
   406 TInt CFatFileCB::ClusterSizeLog2()
   399 	{return(FatMount().ClusterSizeLog2());}
   407     {return(FatMount().ClusterSizeLog2());}
   400 
   408 
   401 /*
   409 /*
   402  Note: this replaces SeekIndex() which was only used in sl_mnt
   410  Note: this replaces SeekIndex() which was only used in sl_mnt
   403  to verify whether the seek index had been created/initialised
   411  to verify whether the seek index had been created/initialised
   404 */
   412 */
   413 Returns the owning mount from directory object
   421 Returns the owning mount from directory object
   414 
   422 
   415 @return pointer to the owning mount object
   423 @return pointer to the owning mount object
   416 */
   424 */
   417 CFatMountCB& CFatDirCB::FatMount()
   425 CFatMountCB& CFatDirCB::FatMount()
   418 	{return((CFatMountCB&)Mount());}
   426     {return((CFatMountCB&)Mount());}
   419 
   427 
   420 
   428 
   421 
   429 
   422 //---------------------------------------------------------------------------------------------------------------------------------
   430 //---------------------------------------------------------------------------------------------------------------------------------
   423 // class CFatTable
   431 // class CFatTable
   427     return iFreeClusters;
   435     return iFreeClusters;
   428     }
   436     }
   429 
   437 
   430 
   438 
   431 TBool CFatTable::IsEof16Bit(TInt aCluster) const
   439 TBool CFatTable::IsEof16Bit(TInt aCluster) const
   432 	{return(aCluster>=0xFFF8 && aCluster<=0xFFFF);}
   440     {return(aCluster>=0xFFF8 && aCluster<=0xFFFF);}
   433 
   441 
   434 TBool CFatTable::IsEof12Bit(TInt aCluster) const
   442 TBool CFatTable::IsEof12Bit(TInt aCluster) const
   435 	{return(aCluster>=0xFF8 && aCluster<=0xFFF);}
   443     {return(aCluster>=0xFF8 && aCluster<=0xFFF);}
   436 
   444 
   437 TInt CFatTable::SectorSizeLog2() const
   445 TInt CFatTable::SectorSizeLog2() const
   438 	{return(iOwner->SectorSizeLog2());}
   446     {return(iOwner->SectorSizeLog2());}
   439 
   447 
   440 //---------------------------------------------------------------------------------------------------------------------------------
   448 //---------------------------------------------------------------------------------------------------------------------------------
   441 
   449 
   442 inline TBool CFatTable::IsFat12() const 
   450 inline TBool CFatTable::IsFat12() const 
   443     {
   451     {
   463     }
   471     }
   464 
   472 
   465 
   473 
   466 // class TFatDriveInterface
   474 // class TFatDriveInterface
   467 TBool TFatDriveInterface::NotifyUser() const
   475 TBool TFatDriveInterface::NotifyUser() const
   468 	{return(iMount->GetNotifyUser());}
   476     {return(iMount->GetNotifyUser());}
   469 
   477 
   470 
   478 
   471 
   479 
   472 //----------------------------------------------------------------------------------------------------
   480 //----------------------------------------------------------------------------------------------------
   473 // class CRawDisk
   481 // class CRawDisk
   482 MWTCacheInterface* CRawDisk::DirCacheInterface()
   490 MWTCacheInterface* CRawDisk::DirCacheInterface()
   483     {
   491     {
   484     return NULL;
   492     return NULL;
   485     }
   493     }
   486 
   494 
   487 //---------------------------------------------------------------------------------------------------------------------------------	
   495 //--------------------------------------------------------------------------------------------------------------------------------- 
   488 //-- class RBitVector
   496 //-- class RBitVector
   489 
   497 
   490 /** @return size of the vector (number of bits) */
   498 /** @return size of the vector (number of bits) */
   491 inline TUint32 RBitVector::Size() const
   499 inline TUint32 RBitVector::Size() const
   492     {
   500     {
   572     }
   580     }
   573 
   581 
   574 /**
   582 /**
   575     Calculate offset of the page starting position in the cluster 
   583     Calculate offset of the page starting position in the cluster 
   576     @param aPos  the current entry position in bytes in the cluster
   584     @param aPos  the current entry position in bytes in the cluster
   577     @param aPageSzLog2	page size in log2
   585     @param aPageSzLog2  page size in log2
   578     @return		the starting position of the page that contains aPos
   586     @return     the starting position of the page that contains aPos
   579 */
   587 */
   580 inline TUint32 CalculatePageOffsetInCluster(TUint32 aPos, TUint aPageSzLog2)
   588 inline TUint32 CalculatePageOffsetInCluster(TUint32 aPos, TUint aPageSzLog2)
   581 	{
   589     {
   582 	return (aPos >> aPageSzLog2) << aPageSzLog2;
   590     return (aPos >> aPageSzLog2) << aPageSzLog2;
   583 	}
   591     }
   584 
   592 
   585 #endif //SL_STD_INL
   593 #endif //SL_STD_INL
   586 
   594 
   587 
   595 
   588 
   596