title: How to copy properties from a bean to another bean in different class?
body: <p>I have two java class with same properties names.How Can I copy all the properties to another bean filled with data.I don't want to use the traditional form to copy properties because I have a lot of properties.</p>
  
  <p>Thanks in advance.</p>
  
  <p><strong>1 class</strong> </p>
  
  <pre><code>@ManagedBean
  @SessionScoped
  public class UserManagedBean implements Serializable {
  
      private static final long serialVersionUID = 1L;
      private String userSessionId;
      private String userId;
      private String name;
      private String adress;
      ......................
  </code></pre>
  
  <p><strong>2 class</strong></p>
  
  <pre><code>public class UserBean {
  
      private String userSessionId;
      private String userId;
      private String name;
     ....................
  </code></pre>