action

package
v0.8.2 Latest Latest
Warning

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

Go to latest
Published: Feb 28, 2024 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Action

type Action int

Action the action of file change

const (
	// UnknownAction the unknown file operation
	UnknownAction Action = iota
	// CreateAction the action of create a file
	CreateAction
	// WriteAction the action of write data to the file
	WriteAction
	// RemoveAction the action of remove the file
	RemoveAction
	// RenameAction the action of rename the file
	RenameAction
	// ChmodAction the action of change the file mode
	ChmodAction
	// SymlinkAction the action of create a symbolic link
	SymlinkAction
)

func ParseAction

func ParseAction(action int) Action

ParseAction parse the int value to Action

func ParseActionFromString

func ParseActionFromString(action string) Action

ParseActionFromString parse the string value to Action

func (Action) Int

func (action Action) Int() int

Int return the int value of Action

func (Action) String

func (action Action) String() string

String return the action description name

func (Action) Valid

func (action Action) Valid() Action

Valid if the current Action is an invalid int value, return the UnknownAction

Jump to

Keyboard shortcuts

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