Seyshell
Loading...
Searching...
No Matches
struct.h
Go to the documentation of this file.
1
2#pragma once
3#include "const.h"
4
10typedef struct inode {
11 unsigned short perms; // rwxrwxrwx
15
20typedef struct bloc {
23
28typedef struct disk {
29 char owned_blocs[MAX_BLOCS]; // 1 si possédé par un inode, 0 si libre
33
34// pour 10 inode qui a 30 blocs de chacun 1024 octets, on a 30720 octets, soit
35// 30,7 Ko sur le disque
#define MAX_BYTES_PER_BLOC
Definition const.h:4
#define MAX_BLOCS
Definition const.h:3
#define MAX_INODE
Definition const.h:5
Un bloc possède un tableau de données brut concernant des inodes.
Definition struct.h:20
char datas[MAX_BYTES_PER_BLOC]
Definition struct.h:21
Un disque est un liste d'inodes qui pointent sur des blocs de donnée.
Definition struct.h:28
inode inodes[MAX_INODE]
Definition struct.h:30
char owned_blocs[MAX_BLOCS]
Definition struct.h:29
bloc blocs[MAX_BLOCS]
Definition struct.h:31
Un inode est un fichier, il possède des permissions, un type (répertoire par exemple) et pointe sur d...
Definition struct.h:10
char filetype
Definition struct.h:12
int blocs[MAX_BLOCS]
Definition struct.h:13
unsigned short perms
Definition struct.h:11