fdpipe

package
v0.0.0-...-522126a Latest Latest
Warning

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

Go to latest
Published: Dec 23, 2019 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Overview

Package fdpipe implements common namedpipe opening and accessing logic.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Open

func Open(ctx context.Context, opener NonBlockingOpener, flags fs.FileFlags) (fs.FileOperations, error)

Open blocks until a host pipe can be opened or the action was cancelled. On success, returns fs.FileOperations wrapping the opened host pipe.

Types

type NonBlockingOpener

type NonBlockingOpener interface {
	// NonBlockingOpen tries to open a host pipe in a non-blocking way,
	// and otherwise returns an error. Implementations should be idempotent.
	NonBlockingOpen(context.Context, fs.PermMask) (*fd.FD, error)
}

NonBlockingOpener is a generic host file opener used to retry opening host pipes if necessary.

Jump to

Keyboard shortcuts

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