volumetransfer

package
v1.0.21 Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2020 License: Apache-2.0 Imports: 2 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

Types

type AcceptOpts

type AcceptOpts struct {
	AuthKey string `json:"auth_key" required:"true"`
}

func (AcceptOpts) ToVolumeAcceptMap

func (opts AcceptOpts) ToVolumeAcceptMap() (map[string]interface{}, error)

type AcceptOptsBuilder

type AcceptOptsBuilder interface {
	ToVolumeAcceptMap() (map[string]interface{}, error)
}

type AcceptResult

type AcceptResult struct {
	// contains filtered or unexported fields
}

func Accept

func Accept(client *gophercloud.ServiceClient, transferID string, opts AcceptOptsBuilder) (r AcceptResult)

func (AcceptResult) Extract

func (r AcceptResult) Extract() (TransferAccept, error)

type CreateOpts

type CreateOpts struct {
	// The volume name
	Name     string `json:"name,omitempty"`
	VolumeID string `json:"volume_id" required:"true"`
}

func (CreateOpts) ToVolumeCreateMap

func (opts CreateOpts) ToVolumeCreateMap() (map[string]interface{}, error)

ToVolumeCreateMap assembles a request body based on the contents of a CreateOpts.

type CreateOptsBuilder

type CreateOptsBuilder interface {
	ToVolumeCreateMap() (map[string]interface{}, error)
}

CreateOptsBuilder allows extensions to add additional parameters to the Create request.

type CreateResult

type CreateResult struct {
	// contains filtered or unexported fields
}

CreateResult contains the response body and error from a Create request.

func Create

func Create(client *gophercloud.ServiceClient, opts CreateOptsBuilder) (r CreateResult)

Create will create a new Volume based on the values in CreateOpts. To extract the Volume object from the response, call the Extract method on the CreateResult.

func (CreateResult) Extract

func (r CreateResult) Extract() (Transfer, error)

type DeleteResult

type DeleteResult struct {
	gophercloud.ErrResult
}

DeleteResult contains the response body and error from a Delete request.

func Delete

func Delete(client *gophercloud.ServiceClient, transferID string) (r DeleteResult)

type GetResult

type GetResult struct {
	// contains filtered or unexported fields
}

GetResult contains the response body and error from a Get request.

func Get

func Get(client *gophercloud.ServiceClient, transferID string) (r GetResult)

func (GetResult) Extract

func (r GetResult) Extract() (TransferInfo, error)
type Links struct {
	Href string `json:"href"`
	Rel  string `json:"rel"`
}

type ListDetailOpts

type ListDetailOpts struct {
	Limit  int `q:"limit"`
	Offset int `q:"offset"`
}

func (ListDetailOpts) ToVolumeListDetailQuery

func (opts ListDetailOpts) ToVolumeListDetailQuery() (string, error)

ToVolumeListQuery formats a ListOpts into a query string.

type ListDetailOptsBuilder

type ListDetailOptsBuilder interface {
	ToVolumeListDetailQuery() (string, error)
}

type Transfer

type Transfer struct {
	ID        string  `json:"id"`
	CreatedAt string  `json:"created_at"`
	Name      string  `json:"name"`
	VolumeID  string  `json:"volume_id"`
	AuthKey   string  `json:"auth_key"`
	Links     []Links `json:"links"`
}

type TransferAccept

type TransferAccept struct {
	ID       string  `json:"id"`
	Name     string  `json:"name"`
	VolumeID string  `json:"volume_id"`
	Links    []Links `json:"links"`
}

func ExtractTransferList

func ExtractTransferList(r pagination.Page) ([]TransferAccept, error)

type TransferDetailsPage

type TransferDetailsPage struct {
	pagination.SinglePageBase
}

func (TransferDetailsPage) IsEmpty

func (r TransferDetailsPage) IsEmpty() (bool, error)

type TransferInfo

type TransferInfo struct {
	ID        string  `json:"id"`
	CreatedAt string  `json:"created_at"`
	Name      string  `json:"name"`
	VolumeID  string  `json:"volume_id"`
	Links     []Links `json:"links"`
}

func ExtractTransferDetails

func ExtractTransferDetails(r pagination.Page) ([]TransferInfo, error)

type TransferListPage

type TransferListPage struct {
	pagination.SinglePageBase
}

func (TransferListPage) IsEmpty

func (r TransferListPage) IsEmpty() (bool, error)

Jump to

Keyboard shortcuts

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