internal

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Sep 7, 2022 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DeviceCategoryDataColumns

type DeviceCategoryDataColumns struct {
	Id         string // 主键
	CategoryId string // 数据类别主键
	DeviceId   string // 设备主键
	DataInt    string // int型数据
	DataStr    string // 字符串型数据
	DataDouble string // double型数据
	CreatedAt  string // 创建时间
}

DeviceCategoryDataColumns defines and stores column names for table device_category_data.

type DeviceCategoryDataDao

type DeviceCategoryDataDao struct {
	// contains filtered or unexported fields
}

DeviceCategoryDataDao is the manager for logic model data accessing and custom defined data operations functions management.

func NewDeviceCategoryDataDao

func NewDeviceCategoryDataDao() *DeviceCategoryDataDao

NewDeviceCategoryDataDao creates and returns a new DAO object for table data access.

func (*DeviceCategoryDataDao) Columns

Columns returns all column names of current dao.

func (*DeviceCategoryDataDao) Ctx

Ctx creates and returns the Model for current DAO, It automatically sets the context for current operation.

func (*DeviceCategoryDataDao) DB

func (dao *DeviceCategoryDataDao) DB() gdb.DB

DB retrieves and returns the underlying raw database management object of current DAO.

func (*DeviceCategoryDataDao) Group

func (dao *DeviceCategoryDataDao) Group() string

Group returns the configuration group name of database of current dao.

func (*DeviceCategoryDataDao) Table

func (dao *DeviceCategoryDataDao) Table() string

Table returns the table name of current dao.

func (*DeviceCategoryDataDao) Transaction

func (dao *DeviceCategoryDataDao) Transaction(ctx context.Context, f func(ctx context.Context, tx *gdb.TX) error) (err error)

Transaction wraps the transaction logic using function f. It rollbacks the transaction and returns the error from function f if it returns non-nil error. It commits the transaction and returns nil if function f returns nil.

Note that, you should not Commit or Rollback the transaction in function f as it is automatically handled by this function.

type DeviceCategotyColumns

type DeviceCategotyColumns struct {
	Id        string // 主键
	KindId    string // 数据模板的主键
	Name      string // 数据名称
	Mark      string // 数据标识
	DataType  string // 数据类型
	Unit      string // 数据单位
	Ratio     string // 变比系数
	Format    string // 格式化显示
	HomeShow  string // 首页是否展示
	Remark    string // 备注
	CreatedAt string // 创建时间
	UpdatedAt string // 修改时间
}

DeviceCategotyColumns defines and stores column names for table device_categoty.

type DeviceCategotyDao

type DeviceCategotyDao struct {
	// contains filtered or unexported fields
}

DeviceCategotyDao is the manager for logic model data accessing and custom defined data operations functions management.

func NewDeviceCategotyDao

func NewDeviceCategotyDao() *DeviceCategotyDao

NewDeviceCategotyDao creates and returns a new DAO object for table data access.

func (*DeviceCategotyDao) Columns

Columns returns all column names of current dao.

func (*DeviceCategotyDao) Ctx

func (dao *DeviceCategotyDao) Ctx(ctx context.Context) *gdb.Model

Ctx creates and returns the Model for current DAO, It automatically sets the context for current operation.

func (*DeviceCategotyDao) DB

func (dao *DeviceCategotyDao) DB() gdb.DB

DB retrieves and returns the underlying raw database management object of current DAO.

func (*DeviceCategotyDao) Group

func (dao *DeviceCategotyDao) Group() string

Group returns the configuration group name of database of current dao.

func (*DeviceCategotyDao) Table

func (dao *DeviceCategotyDao) Table() string

Table returns the table name of current dao.

func (*DeviceCategotyDao) Transaction

func (dao *DeviceCategotyDao) Transaction(ctx context.Context, f func(ctx context.Context, tx *gdb.TX) error) (err error)

Transaction wraps the transaction logic using function f. It rollbacks the transaction and returns the error from function f if it returns non-nil error. It commits the transaction and returns nil if function f returns nil.

Note that, you should not Commit or Rollback the transaction in function f as it is automatically handled by this function.

type DeviceGroupColumns

type DeviceGroupColumns struct {
	Id        string // 主键
	Name      string // 组名
	CreatedAt string // 创建时间
	UpdatedAt string // 修改时间
}

DeviceGroupColumns defines and stores column names for table device_group.

type DeviceGroupDao

type DeviceGroupDao struct {
	// contains filtered or unexported fields
}

DeviceGroupDao is the manager for logic model data accessing and custom defined data operations functions management.

func NewDeviceGroupDao

func NewDeviceGroupDao() *DeviceGroupDao

NewDeviceGroupDao creates and returns a new DAO object for table data access.

func (*DeviceGroupDao) Columns

func (dao *DeviceGroupDao) Columns() DeviceGroupColumns

Columns returns all column names of current dao.

func (*DeviceGroupDao) Ctx

func (dao *DeviceGroupDao) Ctx(ctx context.Context) *gdb.Model

Ctx creates and returns the Model for current DAO, It automatically sets the context for current operation.

func (*DeviceGroupDao) DB

func (dao *DeviceGroupDao) DB() gdb.DB

DB retrieves and returns the underlying raw database management object of current DAO.

func (*DeviceGroupDao) Group

func (dao *DeviceGroupDao) Group() string

Group returns the configuration group name of database of current dao.

func (*DeviceGroupDao) Table

func (dao *DeviceGroupDao) Table() string

Table returns the table name of current dao.

func (*DeviceGroupDao) Transaction

func (dao *DeviceGroupDao) Transaction(ctx context.Context, f func(ctx context.Context, tx *gdb.TX) error) (err error)

Transaction wraps the transaction logic using function f. It rollbacks the transaction and returns the error from function f if it returns non-nil error. It commits the transaction and returns nil if function f returns nil.

Note that, you should not Commit or Rollback the transaction in function f as it is automatically handled by this function.

type DeviceInfoColumns

type DeviceInfoColumns struct {
	Id        string // 主键
	Name      string // 设备名称
	Group     string // 设备组
	Sn        string // SN
	Pwd       string // 密码
	Kind      string // 设备类别
	Monitor   string // 是否监视
	Location  string // 地理位置
	CreatedAt string // 创建时间
	UpdatedAt string // 修改时间
}

DeviceInfoColumns defines and stores column names for table device_info.

type DeviceInfoDao

type DeviceInfoDao struct {
	// contains filtered or unexported fields
}

DeviceInfoDao is the manager for logic model data accessing and custom defined data operations functions management.

func NewDeviceInfoDao

func NewDeviceInfoDao() *DeviceInfoDao

NewDeviceInfoDao creates and returns a new DAO object for table data access.

func (*DeviceInfoDao) Columns

func (dao *DeviceInfoDao) Columns() DeviceInfoColumns

Columns returns all column names of current dao.

func (*DeviceInfoDao) Ctx

func (dao *DeviceInfoDao) Ctx(ctx context.Context) *gdb.Model

Ctx creates and returns the Model for current DAO, It automatically sets the context for current operation.

func (*DeviceInfoDao) DB

func (dao *DeviceInfoDao) DB() gdb.DB

DB retrieves and returns the underlying raw database management object of current DAO.

func (*DeviceInfoDao) Group

func (dao *DeviceInfoDao) Group() string

Group returns the configuration group name of database of current dao.

func (*DeviceInfoDao) Table

func (dao *DeviceInfoDao) Table() string

Table returns the table name of current dao.

func (*DeviceInfoDao) Transaction

func (dao *DeviceInfoDao) Transaction(ctx context.Context, f func(ctx context.Context, tx *gdb.TX) error) (err error)

Transaction wraps the transaction logic using function f. It rollbacks the transaction and returns the error from function f if it returns non-nil error. It commits the transaction and returns nil if function f returns nil.

Note that, you should not Commit or Rollback the transaction in function f as it is automatically handled by this function.

type DeviceKindColumns

type DeviceKindColumns struct {
	Id        string // 设备种类主键
	Name      string // 设备种类名称
	Mark      string // 设备名称标记
	TimeOut   string // 超时时间
	CreatedAt string // 创建时间
	UpdatedAt string // 修改时间
}

DeviceKindColumns defines and stores column names for table device_kind.

type DeviceKindDao

type DeviceKindDao struct {
	// contains filtered or unexported fields
}

DeviceKindDao is the manager for logic model data accessing and custom defined data operations functions management.

func NewDeviceKindDao

func NewDeviceKindDao() *DeviceKindDao

NewDeviceKindDao creates and returns a new DAO object for table data access.

func (*DeviceKindDao) Columns

func (dao *DeviceKindDao) Columns() DeviceKindColumns

Columns returns all column names of current dao.

func (*DeviceKindDao) Ctx

func (dao *DeviceKindDao) Ctx(ctx context.Context) *gdb.Model

Ctx creates and returns the Model for current DAO, It automatically sets the context for current operation.

func (*DeviceKindDao) DB

func (dao *DeviceKindDao) DB() gdb.DB

DB retrieves and returns the underlying raw database management object of current DAO.

func (*DeviceKindDao) Group

func (dao *DeviceKindDao) Group() string

Group returns the configuration group name of database of current dao.

func (*DeviceKindDao) Table

func (dao *DeviceKindDao) Table() string

Table returns the table name of current dao.

func (*DeviceKindDao) Transaction

func (dao *DeviceKindDao) Transaction(ctx context.Context, f func(ctx context.Context, tx *gdb.TX) error) (err error)

Transaction wraps the transaction logic using function f. It rollbacks the transaction and returns the error from function f if it returns non-nil error. It commits the transaction and returns nil if function f returns nil.

Note that, you should not Commit or Rollback the transaction in function f as it is automatically handled by this function.

type DeviceLabelColumns

type DeviceLabelColumns struct {
	Id        string // 主键
	Name      string // 标签内容
	CreatedAt string // 创建时间
	UpdatedAt string // 修改时间
}

DeviceLabelColumns defines and stores column names for table device_label.

type DeviceLabelDao

type DeviceLabelDao struct {
	// contains filtered or unexported fields
}

DeviceLabelDao is the manager for logic model data accessing and custom defined data operations functions management.

func NewDeviceLabelDao

func NewDeviceLabelDao() *DeviceLabelDao

NewDeviceLabelDao creates and returns a new DAO object for table data access.

func (*DeviceLabelDao) Columns

func (dao *DeviceLabelDao) Columns() DeviceLabelColumns

Columns returns all column names of current dao.

func (*DeviceLabelDao) Ctx

func (dao *DeviceLabelDao) Ctx(ctx context.Context) *gdb.Model

Ctx creates and returns the Model for current DAO, It automatically sets the context for current operation.

func (*DeviceLabelDao) DB

func (dao *DeviceLabelDao) DB() gdb.DB

DB retrieves and returns the underlying raw database management object of current DAO.

func (*DeviceLabelDao) Group

func (dao *DeviceLabelDao) Group() string

Group returns the configuration group name of database of current dao.

func (*DeviceLabelDao) Table

func (dao *DeviceLabelDao) Table() string

Table returns the table name of current dao.

func (*DeviceLabelDao) Transaction

func (dao *DeviceLabelDao) Transaction(ctx context.Context, f func(ctx context.Context, tx *gdb.TX) error) (err error)

Transaction wraps the transaction logic using function f. It rollbacks the transaction and returns the error from function f if it returns non-nil error. It commits the transaction and returns nil if function f returns nil.

Note that, you should not Commit or Rollback the transaction in function f as it is automatically handled by this function.

type DeviceLabelDataColumns

type DeviceLabelDataColumns struct {
	Id       string // 主键
	LabelId  string // 标签主键
	DeviceId string // 设备主键
}

DeviceLabelDataColumns defines and stores column names for table device_label_data.

type DeviceLabelDataDao

type DeviceLabelDataDao struct {
	// contains filtered or unexported fields
}

DeviceLabelDataDao is the manager for logic model data accessing and custom defined data operations functions management.

func NewDeviceLabelDataDao

func NewDeviceLabelDataDao() *DeviceLabelDataDao

NewDeviceLabelDataDao creates and returns a new DAO object for table data access.

func (*DeviceLabelDataDao) Columns

Columns returns all column names of current dao.

func (*DeviceLabelDataDao) Ctx

func (dao *DeviceLabelDataDao) Ctx(ctx context.Context) *gdb.Model

Ctx creates and returns the Model for current DAO, It automatically sets the context for current operation.

func (*DeviceLabelDataDao) DB

func (dao *DeviceLabelDataDao) DB() gdb.DB

DB retrieves and returns the underlying raw database management object of current DAO.

func (*DeviceLabelDataDao) Group

func (dao *DeviceLabelDataDao) Group() string

Group returns the configuration group name of database of current dao.

func (*DeviceLabelDataDao) Table

func (dao *DeviceLabelDataDao) Table() string

Table returns the table name of current dao.

func (*DeviceLabelDataDao) Transaction

func (dao *DeviceLabelDataDao) Transaction(ctx context.Context, f func(ctx context.Context, tx *gdb.TX) error) (err error)

Transaction wraps the transaction logic using function f. It rollbacks the transaction and returns the error from function f if it returns non-nil error. It commits the transaction and returns nil if function f returns nil.

Note that, you should not Commit or Rollback the transaction in function f as it is automatically handled by this function.

type DeviceStatusColumns

type DeviceStatusColumns struct {
	Id                 string // 主键
	DeviceId           string // 设备ID
	Status             string // 状态
	TimeOut            string // 超时时间
	UpTime             string // 上线时间
	DownTime           string // 离线时间
	LastDataUpdateTime string // 最新一次数据更新时间
}

DeviceStatusColumns defines and stores column names for table device_status.

type DeviceStatusDao

type DeviceStatusDao struct {
	// contains filtered or unexported fields
}

DeviceStatusDao is the manager for logic model data accessing and custom defined data operations functions management.

func NewDeviceStatusDao

func NewDeviceStatusDao() *DeviceStatusDao

NewDeviceStatusDao creates and returns a new DAO object for table data access.

func (*DeviceStatusDao) Columns

func (dao *DeviceStatusDao) Columns() DeviceStatusColumns

Columns returns all column names of current dao.

func (*DeviceStatusDao) Ctx

func (dao *DeviceStatusDao) Ctx(ctx context.Context) *gdb.Model

Ctx creates and returns the Model for current DAO, It automatically sets the context for current operation.

func (*DeviceStatusDao) DB

func (dao *DeviceStatusDao) DB() gdb.DB

DB retrieves and returns the underlying raw database management object of current DAO.

func (*DeviceStatusDao) Group

func (dao *DeviceStatusDao) Group() string

Group returns the configuration group name of database of current dao.

func (*DeviceStatusDao) Table

func (dao *DeviceStatusDao) Table() string

Table returns the table name of current dao.

func (*DeviceStatusDao) Transaction

func (dao *DeviceStatusDao) Transaction(ctx context.Context, f func(ctx context.Context, tx *gdb.TX) error) (err error)

Transaction wraps the transaction logic using function f. It rollbacks the transaction and returns the error from function f if it returns non-nil error. It commits the transaction and returns nil if function f returns nil.

Note that, you should not Commit or Rollback the transaction in function f as it is automatically handled by this function.

Jump to

Keyboard shortcuts

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