谢谢!

解决方案 »

  1.   

    扩展ResourceBundle类->重写即可
      

  2.   

    String url = "I want to write this to properties";
            try {
                String strUrlPath = "com/iijt/ticket/client/properties/URL.properties";
                InputStream fis = new FileInputStream(strUrlPath);
                FileOutputStream fos = new FileOutputStream(strUrlPath);
                Properties prop = new Properties();
                prop.load(fis);
                prop.put("url", url);
                prop.store(fos, "");
            } catch (FileNotFoundException e) {
                e.printStackTrace();
            } catch (IOException e) {
                e.printStackTrace();
            } finally{
                fos.close();
                fis.close();
                prop.clear();
            }
      

  3.   

    properties file is changed into
    url=I want to write this to properties
      

  4.   

    To strUrlPath,you can use absolute path or relatively path , on the basis of your project.