Documentation
¶
Index ¶
- func ExtractInterconnectionssInto(r pagination.Page, v any) error
- func List(c *gophercloud.ServiceClient, opts ListOptsBuilder) pagination.Pager
- type CreateOpts
- type CreateOptsBuilder
- type CreateResult
- type DeleteResult
- type GetResult
- type Interconnection
- type InterconnectionPage
- type ListOpts
- type ListOptsBuilder
- type Parameters
- type UpdateOpts
- type UpdateOptsBuilder
- type UpdateResult
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ExtractInterconnectionssInto ¶
func ExtractInterconnectionssInto(r pagination.Page, v any) error
func List ¶
func List(c *gophercloud.ServiceClient, opts ListOptsBuilder) pagination.Pager
List makes a request against the API to list interconnections accessible to you.
Types ¶
type CreateOpts ¶
type CreateOpts struct {
Name string `json:"name,omitempty"`
ProjectID string `json:"project_id,omitempty"`
Type string `json:"type,omitempty"`
LocalResourceID string `json:"local_resource_id"`
RemoteResourceID string `json:"remote_resource_id"`
RemoteRegion string `json:"remote_region"`
RemoteInterconnectionID string `json:"remote_interconnection_id,omitempty"`
}
CreateOpts represents options used to create an interconnection.
func (CreateOpts) ToInterconnectionCreateMap ¶
func (opts CreateOpts) ToInterconnectionCreateMap() (map[string]any, error)
ToInterconnectionCreateMap formats a CreateOpts into a map.
type CreateOptsBuilder ¶
CreateOptsBuilder allows extensions to add additional parameters to the Create request.
type CreateResult ¶
type CreateResult struct {
// contains filtered or unexported fields
}
CreateResult represents the result of a create operation.
func Create ¶
func Create(c *gophercloud.ServiceClient, opts CreateOptsBuilder) (r CreateResult)
Create creates a new interconnection.
func (CreateResult) Extract ¶
func (r CreateResult) Extract() (*Interconnection, error)
Extract will extract a response object from a result.
func (CreateResult) ExtractInto ¶
type DeleteResult ¶
type DeleteResult struct {
gophercloud.ErrResult
}
DeleteResult represents the result of a delete operation.
func Delete ¶
func Delete(c *gophercloud.ServiceClient, id string) (r DeleteResult)
Delete deletes an interconnection.
type GetResult ¶
type GetResult struct {
// contains filtered or unexported fields
}
GetResult represents the result of a get operation.
func Get ¶
func Get(c *gophercloud.ServiceClient, id string) (r GetResult)
Get retrieves a specific interconnection based on its ID.
func (GetResult) Extract ¶
func (r GetResult) Extract() (*Interconnection, error)
Extract will extract a response object from a result.
func (GetResult) ExtractInto ¶
type Interconnection ¶
type Interconnection struct {
ID string `json:"id"`
Name string `json:"name"`
ProjectID string `json:"project_id"`
TenantID string `json:"tenant_id"`
Type string `json:"type"`
State string `json:"state"`
LocalResourceID string `json:"local_resource_id"`
RemoteResourceID string `json:"remote_resource_id"`
RemoteRegion string `json:"remote_region"`
RemoteInterconnectionID string `json:"remote_interconnection_id"`
LocalParameters Parameters `json:"local_parameters"`
RemoteParameters Parameters `json:"remote_parameters"`
}
Interconnection represents the structure of an interconnection object.
func ExtractInterconnections ¶
func ExtractInterconnections(r pagination.Page) ([]Interconnection, error)
ExtractInterconnections accepts a Page struct, specifically a InterconnectionPage struct, and extracts the elements into a slice of Interconnection structs. In other words, a generic collection is mapped into a relevant slice.
type InterconnectionPage ¶
type InterconnectionPage struct {
pagination.MarkerPageBase
}
InterconnectionPage
func (InterconnectionPage) IsEmpty ¶
func (r InterconnectionPage) IsEmpty() (bool, error)
IsEmpty checks whether a Interconnection struct is empty.
func (InterconnectionPage) LastMarker ¶
func (r InterconnectionPage) LastMarker() (string, error)
LastMarker returns the last offset in a ListResult.
func (InterconnectionPage) NextPageURL ¶
func (r InterconnectionPage) NextPageURL() (string, error)
NextPageURL is invoked when a paginated collection of interconnections has reached the end of a page and the pager seeks to traverse to the next page.
type ListOpts ¶
type ListOpts struct {
ID []string `q:"id"`
State []string `q:"state"`
ProjectID []string `q:"project_id"`
Name []string `q:"name"`
Type []string `q:"type"`
LocalResourceID []string `q:"local_resource_id"`
RemoteResourceID []string `q:"remote_resource_id"`
RemoteRegion []string `q:"remote_region"`
RemoteInterconnectionID []string `q:"remote_interconnection_id"`
Fields []string `q:"fields"`
Limit int `q:"limit"`
Marker string `q:"marker"`
}
ListOpts allows the filtering and sorting of paginated collections through the API.
func (ListOpts) ToInterconnectionListQuery ¶
ToInterconnectionListQuery formats a ListOpts into a query string.
type ListOptsBuilder ¶
ListOptsBuilder allows extensions to add additional parameters to the List request.
type Parameters ¶
type Parameters struct {
ProjectID []string `json:"project_id"`
}
Parameter represents the structure of a parameter object.
type UpdateOpts ¶
type UpdateOpts struct {
Name *string `json:"name,omitempty"`
State *string `json:"state,omitempty"`
RemoteInterconnectionID *string `json:"remote_interconnection_id,omitempty"`
}
UpdateOpts represents options used to update an interconnection.
func (UpdateOpts) ToInterconnectionUpdateMap ¶
func (opts UpdateOpts) ToInterconnectionUpdateMap() (map[string]any, error)
ToInterconnectionUpdateMap formats an UpdateOpts into a map.
type UpdateOptsBuilder ¶
UpdateOptsBuilder allows extensions to add additional parameters to the Update request.
type UpdateResult ¶
type UpdateResult struct {
// contains filtered or unexported fields
}
UpdateResult represents the result of an update operation.
func Update ¶
func Update(c *gophercloud.ServiceClient, id string, opts UpdateOptsBuilder) (r UpdateResult)
Update allows interconnections to be updated.
func (UpdateResult) Extract ¶
func (r UpdateResult) Extract() (*Interconnection, error)
Extract will extract a response object from a result.