By default, “OFS” (hierarchical file system), “SBFS” (Petit computer file system) exist, OFS is the root file system. You can mount using the mount command
mount filesystem [data] path
mount SBFS TXT: / TXT
allows you to mount only TXT files in / TXT
In the initial state
It is scheduled to be
Create a file system based on NAME$\ If NAME$ already exists: FS_ERROR_DUPFS\ When memory is insufficient FS_ERROR_OUTOFMEM
Search FileSystem for NAME$\ If it does not exist, CALL “FS_INIT_“+NAME$
DEF FUNC FS,DATA$,PATH$,FILELIST$[] OUT ERR
Called when file list is acquired\ PUSH the file to FILELIST$[]
When FS is invalid: FS_ERROR_INVALIDFS\ When FUNC$ is invalid: FS_ERROR_INVALIDFUNC
DEF FUNC FS,DATA$,PATH$,OPTION$ OUT FILE,ERR
Called when a PATH$ file is opened\ Store error in file FILE in ERR
When FS is invalid: FS_ERROR_INVALIDFS\ When FUNC$ is invalid: FS_ERROR_INVALIDFUNC
Function to call when mounting
DEF FUNC FS,DATA$,PATH$,MOUNTFS$,MOUNTDATA$ OUT ERR
Default behavior when not set is FS_ERROR_NOTSUPPORTED in ERR
When FS is invalid FS_ERROR_INVALIDFS\ When FUNC $ is invalid FS_ERROR_INVALIDFUNC
DEF FUNC FS,DATA$,PATH$ OUT OUTFS,OUTDATA$,OUTPATH$,ERR
Behavior at the time of unsetting sets ERR to 0 if PATH$ exists, and sets a value in ERR if not\ Let OUTFS be FS and set OUTDATA$ to DATA$ and set OUTPATH$ to PATH$
Set handler for directory creation for only one hierarchy
DEF FUNC FS,DATA$,PATH$ OUT ERR
Set handler for file deletion
DEF FUNC FS,DATA$,PATH$ OUT ERR
Set name change handler
DEF FUNC FS,DATA$,PATH$,NEWNAME$ OUT ERR
Set file type acquisition handler
DEF FUNC FS,DATA$,PATH$ OUT TYPE$,ERR
Get filename in PetitCom
DEF FUNC FS,DATA$,PATH$ OUT FILE$,ERR
FILE$ is a valid filename for PetitCon(DAT:HOGE.GRP,TXT:HOGE.PRG)
Set handler to save DATA file
DEF FUNC FS,DATA$,PATH$,ARRAY OUT ERR
Mount FILESYSTEM$ at PATH$
FS_ERROR_NOTFOUND FS_ERROR_NOTSUPPORTED FS_ERROR_ACCESS FS_ERROR_NOSPACE FS_ERROR_CANCEL
0x6001
0x6002