}
public List<Map<String, Object>> generateModel() {
Map<String, Object> modelObjects = new HashMap<String, Object>();
Author author;
Book book;
Map<String, Object> model = new HashMap<String, Object>();
List<Book> books = new ArrayList<Book>();
// List<Reference> references = new ArrayList<Reference>();
// List<Editor> editors = new ArrayList<Editor>();
author = new Author();
author.setFirstName("Charles");
author.setLastName("Moulliard");
author.setAge("43");
// 1st Book
book = new Book();
book.setTitle("Camel in Action 1");
book.setYear("2010");
books.add(book);
// 2nd book
book = new Book();
book.setTitle("Camel in Action 2");
book.setYear("2012");
books.add(book);
// 3rd book
book = new Book();
book.setTitle("Camel in Action 3");
book.setYear("2013");
books.add(book);
// 4th book
book = new Book();
book.setTitle("Camel in Action 4");
book.setYear(null);
books.add(book);
// Add books to author
author.setBooks(books);
model.put(author.getClass().getName(), author);
models.add(model);
return models;
}