title: Dozer mapping not working for nested object
body: <p>I was Trying to copy value of <code>StudentRequestForm</code> class  to <code>StudentEntity</code> class .all values are saved but a <code>classI</code> field in <code>studentBean</code> is not saved which is mapped to  <code>StudentEntity</code> <code>classId</code> .So i want my ClassI value copy to classId  </p>
  
  <p>you can check in below dozer mapping</p>
  
  <hr>
  
  <pre><code>public class StudentRequestForm {
  
          private StudentModel studentbean;
  
          public StudentModel getStudentbean() {
              return studentbean;
          }
          public void setStudentbean(StudentModel studentbean) {
              this.studentbean = studentbean;
          }`enter code here`
  
  
  
  
  public class StudentModel {
  
      private int countryId,cityId,stateId,classI;
      private String enrollmentId,firstName,lastName,gender,category,pincode,sectionName;
  
  
  
  @Entity
  @Table(name="students")
  public class StudentEntity implements Serializable {
      private static final long serialVersionUID = 1L;
  
      @Id
      @GeneratedValue(strategy=GenerationType.AUTO)
      private int id;
  
      private int age;
  
      private String category;
  
      private String pincode;
  
      private int cityId;
  
      @Column(name="class_id")
      private int classId;
  
      @Column(name="country_id")
      private int countryId;
  
  
  
          @Column(name="first_name")
      private String firstName;
  
      private String gender
  </code></pre>
  
  <p>...................
  ................
  ;</p>
  
  <p>Dozer mapping</p>
  
  <pre><code>&lt;mapping&gt;
      &lt;class-a&gt;com.myschool.entity.StudentRequestForm&lt;/class-a&gt;
      &lt;class-b&gt;com.myschool.entity.StudentEntity&lt;/class-b&gt;
  
      &lt;field&gt;
           &lt;a&gt;studentbean.classI&lt;/a&gt;   
          &lt;b&gt;classId&lt;/b&gt;
      &lt;/field&gt;
  
  
  &lt;/mapping&gt;
  </code></pre>
  
  <p></p>
  
  <p>controller methood</p>
  
  <pre><code>public ModelAndView saveForm(HttpServletRequest request,HttpServletResponse response,StudentRequestForm studentForm){
          try{
  
  
          StudentEntity studententity = mapper.map(studentForm.getStudentbean(), StudentEntity.class);
          studentservice.saveStudentForm(studententity);
  
          }catch(Exception e){
              e.printStackTrace();
          }
          return new ModelAndView("abc/helo.html");
      }
  </code></pre>