Java Map Replace replaceElements(Map destinationMap, Map sourceMap)

Here you can find the source of replaceElements(Map destinationMap, Map sourceMap)

Description

replace Elements

License

Apache License

Declaration

public static <K, V> void replaceElements(Map<K, V> destinationMap, Map<K, V> sourceMap) 

Method Source Code


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

import java.util.Map;

public class Main {
    public static <K, V> void replaceElements(Map<K, V> destinationMap, Map<K, V> sourceMap) {
        if (destinationMap != null && sourceMap != null) {
            destinationMap.clear();/*w  w  w  .  j av a  2s.c o  m*/
            destinationMap.putAll(sourceMap);
        }
    }
}

Related

  1. replaceAllRegex(String input, Map replacements)
  2. replaceByMap(String _searchStr, Map _replacements)
  3. replaceByMap(String tpl, Map map)
  4. replaceCharacters(String sequence, Map map, boolean reverse)
  5. replaceCharactersInArray(char[] characters, Map replacements)
  6. replaceEntities(final Map replacements, final String xml)
  7. replaceFromMap(final String string, final Map replacements)
  8. replaceFromMap(String string, Map replacements)
  9. replaceGlobalTokensFromMap(Map dataMap, String message)