|
|
@ -2,6 +2,7 @@ package com.fanruan.api.cluster.resource; |
|
|
|
|
|
|
|
|
|
|
|
import com.fr.decision.fileserver.FineFileServer; |
|
|
|
import com.fr.decision.fileserver.FineFileServer; |
|
|
|
import com.fr.io.config.RepositoryConfig; |
|
|
|
import com.fr.io.config.RepositoryConfig; |
|
|
|
|
|
|
|
import com.fr.io.repository.ResourceRepository; |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* 文件服务器Kit. |
|
|
|
* 文件服务器Kit. |
|
|
@ -22,4 +23,15 @@ public class FineFileServerKit { |
|
|
|
return FineFileServer.getInstance().getRepoConfig(); |
|
|
|
return FineFileServer.getInstance().getRepoConfig(); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
|
|
|
* 文件服务器读写权限测试. |
|
|
|
|
|
|
|
* |
|
|
|
|
|
|
|
* @param repo 仓库 |
|
|
|
|
|
|
|
* @param workRoot 工作路径 |
|
|
|
|
|
|
|
* @return 是否有读写权限 |
|
|
|
|
|
|
|
*/ |
|
|
|
|
|
|
|
public static boolean hasReadWritePermission(ResourceRepository repo, String workRoot) { |
|
|
|
|
|
|
|
return FineFileServer.getInstance().hasReadWritePermission(repo, workRoot); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|