gophercloud: github.com/rackspace/gophercloud/openstack/db/v1/flavors Index | Files

package flavors

import "github.com/rackspace/gophercloud/openstack/db/v1/flavors"

Package flavors provides information and interaction with the flavor API resource in the OpenStack Database service.

A flavor is an available hardware configuration for a database instance. Each flavor has a unique combination of disk space, memory capacity and priority for CPU time.

Index

Package Files

doc.go requests.go results.go urls.go

func List Uses

func List(client *gophercloud.ServiceClient) pagination.Pager

List will list all available hardware flavors that an instance can use. The operation is identical to the one supported by the Nova API, but without the "disk" property.

type Flavor Uses

type Flavor struct {
    // The flavor's unique identifier.
    ID  string `mapstructure:"id"`

    // The RAM capacity for the flavor.
    RAM int `mapstructure:"ram"`

    // The Name field provides a human-readable moniker for the flavor.
    Name string `mapstructure:"name"`

    // Links to access the flavor.
    Links []gophercloud.Link
}

Flavor records represent (virtual) hardware configurations for server resources in a region.

func ExtractFlavors Uses

func ExtractFlavors(page pagination.Page) ([]Flavor, error)

ExtractFlavors provides access to the list of flavors in a page acquired from the List operation.

type FlavorPage Uses

type FlavorPage struct {
    pagination.LinkedPageBase
}

FlavorPage contains a single page of the response from a List call.

func (FlavorPage) IsEmpty Uses

func (p FlavorPage) IsEmpty() (bool, error)

IsEmpty determines if a page contains any results.

func (FlavorPage) NextPageURL Uses

func (p FlavorPage) NextPageURL() (string, error)

NextPageURL uses the response's embedded link reference to navigate to the next page of results.

type GetResult Uses

type GetResult struct {
    gophercloud.Result
}

GetResult temporarily holds the response from a Get call.

func Get Uses

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

Get will retrieve information for a specified hardware flavor.

func (GetResult) Extract Uses

func (gr GetResult) Extract() (*Flavor, error)

Extract provides access to the individual Flavor returned by the Get function.

Package flavors imports 3 packages (graph) and is imported by 3 packages. Updated 2018-07-02. Refresh now. Tools for package owners.