ProjectMetadata implements Serializable { @Override public String toString() { StringBuilder sb = new StringBuilder(200); sb.append("files ["); if (!files.isEmpty()) { sb.append("\n"); for (File f : files) { sb.append(f).append("\n"); } } sb.append("]\n").append(hierarchy); return sb.toString(); } @SuppressWarnings("unchecked")  ProjectMetadata(Project project);  ProjectMetadata(Hierarchy hierarchy, Set<File> files); Project getProject(); Set<File> getFiles(); Hierarchy getHierarchy(); void setHierarchy(Hierarchy hierarchy); void addFile(File file); void removeFile(File file); @Override String toString();  }
@Test public void testToString() { toStringPrint(metadata); }