Package edu.isi.karma.controller.update

Examples of edu.isi.karma.controller.update.WorksheetListUpdate


    // Initialize the Outlier tag
    Tag outlierTag = new Tag(TagName.Outlier, Color.Red);
    workspace.getTagsContainer().addTag(outlierTag);

    // Put all created worksheet models in the view.
    updateContainer.add(new WorksheetListUpdate());
   
    for (Worksheet w : vwsp.getWorkspace().getWorksheets()) {
      updateContainer.append(WorksheetUpdateFactory.createWorksheetHierarchicalUpdates(w.getId(), SuperSelectionManager.DEFAULT_SELECTION));
    }
View Full Code Here


      workspace.removeWorksheet(worksheetId);     
      workspace.getFactory().removeWorksheet(worksheetId, workspace.getCommandHistory());       
    }
   
    UpdateContainer update = new UpdateContainer();
    update.add(new WorksheetListUpdate());
    if(worksheetExists) {
      update.add(new WorksheetDeleteUpdate(worksheetId));
      update.add(new HistoryUpdate(workspace.getCommandHistory()));
    }
    return update;
View Full Code Here

      JSONObject ClusterAnnotation = new JSONObject();
     
      ClusterAnnotation.put("ClusterId",ws.getId());
     
      worksheet.setJsonAnnotation(ClusterAnnotation);
      c.add(new WorksheetListUpdate());
      c.append(WorksheetUpdateFactory.createWorksheetHierarchicalAndCleaningResultsUpdates(ws.getId(), getSuperSelection(ws)));
     
      return c;
      //return null;
    } catch (Exception e) {
View Full Code Here

            Import imp = new JsonImport(json, worksheetName, workspace, encoding, -1);

            Worksheet wsht = imp.generateWorksheet();
            c.add(new ImportServiceCommandPreferencesUpdate(serviceUrl, worksheetName));

            c.add(new WorksheetListUpdate());
            c.append(WorksheetUpdateFactory.createWorksheetHierarchicalAndCleaningResultsUpdates(wsht.getId(), SuperSelectionManager.DEFAULT_SELECTION));
            return c;
        } catch (Exception e) {
            logger.error("Error occured while creating worksheet from web-service: " + serviceUrl);
            return new UpdateContainer(new ErrorUpdate("Error creating worksheet from web-service"));
View Full Code Here

      groupByNestedTable(oldws, workspace, ht, hnodeIDs, keyhnodes, valuehnodes, factory);
    }
    try{
      UpdateContainer c =  new UpdateContainer();
      WorksheetUpdateFactory.detectSelectionStatusChange(worksheetId, workspace, this);
      c.add(new WorksheetListUpdate());
      if (newws == null)
        c.append(WorksheetUpdateFactory.createRegenerateWorksheetUpdates(oldws.getId(), getSuperSelection(oldws)));
      if (newws != null) {
        c.append(WorksheetUpdateFactory.createRegenerateWorksheetUpdates(newws.getId(), SuperSelectionManager.DEFAULT_SELECTION));
        //c.append(WorksheetUpdateFactory.createWorksheetHierarchicalAndCleaningResultsUpdates(newws.getId()));
View Full Code Here

  public UpdateContainer undoIt(Workspace workspace) {
    UpdateContainer c = new UpdateContainer();
    if (this.newWorksheetId != null) {
      workspace.removeWorksheet(newWorksheetId);
      workspace.getFactory().removeWorksheet(newWorksheetId, workspace.getCommandHistory());
      c.add(new WorksheetListUpdate());
      c.add(new WorksheetDeleteUpdate(newWorksheetId));
    }
    if (this.newHNodeId != null) {
      Worksheet worksheet = workspace.getWorksheet(worksheetId);
      HNode ndid = workspace.getFactory().getHNode(newHNodeId);
View Full Code Here

        e.printStackTrace();
      }
    }
    try{
      UpdateContainer c =  new UpdateContainer();
      c.add(new WorksheetListUpdate());
      if (newws == null)
        c.append(WorksheetUpdateFactory.createRegenerateWorksheetUpdates(oldws.getId(), getSuperSelection(oldws)));
      if (newws != null) {
        c.append(WorksheetUpdateFactory.createRegenerateWorksheetUpdates(newws.getId(), SuperSelectionManager.DEFAULT_SELECTION));
        Alignment alignment = AlignmentManager.Instance().getAlignmentOrCreateIt(workspace.getId(), newws.getId(), workspace.getOntologyManager());
View Full Code Here

  public UpdateContainer undoIt(Workspace workspace) {
    UpdateContainer c = new UpdateContainer();
    if (this.newWorksheetId != null) {
      workspace.removeWorksheet(newWorksheetId);
      workspace.getFactory().removeWorksheet(newWorksheetId, workspace.getCommandHistory());
      c.add(new WorksheetListUpdate());
      c.add(new WorksheetDeleteUpdate(newWorksheetId));
    }
    if (this.newHNodeId != null) {
      Worksheet worksheet = workspace.getWorksheet(worksheetId);
      HNode ndid = workspace.getFactory().getHNode(newHNodeId);
View Full Code Here

      Import impJson = new JsonImport(new File(fileName), fName, workspace, "UTF-8", -1, null);
            Worksheet wsht = impJson.generateWorksheet();
//            Worksheet wsht2, wsht3;
            logger.info("Creating worksheet with json : " + wsht.getId());
            uc = new UpdateContainer();
            uc.add(new WorksheetListUpdate());
            uc.append(WorksheetUpdateFactory.createWorksheetHierarchicalAndCleaningResultsUpdates(wsht.getId(), SuperSelectionManager.DEFAULT_SELECTION));
         
          logger.info("Created : " + fileName);
            new File(fileName).delete();
View Full Code Here

                    if (hasRevisionId()) {
                        Worksheet revisedWorksheet = workspace.getWorksheet(getRevisionId());
                        wsht.setRevisedWorksheet(revisedWorksheet);
                    }

                    c.add(new WorksheetListUpdate());
                    c.append(WorksheetUpdateFactory.createWorksheetHierarchicalAndCleaningResultsUpdates(wsht.getId(), SuperSelectionManager.DEFAULT_SELECTION));
                } catch (Exception e) {
                    logger.error("Error occured while importing CSV file.", e);
                    return new UpdateContainer(new ErrorUpdate(
                            "Error occured while importing CSV File."));
View Full Code Here

TOP

Related Classes of edu.isi.karma.controller.update.WorksheetListUpdate

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.