regions

package
Version: v0.0.0-...-892e304 Latest Latest
Warning

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

Go to latest
Published: Jul 20, 2018 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetAZNameList

func GetAZNameList() (names []string)

GetAZNameList returns a list of AWS Availability Zone Names as slice of strings

func GetRegionAZs

func GetRegionAZs(region string, azList *AZs) error

GetRegionAZs returns a slice of a regions Availability Zones into the provided AZs

func GetRegionList

func GetRegionList() []*ec2.Region

GetRegionList returns a list of AWS Regions as a slice of *ec2.Region

func GetRegionNameList

func GetRegionNameList() (names []string)

GetRegionNameList returns a list of AWS Region Names as slice of strings

func ValidRegion

func ValidRegion(region string) bool

ValidRegion returns true if the provided region is valid

Types

type AZ

type AZ struct {
	Name   string `json:"name"`
	Region string `json:"region"`
	State  string `json:"state"`
}

AZ represents a single Availability Zone

type AZs

type AZs []AZ

AZs represents a slice of Availability Zones

func GetAZs

func GetAZs() (*AZs, []error)

GetAZs returns a slice of Availability Zones

func (*AZs) GetRegion

func (a *AZs) GetRegion(az string) string

GetRegion returns the region of a provided Availability Zone

func (*AZs) GetRegionMap

func (a *AZs) GetRegionMap(azList []string) map[string][]string

GetRegionMap returns a map of Regions and their Availability Zones

func (*AZs) ValidAZ

func (a *AZs) ValidAZ(az string) bool

ValidAZ returns true if the provided string is a valid Availability Zone

Source Files

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL