Examples of EditorConfig


Examples of net.sf.pipet.editor.EditorConfig

    System.exit(0);
  }
 
  private static EditorConfig readEditorConfig(Messenger reporter)
  {
    EditorConfig cfg = null;
   
    File cfgdir = new File(System.getProperty("user.home"), ".pipet");
    File cfgfile = new File(cfgdir, "editor.cfg");

    if (cfgdir.exists() || cfgdir.mkdirs())
    {
      if (cfgfile.canRead())
      {
        try
        {
          cfg = new EditorConfigParser().parseInputStream(new FileInputStream(cfgfile));
        }
        catch (IOException e)
        {
          reporter.warn(e.toString());
        }
        catch (InvalidConfigurationException e)
        {
          reporter.warn("While reading edtior config: "+e.getMessage());
        }
      }
    }
   
    if (cfg == null)
      cfg = new EditorConfig();
   
    File writetest = cfgfile.exists() ? cfgfile : cfgdir;
    if (writetest.canWrite())
      cfg.addChangeListener(new EditorConfigManager(cfgfile, reporter));
   
    return cfg;
  }
View Full Code Here

Examples of net.sf.pipet.editor.EditorConfig

    ConfigurationFileResource backup_resource = new ConfigurationFileResource(DEFAULT_CONFIGFILE);
    ConfigurationResource empty_resource = new ConfigurationDefaultResource();
   
    Messenger reporter = new MessageReporterDialog();
    EditorConfig cfg = readEditorConfig(reporter);

    if (cfgfile == null)
      cfgfile = cfg.getWorkingFile();

    Configuration pipesetup = null;
    boolean file_modified = false;
   
    if (cfgfile != null && cfg.getWorkingFile() != null && cfgfile.equals(cfg.getWorkingFile()) && DEFAULT_CONFIGFILE.lastModified() > cfgfile.lastModified())
    {
      int recover = JOptionPane.showConfirmDialog(null,
          "There may be unsaved changes to this file. Try to recover?",
                  "Recover",
                  JOptionPane.YES_NO_OPTION,
View Full Code Here

Examples of org.editorconfig.core.EditorConfig

            Logger.getInstance("#org.editorconfig.plugincomponents.SettingsProviderComponent");

    private EditorConfig editorConfig;
   
    public SettingsProviderComponent() {
        editorConfig = new EditorConfig();
    }
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.