This step is identical to that in You want to read some data from a database table above.
In your façade method, code a variable to hold a set of instances of the entity interface, and set its value by calling.readAll() on the DAO:
// retrieve all the instances of the entity final Set<SomeEntity> someEntities = someEntityDAO.readAll();
Now code a loop which iterates the set retrieved, and maps each instance to the client struct. Note that since a Set is used, the Java 5 syntax for "for" loops can be used:
// map the details returned for (final SomeEntity someEntity : someEntities) { final SomeEntitySummaryDetails someEntitySummaryDetails = new SomeEntitySummaryDetails(); someEntitySummaryDetails.someEntityID = someEntity.getID(); someEntitySummaryDetails.name = someEntity.getName(); list.details.addRef(someEntitySummaryDetails); }