首页 开发技术 C++     /    操作系统简单二级文件系统

操作系统简单二级文件系统

上传者: l591492105 | 上传时间:2025/5/5 3:46:40 | 文件大小:439KB | 文件类型:rar
操作系统简单二级文件系统
共两个不同设计例子,都含详细的文档资料。
任务2.设计一个简单的二级文件系统设计要求:在任一OS下,建立一个大文件,把它假象成硬盘,在其中实现一个简单的模拟文件系统。
编写一管理程序对此空间进行管理,要求:1.实现盘块管理2.实现文件的读写操作3.每组最多2人,小组内要有明确分工,课程设计报告中设计部分可以相同,个人实现部分不同参考建议:将模拟硬盘的文件空间划分为目录区,文件区;
采用位示图进行空间管理,盘块的分配使用显示链接(FAT表)的方式。
设计技术参数(数据结构)参考:#defineMaxSize100#defineDisk512//每个盘块大小为512bit#defineNumDisk2048//有2048个盘块,既可分配空间为1M/*************目录和文件的结构定义***********************/structDirectoryNode{charname[9];/*目录或文件的名字*/inttype;/*0代表目录,1代表普通文件*/structDirectoryNode*next;/*指向下一个兄弟结点的指针*/structDirectoryNode*preDirFile;/*指向父结点的指针*/structDirectoryNode*subFile;/*指向第一个子结点的指针*/intsize;/*如果是文件则表示文件的大小*/intfirst;/*起始盘块号*/intlast;/*末尾盘块号*/intorder;/*备用*/};//连续分配structFileSys{intVacTable[NumDisk];//空闲表,0为空闲,1为被用structDirectoryNoderoot;//根目录structDirectoryNodeDirectory[NumDisk];}*filesys;typedefstruct{structDirectoryNode*DirFile;charname[9];}DataType;//包含一个指向目录的指针和名字typedefstruct{//队列结构的实现DataTypedata[MaxSize];intfront,rear;//分别表示队列的头结点和尾结点}Tp;voidInitQueue(Tp*sq)//队列初始化intEnAddQueue(Tp*sq,DataTypedata)//在队列中增加元素DataTypeEnDelQueue(Tp*sq)//从队列中删除一个元素intEmpty(Tp*sq)//判断队列是否为空,返回0表示队列为空①.Dir:显示目录内容命令,显示当前目录下的文件和子目录。
②.Md:创建目录操作。
③.Create:创建文件,在当前目录下创建一个文件。
④.all:显示从根目录开始的所有目录和文件及其层次结点。
⑤.Cd:改变目录。
⑥.Del:删除文件操作。
⑦.Rd:删除目录操作,删除当前目录下的子目录。
⑧.Ren:重命名函数⑨.Exit:退出命令 本软件ID:4017787

文件下载

资源详情

[{"title":"(25个子文件439KB)操作系统简单二级文件系统","children":[{"title":"REG.C <span style='color:#111;'>2.78KB</span>","children":null,"spread":false},{"title":"BALLFRE.C <span style='color:#111;'>1.73KB</span>","children":null,"spread":false},{"title":"报告.doc <span style='color:#111;'>712.00KB</span>","children":null,"spread":false},{"title":"MAIN.OPT <span style='color:#111;'>51.50KB</span>","children":null,"spread":false},{"title":"ACCESS.C <span style='color:#111;'>1.05KB</span>","children":null,"spread":false},{"title":"MAIN.DSP <span style='color:#111;'>4.36KB</span>","children":null,"spread":false},{"title":"IALLFRE.C <span style='color:#111;'>3.11KB</span>","children":null,"spread":false},{"title":"OPENCLO.C <span style='color:#111;'>2.03KB</span>","children":null,"spread":false},{"title":"BRDWT.C <span style='color:#111;'>556B</span>","children":null,"spread":false},{"title":"CMDEXP.C <span style='color:#111;'>5.78KB</span>","children":null,"spread":false},{"title":"二级文件系统2.rar <span style='color:#111;'>99.72KB</span>","children":null,"spread":false},{"title":"MAIN.NCB <span style='color:#111;'>233.00KB</span>","children":null,"spread":false},{"title":"CREATDE.C <span style='color:#111;'>2.55KB</span>","children":null,"spread":false},{"title":"MAIN.DSW <span style='color:#111;'>533B</span>","children":null,"spread":false},{"title":"NAME.C <span style='color:#111;'>933B</span>","children":null,"spread":false},{"title":"FILSYS.H <span style='color:#111;'>6.97KB</span>","children":null,"spread":false},{"title":"DIR.C <span style='color:#111;'>3.91KB</span>","children":null,"spread":false},{"title":"FORMATIT.C <span style='color:#111;'>4.15KB</span>","children":null,"spread":false},{"title":"LOG.C <span style='color:#111;'>2.57KB</span>","children":null,"spread":false},{"title":"MAIN.C <span style='color:#111;'>2.88KB</span>","children":null,"spread":false},{"title":"HALTIT.C <span style='color:#111;'>693B</span>","children":null,"spread":false},{"title":"DIRGETT.C <span style='color:#111;'>1.70KB</span>","children":null,"spread":false},{"title":"READWE.C <span style='color:#111;'>5.35KB</span>","children":null,"spread":false},{"title":"IGETPUT.C <span style='color:#111;'>3.12KB</span>","children":null,"spread":false},{"title":"INIT.C <span style='color:#111;'>924B</span>","children":null,"spread":false}],"spread":true}]

评论信息

  • cjipcrwitz:
    感謝LZ收集,谢谢分享.2018-12-18
  • 桃花岛人贩子:
    打不开啊,楼主2018-01-29
  • ab_12393:
    自己不会只能参照楼主的谢谢2017-06-05
  • hwx1102:
    资源有用,可以参考2016-07-31
  • qq_18582295:
    完成学校布置的大作业拿来做参考,多谢帮助!看了之后感觉收获很大,自己照着写了!2015-12-23

免责申明

【好快吧下载】的资源来自网友分享,仅供学习研究,请务必在下载后24小时内给予删除,不得用于其他任何用途,否则后果自负。基于互联网的特殊性,【好快吧下载】 无法对用户传输的作品、信息、内容的权属或合法性、合规性、真实性、科学性、完整权、有效性等进行实质审查;无论 【好快吧下载】 经营者是否已进行审查,用户均应自行承担因其传输的作品、信息、内容而可能或已经产生的侵权或权属纠纷等法律责任。
本站所有资源不代表本站的观点或立场,基于网友分享,根据中国法律《信息网络传播权保护条例》第二十二条之规定,若资源存在侵权或相关问题请联系本站客服人员,8686821#qq.com,请把#换成@,本站将给予最大的支持与配合,做到及时反馈和处理。关于更多版权及免责申明参见 版权及免责申明