file

package
v0.0.0-...-3279554 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 22, 2018 License: BSD-3-Clause Imports: 8 Imported by: 0

Documentation

Overview

Package file provides an os.File-like interface of a memory mapped file.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Interface

type Interface interface {
	io.ReaderAt
	io.ReaderFrom
	io.WriterAt
	io.WriterTo

	Close() error
	Stat() (os.FileInfo, error)
	Sync() error
	Truncate(int64) error
}

Interface is a os.File-like entity.

func Open

func Open(f *os.File) (Interface, error)

Open returns a new Interface backed by f, or an error, if any.

func OpenMem

func OpenMem(name string) (Interface, error)

OpenMem returns a new Interface, or an error, if any. The Interface content is volatile, it's backed only by process' memory.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL