// Generated by Lisette bindgen
// Source: net/rpc/jsonrpc (Go stdlib)
// Go: 1.25.5
// Lisette: 0.1.14

import "go:io"
import "go:net/rpc"

/// Dial connects to a JSON-RPC server at the specified network address.
pub fn Dial(network: string, address: string) -> Result<Ref<rpc.Client>, error>

/// NewClient returns a new [rpc.Client] to handle requests to the
/// set of services at the other end of the connection.
pub fn NewClient(conn: io.ReadWriteCloser) -> Ref<rpc.Client>

/// NewClientCodec returns a new [rpc.ClientCodec] using JSON-RPC on conn.
pub fn NewClientCodec(conn: io.ReadWriteCloser) -> rpc.ClientCodec

/// NewServerCodec returns a new [rpc.ServerCodec] using JSON-RPC on conn.
pub fn NewServerCodec(conn: io.ReadWriteCloser) -> rpc.ServerCodec

/// ServeConn runs the JSON-RPC server on a single connection.
/// ServeConn blocks, serving the connection until the client hangs up.
/// The caller typically invokes ServeConn in a go statement.
pub fn ServeConn(conn: io.ReadWriteCloser)
