title: Use JAXB to create Object from XML String
body: <p>How can I use the below code to unmarshal a XML string an map it to the JAXB object below?</p>
  
  <pre><code>JAXBContext jaxbContext = JAXBContext.newInstance(Person.class);
  Unmarshaller unmarshaller = jaxbContext.createUnmarshaller();
  Person person = (Person) unmarshaller.unmarshal("xml string here");
  </code></pre>
  
  <hr>
  
  <pre><code>@XmlRootElement(name = "Person")
  public class Person {
      @XmlElement(name = "First-Name")
      String firstName;
      @XmlElement(name = "Last-Name")
      String lastName;
      public String getFirstName() {
          return firstName;
      }
      public void setFirstName(String firstName) {
          this.firstName = firstName;
      }
      public String getLastName() {
          return lastName;
      }
      public void setLastName(String lastName) {
          this.lastName = lastName;
      }
  }
  </code></pre>