PTFilterWriter
@interface PTFilterWriter : NSObjectFilterWriter is a utility class providing a convenient way to write data to an output filter (using Filter directly is not very intuitive).
For example:
 StdFile outfile("file.dat", StdFile::e_write_mode);
 FilterWriter fwriter(outfile);
 fwriter.WriteBuffer(buf, buf_sz);
 fwriter.Flush();
- 
                  
                  Write a single character to the output stream. DeclarationObjective-C - (void)WriteUChar:(unsigned char)ch;Swift func writeUChar(_ ch: UInt8)ParameterschAn unsigned character to write to the output stream. 
- 
                  
                  Write an integer to the output stream. DeclarationObjective-C - (void)WriteInt16:(short)num;Swift func write(_ num: Int16)ParametersnumAn integer to write to the output stream. 
- 
                  
                  Undocumented DeclarationObjective-C - (void)WriteUInt16: (unsigned short)num;Swift func write(_ num: UInt16)
- 
                  
                  Undocumented DeclarationObjective-C - (void)WriteInt32: (int)num;Swift func write(_ num: Int32)
- 
                  
                  Undocumented DeclarationObjective-C - (void)WriteUInt32: (unsigned int)num;Swift func write(_ num: UInt32)
- 
                  
                  Undocumented DeclarationObjective-C - (void)WriteInt64: (long long)num;Swift func write(_ num: Int64)
- 
                  
                  Undocumented DeclarationObjective-C - (void)WriteUInt64: (unsigned long long)num;Swift func write(_ num: UInt64)
- 
                  
                  Write a string to the output stream. DeclarationObjective-C - (void)WriteString:(NSString *)str;Swift func write(_ str: String!)ParametersstrA string to write to the output stream. 
- 
                  
                  Write the entire input stream to the output stream (i.e. to this FilterWriter). DeclarationObjective-C - (void)WriteFilter:(PTFilterReader *)reader;Swift func writeFilter(_ reader: PTFilterReader!)ParametersreaderA FilterReader attached to an input stream. 
- 
                  
                  Write out a null terminated ‘line’ followed by a end of line character default end of line character is carriage return. DeclarationObjective-C - (void)WriteLine:(NSString *)line eol:(char)eol;Swift func writeLine(_ line: String!, eol: CChar)Parameterslinestring to write out. eolend of line character. Defaults to carriage return (0x0D). 
- 
                  
                  DeclarationObjective-C - (unsigned long)WriteBuffer:(NSData *)buf;Swift func writeBuffer(_ buf: Data!) -> UIntParametersbufbuffer object to write out. Return Value- returns the number of bytes actually written to a stream. This number may less than buf_size if the stream is corrupted. 
- 
                  
                  Sets the position within the current stream. Note - After each Seek() operation the number of consumed bytes (i.e. Count()) is set to 0. @exception - throws an exception if the method is not implemented in the associated filter. DeclarationObjective-C - (void)Seek:(unsigned long long)offset origin:(PTReferencePos)origin;Swift func seek(_ offset: UInt64, origin: PTReferencePos)Parametersoffset- A byte offset relative to origin. If offset is negative, the new position will precede the position specified by origin by the number of bytes specified by offset. If offset is zero, the new position will be the position specified by origin. If offset is positive, the new position will follow the position specified by origin by the number of bytes specified by offset. origin- A value of type ReferencePos indicating the reference point used to obtain the new position 
- 
                  
                  Reports the current read position in the stream relative to the stream origin. DeclarationObjective-C - (unsigned long long)Tell;Swift func tell() -> UInt64Return Value- The current position in the stream @exception - throws an exception if the method is not implemented in the associated filter. 
- 
                  
                  DeclarationObjective-C - (unsigned long)Count;Swift func count() -> UIntReturn Value- the number of bytes consumed since opening the filter or since the last Seek operation. 
- 
                  
                  Forces any data remaining in the buffer to be written to input or output filter. DeclarationObjective-C - (void)Flush;Swift func flush()
- 
                  
                  Forces any data remaining in the filter chain to the source or destination. DeclarationObjective-C - (void)FlushAll;Swift func flushAll()
- 
                  
                  Undocumented DeclarationObjective-C - (instancetype)init;Swift init!()
 PTFilterWriter Class Reference
        PTFilterWriter Class Reference