Root/
Source at commit 1275 created 12 years 11 months ago. By meklort, Remove unused file. Fixup makefiles some more - boot2 compiles again. | |
---|---|
1 | /*␊ |
2 | * Copyright (c) 2011 Evan Lojewski. All rights reserved.␊ |
3 | *␊ |
4 | */␊ |
5 | #ifndef PARTITION_H␊ |
6 | #define PARTITION_H␊ |
7 | ␊ |
8 | #include <IOKit/IOTypes.h>␊ |
9 | ␊ |
10 | #define INVALID_PARTITION (-1)␊ |
11 | ␊ |
12 | class Disk;␊ |
13 | ␊ |
14 | class Partition␊ |
15 | {␊ |
16 | public:␊ |
17 | Partition(Disk* disk, UInt8 partitionNumber);␊ |
18 | ~Partition();␊ |
19 | ␊ |
20 | virtual IOReturn Read(UInt64 sector, UInt64 size, UInt8* buffer);␊ |
21 | virtual IOReturn Write(UInt64 sector, UInt64 size, UInt8* buffer);␊ |
22 | ␊ |
23 | virtual bool probe(); ␊ |
24 | ␊ |
25 | //virtual uuid_t getUUID();␊ |
26 | ␊ |
27 | virtual UInt32 getPartitionNumber() { return mPartitionNumber; };␊ |
28 | virtual UInt8 getNumPartitions() { return mNumPartitions; };␊ |
29 | ␊ |
30 | protected:␊ |
31 | Disk *mDisk;␊ |
32 | UInt64 mNumSectors;␊ |
33 | UInt64 mBeginSector;␊ |
34 | SInt8 mPartitionNumber;␊ |
35 | UInt8 mNumPartitions;␊ |
36 | //uuid_t mUUID;␊ |
37 | ␊ |
38 | private:␊ |
39 | ␊ |
40 | };␊ |
41 | ␊ |
42 | ␊ |
43 | class PartitionList␊ |
44 | {␊ |
45 | public:␊ |
46 | Partition *entry;␊ |
47 | PartitionList *next;␊ |
48 | };␊ |
49 | ␊ |
50 | ␊ |
51 | #endif /* PARTITION_H */␊ |
52 |