mongodecimal

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 14, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MongoDecimal

type MongoDecimal struct{}

MongoDecimal 是一个值编解码器,允许十进制编码,将 Decimal128 与 decimal.Decimal 相互转换

func (*MongoDecimal) DecodeValue

func (dc *MongoDecimal) DecodeValue(_ bson.DecodeContext, r bson.ValueReader, value reflect.Value) error

DecodeValue 从 BSON 解码到 decimal.Decimal

func (*MongoDecimal) EncodeValue

func (dc *MongoDecimal) EncodeValue(_ bson.EncodeContext, w bson.ValueWriter, value reflect.Value) error

EncodeValue 从 decimal.Decimal 编码到 BSON

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL