Java Map Remove removeClassFromMap(final Map the_map, final String the_class_name)

Here you can find the source of removeClassFromMap(final Map the_map, final String the_class_name)

Description

Removes a class from a database of debugging-enabled classes.

License

Open Source License

Parameter

Parameter Description
the_map the map from which the class is removed.
the_class_name the name of the class to remove.

Declaration


static void removeClassFromMap(final  Map the_map,
        final  String the_class_name) 

Method Source Code

//package com.java2s;

import java.util.Map;

public class Main {
    /**/*from  ww w  .j  a  va2 s .  c o  m*/
     * <p> Removes a class from a database of debugging-enabled classes.
     * Note that a class of "*" means that all classes will be removed
     * and debugging disabled.  There is no way to "undo" such a
     * command.  Adding classes after the removal of "*" works as you
     * would expect. </p>
     * 
     * <p> The caller must guarantee that this method is synchronized. </p>
     *
     * @param the_map the map from which the class is removed.
     * @param the_class_name the name of the class to remove.
     */

    static void removeClassFromMap(final /*@ non_null @*/ Map the_map,
            final /*@ non_null @*/ String the_class_name) {
        // If we are removing the class "*", just clear the map.
        if ("*".equals(the_class_name)) {
            the_map.clear();
        } else
            // If entry is in the map, remove it.
            the_map.remove(the_class_name);
    }
}

Related

  1. removeAll(Map map, Set keys)
  2. removeAllFromCollection(Map> map, Object key, Collection values)
  3. removeAllNullValueEntry(Map source)
  4. removeAndCleanFromCollectionMap(KeyT key, ValT toBeRemoved, Map> map)
  5. removeApiUuidMap(String apiName)
  6. removeColor(Map windowColorCountMap, int windowColorCount, int lastColor)
  7. removeDefaultAnnotationPackage(final String packageName, final Map context)
  8. removeDoubleQuotes(Map argMap)
  9. removeElementFromJsonMap(Map toscaJson, String elementName)