-
Notifications
You must be signed in to change notification settings - Fork 17
/
MPWWriteStream.h
86 lines (52 loc) · 1.42 KB
/
MPWWriteStream.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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
/* MPWWriteStream.h Copyright (c) 1998-2017 by Marcel Weiher, All Rights Reserved.
*/
#import <Foundation/Foundation.h>
#import <MPWFoundation/AccessorMacros.h>
#import <MPWFoundation/MPWObject.h>
@protocol Streaming
-(void)writeObject:anObject;
@end
@class MPWByteStream;
@protocol StreamSource
@property (nonatomic, strong) IBOutlet NSObject <Streaming> *target;
@end
@interface NSObject(MPWStreaming)
-(void)writeOnStream:(id <Streaming>)aStream;
@end
@interface NSObject(graphViz)
-(void)graphViz:(MPWByteStream*)aStream;
-(NSString*)graphViz;
-(NSString*)graphVizName;
@end
@interface MPWWriteStream : NSObject <Streaming>
{
SEL streamWriterMessage;
}
@property (nonatomic, strong) NSString *name;
+process:anObject;
+(void)processAndIgnore:anObject;
-(void)writeObjectAndClose:anObject;
-(void)writeObject:anObject sender:sourceStream;
-(void)writeEnumerator:e spacer:spacer;
-(void)writeEnumerator:e;
-(void)writeNSObject:anObject;
-(void)writeData:(NSData*)d;
+(instancetype)stream;
//-(instancetype)init;
-(void)writeObjectAndFlush:anObject;
-(void)writeTarget:aTarget;
-(void)setFinalTarget:newTarget;
-(void)do:aBlock;
-(SEL)streamWriterMessage;
-(void)close;
-(void)flush;
-result;
-(void)closeLocal;
-(void)flushLocal;
-(void)reportError:(NSError*)error;
@end
@interface NSObject(BaseStreaming)
-(void)writeOnMPWStream:(MPWWriteStream*)aStream;
@end
@interface NSMutableArray(StreamTarget) <Streaming>
@end