blob: 6dc8ece1187feaba9974429c7f1f4f030ef502d2 (
plain)
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
|
//
// WriterThread.h
// Liaison
//
// Created by Brian Cully on Wed Feb 26 2003.
// Copyright (c) 2003 Brian Cully. All rights reserved.
//
#define WriterThreadDied @"LiWriterThreadDied"
@interface WriterThread : NSObject {
NSMutableArray *theDataQueue;
NSConditionLock *theQueueLock;
NSFileHandle *theFile;
volatile BOOL theConnectionIsOpen;
volatile BOOL theKillFlag;
}
- (id)initWithFileHandle: (NSFileHandle *)aFileHandle;
- (void)die;
- (void)writeData: (NSData *)someData;
@property (retain,getter=queueLock) NSConditionLock *theQueueLock;
@property (retain,getter=dataQueue) NSMutableArray *theDataQueue;
@property volatile BOOL theConnectionIsOpen;
@property volatile BOOL theKillFlag;
@property (assign,getter=file,setter=setFile:) NSFileHandle *theFile;
@end
@interface WriterThread (Accessors)
- (NSMutableArray *)dataQueue;
- (void)setDataQueue: (NSMutableArray *)aQueue;
- (NSConditionLock *)queueLock;
- (void)setQueueLock: (NSConditionLock *)aLock;
- (NSFileHandle *)file;
- (void)setFile: (NSFileHandle *)aFile;
@end
|