models

package
v1.0.4 Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2024 License: LGPL-2.1 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

Functions

This section is empty.

Types

type AuthorizationEvent

type AuthorizationEvent struct {
	// Event `msgpack:",noinline"`
	entities.Event `msgpack:",noinline"`
	//IsValid   bool `gorm:"default:false" json:"isVal"`
	// EventType int16 `json:"t"`
	// Payload entities.ClientPayload  `json:"pld" gorm:"serializer:json" msgpack:",noinline"`
	BaseModel `msgpack:",noinline"`
}

type AuthorizationState

type AuthorizationState struct {
	entities.Authorization `msgpack:",noinline"`
	BaseModel
}

func (*AuthorizationState) BeforeCreate

func (d *AuthorizationState) BeforeCreate(tx *gorm.DB) (err error)

type BaseModel

type BaseModel struct {
	// ID string `gorm:"primaryKey" json:"id,omitempty"`
	CreatedAt time.Time
	UpdatedAt time.Time
	DeletedAt gorm.DeletedAt `gorm:"index"`
}

type BlockStat

type BlockStat struct {
	entities.Stats
	BaseModel
}

func (*BlockStat) BeforeCreate

func (t *BlockStat) BeforeCreate(tx *gorm.DB) (err error)

type Config

type Config struct {
	gorm.Model
	Key   string `gorm:"key;unique"`
	Value string `gorm:"value"`
}

type DeleteEvent

type DeleteEvent struct {
	entities.Event `msgpack:",noinline"`
	//IsValid   bool `gorm:"default:false" json:"isVal"`
	EventType int16 `json:"t"`
}

type EventInterface

type EventInterface interface {
}

type MessageEvent

type MessageEvent struct {
	entities.Event
	BaseModel
}

type MessageState

type MessageState struct {
	entities.Message
	BaseModel
}

func (*MessageState) BeforeCreate

func (d *MessageState) BeforeCreate(tx *gorm.DB) (err error)

type MigrationState

type MigrationState struct {
	Key string `gorm:"unique"`
	BaseModel
}

type SubnetEvent

type SubnetEvent struct {
	entities.Event
	BaseModel
}

type SubnetState

type SubnetState struct {
	entities.Subnet
	BaseModel
}

func (*SubnetState) BeforeCreate

func (d *SubnetState) BeforeCreate(tx *gorm.DB) (err error)

type SubscriptionEvent

type SubscriptionEvent struct {
	BaseModel `msgpack:",noinline"`
	// Event `msgpack:",noinline"`
	entities.Event `msgpack:",noinline"`
	Status         string `gorm:"index" json:"st"`
}

type SubscriptionState

type SubscriptionState struct {
	BaseModel             `msgpack:",noinline"`
	entities.Subscription `msgpack:",noinline"`
}

func (*SubscriptionState) BeforeCreate

func (d *SubscriptionState) BeforeCreate(tx *gorm.DB) (err error)

type TopicEvent

type TopicEvent struct {
	entities.Event
	BaseModel
}

type TopicState

type TopicState struct {
	entities.Topic
	BaseModel
}

func (*TopicState) BeforeCreate

func (d *TopicState) BeforeCreate(tx *gorm.DB) (err error)

type WalletEvent

type WalletEvent struct {
	entities.Event
	BaseModel
}

type WalletState

type WalletState struct {
	entities.Wallet
	BaseModel
}

func (*WalletState) BeforeCreate

func (d *WalletState) BeforeCreate(tx *gorm.DB) (err error)

Jump to

Keyboard shortcuts

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