commentapi

package
v1.17.0 Latest Latest
Warning

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

Go to latest
Published: Apr 10, 2024 License: Apache-2.0 Imports: 8 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Create

func Create(params CreateParams) (string, error)

Create creates a comment to the given resource and returns a reference ID.

func Delete

func Delete(params DeleteParams) error

Delete delete the comment of the given combination of comment ID, version, resource type and resource ID.

func Get

func Get(params GetParams) (*models.Comment, error)

Get fetches the comment of the given combination of comment ID, resource type and resource ID.

func List

func List(params ListParams) (*models.CommentsWithMetas, error)

List fetches the comment of the given combination of comment ID, resource type and resource ID.

func Update

func Update(params UpdateParams) (string, error)

Update creates a comment to the given resource and returns a reference ID.

Types

type CreateParams

type CreateParams struct {
	*api.API
	ResourceType, ResourceID, Message, Region string
}

CreateParams is consumed by the Create function.

func (CreateParams) Validate

func (params CreateParams) Validate() error

Validate ensures the parameters are usable by Create.

type DeleteParams

type DeleteParams struct {
	*api.API
	ResourceType, ResourceID, CommentID, Region, Version string
}

DeleteParams is consumed by the Delete function.

func (DeleteParams) Validate

func (params DeleteParams) Validate() error

Validate ensures the parameters are usable by Delete.

type GetParams

type GetParams struct {
	*api.API
	ResourceType, ResourceID, CommentID, Region string
}

GetParams is consumed by the Get function.

func (GetParams) Validate

func (params GetParams) Validate() error

Validate ensures the parameters are usable by Get.

type ListParams

type ListParams struct {
	*api.API
	ResourceType, ResourceID, Region string
}

ListParams is consumed by the List function.

func (ListParams) Validate

func (params ListParams) Validate() error

Validate ensures the parameters are usable by List.

type UpdateParams

type UpdateParams struct {
	*api.API
	ResourceType, ResourceID, Message, CommentID, Version, Region string
}

UpdateParams is consumed by the Update function.

func (UpdateParams) Validate

func (params UpdateParams) Validate() error

Validate ensures the parameters are usable by Update.

Jump to

Keyboard shortcuts

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