title: String to String mapping using Spring?
body: <p>From external system I receive String representation of some abbreviations and I have to make transformation(conversion) to another String for example:</p>
  
  <pre><code>"O" -&gt; Open
  "C" -&gt; Closed
  "E" -&gt; Exit
  </code></pre>
  
  <p>For Object to Object conversion I was using Spring Custom COnverter</p>
  
  <pre><code>import org.springframework.core.convert.converter.Converter;
  public class Converter&lt;Source, Target&gt; implements Converter&lt;Source, Target&gt;
   public final Target convert(@Nonnull Source source) {
   ...
   }
  </code></pre>
  
  <p>But I can't create String to String converter. I do not want to use external mapping library only Spring capabilities. But I can't do this. The simplest thing that I can do is switch</p>
  
  <pre><code>String input = "O";
  String result = null;
  switch(input){
   case "O": result ="Open"
   break;
  case "C": result ="Close"
   break;
  ....
  </code></pre>
  
  <p>In matter of fact I have to do over 100 mapings. Can Spring  offer better solution?</p>