de.esprit.common.util

## Class ReplacementMap

- java.lang.Object
- - de.esprit.common.util.DumpableObject
  - - de.esprit.common.util.ReplacementMap

- All Implemented Interfaces:
    Clearable, Dumpable

      public class ReplacementMap
      extends DumpableObject
      implements Clearable

  This class is used to perform predefined replacements in a string.
  Author:
    Rainer Buesch

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ReplacementMap()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `clear()` Clears the content
    `java.lang.String` | `filter(java.lang.String str)`
    `java.lang.Object` | `getAsBoolean(java.lang.String key)`
    `double` | `getAsDouble(java.lang.String key)`
    `int` | `getAsInt(java.lang.String key)`
    `java.lang.String` | `getAsString(java.lang.String key)`
    `java.util.Map<java.lang.String,java.lang.String>` | `getMap()`
    `int` | `getSize()`
    `void` | `put(java.lang.String searchStr, boolean replacementValue)`
    `void` | `put(java.lang.String searchStr, double replacementValue)`
    `void` | `put(java.lang.String searchStr, int replacementValue)`
    `void` | `put(java.lang.String searchStr, java.lang.String replacementStr)`
    `void` | `putAll(java.util.Map<java.lang.String,java.lang.String> otherMap)`
    `void` | `putAll(ReplacementMap otherMap)`
    `DumpString` | `toDumpString(DumpString s)` This method allows subclasses to add values to the existing DumpString of the superclass.
    `ToString` | `toString(ToString s)` This method allows subclasses to add values to the existing ToString of the superclass.

    - ### Methods inherited from class de.esprit.common.util.DumpableObject

      `configureDumpHeadlineLength, configureDumpMaxElementsPrinted, copyDumpStringValues, copyToStringValues, createDumpHeader, toDumpString, toString`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### ReplacementMap

          public ReplacementMap()

  - ### Method Detail

    - #### put

          public void put(java.lang.String searchStr,
                 boolean replacementValue)

    - #### put

          public void put(java.lang.String searchStr,
                 int replacementValue)

    - #### put

          public void put(java.lang.String searchStr,
                 double replacementValue)

    - #### put

          public void put(java.lang.String searchStr,
                 java.lang.String replacementStr)

    - #### putAll

          public void putAll(ReplacementMap otherMap)

    - #### putAll

          public void putAll(java.util.Map<java.lang.String,java.lang.String> otherMap)

    - #### getMap

          public java.util.Map<java.lang.String,java.lang.String> getMap()

    - #### filter

          public java.lang.String filter(java.lang.String str)

    - #### clear

          public void clear()

      Description copied from interface: `Clearable`
      Clears the content
      Specified by:
        `clear` in interface `Clearable`

    - #### getSize

          public int getSize()

    - #### getAsString

          public java.lang.String getAsString(java.lang.String key)

    - #### getAsBoolean

          public java.lang.Object getAsBoolean(java.lang.String key)

    - #### getAsInt

          public int getAsInt(java.lang.String key)

    - #### getAsDouble

          public double getAsDouble(java.lang.String key)

    - #### toString

          public ToString toString(ToString s)

      Description copied from interface: `Dumpable`
      This method allows subclasses to add values to the existing ToString of the superclass. Usually subclasses only need to override this method.
      Specified by:
        `toString` in interface `Dumpable`
      Overrides:
        `toString` in class `DumpableObject`

    - #### toDumpString

          public DumpString toDumpString(DumpString s)

      Description copied from interface: `Dumpable`
      This method allows subclasses to add values to the existing DumpString of the superclass. Usually subclasses only need to override this method.
      Specified by:
        `toDumpString` in interface `Dumpable`
      Overrides:
        `toDumpString` in class `DumpableObject`

Copyright © 2014 EsprIT-Systems. All Rights Reserved.