Examples of save()


Examples of org.eclipse.higgins.rsse.RssFeed.save()

      // merge remote feed with local one
      localFeed.merge(remoteFeed);
      // add a new item to feed
      localFeed.addItem(new RssItem("New Google Item", "This is a new item", "http://www.google.com"));
      // publish updated feed
      localFeed.save(feedFile);
      // print item titles
      final java.util.List items = localFeed.getItems();
      for (int i = 0; i < items.size(); i++) {
        System.out.println(" " + i + " " + ((RssItem) items.get(i)).getTitle());
      }
View Full Code Here

Examples of org.eclipse.jdt.core.IBuffer.save()

      String originalContent = buf.getText(range.getOffset(), range.getLength());
      String formattedContent = CodeFormatterUtil.format(CodeFormatter.K_CLASS_BODY_DECLARATIONS, originalContent, 1, null,
          lineDelimiter, field.getJavaProject());
      buf.replace(range.getOffset(), range.getLength(), formattedContent);
      if (!cu.isWorkingCopy())
        buf.save(null, false);

      imports.create(needsSave, new SubProgressMonitor(monitor, 1));
      removeUnusedImports(cu, needsSave);
      if (needsCommit)
        cu.commitWorkingCopy(false, new SubProgressMonitor(monitor, 1));
View Full Code Here

Examples of org.eclipse.jdt.core.ICompilationUnit.save()

        equals += "\t\r\n";
        equals += "\treturn false;\r\n";
        equals += "}\r\n";
        type.createMethod(equals, null, true, null);

        icu.save(null, true);
      }
    }
    catch (Exception e)
    {
      ErrorMessageDialog errorMessageDialog = new ErrorMessageDialog(e.getMessage());
View Full Code Here

Examples of org.eclipse.jdt.core.IJavaProject.save()

        output = BuildPathsBlock.getDefaultOutputLocation(javaProject);
      }
      javaProject.setOutputLocation(output, null);
    }
    javaProject.makeConsistent(null);
    javaProject.save(null, false);
  }

  /**
   * Creates or updates the projects dependencies on other projects.
   *
 
View Full Code Here

Examples of org.eclipse.jdt.core.IPackageFragment.save()

          newFolder.create(false, true, null);
            }

        IPackageFragment newPackage = (IPackageFragment) JavaCore.create(newFolder);
        if (!newPackage.exists())
          newPackage.save(progress, true);
       
        /*
         * Create compilation unit
         */
        ICompilationUnit newCompilationUnit = newPackage.createCompilationUnit(original.getElementName(), "", true, progress);
View Full Code Here

Examples of org.eclipse.jdt.internal.core.index.Index.save()

          JavaSearchDocument entryDocument = new JavaSearchDocument(ze, new Path(pathToJar), classFileBytes, participant);
          entryDocument.setIndex(index);
          new BinaryIndexer(entryDocument).indexDocument();
        }
      }
      index.save();
    } finally {
      zip.close();
    }
    return;
  }
View Full Code Here

Examples of org.eclipse.jface.commands.PersistentState.save()

        final String stateId = stateIds[j];
        final State state = command.getState(stateId);
        if (state instanceof PersistentState) {
          final PersistentState persistentState = (PersistentState) state;
          if (persistentState.shouldPersist()) {
            persistentState.save(PrefUtil
                .getInternalPreferenceStore(),
                createPreferenceKey(command, stateId));
          }
        }
      }
View Full Code Here

Examples of org.eclipse.jface.dialogs.IDialogSettings.save()

       
        settings.put(KEY_LAST_SELECTIONS, ar.toArray(new String[0]));
      }
     
      try {
        settings.save(SETTINGS_FILE);
      } catch (IOException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
      }
    }
View Full Code Here

Examples of org.eclipse.jface.preference.IPersistentPreferenceStore.save()

    IPreferenceStore store = getPreferenceStore();
    if (store instanceof IPersistentPreferenceStore) {
      IPersistentPreferenceStore pstore = (IPersistentPreferenceStore) store;
      if (pstore.needsSaving()) {
        try {
          pstore.save();
        } catch (IOException up) {
          // hmm, what should we do?
        }
      }
    }
View Full Code Here

Examples of org.eclipse.jface.preference.PreferenceStore.save()

                  tsPrefStore.putValue(shownType + ".isShown", "true");
                }

                ByteArrayOutputStream prefOut = new ByteArrayOutputStream();
                try {
                  tsPrefStore.save(prefOut, "");
                } catch (IOException e) {
                  // Should never happen!
                  CasEditorPlugin.log(e);
                }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.