commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From simonetrip...@apache.org
Subject svn commit: r1241013 - /commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/export/GraphMLExporter.java
Date Mon, 06 Feb 2012 13:56:34 GMT
Author: simonetripodi
Date: Mon Feb  6 13:56:34 2012
New Revision: 1241013

URL: http://svn.apache.org/viewvc?rev=1241013&view=rev
Log:
added generation comment on XML GraphML

Modified:
    commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/export/GraphMLExporter.java

Modified: commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/export/GraphMLExporter.java
URL: http://svn.apache.org/viewvc/commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/export/GraphMLExporter.java?rev=1241013&r1=1241012&r2=1241013&view=diff
==============================================================================
--- commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/export/GraphMLExporter.java
(original)
+++ commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/export/GraphMLExporter.java
Mon Feb  6 13:56:34 2012
@@ -19,7 +19,10 @@ package org.apache.commons.graph.export;
  * under the License.
  */
 
+import static java.lang.String.format;
+
 import java.io.Writer;
+import java.util.Date;
 import java.util.HashMap;
 import java.util.Map;
 
@@ -133,6 +136,9 @@ final class GraphMLExporter<V extends Ve
 
         // start document tokens
         xmlWriter.writeStartDocument();
+
+        xmlWriter.writeComment( format( "Graph generated by Apache Commons Graph on %s%n",
new Date() ) );
+
         xmlWriter.writeStartElement( GRAPHML );
         xmlWriter.writeAttribute( XMLNS, GRAPHML_XMLNS );
 



Mime
View raw message