client/lxd_storage_volumes.go
func (r *ProtocolLXD) CreateStoragePoolVolumeSnapshot(pool string, volumeType string, volumeName string, snapshot api.StorageVolumeSnapshotsPost) (Operation, error) {
	if !r.HasExtension("storage_api_volume_snapshots") {
		return nil, fmt.Errorf("The server is missing the required \"storage_api_volume_snapshots\" API extension")
	}

	// Send the request
	path := fmt.Sprintf("/storage-pools/%s/volumes/%s/%s/snapshots",
		url.QueryEscape(pool),
		url.QueryEscape(volumeType),
		url.QueryEscape(volumeName))
	op, _, err := r.queryOperation("POST", path, snapshot, "")
	if err != nil {
		return nil, err
	}

	return op, nil
}
func (r *ProtocolLXD) CreateStoragePoolVolumeSnapshot(pool string, volumeType string, volumeName string, snapshot api.StorageVolumeSnapshotsPost) (Operation, error) {
	if !r.HasExtension("storage_api_volume_snapshots") {
		return nil, fmt.Errorf("The server is missing the required \"storage_api_volume_snapshots\" API extension")
	}

	// Send the request
	path := fmt.Sprintf("/storage-pools/%s/volumes/%s/%s/snapshots",
		url.QueryEscape(pool),
		url.QueryEscape(volumeType),
		url.QueryEscape(volumeName))
	op, _, err := r.queryOperation("POST", path, snapshot, "")
	if err != nil {
		return nil, err
	}

	return op, nil
}
func ( r * ProtocolLXD ) CreateStoragePoolVolumeSnapshot ( pool string , volumeType string , volumeName string , snapshot api . StorageVolumeSnapshotsPost ) ( Operation , error ) { if ! r . HasExtension ( " " ) { return nil , fmt . Errorf ( " \" \" " ) } // Send the request path := fmt . Sprintf ( " " , url . QueryEscape ( pool ) , url . QueryEscape ( volumeType ) , url . QueryEscape ( volumeName ) ) op , _ , err := r . queryOperation ( " " , path , snapshot , " " ) if err != nil { return nil , err } return op , nil }
// CreateStoragePoolVolumeSnapshot defines a new storage volume
CreateStoragePoolVolumeSnapshot defines a new storage volume