惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

J
Java Code Geeks
腾讯CDC
Jina AI
Jina AI
博客园 - 司徒正美
博客园 - 三生石上(FineUI控件)
Apple Machine Learning Research
Apple Machine Learning Research
GbyAI
GbyAI
WordPress大学
WordPress大学
Hugging Face - Blog
Hugging Face - Blog
T
The Blog of Author Tim Ferriss
小众软件
小众软件
M
MIT News - Artificial intelligence
MyScale Blog
MyScale Blog
D
Docker
H
Hackread – Cybersecurity News, Data Breaches, AI and More
Google DeepMind News
Google DeepMind News
月光博客
月光博客
L
LangChain Blog
F
Fortinet All Blogs
Microsoft Azure Blog
Microsoft Azure Blog
博客园 - Franky
C
Check Point Blog
U
Unit 42
人人都是产品经理
人人都是产品经理

博客园 - 震

关于反射中方法指针中我遇到的问题 一些关于数据库的问题 使用ORACLE和MYSQL的简单心得 出来混总有一天要还的 Java中的访问修饰符 Java中的static、final、this、super xslt学习简单笔记 XML schema学习笔记 DOM中对象的方法(转贴) 学习JavaScript的开源好东东 关于CSS中的一些问题 - 震 - 博客园 web标准的悄然袭来 替换字符性能测试 在JAVA中调用外部可执行程序 - 震 - 博客园 Java中的String类和StringBuffer类 将Java对象转为String的几种方法剖析(转贴) java 中的随机数用法 两种特殊的Java容器类List和Set分析[转贴] java.util.list初体验
一小练习 - 震 - 博客园
· 2006-06-06 · via 博客园 - 震

import java.util.*;
import java.io.*;
public class Test66{
    
public static void main(String[] args){
        Properties pro 
= new Properties();
        
try{
            pro.load(
new FileInputStream("Test66.Properties"));
        }
catch(IOException e){
        }

                
        StringBuffer str 
= new StringBuffer(pro.getProperty("a")) ;
        str.append(
".this is a Test66");
        str.delete(
0,4);
        str.insert(
0,"this");
        str.replace(
40,50,"java");        
        pro.setProperty("a",str.toString());

         
        
        
        
try{
            pro.store(
new FileOutputStream("Test66_new.Properties"),null);
        }
catch(IOException e){
        }

        
    }

}

ps:
a = Here is an example of the contents of a properties file