1 /********************
\r
2 * 2004 Jalview Reengineered
\r
10 package jalview.bin;
\r
16 public static Properties applicationProperties;
\r
17 // Current properties include:
\r
19 // LAST_DIRECTORY , use this to cache record of where the user looked to find a file
\r
22 public static void loadProperties()
\r
24 applicationProperties = new Properties();
\r
28 FileInputStream in = new FileInputStream(System.getProperty("user.home") +
\r
29 "/.jalview_properties");
\r
30 applicationProperties = new Properties();
\r
31 applicationProperties.load(in);
\r
34 catch (Exception ex)
\r
36 ex.printStackTrace();
\r
42 public static String getProperty(String key)
\r
44 return applicationProperties.getProperty(key);
\r
47 public static void setProperty(String key, String obj)
\r
51 FileOutputStream out = new FileOutputStream(System.getProperty(
\r
52 "user.home") + "/.jalview_properties");
\r
54 applicationProperties.setProperty(key, obj);
\r
56 applicationProperties.store(out, "---JalviewX Properties File---");
\r
59 catch (Exception ex)
\r