1 | //␊ |
2 | // PartitionInfoElement.h␊ |
3 | // ChameleonPrefPane␊ |
4 | //␊ |
5 | // Created by Rekursor on 11-11-12.␊ |
6 | //␊ |
7 | ␊ |
8 | #import <Cocoa/Cocoa.h>␊ |
9 | ␊ |
10 | @interface PartitionInfoElement : NSObject {␊ |
11 | ␉NSString*␉ bsdName;␊ |
12 | ␉NSString␉␉*vUUID, *vName, *vPath, *vKind, *mediaPath, *devProtocol;␊ |
13 | ␉NSString␉␉*vAliasName; // for rename partition purpose␊ |
14 | ␉NSString␉␉*bootInfo; // for displaying partition info␊ |
15 | ␉bool␉␉␉␉devInternal, mediaRemovable;␊ |
16 | ␉NSDictionary*␉descDict;␊ |
17 | ␊ |
18 | ␉bool␉␉␉␉hidden;␉␉ // for hide partition purpose␊ |
19 | ␉int␉␉␉␉err; // non zero if problem occurred during info extraction␊ |
20 | ␉int␉␉␉␉diskNum, partNum;␊ |
21 | }␊ |
22 | ␊ |
23 | // Partition information properties␊ |
24 | @property (retain) NSDictionary* descDict;␊ |
25 | @property (retain) NSString* bsdName;␊ |
26 | @property (retain) NSString* vUUID;␊ |
27 | @property (retain) NSString* vKind;␊ |
28 | @property (retain) NSString* vName;␊ |
29 | @property (retain) NSString* vPath;␊ |
30 | @property (retain) NSString* mediaPath;␊ |
31 | @property (retain) NSString* devProtocol;␊ |
32 | @property (retain) NSString* bootInfo;␊ |
33 | ␊ |
34 | @property (assign) bool devInternal;␊ |
35 | @property (assign) bool mediaRemovable;␊ |
36 | ␊ |
37 | @property (retain) NSString* vAliasName;␊ |
38 | @property (assign) bool hidden;␊ |
39 | ␊ |
40 | +(NSArray*) createBSDPartitionList;␊ |
41 | +(NSUInteger*) hdRedirTable;␊ |
42 | ␊ |
43 | -(id)␉initWithBSDName: (NSString*) bsdName;␊ |
44 | -(id)␉initWithBSDName: (NSString*) bsdName withinSession: (DASessionRef) session;␊ |
45 | -(void) cleanup;␊ |
46 | ␊ |
47 | -(int)␉extractInfoWithBSDName: (NSString*) bsdName;␊ |
48 | -(int)␉extractInfoWithBSDName: (NSString*) bsdName withinSession:(DASessionRef) session;␊ |
49 | ␊ |
50 | +(NSMutableArray*)␉extractInfoWithBSDNames: (NSArray*) bsdNames;␊ |
51 | +(NSMutableArray*)␉extractInfoWithBSDNames: (NSArray*) bsdNames withArray:(NSMutableArray*) arr;␊ |
52 | ␊ |
53 | -(bool)␉isValid;␊ |
54 | ␊ |
55 | // Get any DA attribute from dict␊ |
56 | -(NSString*) stringValueWithKey: (NSString*) key;␊ |
57 | // Get the boot information string, for chameleon only for now ...␊ |
58 | -(NSString*) bootDescription;␊ |
59 | ␊ |
60 | -(int) diskNumber;␊ |
61 | -(int) partitionNumber;␊ |
62 | -(void) setDiskNumber:(int) d;␊ |
63 | -(void) setPartitionNumber:(int)p;␊ |
64 | -(NSString*) hdString;␊ |
65 | ␊ |
66 | -(NSString*) description;␊ |
67 | -(bool) isBootable;␊ |
68 | -(int) imageIndexFromFs;␊ |
69 | +(NSString*) removesSpacesFromLabel:(NSString*) label;␊ |
70 | ␊ |
71 | @end␊ |
72 | |