Java Map to String mapToString(Map map)

Here you can find the source of mapToString(Map map)

Description

map To String

License

Apache License

Declaration

public static String mapToString(Map<String, String> map) 

Method Source Code

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

import java.util.Map;

public class Main {
    public static String mapToString(Map<String, String> map) {
        StringBuffer buf = new StringBuffer();
        for (String key : map.keySet()) {
            buf.append(key).append('=');
            if (map.containsKey(key)) {
                buf.append(map.get(key));
            }//from w w  w  .java  2s .c om
            buf.append("\n");
        }
        return buf.toString();
    }
}

Related

  1. mapToString(Map m)
  2. mapToString(Map map)
  3. mapToString(Map criteria)
  4. mapToString(Map map)
  5. mapToString(Map map)
  6. mapToString(Map map)
  7. MapToString(Map map)
  8. mapToString(Map map)
  9. mapToString(Map parameterMap)