Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Unzip_InputTypeErr = "input必须是一个文件"
View Source
var Unzip_InputZipErr = "input不是zip文件或文件已经损坏"
View Source
var Unzip_MakeDirErr = "创建文件夹失败"
View Source
var Zip_FileModeErr = "文件的filemod不一致"
Functions ¶
func Zip ¶
func Zip(files []*ZipFileStruct, out string) error
Types ¶
type ZipFileStruct ¶
type ZipFileStruct struct { FilePath string //需要压缩的文件地址 ZipPath string //zip文件的地址 FileMode os.FileMode //文件类型 ModTime time.Time // StreamTransform func(string) (io.ReadCloser, error) //转换读写流 }
func (*ZipFileStruct) Reader ¶
func (zfs *ZipFileStruct) Reader() (io.ReadCloser, error)
Click to show internal directories.
Click to hide internal directories.