client/lxd_storage_volumes.go
func (r *ProtocolLXD) GetStoragePoolVolumes(pool string) ([]api.StorageVolume, error) {
	if !r.HasExtension("storage") {
		return nil, fmt.Errorf("The server is missing the required \"storage\" API extension")
	}

	volumes := []api.StorageVolume{}

	// Fetch the raw value
	_, err := r.queryStruct("GET", fmt.Sprintf("/storage-pools/%s/volumes?recursion=1", url.QueryEscape(pool)), nil, "", &volumes)
	if err != nil {
		return nil, err
	}

	return volumes, nil
}
func (r *ProtocolLXD) GetStoragePoolVolumes(pool string) ([]api.StorageVolume, error) {
	if !r.HasExtension("storage") {
		return nil, fmt.Errorf("The server is missing the required \"storage\" API extension")
	}

	volumes := []api.StorageVolume{}

	// Fetch the raw value
	_, err := r.queryStruct("GET", fmt.Sprintf("/storage-pools/%s/volumes?recursion=1", url.QueryEscape(pool)), nil, "", &volumes)
	if err != nil {
		return nil, err
	}

	return volumes, nil
}
func ( r * ProtocolLXD ) GetStoragePoolVolumes ( pool string ) ( [ ] api . StorageVolume , error ) { if ! r . HasExtension ( " " ) { return nil , fmt . Errorf ( " \" \" " ) } volumes := [ ] api . StorageVolume { } // Fetch the raw value _ , err := r . queryStruct ( " " , fmt . Sprintf ( " " , url . QueryEscape ( pool ) ) , nil , " " , & volumes ) if err != nil { return nil , err } return volumes , nil }
// GetStoragePoolVolumes returns a list of StorageVolume entries for the provided pool
GetStoragePoolVolumes returns a list of StorageVolume entries for the provided pool