Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func List ¶
func List(client *gophercloud.ServiceClient, opts ListOptsBuilder) pagination.Pager
Types ¶
type CreateOpts ¶
type CreateOpts struct { // Name is the name of the Domain. Name string `json:"name"` Email string `json:"emailAddress"` TTL uint `json:"ttl"` Comment string `json:"comment"` }
CreateOpts contain the values necessary to create a domain
type CreateResult ¶
type CreateResult struct {
gophercloud.Result
}
CreateResult is the result of a Create operation
func Create ¶
func Create(client *gophercloud.ServiceClient, opts CreateOpts) (r CreateResult)
Create creates a requested domain
func (CreateResult) Extract ¶
func (r CreateResult) Extract() (*DomainList, error)
Extract interprets a CreateResult as a Domain.
type DeleteResult ¶
type DeleteResult struct {
gophercloud.ErrResult
}
method to determine if the call succeeded or failed.
func Delete ¶
func Delete(client *gophercloud.ServiceClient, id string) (r DeleteResult)
Delete deletes the specified domain ID.
type DomainList ¶
type DomainList struct { // ID is the unique ID of a domain. ID string // Created is the date when the domain was created. Created string // Updated is the date when the domain was updated. Updated string // EmailAddress is the email associated with this domain. Email string `json:"emailAddress"` // AccountID is the Tenant ID this domain is under AccountID string `json:"accountId"` // name is the domain name Name string }
DomainList represents a domain returned by the CloudDNS API.
func ExtractDomains ¶
func ExtractDomains(r pagination.Page) ([]DomainList, error)
ExtractDomains converts a page of List results into a slice of usable Domain structs.
type DomainPage ¶
type DomainPage struct {
pagination.LinkedPageBase
}
DomainPage contains a single page of all Domains returne from a List operation. Use ExtractDomains to convert it into a slice of usable structs.
func (DomainPage) IsEmpty ¶
func (r DomainPage) IsEmpty() (bool, error)
IsEmpty returns true if response contains no Domain results.
func (DomainPage) NextPageURL ¶
func (page DomainPage) NextPageURL() (string, error)
NextPageURL uses the response's embedded link reference to navigate to the next page of results.
type DomainShow ¶
type DomainShow struct { RecordsList struct { TotalEntries int `json:"totalEntries"` Records []struct { ID string `json:"id"` Name string `json:"name"` Type string `json:"type"` Data string `json:"data"` TTL uint `json:"ttl"` Updated string `json:"updated"` Created string `json:"created"` } `json:"records"` } `json:"recordsList"` TTL uint64 `json:"ttl"` Nameservers []struct { Name string `json:"name"` } `json:"nameservers"` AccountID string `json:"accountId"` ID string `json:"id"` Name string `json:"name"` EmailAddress string `json:"emailAddress"` Updated string `json:"updated"` Created string `json:"created"` Comment string `json:"comment"` }
DomainShow represents a domain returned by the CloudDNS API.
type GetResult ¶
type GetResult struct {
gophercloud.Result
}
GetResult is the response from a Get operation. Call its Extract method to interpret it as a Domain.
func Get ¶
func Get(client *gophercloud.ServiceClient, id string) (r GetResult)
Get returns data about a specific domain by its ID.
func (GetResult) Extract ¶
func (r GetResult) Extract() (*DomainShow, error)
Extract interprets a GetResult as a Domain.
type ListOpts ¶
type ListOpts struct { // Name is the name of the Domain. Name string `q:"name"` }
ListOpts contain options filtering Domains returned from a call to List.
func (ListOpts) ToDomainListQuery ¶
ToDomainListQuery formats a ListOpts into a query string.
type ListOptsBuilder ¶
ListOptsBuilder allows extensions to add additional parameters to the List request.
type UpdateOpts ¶
type UpdateOpts struct { Email string `json:"emailAddress,omitempty"` TTL uint `json:"ttl,omitempty"` Comment string `json:"comment,omitempty"` }
UpdateOpts contain the values necessary to create a domain
type UpdateResult ¶
type UpdateResult struct {
gophercloud.ErrResult
}
method to determine if the call succeeded or failed.
func Update ¶
func Update(client *gophercloud.ServiceClient, domain *DomainShow, opts UpdateOpts) (r UpdateResult)
Update updates a requested domain