|  |  |  | GMime 2.6 Reference Manual |  | 
|---|---|---|---|---|
| Top | Description | Object Hierarchy | ||||
struct GMimeStreamFs; GMimeStream * g_mime_stream_fs_new (int fd); GMimeStream * g_mime_stream_fs_new_with_bounds (int fd,gint64 start,gint64 end); GMimeStream * g_mime_stream_fs_new_for_path (const char *path,int flags,int mode); gboolean g_mime_stream_fs_get_owner (GMimeStreamFs *stream); void g_mime_stream_fs_set_owner (GMimeStreamFs *stream,gboolean owner);
A simple GMimeStream implementation that sits on top of the low-level UNIX file descriptor based I/O layer.
GMimeStream *       g_mime_stream_fs_new                (int fd);
Creates a new GMimeStreamFs object around fd.
| 
 | a file descriptor | 
| Returns : | a stream using fd. | 
GMimeStream * g_mime_stream_fs_new_with_bounds (int fd,gint64 start,gint64 end);
Creates a new GMimeStreamFs object around fd with bounds start
and end.
| 
 | a file descriptor | 
| 
 | start boundary | 
| 
 | end boundary | 
| Returns : | a stream using fdwith boundsstartandend. | 
GMimeStream * g_mime_stream_fs_new_for_path (const char *path,int flags,int mode);
Creates a new GMimeStreamFs object for the specified path.
| 
 | the path to a file | 
| 
 | as in open(2) | 
| 
 | as in open(2) | 
| Returns : | a stream using for reading and/or writing to the specified
file path or NULLon error. | 
Since 2.6.18
gboolean            g_mime_stream_fs_get_owner          (GMimeStreamFs *stream);
Gets whether or not stream owns the backend file descriptor.
| 
 | a GMimeStreamFs | 
| Returns : | TRUEifstreamowns the backend file descriptor orFALSEotherwise. | 
void g_mime_stream_fs_set_owner (GMimeStreamFs *stream,gboolean owner);
Sets whether or not stream owns the backend file descriptor.
Note: owner should be TRUE if the stream should close() the
backend file descriptor when destroyed or FALSE otherwise.
| 
 | a GMimeStreamFs | 
| 
 | TRUEif this stream should own the file descriptor orFALSEotherwise |