Here you can find the source of putPrefixToProperties(String prefix, Properties pro)
static public Properties putPrefixToProperties(String prefix, Properties pro)
//package com.java2s; // it under the terms of the GNU Lesser General Public License as published by import java.util.*; public class Main { static public Properties putPrefixToProperties(String prefix, Properties pro) {// w w w. ja va2 s. c o m Enumeration en; Properties res = new Properties(); en = pro.propertyNames(); for (; en.hasMoreElements();) { String nom = (String) en.nextElement(); res.setProperty(prefix + nom, pro.getProperty(nom)); } return res; } }