Documentation ¶
Index ¶
- Constants
- type Action
- type ApiError
- type ApiVersion
- type ApiVersionClient
- func (c *ApiVersionClient) ById(id string) (*ApiVersion, error)
- func (c *ApiVersionClient) Create(container *ApiVersion) (*ApiVersion, error)
- func (c *ApiVersionClient) Delete(container *ApiVersion) error
- func (c *ApiVersionClient) List(opts *ListOpts) (*ApiVersionCollection, error)
- func (c *ApiVersionClient) Update(existing *ApiVersion, updates interface{}) (*ApiVersion, error)
- type ApiVersionCollection
- type ApiVersionOperations
- type Catalog
- type CatalogClient
- func (c *CatalogClient) ById(id string) (*Catalog, error)
- func (c *CatalogClient) Create(container *Catalog) (*Catalog, error)
- func (c *CatalogClient) Delete(container *Catalog) error
- func (c *CatalogClient) List(opts *ListOpts) (*CatalogCollection, error)
- func (c *CatalogClient) Update(existing *Catalog, updates interface{}) (*Catalog, error)
- type CatalogCollection
- type CatalogOperations
- type ClientOpts
- type Collection
- type Condition
- type Error
- type ErrorClient
- func (c *ErrorClient) ById(id string) (*Error, error)
- func (c *ErrorClient) Create(container *Error) (*Error, error)
- func (c *ErrorClient) Delete(container *Error) error
- func (c *ErrorClient) List(opts *ListOpts) (*ErrorCollection, error)
- func (c *ErrorClient) Update(existing *Error, updates interface{}) (*Error, error)
- type ErrorCollection
- type ErrorOperations
- type Field
- type Filter
- type GenericCollection
- type ListOpts
- type Pagination
- type Question
- type QuestionClient
- func (c *QuestionClient) ById(id string) (*Question, error)
- func (c *QuestionClient) Create(container *Question) (*Question, error)
- func (c *QuestionClient) Delete(container *Question) error
- func (c *QuestionClient) List(opts *ListOpts) (*QuestionCollection, error)
- func (c *QuestionClient) Update(existing *Question, updates interface{}) (*Question, error)
- type QuestionCollection
- type QuestionOperations
- type RancherBaseClient
- func (rancherClient *RancherBaseClient) Create(schemaType string, createObj interface{}, respObject interface{}) error
- func (rancherClient *RancherBaseClient) GetLink(resource Resource, link string, respObject interface{}) error
- func (rancherClient *RancherBaseClient) Post(url string, createObj interface{}, respObject interface{}) error
- func (rancherClient *RancherBaseClient) Reload(existing *Resource, output interface{}) error
- func (rancherClient *RancherBaseClient) Update(schemaType string, existing *Resource, updates interface{}, ...) error
- func (rancherClient *RancherBaseClient) Websocket(url string, headers map[string][]string) (*websocket.Conn, *http.Response, error)
- type RancherCatalogClient
- type Resource
- type Schema
- type Schemas
- type Sort
- type Template
- type TemplateClient
- func (c *TemplateClient) ById(id string) (*Template, error)
- func (c *TemplateClient) Create(container *Template) (*Template, error)
- func (c *TemplateClient) Delete(container *Template) error
- func (c *TemplateClient) List(opts *ListOpts) (*TemplateCollection, error)
- func (c *TemplateClient) Update(existing *Template, updates interface{}) (*Template, error)
- type TemplateCollection
- type TemplateOperations
- type TemplateVersion
- type TemplateVersionClient
- func (c *TemplateVersionClient) ById(id string) (*TemplateVersion, error)
- func (c *TemplateVersionClient) Create(container *TemplateVersion) (*TemplateVersion, error)
- func (c *TemplateVersionClient) Delete(container *TemplateVersion) error
- func (c *TemplateVersionClient) List(opts *ListOpts) (*TemplateVersionCollection, error)
- func (c *TemplateVersionClient) Update(existing *TemplateVersion, updates interface{}) (*TemplateVersion, error)
- type TemplateVersionCollection
- type TemplateVersionOperations
Constants ¶
View Source
const ( SELF = "self" COLLECTION = "collection" )
View Source
const (
API_VERSION_TYPE = "apiVersion"
)
View Source
const (
CATALOG_TYPE = "catalog"
)
View Source
const (
ERROR_TYPE = "error"
)
View Source
const (
QUESTION_TYPE = "question"
)
View Source
const (
TEMPLATE_TYPE = "template"
)
View Source
const (
TEMPLATE_VERSION_TYPE = "templateVersion"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ApiVersion ¶
type ApiVersionClient ¶
type ApiVersionClient struct {
// contains filtered or unexported fields
}
func (*ApiVersionClient) ById ¶
func (c *ApiVersionClient) ById(id string) (*ApiVersion, error)
func (*ApiVersionClient) Create ¶
func (c *ApiVersionClient) Create(container *ApiVersion) (*ApiVersion, error)
func (*ApiVersionClient) Delete ¶
func (c *ApiVersionClient) Delete(container *ApiVersion) error
func (*ApiVersionClient) List ¶
func (c *ApiVersionClient) List(opts *ListOpts) (*ApiVersionCollection, error)
func (*ApiVersionClient) Update ¶
func (c *ApiVersionClient) Update(existing *ApiVersion, updates interface{}) (*ApiVersion, error)
type ApiVersionCollection ¶
type ApiVersionCollection struct { Collection Data []ApiVersion `json:"data,omitempty"` }
type ApiVersionOperations ¶
type ApiVersionOperations interface { List(opts *ListOpts) (*ApiVersionCollection, error) Create(opts *ApiVersion) (*ApiVersion, error) Update(existing *ApiVersion, updates interface{}) (*ApiVersion, error) ById(id string) (*ApiVersion, error) Delete(container *ApiVersion) error }
type Catalog ¶
type Catalog struct { Resource Actions map[string]interface{} `json:"actions,omitempty" yaml:"actions,omitempty"` CatalogRoot string `json:"catalogRoot,omitempty" yaml:"catalog_root,omitempty"` Description string `json:"description,omitempty" yaml:"description,omitempty"` LastUpdated string `json:"lastUpdated,omitempty" yaml:"last_updated,omitempty"` Links map[string]interface{} `json:"links,omitempty" yaml:"links,omitempty"` Message string `json:"message,omitempty" yaml:"message,omitempty"` Metadata map[string]interface{} `json:"metadata,omitempty" yaml:"metadata,omitempty"` State string `json:"state,omitempty" yaml:"state,omitempty"` Type string `json:"type,omitempty" yaml:"type,omitempty"` Uri string `json:"uri,omitempty" yaml:"uri,omitempty"` }
type CatalogClient ¶
type CatalogClient struct {
// contains filtered or unexported fields
}
func (*CatalogClient) Delete ¶
func (c *CatalogClient) Delete(container *Catalog) error
func (*CatalogClient) List ¶
func (c *CatalogClient) List(opts *ListOpts) (*CatalogCollection, error)
type CatalogCollection ¶
type CatalogCollection struct { Collection Data []Catalog `json:"data,omitempty"` }
type CatalogOperations ¶
type ClientOpts ¶
type Collection ¶
type Collection struct { Type string `json:"type,omitempty"` ResourceType string `json:"resourceType,omitempty"` Links map[string]string `json:"links,omitempty"` CreateTypes map[string]string `json:"createTypes,omitempty"` Actions map[string]string `json:"actions,omitempty"` SortLinks map[string]string `json:"sortLinks,omitempty"` Pagination *Pagination `json:"pagination,omitempty"` Sort *Sort `json:"sort,omitempty"` Filters map[string][]Condition `json:"filters,omitempty"` }
type Condition ¶
type Condition struct { Modifier string `json:"modifier,omitempty"` Value interface{} `json:"value,omitempty"` }
type Error ¶
type Error struct { Resource Actions map[string]interface{} `json:"actions,omitempty" yaml:"actions,omitempty"` Links map[string]interface{} `json:"links,omitempty" yaml:"links,omitempty"` Message string `json:"message,omitempty" yaml:"message,omitempty"` Status string `json:"status,omitempty" yaml:"status,omitempty"` Type string `json:"type,omitempty" yaml:"type,omitempty"` }
type ErrorClient ¶
type ErrorClient struct {
// contains filtered or unexported fields
}
func (*ErrorClient) Delete ¶
func (c *ErrorClient) Delete(container *Error) error
func (*ErrorClient) List ¶
func (c *ErrorClient) List(opts *ListOpts) (*ErrorCollection, error)
type ErrorCollection ¶
type ErrorCollection struct { Collection Data []Error `json:"data,omitempty"` }
type ErrorOperations ¶
type Field ¶
type Field struct { Type string `json:"type,omitempty"` Default interface{} `json:"default,omitempty"` Unique bool `json:"unique,omitempty"` Nullable bool `json:"nullable,omitempty"` Create bool `json:"create,omitempty"` Required bool `json:"required,omitempty"` Update bool `json:"update,omitempty"` MinLength *int64 `json:"minLength,omitempty"` MaxLength *int64 `json:"maxLength,omitempty"` Min *int64 `json:"min,omitempty"` Max *int64 `json:"max,omitempty"` Options []string `json:"options,omitempty"` ValidChars string `json:"validChars,omitempty"` InvalidChars string `json:"invalidChars,omitempty"` }
type GenericCollection ¶
type GenericCollection struct { Collection Data []interface{} `json:"data,omitempty"` }
type ListOpts ¶
type ListOpts struct {
Filters map[string]interface{}
}
func NewListOpts ¶
func NewListOpts() *ListOpts
type Pagination ¶
type Pagination struct { Marker string `json:"marker,omitempty"` First string `json:"first,omitempty"` Previous string `json:"previous,omitempty"` Next string `json:"next,omitempty"` Limit *int64 `json:"limit,omitempty"` Total *int64 `json:"total,omitempty"` Partial bool `json:"partial,omitempty"` }
type Question ¶
type Question struct { Resource Default string `json:"default,omitempty" yaml:"default,omitempty"` Description string `json:"description,omitempty" yaml:"description,omitempty"` Group string `json:"group,omitempty" yaml:"group,omitempty"` InvalidChars string `json:"invalidChars,omitempty" yaml:"invalid_chars,omitempty"` Label string `json:"label,omitempty" yaml:"label,omitempty"` Max int64 `json:"max,omitempty" yaml:"max,omitempty"` MaxLength int64 `json:"maxLength,omitempty" yaml:"max_length,omitempty"` Min int64 `json:"min,omitempty" yaml:"min,omitempty"` MinLength int64 `json:"minLength,omitempty" yaml:"min_length,omitempty"` Options []string `json:"options,omitempty" yaml:"options,omitempty"` Required bool `json:"required,omitempty" yaml:"required,omitempty"` Type string `json:"type,omitempty" yaml:"type,omitempty"` ValidChars string `json:"validChars,omitempty" yaml:"valid_chars,omitempty"` Variable string `json:"variable,omitempty" yaml:"variable,omitempty"` }
type QuestionClient ¶
type QuestionClient struct {
// contains filtered or unexported fields
}
func (*QuestionClient) Create ¶
func (c *QuestionClient) Create(container *Question) (*Question, error)
func (*QuestionClient) Delete ¶
func (c *QuestionClient) Delete(container *Question) error
func (*QuestionClient) List ¶
func (c *QuestionClient) List(opts *ListOpts) (*QuestionCollection, error)
type QuestionCollection ¶
type QuestionCollection struct { Collection Data []Question `json:"data,omitempty"` }
type QuestionOperations ¶
type RancherBaseClient ¶
type RancherBaseClient struct { Opts *ClientOpts Schemas *Schemas Types map[string]Schema }
func (*RancherBaseClient) Create ¶
func (rancherClient *RancherBaseClient) Create(schemaType string, createObj interface{}, respObject interface{}) error
func (*RancherBaseClient) GetLink ¶
func (rancherClient *RancherBaseClient) GetLink(resource Resource, link string, respObject interface{}) error
func (*RancherBaseClient) Post ¶
func (rancherClient *RancherBaseClient) Post(url string, createObj interface{}, respObject interface{}) error
func (*RancherBaseClient) Reload ¶
func (rancherClient *RancherBaseClient) Reload(existing *Resource, output interface{}) error
type RancherCatalogClient ¶
type RancherCatalogClient struct { RancherBaseClient ApiVersion ApiVersionOperations Question QuestionOperations Template TemplateOperations TemplateVersion TemplateVersionOperations Catalog CatalogOperations Error ErrorOperations }
func NewRancherCatalogClient ¶
func NewRancherCatalogClient(opts *ClientOpts) (*RancherCatalogClient, error)
type Schema ¶
type Schema struct { Resource PluralName string `json:"pluralName,omitempty"` ResourceMethods []string `json:"resourceMethods,omitempty"` ResourceFields map[string]Field `json:"resourceFields,omitempty"` ResourceActions map[string]Action `json:"resourceActions,omitempty"` CollectionMethods []string `json:"collectionMethods,omitempty"` CollectionFields map[string]Field `json:"collectionFields,omitempty"` CollectionActions map[string]Action `json:"collectionActions,omitempty"` CollectionFilters map[string]Filter `json:"collectionFilters,omitempty"` IncludeableLinks []string `json:"includeableLinks,omitempty"` }
type Schemas ¶
type Schemas struct { Collection Data []Schema `json:"data,omitempty"` // contains filtered or unexported fields }
type Template ¶
type Template struct { Resource Actions map[string]interface{} `json:"actions,omitempty" yaml:"actions,omitempty"` CatalogId string `json:"catalogId,omitempty" yaml:"catalog_id,omitempty"` Category string `json:"category,omitempty" yaml:"category,omitempty"` DefaultVersion string `json:"defaultVersion,omitempty" yaml:"default_version,omitempty"` Description string `json:"description,omitempty" yaml:"description,omitempty"` Files map[string]interface{} `json:"files,omitempty" yaml:"files,omitempty"` License string `json:"license,omitempty" yaml:"license,omitempty"` Links map[string]interface{} `json:"links,omitempty" yaml:"links,omitempty"` Maintainer string `json:"maintainer,omitempty" yaml:"maintainer,omitempty"` MinimumRancherVersion string `json:"minimumRancherVersion,omitempty" yaml:"minimum_rancher_version,omitempty"` Name string `json:"name,omitempty" yaml:"name,omitempty"` Path string `json:"path,omitempty" yaml:"path,omitempty"` TemplateBase string `json:"templateBase,omitempty" yaml:"template_base,omitempty"` TemplateVersionRancherVersion map[string]interface{} `json:"templateVersionRancherVersion,omitempty" yaml:"template_version_rancher_version,omitempty"` Type string `json:"type,omitempty" yaml:"type,omitempty"` UpgradeVersionLinks map[string]interface{} `json:"upgradeVersionLinks,omitempty" yaml:"upgrade_version_links,omitempty"` VersionLinks map[string]interface{} `json:"versionLinks,omitempty" yaml:"version_links,omitempty"` }
type TemplateClient ¶
type TemplateClient struct {
// contains filtered or unexported fields
}
func (*TemplateClient) Create ¶
func (c *TemplateClient) Create(container *Template) (*Template, error)
func (*TemplateClient) Delete ¶
func (c *TemplateClient) Delete(container *Template) error
func (*TemplateClient) List ¶
func (c *TemplateClient) List(opts *ListOpts) (*TemplateCollection, error)
type TemplateCollection ¶
type TemplateCollection struct { Collection Data []Template `json:"data,omitempty"` }
type TemplateOperations ¶
type TemplateVersion ¶
type TemplateVersion struct { Resource Actions map[string]interface{} `json:"actions,omitempty" yaml:"actions,omitempty"` CatalogId string `json:"catalogId,omitempty" yaml:"catalog_id,omitempty"` Category string `json:"category,omitempty" yaml:"category,omitempty"` DefaultVersion string `json:"defaultVersion,omitempty" yaml:"default_version,omitempty"` Description string `json:"description,omitempty" yaml:"description,omitempty"` Files map[string]interface{} `json:"files,omitempty" yaml:"files,omitempty"` IconLink string `json:"iconLink,omitempty" yaml:"icon_link,omitempty"` License string `json:"license,omitempty" yaml:"license,omitempty"` Links map[string]interface{} `json:"links,omitempty" yaml:"links,omitempty"` Maintainer string `json:"maintainer,omitempty" yaml:"maintainer,omitempty"` MinimumRancherVersion string `json:"minimumRancherVersion,omitempty" yaml:"minimum_rancher_version,omitempty"` Name string `json:"name,omitempty" yaml:"name,omitempty"` Path string `json:"path,omitempty" yaml:"path,omitempty"` ProjectURL string `json:"projectURL,omitempty" yaml:"project_url,omitempty"` Questions []string `json:"questions,omitempty" yaml:"questions,omitempty"` ReadmeLink string `json:"readmeLink,omitempty" yaml:"readme_link,omitempty"` TemplateBase string `json:"templateBase,omitempty" yaml:"template_base,omitempty"` TemplateVersionRancherVersion map[string]interface{} `json:"templateVersionRancherVersion,omitempty" yaml:"template_version_rancher_version,omitempty"` Type string `json:"type,omitempty" yaml:"type,omitempty"` UpgradeVersionLinks map[string]interface{} `json:"upgradeVersionLinks,omitempty" yaml:"upgrade_version_links,omitempty"` Version string `json:"version,omitempty" yaml:"version,omitempty"` VersionLinks map[string]interface{} `json:"versionLinks,omitempty" yaml:"version_links,omitempty"` }
type TemplateVersionClient ¶
type TemplateVersionClient struct {
// contains filtered or unexported fields
}
func (*TemplateVersionClient) ById ¶
func (c *TemplateVersionClient) ById(id string) (*TemplateVersion, error)
func (*TemplateVersionClient) Create ¶
func (c *TemplateVersionClient) Create(container *TemplateVersion) (*TemplateVersion, error)
func (*TemplateVersionClient) Delete ¶
func (c *TemplateVersionClient) Delete(container *TemplateVersion) error
func (*TemplateVersionClient) List ¶
func (c *TemplateVersionClient) List(opts *ListOpts) (*TemplateVersionCollection, error)
func (*TemplateVersionClient) Update ¶
func (c *TemplateVersionClient) Update(existing *TemplateVersion, updates interface{}) (*TemplateVersion, error)
type TemplateVersionCollection ¶
type TemplateVersionCollection struct { Collection Data []TemplateVersion `json:"data,omitempty"` }
type TemplateVersionOperations ¶
type TemplateVersionOperations interface { List(opts *ListOpts) (*TemplateVersionCollection, error) Create(opts *TemplateVersion) (*TemplateVersion, error) Update(existing *TemplateVersion, updates interface{}) (*TemplateVersion, error) ById(id string) (*TemplateVersion, error) Delete(container *TemplateVersion) error }
Click to show internal directories.
Click to hide internal directories.