Package net.sourceforge.squirrel_sql.client.util

Examples of net.sourceforge.squirrel_sql.client.util.ApplicationFiles


  }

  private URL[] getUrlsToLoadI18nPropertiesFrom(File workDir)
  {
    ApplicationFiles af = new ApplicationFiles();

    ArrayList<URL> ret = new ArrayList<URL>();
    URL[] urls;

    urls = ((URLClassLoader) _app.getClass().getClassLoader()).getURLs();

    for (int i = 0; i < urls.length; i++)
    {
      File file = new File(urls[i].getFile().replaceAll("%20", " "));
      if (file.getName().equals(af.getSQuirrelJarFile().getName()))
      {
        ret.add(urls[i]);
      }
      else if (file.getName().equals(af.getFwJarFile().getName()))
      {
        ret.add(urls[i]);
      }
    }
View Full Code Here


   
    private static void setupScriptsDir() {
        String userHomeDir = System.getProperty("user.home");
        if (userHomeDir != null) {           
            StringBuffer scriptsDir = new StringBuffer();
            ApplicationFiles appFiles = new ApplicationFiles();
            // user.home/.squirrel-sql/plugins
            scriptsDir.append(appFiles.getPluginsUserSettingsDirectory());
            scriptsDir.append(File.separator);
            // user.home/.squirrel-sql/plugins/dbcopy
            scriptsDir.append("dbcopy");
            if (mkdir(scriptsDir.toString())) {
                scriptsDir.append(File.separator);
View Full Code Here

   *
   * @return  The default file name.
   */
  protected String getDefaultFilename()
  {
    return new ApplicationFiles().getDatabaseAliasesFile().getName();
  }
View Full Code Here

   *
   * @return  The default file name.
   */
  protected String getDefaultFilename()
  {
    return new ApplicationFiles().getDatabaseDriversFile().getName();
  }
View Full Code Here

   *
   * @return  The default file name.
   */
  protected String getDefaultFilename()
  {
    return new ApplicationFiles().getUserPreferencesFile().getName();
  }
View Full Code Here

    super(s_stringMgr.getString("ViewLogsSheet.title"), true, true, true, true, app);
    if (app == null) { throw new IllegalArgumentException("IApplication == null"); }

    _app = app;
    _prefs = _app.getSquirrelPreferences();
    _logDir = new ApplicationFiles().getExecutionLogFile().getParentFile();
    createUserInterface();
  }
View Full Code Here

          pop.show(evt.getComponent(), evt.getX(), evt.getY());
        }
      }
    });

    final File appLogFile = new ApplicationFiles().getExecutionLogFile();
    _logDirCmb.load(appLogFile.getParentFile());

    if (_logDirCmb.getModel().getSize() > 0)
    {
      _logDirCmb.setSelectedItem(appLogFile.getName());
View Full Code Here

TOP

Related Classes of net.sourceforge.squirrel_sql.client.util.ApplicationFiles

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.