GMimeStreamMmap

GMimeStreamMmap — A memory-mapped file stream

Synopsis

                    GMimeStreamMmap;
GMimeStream*        g_mime_stream_mmap_new              (int fd,
                                                         int prot,
                                                         int flags);
GMimeStream*        g_mime_stream_mmap_new_with_bounds  (int fd,
                                                         int prot,
                                                         int flags,
                                                         gint64 start,
                                                         gint64 end);

Object Hierarchy

  GObject
   +----GMimeStream
         +----GMimeStreamMmap

Description

A GMimeStream implementation using a memory-mapped file backing store. This may be faster than GMimeStreamFs or GMimeStreamFile but you'll have to do your own performance checking to be sure for your particular application/platform.

Details

GMimeStreamMmap

typedef struct _GMimeStreamMmap GMimeStreamMmap;

A memory-mapped GMimeStream.


g_mime_stream_mmap_new ()

GMimeStream*        g_mime_stream_mmap_new              (int fd,
                                                         int prot,
                                                         int flags);

Creates a new GMimeStreamMmap object around fd.

fd :

file descriptor

prot :

protection flags

flags :

map flags

Returns :

a stream using fd.

g_mime_stream_mmap_new_with_bounds ()

GMimeStream*        g_mime_stream_mmap_new_with_bounds  (int fd,
                                                         int prot,
                                                         int flags,
                                                         gint64 start,
                                                         gint64 end);

Creates a new GMimeStreamMmap object around fd with bounds start and end.

fd :

file descriptor

prot :

protection flags

flags :

map flags

start :

start boundary

end :

end boundary

Returns :

a stream using fd with bounds start and end.

See Also

GMimeStream