package com.bocloud.cmp.provider.storage;

import java.util.List;

import com.bocloud.cmp.model.*;
import com.bocloud.cmp.model.h3c.H3cVolumeModel;
import com.bocloud.cmp.model.storage.StorageGroupModel;
import com.bocloud.cmp.provider.SuperProvider;
import com.bocloud.common.model.BocloudResult;

public interface VolumeProvider extends SuperProvider {
    @Override
    public boolean accessable();

    default BocloudResult list() {
        return null;
    }

    default BocloudResult create(VolumeModel volume) {
        return null;
    }

    default BocloudResult getVolumeSamples(Long volumeId) {
        return null;
    }

    default BocloudResult list(String hostId, String storagePoolName) {
        return null;
    }

    default BocloudResult remove(H3cVolumeModel volume) {
        return null;
    }

    default BocloudResult createVolumeType(VolumeTypeModel model) {
        return null;
    }

    default BocloudResult deleteVolumeType(String volumeTypeUuid) {
        return null;
    }

    default BocloudResult modify(VolumeModel volume) {
        return null;
    }

    default BocloudResult migrateVolume(VolumeModel volume) {
        return null;
    }

    default BocloudResult copyVolume(VolumeModel volume) {
        return null;
    }

    default BocloudResult remove(String volumeId) {
        return null;
    }

    default BocloudResult detail(String volumeId) {
        return null;
    }

    default BocloudResult snapshot(SnapshotModel snapshotModel) {
        return null;
    }

    default BocloudResult attach(String serverId, String volumeId) {
        return null;
    }

    default BocloudResult attach(String serverId, String mountpoint, String volumeId) {
        return null;
    }

    default BocloudResult detach(String serverId, String volumeId) {
        return null;
    }

    default BocloudResult resetStatus(String volumeId, String status) {
        return null;
    }

    default BocloudResult uploadToImage(String volumeId, ImageModel imageModel) {
        return null;
    }

    default BocloudResult extend(String volumeId, Integer newSize) {
        return null;
    }

    default BocloudResult list(String zone) {
        return null;
    }

    default BocloudResult extend(String volumeId, Integer newSize, String type) {
        return null;
    }

    /**
     * 删除云硬盘
     *
     * @param volume
     * @return
     */
    default BocloudResult remove(VolumeModel volume) {
        return null;
    }

    default BocloudResult onboard(String storageName, List<String> volumeIds) {
        return null;
    }

    default BocloudResult unmanage(String storageName, List<String> volumeIds) {
        return null;
    }

    default BocloudResult allVolumes(String storageName) {
        return null;
    }

    default BocloudResult setMetadata(String volumeUuid, VolumeMetadataModel metadataModel) {
        return null;
    }

    default BocloudResult listMirrors(String volumeUuid) {
        return null;
    }

    default BocloudResult addGroups(String volumeKeyPath, List<StorageGroupModel> model) {
        return null;
    }

    default BocloudResult removeGroups(String volumeKeyPath, List<StorageGroupModel> model) {
        return null;
    }

    default BocloudResult getMetadata(String volumeUuid) {
        return null;
    }

    default BocloudResult attach(VolumeModel model) {
        return null;
    }

    /**
     * 查询支持的磁盘类型
     *
     * @return
     */
    default BocloudResult listVolumeTypes() {
        return null;
    }

    default BocloudResult createTag(VolumeModel model) {
        return null;
    }

    default BocloudResult removeTag(VolumeModel model) {
        return null;
    }

    // 恢复云硬盘
    default BocloudResult restore(VolumeModel model) {
        return null;
    }
    
    default BocloudResult cinderListQuotasSolution() {
        return null;
    }

    default BocloudResult listByVdc(String siteUri) {
        return new BocloudResult(false, "need implement");
    }

    default BocloudResult attach(String serverId, VolumeModel model) {
        return null;
    }

    default BocloudResult listPolicy(String volumeUuid) {
        return null;
    }

}
