Document every exported symbol and how callers use the library.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-09-29 19:25:43 +02:00
co-authored by Cursor
parent c2cdd85ef1
commit 1bb7abd96b
10 changed files with 842 additions and 81 deletions
+6 -2
View File
@@ -9,13 +9,17 @@ import (
"github.com/miekg/dns"
)
// TransferResult is a completed AXFR plus SOA serial metadata.
// TransferResult is a completed AXFR.
// Serial is the SOA serial and is the same value stored on Zone.
type TransferResult struct {
Zone Zone
Serial uint32
}
// AXFR fetches the full zone over TCP, signed with the session TSIG key.
// AXFR reads the full zone over TCP, signed with the session TSIG key.
// It returns an error when ctx is done, the transfer fails, a record owner
// is not ASCII, or the stream contains no SOA.
// The closing SOA of the transfer is not appended again.
func (c *Client) AXFR(ctx context.Context) (*TransferResult, error) {
if err := ctx.Err(); err != nil {
return nil, err