title: Mapping from a flat domain object to a nested SOAP XML
body: <p>I have an xml generated from a wsdl which is deeply nested with and contain a lot of field. The structure of the xml is in the form </p>
  
  <pre><code>&lt;types:Top&gt;
    &lt;types:Landlords&gt;
     &lt;types:County&gt;
       &lt;types:State&gt;
          &lt;types:Locality&gt;
             &lt;types:FirstName&gt;Hackaton&lt;/types:FirstName&gt;
             &lt;types:FirstName&gt;Manker&lt;/types:FirstName&gt;
          &lt;/types:Locality&gt;
            &lt;types:Locality&gt;
             &lt;types:LastName&gt;Hackaton&lt;/types:LastName&gt;
          &lt;/types:Locality&gt;
       &lt;types:State/&gt;
    &lt;/types:County&gt;
   &lt;/types:Landords&gt;
  &lt;types:Top&gt;
  </code></pre>
  
  <p>I have generated by class from the wsdl and but mapping this field by hand is really error prone and I am not sure if it is even the best way to go. Please is this possible to do with automapper.</p>
  
  <pre><code>Mapper.Map&lt;Domain , Landords&gt;();
  Mapper.Map&lt;Domain, County&gt;(); 
  Mapper.Map&lt;Domain, State&gt;() ; 
  Mapper.Map&lt;Domain, Locality&gt;().ForMember(s=&gt;s.FirstName , m=&gt;m.mapFrom(e=&gt;e.FirstName));
  </code></pre>
  
  <p>I have tried the above in automapper with no luck of mapping. Any idea of how to map this kind of object such that it is maintainable for over 600 fields On the side note my Domain is really flat. </p>