model

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Dec 2, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AttrOption

type AttrOption struct {
	Attr  string
	Value interface{}
}

type ModelBuilder

type ModelBuilder[T interface{}] struct {
	// contains filtered or unexported fields
}

func (*ModelBuilder[T]) AddAttr

func (mb *ModelBuilder[T]) AddAttr(attr string, value interface{}) *ModelBuilder[T]

func (*ModelBuilder[T]) GetBsonM

func (mb *ModelBuilder[T]) GetBsonM() bson.M

for mongo

func (*ModelBuilder[T]) GetMap

func (mb *ModelBuilder[T]) GetMap() map[string]interface{}

for others

func (*ModelBuilder[T]) GetSlice

func (mb *ModelBuilder[T]) GetSlice() []AttrOption

Jump to

Keyboard shortcuts

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