package cn.reghao.oss.api.iface;

import cn.reghao.oss.api.dto.ObjectInfo;
import cn.reghao.oss.api.dto.StoreInfo;
import cn.reghao.oss.api.dto.media.AudioInfo;
import cn.reghao.oss.api.dto.media.ConvertedImageInfo;
import cn.reghao.oss.api.dto.media.ImageInfo;
import cn.reghao.oss.api.dto.media.VideoInfo;

/**
 * 对 oss-store 进行操作
 * 第三方通过 oss-console 调用
 *
 * @author reghao
 * @date 2024-04-23 15:14:06
 */
public interface StoreServiceWrapper {
    int getChannelScope(int channelId);

    void createChannel(int channelId, String channelPrefix);
    StoreInfo getStoreInfo(int channelId);

    void setObjectScope(int channelId, String objectId, int scope);
    void deleteByObjectId(int channelId, String objectId);
    void deleteByObjectUrl(String objectUrl);
    ObjectInfo getObjectInfo(int channelId, String objectId);
    String getSignedUrl(int channelId, String objectId);

    VideoInfo getVideoInfo(int channelId, String objectId);
    ImageInfo getImageInfo(int channelId, String objectId);
    ConvertedImageInfo getWebpInfo(int channelId, String objectId);
    AudioInfo getAudioInfo(int channelId, String objectId);
}
