client_model_relation

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func TxCheckClientID

func TxCheckClientID(tx *gorm.DB, clientID string) error

func TxCheckModelIDs

func TxCheckModelIDs(tx *gorm.DB, modelIDs []string) error

Types

type ClientModelRelation

type ClientModelRelation struct {
	common.BaseModel
	ClientID string `gorm:"column:client_id;type:char(36)" json:"clientID" yaml:"clientID"`
	ModelID  string `gorm:"column:model_id;type:char(36)" json:"modelID" yaml:"modelID"`
}

func (*ClientModelRelation) TableName

func (*ClientModelRelation) TableName() string

type DBClient

type DBClient struct {
	DB           *gorm.DB
	ClientClient *client.DBClient
}

func (*DBClient) Allocate

func (dbClient *DBClient) Allocate(ctx context.Context, req *pb.AllocateRequest) (*commonpb.VoidResponse, error)

func (*DBClient) ListClientModels

func (dbClient *DBClient) ListClientModels(ctx context.Context, req *pb.ListClientModelsRequest) (*pb.ListAllocatedModelsResponse, error)

func (*DBClient) UnAllocate

func (dbClient *DBClient) UnAllocate(ctx context.Context, req *pb.AllocateRequest) (*commonpb.VoidResponse, error)

Jump to

Keyboard shortcuts

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