Documentation ¶
Index ¶
- type Bson
- type BsonArray
- type BsonBinary
- type BsonBoolean
- type BsonDBPointer
- type BsonDateTime
- type BsonDecimal128
- type BsonDocument
- func (d *BsonDocument) Append(key string, value IBsonValue) *BsonDocument
- func (d *BsonDocument) AsDocument() *BsonDocument
- func (d *BsonDocument) BsonDocument() *BsonDocument
- func (d *BsonDocument) ContainsKey(key string) bool
- func (d *BsonDocument) ContainsValue(val any) bool
- func (d *BsonDocument) Data() D
- func (d *BsonDocument) Document() bson.D
- func (d *BsonDocument) Exp() IBsonValue
- func (d *BsonDocument) Get() any
- func (d *BsonDocument) GetArray(key string) *BsonArray
- func (d *BsonDocument) GetBinary(key string) *BsonBinary
- func (d *BsonDocument) GetBoolean(key string) *BsonBoolean
- func (d *BsonDocument) GetBsonArray(key string, defaultValue BsonArray) *BsonArray
- func (d *BsonDocument) GetBsonBinary(key string, defaultValue BsonBinary) *BsonBinary
- func (d *BsonDocument) GetBsonBoolean(key string, defaultValue BsonBoolean) *BsonBoolean
- func (d *BsonDocument) GetBsonDateTime(key string, defaultValue BsonDateTime) *BsonDateTime
- func (d *BsonDocument) GetBsonDecimal128(key string, defaultValue BsonDecimal128) *BsonDecimal128
- func (d *BsonDocument) GetBsonDocument(key string, defaultValue BsonDocument) *BsonDocument
- func (d *BsonDocument) GetBsonDouble(key string, defaultValue BsonDouble) *BsonDouble
- func (d *BsonDocument) GetBsonInt32(key string, defaultValue BsonInt32) *BsonInt32
- func (d *BsonDocument) GetBsonInt64(key string, defaultValue BsonInt64) *BsonInt64
- func (d *BsonDocument) GetBsonNumber(key string, defaultValue BsonNumber) IBsonNumber
- func (d *BsonDocument) GetBsonObjectId(key string, defaultValue BsonObjectId) *BsonObjectId
- func (d *BsonDocument) GetBsonRegularExpression(key string, defaultValue BsonRegularExpression) *BsonRegularExpression
- func (d *BsonDocument) GetBsonString(key string, defaultValue BsonString) *BsonString
- func (d *BsonDocument) GetBsonTimestamp(key string, defaultValue BsonTimestamp) *BsonTimestamp
- func (d *BsonDocument) GetBsonType() BsonType
- func (d *BsonDocument) GetDateTime(key string) *BsonDateTime
- func (d *BsonDocument) GetDecimal128(key string) *BsonDecimal128
- func (d *BsonDocument) GetDocument(key string) *BsonDocument
- func (d *BsonDocument) GetDouble(key string) *BsonDouble
- func (d *BsonDocument) GetInt32(key string) *BsonInt32
- func (d *BsonDocument) GetInt64(key string) *BsonInt64
- func (d *BsonDocument) GetNumber(key string) IBsonNumber
- func (d *BsonDocument) GetObjectId(key string) *BsonObjectId
- func (d *BsonDocument) GetRegularExpression(key string) *BsonRegularExpression
- func (d *BsonDocument) GetString(key string) *BsonString
- func (d *BsonDocument) GetTimestamp(key string) *BsonTimestamp
- func (d *BsonDocument) GetValue(key string) IBsonValue
- func (d *BsonDocument) IsBsonArray(key string) bool
- func (d *BsonDocument) IsBsonBinary(key string) bool
- func (d *BsonDocument) IsBsonBoolean(key string) bool
- func (d *BsonDocument) IsBsonDateTime(key string) bool
- func (d *BsonDocument) IsBsonDecimal128(key string) bool
- func (d *BsonDocument) IsBsonDocument(key string) bool
- func (d *BsonDocument) IsBsonDouble(key string) bool
- func (d *BsonDocument) IsBsonInt32(key string) bool
- func (d *BsonDocument) IsBsonInt64(key string) bool
- func (d *BsonDocument) IsBsonNull(key string) bool
- func (d *BsonDocument) IsBsonNumber(key string) bool
- func (d *BsonDocument) IsBsonObjectId(key string) bool
- func (d *BsonDocument) IsBsonString(key string) bool
- func (d *BsonDocument) IsBsonTimestamp(key string) bool
- func (d *BsonDocument) IsDocument() bool
- func (d *BsonDocument) IsEmpty() bool
- func (d *BsonDocument) Keys() []string
- func (d *BsonDocument) Remove(key string) *BsonDocument
- func (d *BsonDocument) Size() int
- type BsonDouble
- func (a *BsonDouble) AsDouble() *BsonDouble
- func (a *BsonDouble) AsNumber() IBsonNumber
- func (a *BsonDouble) BigIntValue() *big.Int
- func (a *BsonDouble) Exp() IBsonValue
- func (a *BsonDouble) Float64Value() float64
- func (a *BsonDouble) Get() any
- func (a *BsonDouble) GetBsonType() BsonType
- func (a *BsonDouble) Int32Value() int32
- func (a *BsonDouble) Int64Value() int64
- func (a *BsonDouble) IsDouble() bool
- func (a *BsonDouble) IsNumber() bool
- type BsonField
- type BsonInt32
- func (a *BsonInt32) AsInt32() *BsonInt32
- func (a *BsonInt32) AsNumber() IBsonNumber
- func (a *BsonInt32) Exp() IBsonValue
- func (a *BsonInt32) Float64Value() float64
- func (a *BsonInt32) Get() any
- func (a *BsonInt32) GetBsonType() BsonType
- func (a *BsonInt32) Int32Value() int32
- func (a *BsonInt32) Int64Value() int64
- func (a *BsonInt32) IsInt32() bool
- func (a *BsonInt32) IsNumber() bool
- type BsonInt64
- func (a *BsonInt64) AsInt64() *BsonInt64
- func (a *BsonInt64) AsNumber() IBsonNumber
- func (a *BsonInt64) Exp() IBsonValue
- func (a *BsonInt64) Float64Value() float64
- func (a *BsonInt64) Get() any
- func (a *BsonInt64) GetBsonType() BsonType
- func (a *BsonInt64) Int32Value() int32
- func (a *BsonInt64) Int64Value() int64
- func (a *BsonInt64) IsInt64() bool
- func (a *BsonInt64) IsNumber() bool
- type BsonJavaScript
- type BsonJavaScriptWithScope
- type BsonMaxKey
- type BsonMinKey
- type BsonNull
- type BsonNumber
- type BsonObjectId
- type BsonRegularExpression
- type BsonString
- type BsonSymbol
- type BsonTimestamp
- type BsonType
- type BsonUndefined
- type BsonValue
- func (v *BsonValue) AsArray() *BsonArray
- func (v *BsonValue) AsBinary() *BsonBinary
- func (v *BsonValue) AsBoolean() *BsonBoolean
- func (v *BsonValue) AsDBPointer() *BsonDBPointer
- func (v *BsonValue) AsDateTime() *BsonDateTime
- func (v *BsonValue) AsDecimal128() *BsonDecimal128
- func (v *BsonValue) AsDocument() *BsonDocument
- func (v *BsonValue) AsDouble() *BsonDouble
- func (v *BsonValue) AsInt32() *BsonInt32
- func (v *BsonValue) AsInt64() *BsonInt64
- func (v *BsonValue) AsJavaScript() *BsonJavaScript
- func (v *BsonValue) AsJavaScriptWithScope() *BsonJavaScriptWithScope
- func (v *BsonValue) AsNumber() IBsonNumber
- func (v *BsonValue) AsObjectId() *BsonObjectId
- func (v *BsonValue) AsRegularExpression() *BsonRegularExpression
- func (v *BsonValue) AsString() *BsonString
- func (v *BsonValue) AsSymbol() *BsonSymbol
- func (v *BsonValue) AsTimestamp() *BsonTimestamp
- func (v *BsonValue) Get() any
- func (v *BsonValue) GetBsonType() BsonType
- func (v *BsonValue) IsArray() bool
- func (v *BsonValue) IsBinary() bool
- func (v *BsonValue) IsBoolean() bool
- func (v *BsonValue) IsDBPointer() bool
- func (v *BsonValue) IsDateTime() bool
- func (v *BsonValue) IsDecimal128() bool
- func (v *BsonValue) IsDocument() bool
- func (v *BsonValue) IsDouble() bool
- func (v *BsonValue) IsInt32() bool
- func (v *BsonValue) IsInt64() bool
- func (v *BsonValue) IsJavaScript() bool
- func (v *BsonValue) IsJavaScriptWithScope() bool
- func (v *BsonValue) IsNull() bool
- func (v *BsonValue) IsNumber() bool
- func (v *BsonValue) IsObjectId() bool
- func (v *BsonValue) IsRegularExpression() bool
- func (v *BsonValue) IsString() bool
- func (v *BsonValue) IsSymbol() bool
- func (v *BsonValue) IsTimestamp() bool
- type D
- type Document
- type E
- type IBsonNumber
- type IBsonValue
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Bson ¶
type Bson interface { BsonDocument() *BsonDocument Document() bson.D }
type BsonArray ¶
type BsonArray struct { BsonValue // contains filtered or unexported fields }
func Array ¶
func Array(values ...IBsonValue) *BsonArray
func (*BsonArray) Append ¶
func (a *BsonArray) Append(value IBsonValue) *BsonArray
func (*BsonArray) Exp ¶
func (a *BsonArray) Exp() IBsonValue
func (*BsonArray) GetBsonType ¶
type BsonBinary ¶
type BsonBinary struct { BsonValue // contains filtered or unexported fields }
func Binary ¶
func Binary(data primitive.Binary) *BsonBinary
func (*BsonBinary) AsBinary ¶
func (a *BsonBinary) AsBinary() *BsonBinary
func (*BsonBinary) Exp ¶
func (a *BsonBinary) Exp() IBsonValue
func (*BsonBinary) Get ¶
func (a *BsonBinary) Get() any
func (*BsonBinary) GetBsonType ¶
func (a *BsonBinary) GetBsonType() BsonType
func (*BsonBinary) IsBinary ¶
func (a *BsonBinary) IsBinary() bool
type BsonBoolean ¶
type BsonBoolean struct { BsonValue // contains filtered or unexported fields }
func Boolean ¶
func Boolean(v bool) *BsonBoolean
func (*BsonBoolean) AsBoolean ¶
func (a *BsonBoolean) AsBoolean() *BsonBoolean
func (*BsonBoolean) Exp ¶
func (a *BsonBoolean) Exp() IBsonValue
func (*BsonBoolean) Get ¶
func (a *BsonBoolean) Get() any
func (*BsonBoolean) GetBsonType ¶
func (a *BsonBoolean) GetBsonType() BsonType
func (*BsonBoolean) IsBoolean ¶
func (a *BsonBoolean) IsBoolean() bool
type BsonDBPointer ¶
type BsonDBPointer struct { BsonValue // contains filtered or unexported fields }
func DbPointer ¶
func DbPointer(data primitive.DBPointer) *BsonDBPointer
func (*BsonDBPointer) AsDBPointer ¶
func (a *BsonDBPointer) AsDBPointer() *BsonDBPointer
func (*BsonDBPointer) Exp ¶
func (a *BsonDBPointer) Exp() IBsonValue
func (*BsonDBPointer) Get ¶
func (a *BsonDBPointer) Get() any
func (*BsonDBPointer) GetBsonType ¶
func (a *BsonDBPointer) GetBsonType() BsonType
func (*BsonDBPointer) IsDBPointer ¶
func (a *BsonDBPointer) IsDBPointer() bool
type BsonDateTime ¶
type BsonDateTime struct { BsonValue // contains filtered or unexported fields }
func DateTime ¶
func DateTime(data primitive.DateTime) *BsonDateTime
func (*BsonDateTime) AsDateTime ¶
func (a *BsonDateTime) AsDateTime() *BsonDateTime
func (*BsonDateTime) Exp ¶
func (a *BsonDateTime) Exp() IBsonValue
func (*BsonDateTime) Get ¶
func (a *BsonDateTime) Get() any
func (*BsonDateTime) GetBsonType ¶
func (a *BsonDateTime) GetBsonType() BsonType
func (*BsonDateTime) IsDateTime ¶
func (a *BsonDateTime) IsDateTime() bool
type BsonDecimal128 ¶
type BsonDecimal128 struct { BsonValue // contains filtered or unexported fields }
func Decimal128 ¶
func Decimal128(data primitive.Decimal128) *BsonDecimal128
func (*BsonDecimal128) AsDecimal128 ¶
func (a *BsonDecimal128) AsDecimal128() *BsonDecimal128
func (*BsonDecimal128) Exp ¶
func (a *BsonDecimal128) Exp() IBsonValue
func (*BsonDecimal128) Get ¶
func (a *BsonDecimal128) Get() any
func (*BsonDecimal128) GetBsonType ¶
func (a *BsonDecimal128) GetBsonType() BsonType
func (*BsonDecimal128) IsDecimal128 ¶
func (a *BsonDecimal128) IsDecimal128() bool
type BsonDocument ¶
type BsonDocument struct { BsonValue // contains filtered or unexported fields }
func BsonDoc ¶
func BsonDoc(key string, value IBsonValue) *BsonDocument
func BsonEmpty ¶
func BsonEmpty() *BsonDocument
func NewMerged ¶
func NewMerged(base, appended *BsonDocument) *BsonDocument
func (*BsonDocument) Append ¶
func (d *BsonDocument) Append(key string, value IBsonValue) *BsonDocument
func (*BsonDocument) AsDocument ¶
func (d *BsonDocument) AsDocument() *BsonDocument
func (*BsonDocument) BsonDocument ¶
func (d *BsonDocument) BsonDocument() *BsonDocument
func (*BsonDocument) ContainsKey ¶
func (d *BsonDocument) ContainsKey(key string) bool
func (*BsonDocument) ContainsValue ¶
func (d *BsonDocument) ContainsValue(val any) bool
func (*BsonDocument) Data ¶
func (d *BsonDocument) Data() D
func (*BsonDocument) Document ¶
func (d *BsonDocument) Document() bson.D
func (*BsonDocument) Exp ¶
func (d *BsonDocument) Exp() IBsonValue
func (*BsonDocument) Get ¶
func (d *BsonDocument) Get() any
func (*BsonDocument) GetArray ¶
func (d *BsonDocument) GetArray(key string) *BsonArray
func (*BsonDocument) GetBinary ¶
func (d *BsonDocument) GetBinary(key string) *BsonBinary
func (*BsonDocument) GetBoolean ¶
func (d *BsonDocument) GetBoolean(key string) *BsonBoolean
func (*BsonDocument) GetBsonArray ¶
func (d *BsonDocument) GetBsonArray(key string, defaultValue BsonArray) *BsonArray
func (*BsonDocument) GetBsonBinary ¶
func (d *BsonDocument) GetBsonBinary(key string, defaultValue BsonBinary) *BsonBinary
func (*BsonDocument) GetBsonBoolean ¶
func (d *BsonDocument) GetBsonBoolean(key string, defaultValue BsonBoolean) *BsonBoolean
func (*BsonDocument) GetBsonDateTime ¶
func (d *BsonDocument) GetBsonDateTime(key string, defaultValue BsonDateTime) *BsonDateTime
func (*BsonDocument) GetBsonDecimal128 ¶
func (d *BsonDocument) GetBsonDecimal128(key string, defaultValue BsonDecimal128) *BsonDecimal128
func (*BsonDocument) GetBsonDocument ¶
func (d *BsonDocument) GetBsonDocument(key string, defaultValue BsonDocument) *BsonDocument
func (*BsonDocument) GetBsonDouble ¶
func (d *BsonDocument) GetBsonDouble(key string, defaultValue BsonDouble) *BsonDouble
func (*BsonDocument) GetBsonInt32 ¶
func (d *BsonDocument) GetBsonInt32(key string, defaultValue BsonInt32) *BsonInt32
func (*BsonDocument) GetBsonInt64 ¶
func (d *BsonDocument) GetBsonInt64(key string, defaultValue BsonInt64) *BsonInt64
func (*BsonDocument) GetBsonNumber ¶
func (d *BsonDocument) GetBsonNumber(key string, defaultValue BsonNumber) IBsonNumber
func (*BsonDocument) GetBsonObjectId ¶
func (d *BsonDocument) GetBsonObjectId(key string, defaultValue BsonObjectId) *BsonObjectId
func (*BsonDocument) GetBsonRegularExpression ¶
func (d *BsonDocument) GetBsonRegularExpression(key string, defaultValue BsonRegularExpression) *BsonRegularExpression
func (*BsonDocument) GetBsonString ¶
func (d *BsonDocument) GetBsonString(key string, defaultValue BsonString) *BsonString
func (*BsonDocument) GetBsonTimestamp ¶
func (d *BsonDocument) GetBsonTimestamp(key string, defaultValue BsonTimestamp) *BsonTimestamp
func (*BsonDocument) GetBsonType ¶
func (d *BsonDocument) GetBsonType() BsonType
func (*BsonDocument) GetDateTime ¶
func (d *BsonDocument) GetDateTime(key string) *BsonDateTime
func (*BsonDocument) GetDecimal128 ¶
func (d *BsonDocument) GetDecimal128(key string) *BsonDecimal128
func (*BsonDocument) GetDocument ¶
func (d *BsonDocument) GetDocument(key string) *BsonDocument
func (*BsonDocument) GetDouble ¶
func (d *BsonDocument) GetDouble(key string) *BsonDouble
func (*BsonDocument) GetInt32 ¶
func (d *BsonDocument) GetInt32(key string) *BsonInt32
func (*BsonDocument) GetInt64 ¶
func (d *BsonDocument) GetInt64(key string) *BsonInt64
func (*BsonDocument) GetNumber ¶
func (d *BsonDocument) GetNumber(key string) IBsonNumber
func (*BsonDocument) GetObjectId ¶
func (d *BsonDocument) GetObjectId(key string) *BsonObjectId
func (*BsonDocument) GetRegularExpression ¶
func (d *BsonDocument) GetRegularExpression(key string) *BsonRegularExpression
func (*BsonDocument) GetString ¶
func (d *BsonDocument) GetString(key string) *BsonString
func (*BsonDocument) GetTimestamp ¶
func (d *BsonDocument) GetTimestamp(key string) *BsonTimestamp
func (*BsonDocument) GetValue ¶
func (d *BsonDocument) GetValue(key string) IBsonValue
func (*BsonDocument) IsBsonArray ¶
func (d *BsonDocument) IsBsonArray(key string) bool
func (*BsonDocument) IsBsonBinary ¶
func (d *BsonDocument) IsBsonBinary(key string) bool
func (*BsonDocument) IsBsonBoolean ¶
func (d *BsonDocument) IsBsonBoolean(key string) bool
func (*BsonDocument) IsBsonDateTime ¶
func (d *BsonDocument) IsBsonDateTime(key string) bool
func (*BsonDocument) IsBsonDecimal128 ¶
func (d *BsonDocument) IsBsonDecimal128(key string) bool
func (*BsonDocument) IsBsonDocument ¶
func (d *BsonDocument) IsBsonDocument(key string) bool
func (*BsonDocument) IsBsonDouble ¶
func (d *BsonDocument) IsBsonDouble(key string) bool
func (*BsonDocument) IsBsonInt32 ¶
func (d *BsonDocument) IsBsonInt32(key string) bool
func (*BsonDocument) IsBsonInt64 ¶
func (d *BsonDocument) IsBsonInt64(key string) bool
func (*BsonDocument) IsBsonNull ¶
func (d *BsonDocument) IsBsonNull(key string) bool
func (*BsonDocument) IsBsonNumber ¶
func (d *BsonDocument) IsBsonNumber(key string) bool
func (*BsonDocument) IsBsonObjectId ¶
func (d *BsonDocument) IsBsonObjectId(key string) bool
func (*BsonDocument) IsBsonString ¶
func (d *BsonDocument) IsBsonString(key string) bool
func (*BsonDocument) IsBsonTimestamp ¶
func (d *BsonDocument) IsBsonTimestamp(key string) bool
func (*BsonDocument) IsDocument ¶
func (d *BsonDocument) IsDocument() bool
func (*BsonDocument) IsEmpty ¶
func (d *BsonDocument) IsEmpty() bool
func (*BsonDocument) Keys ¶
func (d *BsonDocument) Keys() []string
func (*BsonDocument) Remove ¶
func (d *BsonDocument) Remove(key string) *BsonDocument
func (*BsonDocument) Size ¶
func (d *BsonDocument) Size() int
type BsonDouble ¶
type BsonDouble struct { BsonNumber // contains filtered or unexported fields }
func Double ¶
func Double(data float64) *BsonDouble
func (*BsonDouble) AsDouble ¶
func (a *BsonDouble) AsDouble() *BsonDouble
func (*BsonDouble) AsNumber ¶
func (a *BsonDouble) AsNumber() IBsonNumber
func (*BsonDouble) BigIntValue ¶
func (a *BsonDouble) BigIntValue() *big.Int
func (*BsonDouble) Exp ¶
func (a *BsonDouble) Exp() IBsonValue
func (*BsonDouble) Float64Value ¶
func (a *BsonDouble) Float64Value() float64
func (*BsonDouble) Get ¶
func (a *BsonDouble) Get() any
func (*BsonDouble) GetBsonType ¶
func (a *BsonDouble) GetBsonType() BsonType
func (*BsonDouble) Int32Value ¶
func (a *BsonDouble) Int32Value() int32
func (*BsonDouble) Int64Value ¶
func (a *BsonDouble) Int64Value() int64
func (*BsonDouble) IsDouble ¶
func (a *BsonDouble) IsDouble() bool
func (*BsonDouble) IsNumber ¶
func (a *BsonDouble) IsNumber() bool
type BsonField ¶
type BsonField struct {
// contains filtered or unexported fields
}
func NewBsonField ¶
type BsonInt32 ¶
type BsonInt32 struct { BsonValue // contains filtered or unexported fields }
func (*BsonInt32) AsNumber ¶
func (a *BsonInt32) AsNumber() IBsonNumber
func (*BsonInt32) Exp ¶
func (a *BsonInt32) Exp() IBsonValue
func (*BsonInt32) Float64Value ¶
func (*BsonInt32) GetBsonType ¶
func (*BsonInt32) Int32Value ¶
func (*BsonInt32) Int64Value ¶
type BsonInt64 ¶
type BsonInt64 struct { BsonValue // contains filtered or unexported fields }
func (*BsonInt64) AsNumber ¶
func (a *BsonInt64) AsNumber() IBsonNumber
func (*BsonInt64) Exp ¶
func (a *BsonInt64) Exp() IBsonValue
func (*BsonInt64) Float64Value ¶
func (*BsonInt64) GetBsonType ¶
func (*BsonInt64) Int32Value ¶
func (*BsonInt64) Int64Value ¶
type BsonJavaScript ¶
type BsonJavaScript struct { BsonValue // contains filtered or unexported fields }
func JavaScript ¶
func JavaScript(data primitive.JavaScript) *BsonJavaScript
func (*BsonJavaScript) AsJavaScript ¶
func (a *BsonJavaScript) AsJavaScript() *BsonJavaScript
func (*BsonJavaScript) Exp ¶
func (a *BsonJavaScript) Exp() IBsonValue
func (*BsonJavaScript) Get ¶
func (a *BsonJavaScript) Get() any
func (*BsonJavaScript) GetBsonType ¶
func (a *BsonJavaScript) GetBsonType() BsonType
func (*BsonJavaScript) IsJavaScript ¶
func (a *BsonJavaScript) IsJavaScript() bool
type BsonJavaScriptWithScope ¶
type BsonJavaScriptWithScope struct { BsonValue // contains filtered or unexported fields }
func JavaScriptWithScope ¶
func JavaScriptWithScope(data primitive.CodeWithScope) *BsonJavaScriptWithScope
func (*BsonJavaScriptWithScope) AsJavaScriptWithScope ¶
func (a *BsonJavaScriptWithScope) AsJavaScriptWithScope() *BsonJavaScriptWithScope
func (*BsonJavaScriptWithScope) Exp ¶
func (a *BsonJavaScriptWithScope) Exp() IBsonValue
func (*BsonJavaScriptWithScope) Get ¶
func (a *BsonJavaScriptWithScope) Get() any
func (*BsonJavaScriptWithScope) GetBsonType ¶
func (a *BsonJavaScriptWithScope) GetBsonType() BsonType
func (*BsonJavaScriptWithScope) IsJavaScriptWithScope ¶
func (a *BsonJavaScriptWithScope) IsJavaScriptWithScope() bool
type BsonMaxKey ¶
type BsonMaxKey struct { BsonValue // contains filtered or unexported fields }
func (*BsonMaxKey) Exp ¶
func (a *BsonMaxKey) Exp() IBsonValue
func (*BsonMaxKey) Get ¶
func (a *BsonMaxKey) Get() any
func (*BsonMaxKey) GetBsonType ¶
func (a *BsonMaxKey) GetBsonType() BsonType
type BsonMinKey ¶
type BsonMinKey struct { BsonValue // contains filtered or unexported fields }
func (*BsonMinKey) Exp ¶
func (a *BsonMinKey) Exp() IBsonValue
func (*BsonMinKey) Get ¶
func (a *BsonMinKey) Get() any
func (*BsonMinKey) GetBsonType ¶
func (a *BsonMinKey) GetBsonType() BsonType
type BsonNull ¶
type BsonNull struct { BsonValue // contains filtered or unexported fields }
func (*BsonNull) Exp ¶
func (a *BsonNull) Exp() IBsonValue
func (*BsonNull) GetBsonType ¶
type BsonNumber ¶
type BsonNumber struct {
BsonValue
}
func (*BsonNumber) Float64Value ¶
func (a *BsonNumber) Float64Value() float64
func (*BsonNumber) Int32Value ¶
func (a *BsonNumber) Int32Value() int32
func (*BsonNumber) Int64Value ¶
func (a *BsonNumber) Int64Value() int64
type BsonObjectId ¶
type BsonObjectId struct { BsonValue // contains filtered or unexported fields }
func ObjectId ¶
func ObjectId(data primitive.ObjectID) *BsonObjectId
func (*BsonObjectId) AsObjectId ¶
func (a *BsonObjectId) AsObjectId() *BsonObjectId
func (*BsonObjectId) Exp ¶
func (a *BsonObjectId) Exp() IBsonValue
func (*BsonObjectId) Get ¶
func (a *BsonObjectId) Get() any
func (*BsonObjectId) GetBsonType ¶
func (a *BsonObjectId) GetBsonType() BsonType
func (*BsonObjectId) IsObjectId ¶
func (a *BsonObjectId) IsObjectId() bool
type BsonRegularExpression ¶
type BsonRegularExpression struct { BsonValue // contains filtered or unexported fields }
func RegularExpression ¶
func RegularExpression(data primitive.Regex) *BsonRegularExpression
func (*BsonRegularExpression) AsRegularExpression ¶
func (a *BsonRegularExpression) AsRegularExpression() *BsonRegularExpression
func (*BsonRegularExpression) Exp ¶
func (a *BsonRegularExpression) Exp() IBsonValue
func (*BsonRegularExpression) Get ¶
func (a *BsonRegularExpression) Get() any
func (*BsonRegularExpression) GetBsonType ¶
func (a *BsonRegularExpression) GetBsonType() BsonType
func (*BsonRegularExpression) IsRegularExpression ¶
func (a *BsonRegularExpression) IsRegularExpression() bool
type BsonString ¶
type BsonString struct { BsonValue // contains filtered or unexported fields }
func String ¶
func String(data string) *BsonString
func (*BsonString) AsString ¶
func (a *BsonString) AsString() *BsonString
func (*BsonString) Exp ¶
func (a *BsonString) Exp() IBsonValue
func (*BsonString) Get ¶
func (a *BsonString) Get() any
func (*BsonString) GetBsonType ¶
func (a *BsonString) GetBsonType() BsonType
func (*BsonString) IsEmpty ¶
func (a *BsonString) IsEmpty() bool
func (*BsonString) IsString ¶
func (a *BsonString) IsString() bool
type BsonSymbol ¶
type BsonSymbol struct { BsonValue // contains filtered or unexported fields }
func Symbol ¶
func Symbol(data primitive.Symbol) *BsonSymbol
func (*BsonSymbol) AsSymbol ¶
func (a *BsonSymbol) AsSymbol() *BsonSymbol
func (*BsonSymbol) Exp ¶
func (a *BsonSymbol) Exp() IBsonValue
func (*BsonSymbol) Get ¶
func (a *BsonSymbol) Get() any
func (*BsonSymbol) GetBsonType ¶
func (a *BsonSymbol) GetBsonType() BsonType
func (*BsonSymbol) IsSymbol ¶
func (a *BsonSymbol) IsSymbol() bool
type BsonTimestamp ¶
type BsonTimestamp struct { BsonValue // contains filtered or unexported fields }
func Timestamp ¶
func Timestamp() *BsonTimestamp
func (*BsonTimestamp) AsTimestamp ¶
func (a *BsonTimestamp) AsTimestamp() *BsonTimestamp
func (*BsonTimestamp) Exp ¶
func (a *BsonTimestamp) Exp() IBsonValue
func (*BsonTimestamp) Get ¶
func (a *BsonTimestamp) Get() any
func (*BsonTimestamp) GetBsonType ¶
func (a *BsonTimestamp) GetBsonType() BsonType
func (*BsonTimestamp) IsTimestamp ¶
func (a *BsonTimestamp) IsTimestamp() bool
type BsonType ¶
type BsonType uint8
const ( END_OF_DOCUMENT BsonType = 0x00 DOUBLE BsonType = 0x01 STRING BsonType = 0x02 DOCUMENT BsonType = 0x03 ARRAY BsonType = 0x04 BINARY BsonType = 0x05 UNDEFINED BsonType = 0x06 OBJECT_ID BsonType = 0x07 BOOLEAN BsonType = 0x08 DATE_TIME BsonType = 0x09 NULL BsonType = 0x0a REGULAR_EXPRESSION BsonType = 0x0b DB_POINTER BsonType = 0x0c JAVASCRIPT BsonType = 0x0d SYMBOL BsonType = 0x0e JAVASCRIPT_WITH_SCOPE BsonType = 0x0f INT32 BsonType = 0x10 TIMESTAMP BsonType = 0x11 INT64 BsonType = 0x12 DECIMAL128 BsonType = 0x13 MIN_KEY BsonType = 0xff MAX_KEY BsonType = 0x7f )
type BsonUndefined ¶
type BsonUndefined struct { BsonValue // contains filtered or unexported fields }
func Undefined ¶
func Undefined() *BsonUndefined
func (*BsonUndefined) Exp ¶
func (a *BsonUndefined) Exp() IBsonValue
func (*BsonUndefined) Get ¶
func (a *BsonUndefined) Get() any
func (*BsonUndefined) GetBsonType ¶
func (a *BsonUndefined) GetBsonType() BsonType
type BsonValue ¶
type BsonValue struct { }
func (*BsonValue) AsBinary ¶
func (v *BsonValue) AsBinary() *BsonBinary
func (*BsonValue) AsBoolean ¶
func (v *BsonValue) AsBoolean() *BsonBoolean
func (*BsonValue) AsDBPointer ¶
func (v *BsonValue) AsDBPointer() *BsonDBPointer
func (*BsonValue) AsDateTime ¶
func (v *BsonValue) AsDateTime() *BsonDateTime
func (*BsonValue) AsDecimal128 ¶
func (v *BsonValue) AsDecimal128() *BsonDecimal128
func (*BsonValue) AsDocument ¶
func (v *BsonValue) AsDocument() *BsonDocument
func (*BsonValue) AsDouble ¶
func (v *BsonValue) AsDouble() *BsonDouble
func (*BsonValue) AsJavaScript ¶
func (v *BsonValue) AsJavaScript() *BsonJavaScript
func (*BsonValue) AsJavaScriptWithScope ¶
func (v *BsonValue) AsJavaScriptWithScope() *BsonJavaScriptWithScope
func (*BsonValue) AsNumber ¶
func (v *BsonValue) AsNumber() IBsonNumber
func (*BsonValue) AsObjectId ¶
func (v *BsonValue) AsObjectId() *BsonObjectId
func (*BsonValue) AsRegularExpression ¶
func (v *BsonValue) AsRegularExpression() *BsonRegularExpression
func (*BsonValue) AsString ¶
func (v *BsonValue) AsString() *BsonString
func (*BsonValue) AsSymbol ¶
func (v *BsonValue) AsSymbol() *BsonSymbol
func (*BsonValue) AsTimestamp ¶
func (v *BsonValue) AsTimestamp() *BsonTimestamp
func (*BsonValue) GetBsonType ¶
func (*BsonValue) IsDBPointer ¶
func (*BsonValue) IsDateTime ¶
func (*BsonValue) IsDecimal128 ¶
func (*BsonValue) IsDocument ¶
func (*BsonValue) IsJavaScript ¶
func (*BsonValue) IsJavaScriptWithScope ¶
func (*BsonValue) IsObjectId ¶
func (*BsonValue) IsRegularExpression ¶
func (*BsonValue) IsTimestamp ¶
type Document ¶
type Document struct {
// contains filtered or unexported fields
}
func (*Document) BsonDocument ¶
func (d *Document) BsonDocument() *BsonDocument
type E ¶
type E struct { Key string Value IBsonValue }
type IBsonNumber ¶
type IBsonNumber interface { IBsonValue Int32Value() int32 Int64Value() int64 Float64Value() float64 }
type IBsonValue ¶
type IBsonValue interface { GetBsonType() BsonType Get() any AsDocument() *BsonDocument AsArray() *BsonArray AsString() *BsonString AsNumber() IBsonNumber AsInt32() *BsonInt32 AsInt64() *BsonInt64 AsDecimal128() *BsonDecimal128 AsDouble() *BsonDouble AsBoolean() *BsonBoolean AsObjectId() *BsonObjectId AsDBPointer() *BsonDBPointer AsTimestamp() *BsonTimestamp AsBinary() *BsonBinary AsDateTime() *BsonDateTime AsSymbol() *BsonSymbol AsRegularExpression() *BsonRegularExpression AsJavaScript() *BsonJavaScript AsJavaScriptWithScope() *BsonJavaScriptWithScope IsNull() bool IsDocument() bool IsArray() bool IsString() bool IsNumber() bool IsInt32() bool IsInt64() bool IsDecimal128() bool IsDouble() bool IsBoolean() bool IsObjectId() bool IsDBPointer() bool IsTimestamp() bool IsBinary() bool IsDateTime() bool IsSymbol() bool IsRegularExpression() bool IsJavaScript() bool IsJavaScriptWithScope() bool }
Source Files ¶
- bson.go
- bsonarray.go
- bsonbinnary.go
- bsonbool.go
- bsondatetime.go
- bsondbpointer.go
- bsondecimal128.go
- bsondocument.go
- bsondouble.go
- bsonfield.go
- bsonint32.go
- bsonint64.go
- bsonjavascript.go
- bsonjavascriptwithscope.go
- bsonmaxkey.go
- bsonminkey.go
- bsonnull.go
- bsonnumber.go
- bsonobjectid.go
- bsonregularexpression.go
- bsonstring.go
- bsonsymbol.go
- bsontimestamp.go
- bsontype.go
- bsonundefined.go
- bsonvalue.go
- document.go
Click to show internal directories.
Click to hide internal directories.