Versions in this module Expand all Collapse all v0 v0.2.0 Apr 24, 2026 Changes in this version + func Equal(a, b Value) bool + type MessageInfo struct + Body []byte + BodyLen int + Index int + Offset int64 + TypeID int + func (m MessageInfo) IsTypeDef() bool type Option + func WithSkipCorruptValues(b bool) Option type Schema + func (s *Schema) JSON() ([]byte, error) + func (s *Schema) JSONIndent(prefix, indent string) ([]byte, error) + type Stats struct + ByType []TypeStats + DecodedOpaques int + Skipped int + TotalBodyBytes int64 + TotalMessages int + TypeDefMessages int + UndecodedOpaques int + ValueMessages int + func (s *Stats) Format(w io.Writer) error + func (s *Stats) JSON() ([]byte, error) + func (s *Stats) JSONIndent(prefix, indent string) ([]byte, error) type Stream + func (s *Stream) Messages() iter.Seq2[MessageInfo, error] + func (s *Stream) SkipCount() int + func (s *Stream) Stats() (*Stats, error) type Style + func (st Style) Apply(s string) string + type TypeStats struct + BodyBytes int64 + FieldPresence map[string]int + Kind TypeKind + Name string + TypeID int + ValueCount int v0.1.0 Apr 24, 2026 Changes in this version + var ANSIColorScheme = ColorScheme + var NoColorScheme = ColorScheme + func CompareValues(a, b Value) int + func CompareValuesFold(a, b Value) int + func Format(v Value, opts ...FormatOption) string + func FormatBytes(b []byte, format BytesFormat, maxBytes int) string + func FormatTo(w io.Writer, v Value, opts ...FormatOption) error + func ToJSON(v Value) ([]byte, error) + func ToJSONIndent(v Value, prefix, indent string) ([]byte, error) + func ValueKind(v Value) string + type ArrayValue struct + ElemType string + Elems []Value + GobTypeID int + Len int + TypeName string + func (v ArrayValue) TypeID() int + type BoolValue struct + V bool + func (BoolValue) TypeID() int + type BytesFormat int + const BytesBase64 + const BytesHex + const BytesLiteral + func ParseBytesFormat(s string) (BytesFormat, bool) + type BytesValue struct + V []byte + func (BytesValue) TypeID() int + type ColorScheme struct + Bool Style + Bytes Style + CloseBrace Style + FieldName Style + Nil Style + Number Style + OpaquePrefix Style + OpaqueValue Style + String Style + TypeHeader Style + type ComplexValue struct + Imag float64 + Real float64 + func (ComplexValue) TypeID() int + type DecoderFunc func([]byte) (any, error) + type Field struct + Name string + Value Value + type FieldDecl struct + Annotation string + Name string + Type string + type FieldInfo struct + Name string + TypeID int + type FloatValue struct + V float64 + func (FloatValue) TypeID() int + type FormatOption func(*formatConfig) + func WithBytesFormat(f BytesFormat) FormatOption + func WithColor(scheme ColorScheme) FormatOption + func WithIndent(indent string) FormatOption + func WithInlineWidth(n int) FormatOption + func WithMapOrder(order MapOrder) FormatOption + func WithMaxBytes(n int) FormatOption + func WithRawOpaques(raw bool) FormatOption + func WithRedactKeys(cfg RedactConfig) FormatOption + func WithRedactTypes(cfg RedactTypesConfig) FormatOption + type Inspector struct + func New(opts ...Option) *Inspector + func (ins *Inspector) RegisterDecoder(typeName string, dec DecoderFunc) + func (ins *Inspector) RegisterUnnamedDecoder(dec DecoderFunc) + func (ins *Inspector) Stream(r io.Reader) *Stream + type IntValue struct + V int64 + func (IntValue) TypeID() int + type InterfaceValue struct + TypeName string + Value Value + func (InterfaceValue) TypeID() int + type MapEntry struct + Key Value + Value Value + type MapOrder int + const MapOrderInsertion + const MapOrderSorted + type MapValue struct + ElemType string + Entries []MapEntry + GobTypeID int + KeyType string + TypeName string + func (v MapValue) TypeID() int + type NilValue struct + func (NilValue) TypeID() int + type OpaqueValue struct + Decoded any + Encoding string + GobTypeID int + Raw []byte + TypeName string + func (v OpaqueValue) TypeID() int + type Option func(*Inspector) + func WithReadLimit(n int64) Option + func WithTimeFormat(layout string) Option + type RedactConfig struct + Char rune + Keys []string + TextLength int + type RedactTypesConfig struct + Char rune + TextLength int + Types []string + type Schema struct + Indent string + Types []TypeDecl + func FormatSchema(types []TypeInfo) *Schema + func (s *Schema) Format(opts ...SchemaFormatOption) string + func (s *Schema) FormatTo(w io.Writer, opts ...SchemaFormatOption) error + func (s *Schema) String() string + func (s *Schema) TypeByName(name string) (*TypeDecl, bool) + type SchemaFormatOption func(*formatConfig) + func SchemaWithColor(scheme ColorScheme) SchemaFormatOption + func SchemaWithIndent(indent string) SchemaFormatOption + type SliceValue struct + ElemType string + Elems []Value + GobTypeID int + TypeName string + func (v SliceValue) TypeID() int + type Stream struct + func (s *Stream) Collect() ([]Value, error) + func (s *Stream) Schema() (*Schema, error) + func (s *Stream) TypeByID(id int) (TypeInfo, bool) + func (s *Stream) Types() []TypeInfo + func (s *Stream) Values() iter.Seq2[Value, error] + type StringValue struct + V string + func (StringValue) TypeID() int + type StructValue struct + Fields []Field + GobTypeID int + TypeName string + func (v StructValue) TypeID() int + type Style struct + Prefix string + Suffix string + type TypeDecl struct + Annotation string + Fields []FieldDecl + Kind TypeKind + Name string + TargetType string + type TypeInfo struct + Elem *TypeRef + Fields []FieldInfo + ID int + Key *TypeRef + Kind TypeKind + Len int + Name string + type TypeKind int + const KindArray + const KindBinaryMarshaler + const KindGobEncoder + const KindMap + const KindSlice + const KindStruct + const KindTextMarshaler + func (k TypeKind) String() string + type TypeRef struct + ID int + Name string + type UintValue struct + V uint64 + func (UintValue) TypeID() int + type Value interface + TypeID func() int