本文整理汇总了Java中com.taobao.tddl.executor.cursor.ITempTableSortCursor类的典型用法代码示例。如果您正苦于以下问题:Java ITempTableSortCursor类的具体用法?Java ITempTableSortCursor怎么用?Java ITempTableSortCursor使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ITempTableSortCursor类属于com.taobao.tddl.executor.cursor包,在下文中一共展示了ITempTableSortCursor类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: tempTableSortCursor
import com.taobao.tddl.executor.cursor.ITempTableSortCursor; //导入依赖的package包/类
@Override
public ITempTableSortCursor tempTableSortCursor(ExecutionContext executionContext, ISchematicCursor cursor,
List<IOrderBy> orderBys, boolean sortedDuplicates, long requestID)
throws TddlException {
try {
if (GeneralUtil.getExtraCmdBoolean(executionContext.getExtraCmds(),
ConnectionProperties.ALLOW_TEMPORARY_TABLE,
false)) {
IRepository bdbRepo = ExecutorContext.getContext()
.getRepositoryHolder()
.getOrCreateRepository(Group.GroupType.BDB_JE.name(),
Collections.EMPTY_MAP,
executionContext.getExtraCmds());
return new TempTableSortCursor(this,
bdbRepo,
cursor,
orderBys,
sortedDuplicates,
requestID,
executionContext);
}
throw new IllegalStateException("not allow to use temporary table . allow first");
} catch (Exception e) {
closeParentCursor(cursor);
throw new TddlException(e);
}
}
示例2: tempTableSortCursor
import com.taobao.tddl.executor.cursor.ITempTableSortCursor; //导入依赖的package包/类
@Override
public ITempTableSortCursor tempTableSortCursor(ExecutionContext executionContext, ISchematicCursor cursor,
List<IOrderBy> orderBys, boolean sortedDuplicates, long requestID)
throws TddlException {
try {
if ("True".equalsIgnoreCase(GeneralUtil.getExtraCmdString(executionContext.getExtraCmds(),
ExtraCmd.ALLOW_TEMPORARY_TABLE))) {
IRepository bdbRepo = ExecutorContext.getContext()
.getRepositoryHolder()
.getOrCreateRepository(Group.GroupType.BDB_JE.name(), Collections.EMPTY_MAP);
return new TempTableSortCursor(this,
bdbRepo,
cursor,
orderBys,
sortedDuplicates,
requestID,
executionContext);
}
throw new IllegalStateException("not allow to use temporary table . allow first ");
} catch (Exception e) {
closeParentCursor(cursor);
throw new TddlException(e);
}
}
示例3: tempTableSortCursor
import com.taobao.tddl.executor.cursor.ITempTableSortCursor; //导入依赖的package包/类
/**
* 临时表的排序用cursor ,将数据拿出写入临时表中,并进行排序。
*
* @param context
* @param cursor
* @param orderBys
* @param sortedDuplicates
* @param requestID
* @return
* @throws TddlException
*/
ITempTableSortCursor tempTableSortCursor(ExecutionContext context, ISchematicCursor cursor,
List<IOrderBy> orderBys, boolean sortedDuplicates, long requestID)
throws TddlException;