HTTPResponse.h.svn-base
上传用户:kc0325
上传日期:2020-06-20
资源大小:204k
文件大小:1k
- #import <Foundation/Foundation.h>
- @protocol HTTPResponse
- - (UInt64)contentLength;
- - (UInt64)offset;
- - (void)setOffset:(UInt64)offset;
- - (NSData *)readDataOfLength:(unsigned int)length;
- @end
- @interface HTTPFileResponse : NSObject <HTTPResponse>
- {
- NSString *filePath;
- NSFileHandle *fileHandle;
- }
- - (id)initWithFilePath:(NSString *)filePath;
- - (NSString *)filePath;
- @end
- @interface HTTPDataResponse : NSObject <HTTPResponse>
- {
- unsigned offset;
- NSData *data;
- }
- - (id)initWithData:(NSData *)data;
- @end