Documentation ¶
Index ¶
- type Client
- func (c Client) AddLabel(ctx context.Context, label models.LabelRequest) (models.Label, error)
- func (c Client) CreateLink(ctx context.Context, link models.LinkRequest) (models.Link, error)
- func (c Client) CreateNamespace(ctx context.Context, namespace string) (ns models.Namespace, err error)
- func (c Client) DeleteLabelByID(ctx context.Context, labelID models.LabelID) error
- func (c Client) DeleteLabelByName(ctx context.Context, name string) error
- func (c Client) DeleteLink(ctx context.Context, linkID models.LinkID) error
- func (c Client) DeleteLinkByID(ctx context.Context, linkID models.LinkID) error
- func (c Client) DeleteLinkByName(ctx context.Context, name string) error
- func (c Client) DeleteNamespace(ctx context.Context, namespace string) (err error)
- func (c Client) GetLabelByID(ctx context.Context, labelID models.LabelID) (label models.Label, err error)
- func (c Client) GetLabelByName(ctx context.Context, name string) (label models.Label, err error)
- func (c Client) GetLabels(ctx context.Context) (labels []models.Label, err error)
- func (c Client) GetLinkByID(ctx context.Context, linkID models.LinkID) (link models.Link, err error)
- func (c Client) GetLinkByName(ctx context.Context, name string) (link models.Link, err error)
- func (c Client) GetLinks(ctx context.Context) (links []models.Link, err error)
- func (c Client) GetLinksAllNamespace(ctx context.Context) (links []models.Link, err error)
- func (c Client) GetLinksAssociatedToLabel(ctx context.Context, labelID models.LabelID) (links []models.Link, err error)
- func (c Client) GetNamespace(ctx context.Context, namespace string) (ns models.Namespace, err error)
- func (c Client) GetNamespaces(ctx context.Context) (namespaces []models.Namespace, err error)
- func (c Client) GetVersion(ctx context.Context) (version string, err error)
- func (c *Client) SetNamespace(namespace string)
- func (c Client) UpdateLink(ctx context.Context, link models.LinkRequest, linkID string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is the golink client.
func (Client) CreateLink ¶
CreateLink creates a link in the database.
func (Client) CreateNamespace ¶
func (c Client) CreateNamespace(ctx context.Context, namespace string) (ns models.Namespace, err error)
CreateNamespace creates a namespace in the database.
func (Client) DeleteLabelByID ¶
DeleteLabelByID deletes a label from the database.
func (Client) DeleteLabelByName ¶
DeleteLabelByName deletes a label from the database.
func (Client) DeleteLink ¶
DeleteLink deletes a link from the database. Is a alias for DeleteLinkByID.
func (Client) DeleteLinkByID ¶
DeleteLinkByID deletes a link from the database.
func (Client) DeleteLinkByName ¶
DeleteLinkByName deletes a link from the database.
func (Client) DeleteNamespace ¶
DeleteNamespace deletes a namespace from the database.
func (Client) GetLabelByID ¶
func (c Client) GetLabelByID(ctx context.Context, labelID models.LabelID) (label models.Label, err error)
GetLabelByID gets a label from the database.
func (Client) GetLabelByName ¶
GetLabelByName gets a label from the database.
func (Client) GetLinkByID ¶
func (c Client) GetLinkByID(ctx context.Context, linkID models.LinkID) (link models.Link, err error)
GetLinkByID gets a link from the database.
func (Client) GetLinkByName ¶
GetLinkByNames gets a link from the database.
func (Client) GetLinksAllNamespace ¶
GetLinksAllNamespace gets a list of links from all namespaces.
func (Client) GetLinksAssociatedToLabel ¶
func (c Client) GetLinksAssociatedToLabel(ctx context.Context, labelID models.LabelID) (links []models.Link, err error)
GetLinksAssociatedToLabel gets a list of links associated to a label from the database.
func (Client) GetNamespace ¶
func (c Client) GetNamespace(ctx context.Context, namespace string) (ns models.Namespace, err error)
GetNamespace gets a namespace from the database.
func (Client) GetNamespaces ¶
GetNamespaces gets a list of namespaces from the database.
func (Client) GetVersion ¶
GetVersion - Get the version of the application.
func (*Client) SetNamespace ¶
SetNamespace - Set namespace for golink Client.
func (Client) UpdateLink ¶
UpdateLink updates a link in the database.