forked from MacFace/MacFace
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDiskHistory.h
executable file
·58 lines (45 loc) · 1.37 KB
/
DiskHistory.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
//
// DiskHistory.h
// MacFace
//
// Created by rryu on Sat Jan 18 2003.
// Copyright (c) 2003-2006 rryu. All rights reserved.
// $Id: DiskHistory.h 48 2006-06-03 10:01:58Z rryu $
//
#import <Cocoa/Cocoa.h>
typedef long long FSSize;
@class ConsumptionForecastInfo;
@interface DiskHistory : NSObject
{
NSString *path;
FSSize *history;
NSUInteger count;
unsigned capacity;
FSSize maxFreeSize;
FSSize minFreeSize;
NSDate *lastCheckDate;
int preferredUnit;
}
- (id)initWithPath:(NSString*)aPath capacity:(unsigned)aCapacity;
- (id)initWithPath:(NSString*)aPath capacity:(unsigned)aCapacity dictionaryRepresentation:(NSDictionary*)dict;
- (BOOL)update;
- (NSDictionary*)dictionaryRepresentation;
- (NSString*)path;
- (NSUInteger)count;
- (unsigned)capacity;
- (FSSize)freeSizeAtIndex:(unsigned)index;
- (FSSize)currentFreeSize;
- (FSSize)maxFreeSize;
- (FSSize)minFreeSize;
- (int)preferredUnit;
- (int)preferredIntPartDigit;
- (int)preferredFractionDigit;
- (int)unitOfSize:(FSSize)size;
- (int)intPartDigitOfSize:(FSSize)size byUnit:(int)unit;
- (int)fractionDigittOfSize:(FSSize)size byUnit:(int)unit;
- (float)unitValueOfSize:(FSSize)size byUnit:(int)unit;
- (FSSize)sizeOfUnitValue:(float)value byUnit:(int)unit;
- (FSSize)unitSizeByUnit:(int)unit;
- (NSString*)symbolStringByUnit:(int)unit;
- (ConsumptionForecastInfo*)calculateConsumptionForcast;
@end