delegate

package
v0.6.0-beta.20220221.1800 Latest Latest
Warning

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

Go to latest
Published: Feb 21, 2022 License: BSD-3-Clause Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetEventName

func GetEventName(d *ModelDelegate, method interfaces.ModelDelegateMethod) (eventName string)

func NewModelDelegate

func NewModelDelegate(doc interfaces.Model, args ...interface{}) interfaces.ModelDelegate

Types

type ModelDelegate

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

func (*ModelDelegate) Add

func (d *ModelDelegate) Add() (err error)

Add model

func (*ModelDelegate) Delete

func (d *ModelDelegate) Delete() (err error)

Delete model

func (*ModelDelegate) GetArtifact

func (d *ModelDelegate) GetArtifact() (res interfaces.ModelArtifact, err error)

GetArtifact refresh artifact and return it

func (*ModelDelegate) GetModel

func (d *ModelDelegate) GetModel() (res interfaces.Model)

GetModel return model

func (*ModelDelegate) Refresh

func (d *ModelDelegate) Refresh() (err error)

Refresh model

func (*ModelDelegate) Save

func (d *ModelDelegate) Save() (err error)

Save model

func (*ModelDelegate) ToBytes

func (d *ModelDelegate) ToBytes(m interface{}) (bytes []byte, err error)

type ModelNodeDelegate

type ModelNodeDelegate struct {
	interfaces.ModelDelegate
	// contains filtered or unexported fields
}

func (*ModelNodeDelegate) UpdateStatus

func (d *ModelNodeDelegate) UpdateStatus(active bool, activeTs *time.Time, status string) (err error)

func (*ModelNodeDelegate) UpdateStatusOffline

func (d *ModelNodeDelegate) UpdateStatusOffline() (err error)

func (*ModelNodeDelegate) UpdateStatusOnline

func (d *ModelNodeDelegate) UpdateStatusOnline() (err error)

Jump to

Keyboard shortcuts

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