glib.mapped_file
Module for [MappedFile] class
class MappedFile
Types 1
classMappedFile : gobject.boxed.Boxed
The #GMappedFile represents a file mapping created with glib.mapped_file.MappedFile.new_. It has only private members and should not be accessed directly.
Methods
glib.mapped_file.MappedFile newFromFd(int fd, bool writable) staticMaps a file into memory. On UNIX, this is using the mmap() function.glib.bytes.Bytes getBytes() nothrowCreates a new #GBytes which references the data mapped from file. The mapped contents of the file must not be modified after creating this bytes object, because a #GBytes should be immutable. Retur...size_t getLength() nothrowReturns the length of the contents of a #GMappedFile. Returns: the length of the contents of file.