edu.isi.karma.rep.Worksheet.getSelectionManager()方法的使用及代码示例

x33g5p2x  于2022-02-03 转载在 其他  
字(3.4k)|赞(0)|评价(0)|浏览(105)

本文整理了Java中edu.isi.karma.rep.Worksheet.getSelectionManager()方法的一些代码示例,展示了Worksheet.getSelectionManager()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Worksheet.getSelectionManager()方法的具体详情如下:
包路径:edu.isi.karma.rep.Worksheet
类名称:Worksheet
方法名:getSelectionManager

Worksheet.getSelectionManager介绍

暂无

代码示例

代码示例来源:origin: usc-isi-i2/Web-Karma

@Override
public UpdateContainer undoIt(Workspace workspace) {
  inputColumns.clear();
  outputColumns.clear();
  Worksheet worksheet = workspace.getWorksheet(worksheetId);
  SuperSelection superSel = getSuperSelection(worksheet);
  for (Entry<String, Selection> entry : oldSelections.entrySet()) {
    outputColumns.addAll(entry.getValue().getInputColumns());
    superSel.addSelection(entry.getValue());
    worksheet.getSelectionManager().addSelection(entry.getValue());
  }
  WorksheetUpdateFactory.detectSelectionStatusChange(worksheetId, workspace, this);
  UpdateContainer uc = WorksheetUpdateFactory.createWorksheetHierarchicalAndCleaningResultsUpdates(worksheetId, superSel, workspace.getContextId());
  uc.add(new WorksheetSuperSelectionListUpdate(worksheetId));
  return uc;
}

代码示例来源:origin: usc-isi-i2/Web-Karma

public static void detectSelectionStatusChange(String worksheetId, Workspace workspace, Command command) {
  Worksheet worksheet = workspace.getWorksheet(worksheetId);
  for (Selection sel : worksheet.getSelectionManager().getAllDefinedSelection()) {
    Set<String> inputColumns = sel.getInputColumns();
    inputColumns.retainAll(command.getOutputColumns());
    if (!inputColumns.isEmpty() && !command.getCommandName().equals("OperateSelectionCommand") && !command.getCommandName().equals("ClearSelectionCommand"))
      sel.invalidateSelection();
    if (sel.isSelectedRowsMethod() && checkSelection(sel, command, workspace.getFactory())) {
      sel.invalidateSelection();
    }
  }
}

代码示例来源:origin: usc-isi-i2/Web-Karma

outputColumns.addAll(currentSel.getInputColumns());
oldSelections.put(currentSel.getHTableId(), currentSel);
worksheet.getSelectionManager().removeSelection(currentSel);
superSel.removeSelection(currentSel);
if (sel != null) {
  oldSelections.put(sel.getHTableId(), sel);
  worksheet.getSelectionManager().removeSelection(sel);
  superSel.removeSelection(sel);

代码示例来源:origin: usc-isi-i2/Web-Karma

@Override
public UpdateContainer undoIt(Workspace workspace) {
  inputColumns.clear();
  outputColumns.clear();
  RepFactory factory = workspace.getFactory();
  Worksheet worksheet = workspace.getWorksheet(worksheetId);
  SuperSelection superSel = getSuperSelection(worksheet);
  HNode hNode = workspace.getFactory().getHNode(hNodeId);
  Selection currentSel = superSel.getSelection(hNode.getHTableId());
  if (previousSelection != null) {
    superSel.addSelection(previousSelection);
    outputColumns.addAll(previousSelection.getInputColumns());
  }
  if (currentSel != null) {
    worksheet.getSelectionManager().removeSelection(currentSel);
    superSel.removeSelection(currentSel);
  }
  worksheet.getMetadataContainer().getColumnMetadata().removeSelectionPythonCode(factory.getHTable(factory.getHNode(hNodeId).getHTableId()).getId());
  WorksheetUpdateFactory.detectSelectionStatusChange(worksheetId, workspace, this);
  UpdateContainer uc = WorksheetUpdateFactory.createWorksheetHierarchicalAndCleaningResultsUpdates(worksheetId, superSel, workspace.getContextId());    
  uc.add(new WorksheetSuperSelectionListUpdate(worksheetId));
  return uc;
}

代码示例来源:origin: usc-isi-i2/Web-Karma

worksheet.getSelectionManager().addSelection(anotherSel);
worksheet.getMetadataContainer().getColumnMetadata().addSelectionPythonCode(hTable.getId(), this.pythonCode);

相关文章