Added public object functionality.
[pithos-ios] / Classes / StorageObject.h
1 //
2 //  Object.h
3 //  OpenStack
4 //
5 //  Created by Mike Mayo on 12/7/10.
6 //  The OpenStack project is provided under the Apache 2.0 license.
7 //
8
9 #import <Foundation/Foundation.h>
10
11
12 @interface StorageObject : NSObject <NSCoding> {
13         NSString *name;
14     NSString *fullPath;
15         NSString *hash;
16         NSUInteger bytes;
17         NSString *contentType;
18         NSDate *lastModified;
19         NSData *data;
20     NSString *publicURI;
21         NSMutableDictionary *metadata;
22 }
23
24 @property (nonatomic, retain) NSString *name;
25 @property (nonatomic, retain) NSString *fullPath;
26 @property (nonatomic, retain) NSString *hash;
27 @property (nonatomic, assign) NSUInteger bytes;
28 @property (nonatomic, retain) NSString *contentType;
29 @property (nonatomic, retain) NSDate *lastModified;
30 @property (nonatomic, retain) NSData *data;     
31 @property (nonatomic, retain) NSString *publicURI;
32 @property (nonatomic, retain) NSMutableDictionary *metadata;
33
34 - (NSString *)humanizedBytes;
35 + (StorageObject *)fromJSON:(NSDictionary *)dict;
36
37 - (BOOL)isPlayableMedia;
38
39 @end