github.com/gophercloud/gophercloud@v1.11.0/openstack/sharedfilesystems/apiversions/errors.go (about) 1 package apiversions 2 3 import ( 4 "fmt" 5 ) 6 7 // ErrVersionNotFound is the error when the requested API version 8 // could not be found. 9 type ErrVersionNotFound struct{} 10 11 func (e ErrVersionNotFound) Error() string { 12 return fmt.Sprintf("Unable to find requested API version") 13 } 14 15 // ErrMultipleVersionsFound is the error when a request for an API 16 // version returns multiple results. 17 type ErrMultipleVersionsFound struct { 18 Count int 19 } 20 21 func (e ErrMultipleVersionsFound) Error() string { 22 return fmt.Sprintf("Found %d API versions", e.Count) 23 }