예제 #1
0
파일: SuperBlock.cs 프로젝트: bwbwbwbw/vfs
        /// <summary>
        /// 创建一个全新的 SuperBlock
        /// </summary>
        /// <param name="vfs"></param>
        /// <param name="inodeCapacity"></param>
        /// <param name="blockSize"></param>
        /// <param name="blockCapacity"></param>
        /// <returns></returns>
        public static SuperBlock Create(VFSCore vfs, UInt32 inodeCapacity, UInt16 blockSize, UInt32 blockCapacity)
        {
            var _superBlock = new _SuperBlock(inodeCapacity, blockSize, blockCapacity);
            var superBlock  = new SuperBlock(vfs, _superBlock);

            superBlock.Save();
            return(superBlock);
        }
예제 #2
0
파일: SuperBlock.cs 프로젝트: bwbwbwbw/vfs
        public SuperBlock(VFSCore vfs, _SuperBlock data)
        {
            this.vfs  = vfs;
            this.data = data;

            if (data.IsValid())
            {
                init();
            }
        }
예제 #3
0
 /// <summary>
 /// 创建一个全新的 SuperBlock
 /// </summary>
 /// <param name="vfs"></param>
 /// <param name="inodeCapacity"></param>
 /// <param name="blockSize"></param>
 /// <param name="blockCapacity"></param>
 /// <returns></returns>
 public static SuperBlock Create(VFSCore vfs, UInt32 inodeCapacity, UInt16 blockSize, UInt32 blockCapacity)
 {
     var _superBlock = new _SuperBlock(inodeCapacity, blockSize, blockCapacity);
     var superBlock = new SuperBlock(vfs, _superBlock);
     superBlock.Save();
     return superBlock;
 }
예제 #4
0
        public SuperBlock(VFSCore vfs, _SuperBlock data)
        {
            this.vfs = vfs;
            this.data = data;

            if (data.IsValid())
            {
                init();
            }
        }