filelock

package
v1.10.0 Latest Latest
Warning

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

Go to latest
Published: Sep 10, 2025 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FileLock

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

FileLock provides file-based locking mechanism

func New

func New(path string) *FileLock

New creates a new file lock for the given path

func (*FileLock) Lock

func (f *FileLock) Lock(timeout time.Duration) error

Lock attempts to acquire the lock with timeout

func (*FileLock) Unlock

func (f *FileLock) Unlock() error

Unlock releases the lock

Jump to

Keyboard shortcuts

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