Java Properties transformPropertiesToParams(Map properties)

Here you can find the source of transformPropertiesToParams(Map properties)

Description

Transform properties to Map of parameters.

License

LGPL

Parameter

Parameter Description
properties are the properties

Return

map

Declaration

public static Map<String, Object> transformPropertiesToParams(Map<String, String> properties) 

Method Source Code

//package com.java2s;
//License from project: LGPL 

import java.util.*;

public class Main {
    /**//  ww  w . j av a  2s.  c om
     * Transform properties to {@link Map} of parameters.
     *
     * @param properties are the properties
     * @return map
     */
    public static Map<String, Object> transformPropertiesToParams(Map<String, String> properties) {
        Map<String, Object> params = new HashMap<>();
        for (Map.Entry<String, String> entry : properties.entrySet()) {
            params.put(entry.getKey(), entry.getValue());
        }
        return params;
    }
}

Related

  1. search(List properties, String term)
  2. setProperty(Properties props, String keyword, Object value)
  3. stringPropertyNames(Properties props, String prefix)
  4. stringToProperties(String str)
  5. toProperties(Map parse)