title: Switch Statement gives Incompatible Types error
body: <p>I am trying to compile and I get this error: </p>
  
  <pre><code>enigma/Rotor.java:30: incompatible types found : java.lang.String required: int     switch(name){
  1 error
  </code></pre>
  
  <p>Why am I getting this error? How do I fix it? It's in the package and I can't seem to figure it out. Here's the code:</p>
  
  <pre><code>String label;
  
  Rotor(){;}
  
  Rotor(String name){
    switch(name){
      case "B":
        conversion_chart = B;
        break;
      case "C":
        conversion_chart = C;
        break;
      case "I":
        conversion_chart=I;
        notch = NOTCH[0];
        break;
      case "II":
        conversion_chart=II;
        notch = NOTCH[1];
        break;
      case "III":
        conversion_chart=III;
        notch = NOTCH[2];
        break;
      case "IV":
        conversion_chart=IV;
        notch = NOTCH[3];
        break;
      case "V":
        conversion_chart=V;
        notch = NOTCH[4];
        break;
      case "VI":
        conversion_chart=VI;
        notch = NOTCH[5];
        break;
      case "VII":
        notch = NOTCH[6];
        conversion_chart=VII;
        break;
      case "VIII":
        notch = NOTCH[7];
        conversion_chart=VIII;
        break;
    }
    label = name;
    position = 0;
  }
  </code></pre>