#ifndef _VOLUME_IDL
|
#define _VOLUME_IDL
|
|
#include "01-base.idl"
|
#include "02-framework.idl"
|
|
module com {
|
module vci {
|
module corba {
|
module volume {
|
module data {
|
/**卷信息**/
|
struct PvolumeInfo {
|
wstring id; //卷id
|
wstring name; //卷名称
|
wstring host; //卷所在的服务器
|
wstring service;//卷所在的服务
|
long type; //卷服务器类型
|
wstring path; //卷所在服务器路径
|
long isvalid; //是否为首选路径
|
};
|
typedef sequence<PvolumeInfo> PvolumeInfoList;
|
// 文件信息
|
struct FileInfo {
|
wstring filePath;
|
wstring fileSavePath;
|
boolean isDirectory;
|
long long fileSize;
|
};
|
typedef sequence<FileInfo> FileInfoList;
|
|
// 卷使用情况
|
struct VolumeUseInfo {
|
long isvalid;
|
wstring id;
|
wstring name;
|
wstring host;
|
wstring service;
|
long type;
|
wstring path;
|
wstring usedSize;
|
wstring diskSize;
|
};typedef sequence<VolumeUseInfo> VolumeUseInfoList;
|
};// data
|
|
interface VolumeService {
|
// 根据卷路径判断文件是否存在
|
boolean isFileExist(in wstring fileName) raises (corba::common::VCIError);
|
//判断路径是否存在
|
boolean existPath(in wstring filePath) raises (corba::common::VCIError);
|
//得到系统当前时间
|
long long getCurrrentTimeMillions();
|
//获取当前文件柜服务器Host信息(返回格式为"HostIPIP@|@HostName")[冗余存储主要解决可能由于文件柜服务器部署变更引起的问题分析, ADD By ZhongGY 2015-03-24]
|
wstring getHostInfo() raises (corba::common::VCIError);
|
//得到文件修改时间
|
long long getFileModifiedTime(in wstring fileName) raises (corba::common::VCIError);
|
//得到文件大小
|
long long getFileSize(in wstring fileName)raises (corba::common::VCIError);
|
//删除文件
|
boolean deleteFile(in wstring fileName) raises (corba::common::VCIError);
|
//更改文件名称
|
boolean ChangeFileName(in wstring resName,in wstring desName) raises (corba::common::VCIError);
|
//服务器端接收文件,客户端上传文件
|
boolean receiveFile(in wstring fileName,in corba::common::data::bytes file,in long long pointoffile,in long long modifiedtime,in long long filesize) raises (corba::common::VCIError);
|
// 校验上传到卷服务的文件是否完整(完成)
|
// destFileFullPath: 远程文件完整路径
|
// clientFileSize: 客户端文件大小
|
// clientFileMD5: 客户端文件MD5值
|
// otherParams: 其它保留参数
|
boolean verifyFileUploadSuccess(in wstring destFileFullPath, in long long clientFileSize,
|
in wstring clientFileMD5, in corba::common::data::WStringArray otherParams)
|
raises (corba::common::VCIError);
|
//创建目录
|
boolean createDirectory(in wstring historyDirectory, in wstring directoryName) raises (corba::common::VCIError);
|
//删除指定文件及其所有备份
|
boolean deleteAllFiles(in corba::common::data::WStringArray fileNames) raises (corba::common::VCIError);
|
//删除指定文件的所有备份
|
boolean deleteAllBakFiles(in wstring fileName) raises (corba::common::VCIError);
|
//服务器端发送文件,客户端下载文件
|
corba::common::data::bytes sendFile(in wstring fileName, in long long pointoffile) raises (corba::common::VCIError);
|
|
corba::common::data::byteSeq downloadFile(in wstring fileName) raises (corba::common::VCIError);
|
|
//获取服务器目录的所有文件列表
|
data::FileInfoList getFileList(in wstring path, in wstring savePath) raises (corba::common::VCIError);
|
|
//获取服务器目录的所有文件列表
|
data::FileInfoList getFolderFiles(in wstring path) raises (corba::common::VCIError);
|
|
//获取服务器目录的子目录
|
com::vci::corba::common::data::WStringArray getSubFolders(in wstring path) raises (corba::common::VCIError);
|
|
//得到文件的md5值,用于比较文件内容是否一样
|
wstring getFileMD5(in wstring fileName) raises (corba::common::VCIError);
|
|
//通过集成方式获得文件大小
|
long long getIntegrationFileSize(in string fileName) raises (corba::common::VCIError);
|
|
//集成方式服务器端发送文件
|
corba::common::data::bytes receiveIntegrationFile(in string fileName, in long long pointoffile) raises (corba::common::VCIError);
|
|
//复制文件
|
boolean copyFile(in wstring fromFileName, in wstring copyFileName) raises (corba::common::VCIError);
|
|
boolean testConntect();
|
//获取文件柜使用情况
|
data::VolumeUseInfoList getVolumeUseInfo() raises (corba::common::VCIError);
|
}; // VolumeService
|
|
interface VolumeFactory {
|
/**卷管理**/
|
/**读取所有的卷**/
|
data::PvolumeInfoList getAllPvolumes() raises(com::vci::corba::common::VCIError);
|
// 查询默认卷
|
data::PvolumeInfo getDefaultVolume() raises(com::vci::corba::common::VCIError);
|
/**分页读取卷**/
|
data::PvolumeInfoList getPvolumesPage(in long pageSize, in long pageIndex) raises(com::vci::corba::common::VCIError);
|
/**卷创建**/
|
wstring savePvolume(in data::PvolumeInfo vol, in com::vci::corba::framework::data::UserEntityInfo userEntity) raises (com::vci::corba::common::VCIError);
|
/**卷修改**/
|
boolean updatePvolume(in data::PvolumeInfo vol, in com::vci::corba::framework::data::UserEntityInfo userEntity) raises (com::vci::corba::common::VCIError);
|
/**卷删除**/
|
boolean deletePvolume(in com::vci::corba::common::data::WStringArray ids, in com::vci::corba::framework::data::UserEntityInfo userEntity) raises (com::vci::corba::common::VCIError);
|
/**获取文档所在的卷**/
|
data::PvolumeInfo getDocumentVolume(in wstring id) raises (com::vci::corba::common::VCIError);
|
/**修改卷,将系统中的其他卷设置为非首选 0**/
|
void updatePvolumeHql(in com::vci::corba::framework::data::UserEntityInfo userEntity) raises (com::vci::corba::common::VCIError);
|
/**查看卷是否被引用**/
|
long fetchVolumeInfoByIds(in wstring id) raises (com::vci::corba::common::VCIError);
|
/**检查要删除的卷是否为首选路径**/
|
boolean checkDelIsvalid(in wstring id) raises (com::vci::corba::common::VCIError);
|
/**获取当前首选卷**/
|
data::PvolumeInfo getIsvalidVolumeName()raises (com::vci::corba::common::VCIError);
|
/** 返回一个在服务器端有效的卷对象 ${user.dir}\attachments\ **/
|
data::PvolumeInfo getIsvalidVolumeNameInServerEnv() raises (com::vci::corba::common::VCIError);
|
// 获取文件传输块大小
|
long getTransmitBlockSize() raises (com::vci::corba::common::VCIError);
|
|
// 获取卷服务
|
//VolumeService getVolumeService() raises (corba::common::VCIError);
|
|
};// VolumeFactory
|
};//volume
|
};//corba
|
};//vci
|
};//com
|
#endif
|