public void LoadInode(Inode inode) { var offset = Offset + (inode.AgBlock * Context.SuperBlock.Blocksize) + (inode.BlockOffset * Context.SuperBlock.InodeSize); Context.RawStream.Position = offset; var data = Utilities.ReadFully(Context.RawStream, (int)Context.SuperBlock.InodeSize); inode.ReadFrom(data, 0); }
public Inode GetInode(ulong number) { var inode = new Inode(number, this); AllocationGroup group = AllocationGroups[inode.AllocationGroup]; group.LoadInode(inode); if (inode.Magic != Inode.InodeMagic) { throw new IOException("invalid inode magic"); } return(inode); }
public File(Context context, Inode inode) { Context = context; Inode = inode; }
public Symlink(Context context, Inode inode) : base(context, inode) { }
public Directory(Context context, Inode inode) : base(context, inode) { }