Documentation ¶
Index ¶
- Variables
- func DefaultDeleteExample(ctx context.Context, in *Example, db *gorm.DB) error
- func DefaultDeleteExampleSet(ctx context.Context, in []*Example, db *gorm.DB) error
- type Example
- func DefaultApplyFieldMaskExample(ctx context.Context, patchee *Example, patcher *Example, ...) (*Example, error)
- func DefaultCreateExample(ctx context.Context, in *Example, db *gorm.DB) (*Example, error)
- func DefaultListExample(ctx context.Context, db *gorm.DB) ([]*Example, error)
- func DefaultPatchExample(ctx context.Context, in *Example, updateMask *field_mask.FieldMask, ...) (*Example, error)
- func DefaultPatchSetExample(ctx context.Context, objects []*Example, updateMasks []*field_mask.FieldMask, ...) ([]*Example, error)
- func DefaultReadExample(ctx context.Context, in *Example, db *gorm.DB) (*Example, error)
- func DefaultStrictUpdateExample(ctx context.Context, in *Example, db *gorm.DB) (*Example, error)
- func (*Example) Descriptor() ([]byte, []int)deprecated
- func (x *Example) GetArrayOfBools() []bool
- func (x *Example) GetArrayOfFloat64() []float64
- func (x *Example) GetArrayOfInt64() []int64
- func (x *Example) GetArrayOfString() []string
- func (x *Example) GetDescription() string
- func (x *Example) GetId() string
- func (*Example) ProtoMessage()
- func (x *Example) ProtoReflect() protoreflect.Message
- func (x *Example) Reset()
- func (x *Example) String() string
- func (m *Example) ToORM(ctx context.Context) (ExampleORM, error)
- type ExampleORM
- type ExampleORMWithAfterCreate_
- type ExampleORMWithAfterDeleteSet
- type ExampleORMWithAfterDelete_
- type ExampleORMWithAfterListFind
- type ExampleORMWithAfterReadFind
- type ExampleORMWithAfterStrictUpdateSave
- type ExampleORMWithBeforeCreate_
- type ExampleORMWithBeforeDeleteSet
- type ExampleORMWithBeforeDelete_
- type ExampleORMWithBeforeListApplyQuery
- type ExampleORMWithBeforeListFind
- type ExampleORMWithBeforeReadApplyQuery
- type ExampleORMWithBeforeReadFind
- type ExampleORMWithBeforeStrictUpdateCleanup
- type ExampleORMWithBeforeStrictUpdateSave
- type ExampleWithAfterPatchSave
- type ExampleWithAfterToORM
- type ExampleWithAfterToPB
- type ExampleWithBeforePatchApplyFieldMask
- type ExampleWithBeforePatchRead
- type ExampleWithBeforePatchSave
- type ExampleWithBeforeToORM
- type ExampleWithBeforeToPB
Constants ¶
This section is empty.
Variables ¶
View Source
var File_postgres_arrays_postgres_arrays_proto protoreflect.FileDescriptor
Functions ¶
func DefaultDeleteExample ¶
Types ¶
type Example ¶
type Example struct { // id for example Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"` ArrayOfBools []bool `protobuf:"varint,20,rep,packed,name=array_of_bools,json=arrayOfBools,proto3" json:"array_of_bools,omitempty"` ArrayOfFloat64 []float64 `protobuf:"fixed64,30,rep,packed,name=array_of_float64,json=arrayOfFloat64,proto3" json:"array_of_float64,omitempty"` ArrayOfInt64 []int64 `protobuf:"varint,40,rep,packed,name=array_of_int64,json=arrayOfInt64,proto3" json:"array_of_int64,omitempty"` ArrayOfString []string `protobuf:"bytes,50,rep,name=array_of_string,json=arrayOfString,proto3" json:"array_of_string,omitempty"` // contains filtered or unexported fields }
func DefaultApplyFieldMaskExample ¶
func DefaultApplyFieldMaskExample(ctx context.Context, patchee *Example, patcher *Example, updateMask *field_mask.FieldMask, prefix string, db *gorm.DB) (*Example, error)
DefaultApplyFieldMaskExample patches an pbObject with patcher according to a field mask.
func DefaultCreateExample ¶
DefaultCreateExample executes a basic gorm create call
func DefaultListExample ¶
DefaultListExample executes a gorm list call
func DefaultPatchExample ¶
func DefaultPatchExample(ctx context.Context, in *Example, updateMask *field_mask.FieldMask, db *gorm.DB) (*Example, error)
DefaultPatchExample executes a basic gorm update call with patch behavior
func DefaultPatchSetExample ¶
func DefaultPatchSetExample(ctx context.Context, objects []*Example, updateMasks []*field_mask.FieldMask, db *gorm.DB) ([]*Example, error)
DefaultPatchSetExample executes a bulk gorm update call with patch behavior
func DefaultReadExample ¶
func DefaultStrictUpdateExample ¶
DefaultStrictUpdateExample clears / replaces / appends first level 1:many children and then executes a gorm update call
func (*Example) Descriptor
deprecated
func (*Example) GetArrayOfBools ¶
func (*Example) GetArrayOfFloat64 ¶
func (*Example) GetArrayOfInt64 ¶
func (*Example) GetArrayOfString ¶
func (*Example) GetDescription ¶
func (*Example) ProtoMessage ¶
func (*Example) ProtoMessage()
func (*Example) ProtoReflect ¶
func (x *Example) ProtoReflect() protoreflect.Message
type ExampleORM ¶
type ExampleORM struct { ArrayOfBools pq.BoolArray `gorm:"type:bool[]"` ArrayOfFloat64 pq.Float64Array `gorm:"type:float[]"` ArrayOfInt64 pq.Int64Array `gorm:"type:integer[]"` ArrayOfString pq.StringArray `gorm:"type:text[]"` Description string Id string `gorm:"type:uuid;primaryKey"` }
func (ExampleORM) TableName ¶
func (ExampleORM) TableName() string
TableName overrides the default tablename generated by GORM
type ExampleWithAfterToORM ¶
type ExampleWithAfterToORM interface {
AfterToORM(context.Context, *ExampleORM) error
}
ExampleAfterToORM called after default ToORM code
type ExampleWithAfterToPB ¶
ExampleAfterToPB called after default ToPB code
type ExampleWithBeforeToORM ¶
type ExampleWithBeforeToORM interface {
BeforeToORM(context.Context, *ExampleORM) error
}
ExampleBeforeToORM called before default ToORM code
Click to show internal directories.
Click to hide internal directories.