files

package
v1.74.0 Latest Latest
Warning

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

Go to latest
Published: Feb 20, 2026 License: MIT Imports: 14 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package files implements io/fs objects

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewArchiveFileInfo

func NewArchiveFileInfo(ctx context.Context, entry fs.DirEntry, prefix string, metadata fs.Metadata) archives.FileInfo

NewArchiveFileInfo will take a fs.DirEntry and return a archives.Fileinfo

Types

type CountWriter

type CountWriter struct {
	// contains filtered or unexported fields
}

CountWriter counts bytes written through it. It is safe for concurrent Count/Reset; Write is as safe as the wrapped Writer.

func NewCountWriter

func NewCountWriter(w io.Writer) *CountWriter

NewCountWriter wraps w (use nil if you want to drop data).

func (*CountWriter) Count

func (cw *CountWriter) Count() uint64

Count returns the total bytes written.

func (*CountWriter) Write

func (cw *CountWriter) Write(p []byte) (int, error)

Jump to

Keyboard shortcuts

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