Documentation

Overview

    Package images provides information and interaction with the image API resource for the Rackspace Cloud Servers service.

    +build fixtures

    Index

    Constants

    View Source
    const GetOutput = `` /* 1685-byte string literal not displayed */
    

      GetOutput is an example response from an /images request.

      View Source
      const ListOutput = `` /* 3472-byte string literal not displayed */
      

        ListOutput is an example response from an /images/detail request.

        Variables

        View Source
        var ArchImage = os.Image{
        	ID:       "30aa010e-080e-4d4b-a7f9-09fc55b07d69",
        	Name:     "Arch 2014.10 (PVHVM)",
        	Created:  "2014-10-01T15:49:02Z",
        	Updated:  "2014-10-01T19:37:58Z",
        	MinDisk:  20,
        	MinRAM:   512,
        	Progress: 100,
        	Status:   "ACTIVE",
        }

          ArchImage is the first Image structure that should be parsed from ListOutput.

          View Source
          var ExpectedImageSlice = []os.Image{ArchImage, UbuntuImage}

            ExpectedImageSlice is the collection of images that should be parsed from ListOutput, in order.

            View Source
            var UbuntuImage = os.Image{
            	ID:       "e19a734c-c7e6-443a-830c-242209c4d65d",
            	Name:     "Ubuntu 14.04 LTS (Trusty Tahr)",
            	Created:  "2014-10-01T12:58:11Z",
            	Updated:  "2014-10-01T15:51:44Z",
            	MinDisk:  20,
            	MinRAM:   512,
            	Progress: 100,
            	Status:   "ACTIVE",
            }

              UbuntuImage is the second Image structure that should be parsed from ListOutput and the only image that should be extracted from GetOutput.

              Functions

              func ExtractImages

              func ExtractImages(page pagination.Page) ([]os.Image, error)

                ExtractImages interprets a page as a collection of server images.

                func Get

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

                  Get acquires additional detail about a specific image by ID.

                  func ListDetail

                  func ListDetail(client *gophercloud.ServiceClient, opts os.ListOptsBuilder) pagination.Pager

                    ListDetail enumerates the available server images.

                    Types

                    This section is empty.