util

package
v6.4.0 Latest Latest
Warning

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

Go to latest
Published: May 18, 2020 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Overview

Package util util chain33基础功能函数实现

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckFileExists

func CheckFileExists(fileName string) (bool, error)

CheckFileExists : check file exists or not

func CheckFileIsExist

func CheckFileIsExist(filename string) bool

CheckFileIsExist : check whether the file exists or not

func CheckPathExisted

func CheckPathExisted(path string) bool

CheckPathExisted : check the path exists or not

func CopyFile

func CopyFile(srcFile, dstFile string) (written int64, err error)

CopyFile : copy file

func DeleteFile

func DeleteFile(fileName string) error

DeleteFile : delete the file

func DirEmpty

func DirEmpty(path string) (bool, error)

DirEmpty : DirEmpty

func DirExists

func DirExists(path string) (bool, error)

DirExists : 检查文件夹是否存在

func MakeDir

func MakeDir(path string) error

MakeDir : MakeDir

func OpenFile

func OpenFile(fileName string) (*os.File, error)

OpenFile : OpenFile

func Pwd

func Pwd() string

Pwd : Pwd

func ReadFile

func ReadFile(file string) ([]byte, error)

ReadFile : read file

func WriteStringToFile

func WriteStringToFile(file, content string) (writeLen int, err error)

WriteStringToFile : write content to file

Types

This section is empty.

Jump to

Keyboard shortcuts

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