fs

package
v0.0.0-...-689b5b4 Latest Latest
Warning

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

Go to latest
Published: Sep 3, 2014 License: BSD-3-Clause Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const NOPARENT_ID = 0xFFFFFFFF

Variables

This section is empty.

Functions

func NewDeviceFSRoot

func NewDeviceFSRoot(d *mtp.Device, storages []uint32, options DeviceFsOptions) (nodefs.Node, error)

DeviceFs is a simple filesystem interface to an MTP device. It should be wrapped in a Locking(Raw)FileSystem to make sure it is threadsafe. The file system assumes the device does not touch the storage. Arguments are the opened mtp device and a directory for the backing store.

func SanitizeDosName

func SanitizeDosName(name string) string

func SelectStorages

func SelectStorages(dev *mtp.Device, pat string) ([]uint32, error)

Types

type DeviceFsOptions

type DeviceFsOptions struct {
	// Assume removable volumes are VFAT and munge filenames
	// accordingly.
	RemovableVFat bool

	// Backing directory.
	Dir string

	// Use android extensions if available.
	Android bool
}

Jump to

Keyboard shortcuts

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