IDEA: Cleanup VFS

IDEA: Cleanup VFS

Post Reply
User avatar
jK
Spring Developer
Posts: 2299
Joined: 28 Jun 2007, 07:30

IDEA: Cleanup VFS

Post by jK »

things to do:
  • make path separator linux style only (get rid of CFileSystemHandler::native_path_separator!)
    atm raw fs uses os specfic one while zip/vfs uses linux only. causing to show files doubled in Lua's VFS.DirList().
  • clean up/unify the classes themselves
    atm there are 3 ways used to scan/open files in the VFS:
    • CArchiveBase (ArchiveScanner/unitsync)
    • CFileHandler (Lua)
    • CVFSHandler
    Problem is that some features of one class aren't exported to the others and that there is no way to get the CArchiveBase via the CFileHandler/CVFSHandler, so there is no way to get that data at all. Examples
    • CArchiveBase has a GetCRC32 it would be very nice to have this in the other interfaces, too, so Lua could use it.
    • It would be nice to have a fast & clean implementation to scan for existing files in VFS&RawFS w/o loading the file itself via CFileHandler() (that's what Lua does atm!). (perhaps make rawfs part of CVFSHandler and remove CFileHandler totally?) - done

files that need to get touched:
  • all in rts/System/FileSystem/*
Post Reply

Return to “New Developer Discussion”