Documentation
¶
Index ¶
- Variables
- func AskPassword(prompt string) (string, error)
- func AskYesNo(prompt string) bool
- func ConfigureZstdParams(level, minSizeB, chunkSizeB int)
- func ControlProtocol(base string) string
- func DataProtocol(base string) string
- func DataProtocolZstd(base string) string
- func GetProtocol() string
- func GetUserAgent() string
- func PipeBothWithIdle(a, b io.ReadWriteCloser, idle time.Duration)
- type ZstdDuplex
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrPasswordInterrupted = errors.New("password input interrupted")
ErrPasswordInterrupted returned when password input is interrupted by signal.
Functions ¶
func AskPassword ¶
AskPassword read password with no echo
func ConfigureZstdParams ¶
func ConfigureZstdParams(level, minSizeB, chunkSizeB int)
func ControlProtocol ¶
func DataProtocol ¶
func DataProtocolZstd ¶
func GetProtocol ¶
func GetProtocol() string
func GetUserAgent ¶
func GetUserAgent() string
func PipeBothWithIdle ¶
func PipeBothWithIdle(a, b io.ReadWriteCloser, idle time.Duration)
PipeBothWithIdle copies data in both directions between a and b. It closes both sides when any direction finishes or when idle timeout elapses.
Types ¶
type ZstdDuplex ¶
type ZstdDuplex struct {
// contains filtered or unexported fields
}
func NewZstdDuplex ¶
func NewZstdDuplex(base io.ReadWriteCloser) (*ZstdDuplex, error)
func (*ZstdDuplex) Close ¶
func (z *ZstdDuplex) Close() error
func (*ZstdDuplex) SetInfo ¶
func (z *ZstdDuplex) SetInfo(side, service, peer, protocol string) *ZstdDuplex
Click to show internal directories.
Click to hide internal directories.