Documentation ¶
Index ¶
- func List(client *golangsdk.ServiceClient, opts ListOptsBuilder) (p pagination.Pager)
- type CreateOpts
- type CreateOptsBuilder
- type CreateResult
- type DeleteResult
- type GetResult
- type ImageRepository
- type ListOpts
- type ListOptsBuilder
- type RepositoryPage
- type UpdateOpts
- type UpdateOptsBuilder
- type UpdateResult
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func List ¶
func List(client *golangsdk.ServiceClient, opts ListOptsBuilder) (p pagination.Pager)
Types ¶
type CreateOpts ¶
type CreateOpts struct { // Name of the image repository Repository string `json:"repository" required:"true"` // Type of the image repository // The value can be app_server, linux, framework_app, database, lang, other, windows, arm Category string `json:"category,omitempty"` // Description of the image repository Description string `json:"description,omitempty"` // Whether the image repository is public IsPublic bool `json:"is_public"` }
func (CreateOpts) ToRepositoryCreateMap ¶
func (opts CreateOpts) ToRepositoryCreateMap() (map[string]interface{}, error)
type CreateOptsBuilder ¶
type CreateResult ¶
type CreateResult struct {
golangsdk.ErrResult
}
func Create ¶
func Create(client *golangsdk.ServiceClient, namespace string, opts CreateOptsBuilder) (r CreateResult)
Create new repository in the namespace(organization)
type DeleteResult ¶
type DeleteResult struct {
golangsdk.ErrResult
}
func Delete ¶
func Delete(client *golangsdk.ServiceClient, namespace, repository string) (r DeleteResult)
type GetResult ¶
type GetResult struct {
golangsdk.Result
}
func (GetResult) Extract ¶
func (r GetResult) Extract() (*ImageRepository, error)
type ImageRepository ¶
type ImageRepository struct { ID int `json:"id"` OrganizationID int `json:"ns_id"` Name string `json:"name"` Category string `json:"category"` Description string `json:"description"` CreatorID string `json:"creator_id"` CreatorName string `json:"creator_name"` Size int `json:"size"` IsPublic bool `json:"is_public"` NumImages int `json:"num_images"` NumDownloads int `json:"num_downloads"` URL string `json:"url"` Path string `json:"path"` InternalPath string `json:"internal_path"` Created string `json:"created"` Updated string `json:"updated"` DomainID string `json:"domain_id"` Prioriry int `json:"poriroty"` }
func ExtractRepositories ¶
func ExtractRepositories(p pagination.Page) ([]ImageRepository, error)
type ListOpts ¶
type ListOpts struct { // Namespace(Organization) name Namespace string `q:"namespace"` // Image repository name Name string `q:"name"` // Image repository category. // The value can be app_server, linux, framework_app, database, lang, other, windows, arm Category string `q:"category"` // Sorting by column. // You can set this parameter to name, updated_time, and tag_count. // The parameters OrderColumn and OrderType should always be used together. OrderColumn string `q:"order_column"` // Sorting type. // You can set this parameter to desc(descending sort) and asc(ascending sort). OrderType string `q:"order_type"` // offset 0 is a valid value Offset *int `q:"offset,omitempty"` Limit int `q:"limit,omitempty"` }
func (ListOpts) ToRepositoryListQuery ¶
type ListOptsBuilder ¶
type RepositoryPage ¶
type RepositoryPage struct {
pagination.LinkedPageBase
}
type UpdateOpts ¶
type UpdateOpts struct { Category string `json:"category,omitempty"` Description string `json:"description,omitempty"` IsPublic bool `json:"is_public"` }
func (UpdateOpts) ToRepositoryUpdateMap ¶
func (opts UpdateOpts) ToRepositoryUpdateMap() (map[string]interface{}, error)
type UpdateOptsBuilder ¶
type UpdateResult ¶
type UpdateResult struct {
golangsdk.ErrResult
}
func Update ¶
func Update(client *golangsdk.ServiceClient, namespace, repository string, opts UpdateOptsBuilder) (r UpdateResult)
Click to show internal directories.
Click to hide internal directories.