Versions in this module Expand all Collapse all v0 v0.2.0 Aug 6, 2026 Changes in this version type Option + func WithReadUntilIdle(window time.Duration) Option + func WithSinglePacket() Option v0.1.0 Aug 5, 2026 Changes in this version + const DefaultDialTimeout + const DefaultTimeout + var DefaultClient = New() + var ErrAuthFailed = rcon.ErrAuthFailed + var ErrCommandEmpty = rcon.ErrCommandEmpty + var ErrCommandTooLong = rcon.ErrCommandTooLong + func Execute(ctx context.Context, address, password, command string) (string, error) + type BackoffFunc func(attempt int) time.Duration + func ExponentialBackoff(base, max time.Duration) BackoffFunc + type Client struct + func New(opts ...Option) *Client + func (c *Client) Dial(ctx context.Context, address, password string) (*Session, error) + func (c *Client) Execute(ctx context.Context, address, password, command string) (string, error) + type DialFunc func(ctx context.Context, address string) (net.Conn, error) + type Option func(*Client) + func WithDialTimeout(d time.Duration) Option + func WithDialer(d DialFunc) Option + func WithLogger(l *slog.Logger) Option + func WithRetry(attempts int, backoff BackoffFunc) Option + func WithTimeout(d time.Duration) Option + type Session struct + func (s *Session) Close() error + func (s *Session) Execute(ctx context.Context, command string) (string, error)