类 MultiLocalStore
java.lang.Object
gu.sql2java.store.BaseURLStore
gu.sql2java.store.BasesLocalBinaryStore
gu.sql2java.store.MultiLocalStore
- 所有已实现的接口:
URLStore,URLStreamHandlerFactory
基于
LocalBinaryStore 支持多分区存储的URLStore实现- 从以下版本开始:
- 3.32.6
- 作者:
- guyadong
-
字段概要
从类继承的字段 gu.sql2java.store.BasesLocalBinaryStore
storeRoot从类继承的字段 gu.sql2java.store.BaseURLStore
additionalParams -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明voidaddPartition(String partition, int level) 增加存储分区voidaddPartition(String partition, LocalBinaryStore localBinaryStore) 增加partition指定的名字的分区protected URL查找指定MD5的二进制数据protected URL存储图像数据boolean返回指定前缀(分区)的存储实例inthashCode()<T> URLstore(String partition, T binary, String md5, String extension, boolean overwrite, boolean makeURLOnly) 保存数据到partition指定的分区toString()从类继承的方法 gu.sql2java.store.BasesLocalBinaryStore
asNativeUrl, doDelete, doExists, doGetURLStreamHandler, getProtocol, getStoreRoot, pathOf从类继承的方法 gu.sql2java.store.BaseURLStore
createURLStreamHandler, delete, delete, exists, find, intall, isStored, setAdditionalParam, store, store
-
构造器详细资料
-
MultiLocalStore
-
MultiLocalStore
-
-
方法详细资料
-
addPartition
增加存储分区- 参数:
partition- 存储路径前缀(分区)level- 存储目录级数,小于0或大于4则使用默认值2
-
addPartition
增加partition指定的名字的分区- 参数:
partition- 存储路径前缀(分区)localBinaryStore-
-
getStore
返回指定前缀(分区)的存储实例- 参数:
partition- 存储路径前缀(分区)
-
store
public <T> URL store(String partition, T binary, String md5, String extension, boolean overwrite, boolean makeURLOnly) throws IOException 保存数据到partition指定的分区 -
doStore
protected URL doStore(byte[] binary, String md5, String extension, boolean overwrite, boolean makeURLOnly) throws IOException 从类复制的说明:BaseURLStore存储图像数据- 指定者:
doStore在类中BaseURLStore- 参数:
binary- 二进制数据字节数组md5- imageBytes的MD5校验码extension- 文件后缀,可为nulloverwrite- 文件存在时是否重写makeURLOnly- 为true时不存储数据只返回存储URL- 返回:
- 存储URL
- 抛出:
IOException
-
doFind
从类复制的说明:BaseURLStore查找指定MD5的二进制数据- 指定者:
doFind在类中BaseURLStore- 参数:
md5- MD5校验码- 返回:
- 数据存储URL,找不到返回
null
-
hashCode
public int hashCode()- 覆盖:
hashCode在类中BasesLocalBinaryStore
-
equals
- 覆盖:
equals在类中BasesLocalBinaryStore
-
toString
- 覆盖:
toString在类中BasesLocalBinaryStore
-