version1

package
v1.1.0-10 Latest Latest
Warning

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

Go to latest
Published: Dec 29, 2022 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ISessionsClientV1

type ISessionsClientV1 interface {
	GetSessions(ctx context.Context, correlationId string, filter *data.FilterParams,
		paging *data.PagingParams) (result data.DataPage[*SessionV1], err error)

	GetSessionById(ctx context.Context, correlationId string, id string) (result *SessionV1, err error)

	OpenSession(ctx context.Context, correlationId string, userId string, userName string,
		address string, client string, user interface{},
		data interface{}) (result *SessionV1, err error)

	StoreSessionData(ctx context.Context, correlationId string, sessionId string,
		data interface{}) (result *SessionV1, err error)

	UpdateSessionUser(ctx context.Context, correlationId string, sessionId string,
		user interface{}) (result *SessionV1, err error)

	CloseSession(ctx context.Context, correlationId string, sessionId string) (result *SessionV1, err error)

	DeleteSessionById(ctx context.Context, correlationId string, sessionId string) (result *SessionV1, err error)
}

type SessionGrpcClientV1

type SessionGrpcClientV1 struct {
	clients.GrpcClient
}

func NewSessionGrpcClientV1

func NewSessionGrpcClientV1() *SessionGrpcClientV1

func (*SessionGrpcClientV1) CloseSession

func (c *SessionGrpcClientV1) CloseSession(ctx context.Context, correlationId string,
	sessionId string) (result *SessionV1, err error)

func (*SessionGrpcClientV1) DeleteSessionById

func (c *SessionGrpcClientV1) DeleteSessionById(ctx context.Context, correlationId string,
	sessionId string) (result *SessionV1, err error)

func (*SessionGrpcClientV1) GetSessionById

func (c *SessionGrpcClientV1) GetSessionById(ctx context.Context, correlationId string, id string) (result *SessionV1, err error)

func (*SessionGrpcClientV1) GetSessions

func (c *SessionGrpcClientV1) GetSessions(ctx context.Context, correlationId string, filter *data.FilterParams,
	paging *data.PagingParams) (result data.DataPage[*SessionV1], err error)

func (*SessionGrpcClientV1) OpenSession

func (c *SessionGrpcClientV1) OpenSession(ctx context.Context, correlationId string, userId string,
	userName string, address string, client string, user interface{},
	data interface{}) (result *SessionV1, err error)

func (*SessionGrpcClientV1) StoreSessionData

func (c *SessionGrpcClientV1) StoreSessionData(ctx context.Context, correlationId string,
	sessionId string, data interface{}) (result *SessionV1, err error)

func (*SessionGrpcClientV1) UpdateSessionUser

func (c *SessionGrpcClientV1) UpdateSessionUser(ctx context.Context, correlationId string,
	sessionId string, user interface{}) (result *SessionV1, err error)

type SessionV1

type SessionV1 struct {
	/* Identification */
	Id       string `json:"id"`
	UserId   string `json:"user_id"`
	UserName string `json:"user_name"`

	/* Session info */
	Active      bool      `json:"active"`
	OpenTime    time.Time `json:"open_time"`
	CloseTime   time.Time `json:"close_time"`
	RequestTime time.Time `json:"request_time"`
	Address     string    `json:"address"`
	Client      string    `json:"client"`

	/* Cached content */
	User interface{} `json:"user"`
	Data interface{} `json:"data"`
}

func EmptySessionV1

func EmptySessionV1() *SessionV1

func NewSessionV1

func NewSessionV1(id string, userId string, userName string) *SessionV1

type SessionV1DataPage

type SessionV1DataPage struct {
	Total *int64       `json:"total" bson:"total"`
	Data  []*SessionV1 `json:"data" bson:"data"`
}

func NewEmptySessionV1DataPage

func NewEmptySessionV1DataPage() *SessionV1DataPage

func NewSessionV1DataPage

func NewSessionV1DataPage(total *int64, data []*SessionV1) *SessionV1DataPage

type SessionsHttpCommandableClientV1

type SessionsHttpCommandableClientV1 struct {
	*cclients.CommandableHttpClient
}

func NewSessionsHttpCommandableClientV1

func NewSessionsHttpCommandableClientV1() *SessionsHttpCommandableClientV1

func (*SessionsHttpCommandableClientV1) CloseSession

func (c *SessionsHttpCommandableClientV1) CloseSession(ctx context.Context, correlationId string, sessionId string) (result *SessionV1, err error)

func (*SessionsHttpCommandableClientV1) DeleteSessionById

func (c *SessionsHttpCommandableClientV1) DeleteSessionById(ctx context.Context, correlationId string, sessionId string) (result *SessionV1, err error)

func (*SessionsHttpCommandableClientV1) GetSessionById

func (c *SessionsHttpCommandableClientV1) GetSessionById(ctx context.Context, correlationId string, id string) (result *SessionV1, err error)

func (*SessionsHttpCommandableClientV1) GetSessions

func (c *SessionsHttpCommandableClientV1) GetSessions(ctx context.Context, correlationId string, filter *cdata.FilterParams,
	paging *cdata.PagingParams) (result cdata.DataPage[*SessionV1], err error)

func (*SessionsHttpCommandableClientV1) OpenSession

func (c *SessionsHttpCommandableClientV1) OpenSession(ctx context.Context, correlationId string, userId string, userName string,
	address string, client string, user interface{},
	data interface{}) (result *SessionV1, err error)

func (*SessionsHttpCommandableClientV1) StoreSessionData

func (c *SessionsHttpCommandableClientV1) StoreSessionData(ctx context.Context, correlationId string, sessionId string,
	data interface{}) (result *SessionV1, err error)

func (*SessionsHttpCommandableClientV1) UpdateSessionUser

func (c *SessionsHttpCommandableClientV1) UpdateSessionUser(ctx context.Context, correlationId string, sessionId string,
	user interface{}) (result *SessionV1, err error)

type SessionsMockClientV1

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

func NewSessionsMockClientV1

func NewSessionsMockClientV1() *SessionsMockClientV1

func (*SessionsMockClientV1) CloseSession

func (c *SessionsMockClientV1) CloseSession(ctx context.Context, correlationId string, sessionId string) (session *SessionV1, err error)

func (*SessionsMockClientV1) DeleteSessionById

func (c *SessionsMockClientV1) DeleteSessionById(ctx context.Context, correlationId string, sessionId string) (session *SessionV1, err error)

func (*SessionsMockClientV1) GetSessionById

func (c *SessionsMockClientV1) GetSessionById(ctx context.Context, correlationId string, sessionId string) (session *SessionV1, err error)

func (*SessionsMockClientV1) GetSessions

func (c *SessionsMockClientV1) GetSessions(ctx context.Context, correlationId string, filter *cdata.FilterParams, paging *cdata.PagingParams) (page cdata.DataPage[*SessionV1], err error)

func (*SessionsMockClientV1) OpenSession

func (c *SessionsMockClientV1) OpenSession(ctx context.Context, correlationId string, userId string, userName string,
	address string, client string, user interface{}, data interface{}) (session *SessionV1, err error)

func (*SessionsMockClientV1) StoreSessionData

func (c *SessionsMockClientV1) StoreSessionData(ctx context.Context, correlationId string, sessionId string, data interface{}) (session *SessionV1, err error)

func (*SessionsMockClientV1) UpdateSessionUser

func (c *SessionsMockClientV1) UpdateSessionUser(ctx context.Context, correlationId string, sessionId string, user interface{}) (session *SessionV1, err error)

Jump to

Keyboard shortcuts

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