Documentation ¶
Index ¶
- Constants
- Variables
- func Offset(offset int64) int64
- func ProtFlags(p Prot) (prot int, flags int)
- type File
- func (m *File) Close() error
- func (m *File) Flush() error
- func (m *File) ReadAt(dest []byte, offset int64) (int, error)
- func (m *File) ReadStringAt(dest *strings.Builder, offset int64) (int, error)
- func (m *File) ReadUint64At(offset int64) (uint64, error)
- func (m *File) WriteAt(src []byte, offset int64) (int, error)
- func (m *File) WriteStringAt(src string, offset int64) (int, error)
- func (m *File) WriteUint64At(num uint64, offset int64) error
- type Prot
Constants ¶
View Source
const ( PROT_READ = syscall.PROT_READ PROT_WRITE = syscall.PROT_WRITE PROT_EXEC = syscall.PROT_EXEC MAP_SHARED = syscall.MAP_SHARED MAP_PRIVATE = syscall.MAP_PRIVATE MAP_COPY = MAP_PRIVATE )
Variables ¶
View Source
var ( // ErrUnmappedMemory is returned when a function is called on unmapped memory. ErrUnmappedMemory = errors.New("unmapped memory") // ErrIndexOutOfBound is returned when given offset lies beyond the mapped region. ErrIndexOutOfBound = errors.New("offset out of mapped region") )
Functions ¶
Types ¶
type File ¶
type File struct {
// contains filtered or unexported fields
}
func (*File) ReadStringAt ¶
func (*File) ReadUint64At ¶
ReadUint64At reads uint64 from offset.
Click to show internal directories.
Click to hide internal directories.