// **********************************************************************
|
//
|
// Copyright (c) 2008-2023 VCI-Tech, Inc. All rights reserved.
|
//
|
// This copy of Ice is licensed to you under the terms described the
|
// ICE_LICENSE file included this distribution.
|
//
|
// **********************************************************************
|
|
#pragma once
|
|
#include "01-common.ice"
|
//#include "02-framework.ice"
|
|
[["java:package:com.vci.corba"]]
|
["cs:namespace:com.vci.corba"]
|
|
|
// module com {
|
// module vci {
|
// module corba {
|
module volume {
|
module data {
|
|
// 文件信息
|
struct FileInfo {
|
string filePath;
|
string fileSavePath;
|
bool isDirectory;
|
long fileSize;
|
};
|
sequence<FileInfo> FileInfoList;
|
|
// 卷使用情况
|
struct VolumeUseInfo {
|
string id;
|
string name;
|
string host;
|
long type;
|
string path;
|
string usedSize;
|
string diskSize;
|
};sequence<VolumeUseInfo> VolumeUseInfoList;
|
};// data
|
|
interface VolumeService {
|
// 获取文件传输块大小
|
long getTransmitBlockSize() throws common::VCIError;
|
// 根据卷路径判断文件是否存在
|
bool isFileExist(string fileName) throws common::VCIError;
|
//判断路径是否存在
|
bool existPath(string filePath) throws common::VCIError;
|
//得到系统当前时间
|
long getCurrrentTimeMillions();
|
//获取当前文件柜服务器Host信息(返回格式为"HostIPIP@|@HostName")[冗余存储主要解决可能由于文件柜服务器部署变更引起的问题分析, ADD By ZhongGY 2015-03-24]
|
string getHostInfo() throws common::VCIError;
|
//得到文件修改时间
|
long getFileModifiedTime(string fileName) throws common::VCIError;
|
//得到文件大小
|
long getFileSize(string fileName)throws common::VCIError;
|
//删除文件
|
bool deleteFile(string fileName) throws common::VCIError;
|
//更改文件名称
|
bool ChangeFileName(string resName,string desName) throws common::VCIError;
|
//服务器端接收文件,客户端上传文件
|
bool receiveFile(string fileName,common::data::bytes file,long pointoffile,long modifiedtime,long filesize) throws common::VCIError;
|
// 校验上传到卷服务的文件是否完整(完成)
|
// destFileFullPath: 远程文件完整路径
|
// clientFileSize: 客户端文件大小
|
// clientFileMD5: 客户端文件MD5值
|
// otherParams: 其它保留参数
|
bool verifyFileUploadSuccess(string destFileFullPath, long clientFileSize,
|
string clientFileMD5, common::data::StringArray otherParams)
|
throws common::VCIError;
|
//创建目录
|
bool createDirectory(string historyDirectory, string directoryName) throws common::VCIError;
|
//删除指定文件及其所有备份
|
bool deleteAllFiles(common::data::StringArray fileNames) throws common::VCIError;
|
//删除指定文件的所有备份
|
bool deleteAllBakFiles(string fileName) throws common::VCIError;
|
//服务器端发送文件,客户端下载文件
|
common::data::bytes sendFile(string fileName, long pointoffile) throws common::VCIError;
|
|
//common::data::byteSeq downloadFile(string fileName) throws common::VCIError;
|
|
//获取服务器目录的所有文件列表
|
data::FileInfoList getFileList(string path, string savePath) throws common::VCIError;
|
|
//获取服务器目录的所有文件列表
|
data::FileInfoList getFolderFiles(string path) throws common::VCIError;
|
|
//获取服务器目录的子目录
|
common::data::StringArray getSubFolders(string path) throws common::VCIError;
|
|
//得到文件的md5值,用于比较文件内容是否一样
|
string getFileMD5(string fileName) throws common::VCIError;
|
|
//通过集成方式获得文件大小
|
long getIntegrationFileSize(string fileName) throws common::VCIError;
|
|
//集成方式服务器端发送文件
|
common::data::bytes receiveIntegrationFile(string fileName, long pointoffile) throws common::VCIError;
|
|
//复制文件
|
bool copyFile(string fromFileName, string copyFileName) throws common::VCIError;
|
|
bool testConntect();
|
//获取文件柜使用情况
|
data::VolumeUseInfoList getVolumeUseInfo() throws common::VCIError;
|
}; // VolumeService
|
|
}//volume
|
// }}}
|