
com.qiniu.datasource.IDataSource Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of qsuits Show documentation
Show all versions of qsuits Show documentation
qiniu-suits is a efficient tools for qiniu api implemented by java8.
package com.qiniu.datasource;
import com.qiniu.entry.CommonParams;
import com.qiniu.interfaces.ILineProcess;
import java.io.IOException;
import java.util.Set;
public interface IDataSource {
String getSourceName();
void setSaveOptions(String savePath, boolean saveTotal, String format, String separator, Set rmFields);
void updateSettings(CommonParams commonParams);
void export(R source, S saver, ILineProcess processor) throws IOException;
// 直接使用 export(source, saver, processor) 方法时可以不设置 processor
default void setProcessor(ILineProcess processor) {}
// 将 source 按照 order 顺序放入线程池进行读取操作,由子类创建线程池在多线程情况下使用并实现
default void execInThread(R source, int order) throws Exception {}
// 根据成员变量参数直接多线程处理数据源,由子类创建线程池在需要多线程情况下使用并实现
default void export() throws Exception {}
default void setRetryTimes(int retryTimes) {}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy