🔥码云GVP开源项目 12k star Uniapp+ElementUI 功能强大 支持多语言、二开方便! 广告
# package bzip2 `import "compress/bzip2"` bzip2包实现bzip2的解压缩。 ## Index * [type StructuralError](#StructuralError) * [func (s StructuralError) Error() string](#StructuralError.Error) * [func NewReader(r io.Reader) io.Reader](#NewReader) ## type [StructuralError](https://github.com/golang/go/blob/master/src/compress/bzip2/bzip2.go#L17 "View Source") ``` type StructuralError string ``` 当bzip2数据的语法不合法时,会返回本类型错误。 ### func (StructuralError) [Error](https://github.com/golang/go/blob/master/src/compress/bzip2/bzip2.go#L19 "View Source") ``` func (s StructuralError) Error() string ``` ## func [NewReader](https://github.com/golang/go/blob/master/src/compress/bzip2/bzip2.go#L45 "View Source") ``` func NewReader(r io.Reader) io.Reader ``` NewReader返回一个从r读取bzip2压缩数据并解压缩后返回给调用者的io.Reader。