title: Java 8 How to manipulate objects in one list and collect them in another list?
body: <p>I'm fairly new to Java8. I have a requirement to convert List of POJOs to group by a certain criteria and show it on UI.</p>
  
  <ul>
  <li>Convert list of objects that belong to Children category to Person
  category. </li>
  <li><p>Return the List.</p>
  
  <pre><code>Children.java
  private String firstName;
  private String lastName;
  private String school;
  private String personId;
  // Setters and getters.
  
  Person.java
  private String fullName;
  private String address;
  // Setters and Getters.
  
  private Person convertChildToPerson(Children child) {
           Person person = new Person();
           person.setFullName(child.getLastName() + ", " + child.getFirstName());
            ..
            return person;
   } 
  </code></pre>
  
  <p>..
      MAIN CODE..
     ..</p>
  
  <pre><code>List&lt;Person&gt; personList;  // Is populated by other functions.
  
  // Connect to DB and gets the output
  List&lt;Children&gt; childrenList = (Children) criteria.list();  
  
  for(Children children: childrenList) {
       personList.add(convertChildToPerson(children));
  }
  return personList; 
  </code></pre>
  
  <p>Can't the <strong>FOR-LOOP</strong> present above be replaced by Java 8 Streams?</p></li>
  </ul>