clients

package
v1.3.9 Latest Latest
Warning

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

Go to latest
Published: May 20, 2024 License: BSD-3-Clause Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ClientBrowserStateEnabled  = 1 // 已启用
	ClientBrowserStateDisabled = 0 // 已禁用
)
View Source
const (
	ClientSystemStateEnabled  = 1 // 已启用
	ClientSystemStateDisabled = 0 // 已禁用
)

Variables

This section is empty.

Functions

This section is empty.

Types

type ClientAgent

type ClientAgent struct {
	Id          uint32 `field:"id"`          // ID
	Name        string `field:"name"`        // 名称
	Code        string `field:"code"`        // 代号
	Description string `field:"description"` // 介绍
	Order       uint32 `field:"order"`       // 排序
	CountIPs    uint32 `field:"countIPs"`    // IP数量
}

ClientAgent Agent库

func (*ClientAgent) NSRouteCode

func (this *ClientAgent) NSRouteCode() string

NSRouteCode NS线路代号

type ClientAgentDAO

type ClientAgentDAO dbs.DAO
var SharedClientAgentDAO *ClientAgentDAO

func NewClientAgentDAO

func NewClientAgentDAO() *ClientAgentDAO

func (*ClientAgentDAO) FindAgent

func (this *ClientAgentDAO) FindAgent(tx *dbs.Tx, agentId int64) (*ClientAgent, error)

FindAgent 查找Agent

func (*ClientAgentDAO) FindAgentIdWithCode

func (this *ClientAgentDAO) FindAgentIdWithCode(tx *dbs.Tx, code string) (int64, error)

FindAgentIdWithCode 根据代号查找ID

func (*ClientAgentDAO) FindAgentNameWithCode

func (this *ClientAgentDAO) FindAgentNameWithCode(tx *dbs.Tx, code string) (string, error)

FindAgentNameWithCode 根据代号查找Agent名称

func (*ClientAgentDAO) FindAllAgents

func (this *ClientAgentDAO) FindAllAgents(tx *dbs.Tx) (result []*ClientAgent, err error)

FindAllAgents 查找所有Agents

func (*ClientAgentDAO) FindAllNSAgents

func (this *ClientAgentDAO) FindAllNSAgents(tx *dbs.Tx) (result []*ClientAgent, err error)

FindAllNSAgents 查找所有DNS可以使用的Agents

func (*ClientAgentDAO) FindClientAgentName

func (this *ClientAgentDAO) FindClientAgentName(tx *dbs.Tx, id int64) (string, error)

FindClientAgentName 根据主键查找名称

func (*ClientAgentDAO) UpdateAgentCountIPs

func (this *ClientAgentDAO) UpdateAgentCountIPs(tx *dbs.Tx, agentId int64, countIPs int64) error

UpdateAgentCountIPs 修改Agent拥有的IP数量

type ClientAgentIP

type ClientAgentIP struct {
	Id      uint64 `field:"id"`      // ID
	AgentId uint32 `field:"agentId"` // Agent ID
	IP      string `field:"ip"`      // IP地址
	Ptr     string `field:"ptr"`     // PTR值
}

ClientAgentIP Agent IP

type ClientAgentIPDAO

type ClientAgentIPDAO dbs.DAO
var SharedClientAgentIPDAO *ClientAgentIPDAO

func NewClientAgentIPDAO

func NewClientAgentIPDAO() *ClientAgentIPDAO

func (*ClientAgentIPDAO) CountAgentIPs

func (this *ClientAgentIPDAO) CountAgentIPs(tx *dbs.Tx, agentId int64) (int64, error)

CountAgentIPs 计算Agent IP数量

func (*ClientAgentIPDAO) CreateIP

func (this *ClientAgentIPDAO) CreateIP(tx *dbs.Tx, agentId int64, ip string, ptr string) error

CreateIP 写入IP

func (*ClientAgentIPDAO) ListIPsAfterId

func (this *ClientAgentIPDAO) ListIPsAfterId(tx *dbs.Tx, id int64, size int64) (result []*ClientAgentIP, err error)

ListIPsAfterId 列出某个ID之后的IP

type ClientAgentIPOperator

type ClientAgentIPOperator struct {
	Id      any // ID
	AgentId any // Agent ID
	IP      any // IP地址
	Ptr     any // PTR值
}

func NewClientAgentIPOperator

func NewClientAgentIPOperator() *ClientAgentIPOperator

type ClientAgentOperator

type ClientAgentOperator struct {
	Id          any // ID
	Name        any // 名称
	Code        any // 代号
	Description any // 介绍
	Order       any // 排序
	CountIPs    any // IP数量
}

func NewClientAgentOperator

func NewClientAgentOperator() *ClientAgentOperator

type ClientBrowser

type ClientBrowser struct {
	Id         uint64   `field:"id"`         // ID
	Name       string   `field:"name"`       // 浏览器名称
	Codes      dbs.JSON `field:"codes"`      // 代号
	CreatedDay string   `field:"createdDay"` // 创建日期YYYYMMDD
	State      uint8    `field:"state"`      // 状态
}

ClientBrowser 终端浏览器信息

type ClientBrowserDAO

type ClientBrowserDAO dbs.DAO
var SharedClientBrowserDAO *ClientBrowserDAO

func NewClientBrowserDAO

func NewClientBrowserDAO() *ClientBrowserDAO

func (*ClientBrowserDAO) Clean

func (this *ClientBrowserDAO) Clean(tx *dbs.Tx, days int) error

Clean 清理

func (*ClientBrowserDAO) CreateBrowserIfNotExists

func (this *ClientBrowserDAO) CreateBrowserIfNotExists(tx *dbs.Tx, browserName string) error

CreateBrowserIfNotExists 创建浏览器信息

func (*ClientBrowserDAO) DisableClientBrowser

func (this *ClientBrowserDAO) DisableClientBrowser(tx *dbs.Tx, id uint32) error

DisableClientBrowser 禁用条目

func (*ClientBrowserDAO) EnableClientBrowser

func (this *ClientBrowserDAO) EnableClientBrowser(tx *dbs.Tx, id uint32) error

EnableClientBrowser 启用条目

func (*ClientBrowserDAO) FindClientBrowserName

func (this *ClientBrowserDAO) FindClientBrowserName(tx *dbs.Tx, id uint32) (string, error)

FindClientBrowserName 根据主键查找名称

func (*ClientBrowserDAO) FindEnabledClientBrowser

func (this *ClientBrowserDAO) FindEnabledClientBrowser(tx *dbs.Tx, id int64) (*ClientBrowser, error)

FindEnabledClientBrowser 查找启用中的条目

type ClientBrowserOperator

type ClientBrowserOperator struct {
	Id         any // ID
	Name       any // 浏览器名称
	Codes      any // 代号
	CreatedDay any // 创建日期YYYYMMDD
	State      any // 状态
}

func NewClientBrowserOperator

func NewClientBrowserOperator() *ClientBrowserOperator

type ClientSystem

type ClientSystem struct {
	Id         uint64   `field:"id"`         // ID
	Name       string   `field:"name"`       // 系统名称
	Codes      dbs.JSON `field:"codes"`      // 代号
	CreatedDay string   `field:"createdDay"` // 创建日期YYYYMMDD
	State      uint8    `field:"state"`      // 状态
}

ClientSystem 终端操作系统信息

type ClientSystemDAO

type ClientSystemDAO dbs.DAO
var SharedClientSystemDAO *ClientSystemDAO

func NewClientSystemDAO

func NewClientSystemDAO() *ClientSystemDAO

func (*ClientSystemDAO) Clean

func (this *ClientSystemDAO) Clean(tx *dbs.Tx, days int) error

Clean 清理

func (*ClientSystemDAO) CreateSystemIfNotExists

func (this *ClientSystemDAO) CreateSystemIfNotExists(tx *dbs.Tx, systemName string) error

CreateSystemIfNotExists 创建系统信息

func (*ClientSystemDAO) DisableClientSystem

func (this *ClientSystemDAO) DisableClientSystem(tx *dbs.Tx, id uint32) error

DisableClientSystem 禁用条目

func (*ClientSystemDAO) EnableClientSystem

func (this *ClientSystemDAO) EnableClientSystem(tx *dbs.Tx, id uint32) error

EnableClientSystem 启用条目

func (*ClientSystemDAO) FindClientSystemName

func (this *ClientSystemDAO) FindClientSystemName(tx *dbs.Tx, id uint32) (string, error)

FindClientSystemName 根据主键查找名称

func (*ClientSystemDAO) FindEnabledClientSystem

func (this *ClientSystemDAO) FindEnabledClientSystem(tx *dbs.Tx, id int64) (*ClientSystem, error)

FindEnabledClientSystem 查找启用中的条目

type ClientSystemOperator

type ClientSystemOperator struct {
	Id         any // ID
	Name       any // 系统名称
	Codes      any // 代号
	CreatedDay any // 创建日期YYYYMMDD
	State      any // 状态
}

func NewClientSystemOperator

func NewClientSystemOperator() *ClientSystemOperator

Jump to

Keyboard shortcuts

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