forrest-svn mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rgard...@apache.org
Subject svn commit: r485915 - /forrest/trunk/whiteboard/forrest2/core/src/test/org/apache/forrest/test/core/plugins/input/HelloWorldInputPlugin.java
Date Mon, 11 Dec 2006 22:16:01 GMT
Author: rgardler
Date: Mon Dec 11 14:16:00 2006
New Revision: 485915

URL: http://svn.apache.org/viewvc?view=rev&rev=485915
Log:
Keep tabs on the source document that created this internal document so that we have tracability
(particularly useful in error messages)

Modified:
    forrest/trunk/whiteboard/forrest2/core/src/test/org/apache/forrest/test/core/plugins/input/HelloWorldInputPlugin.java

Modified: forrest/trunk/whiteboard/forrest2/core/src/test/org/apache/forrest/test/core/plugins/input/HelloWorldInputPlugin.java
URL: http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrest2/core/src/test/org/apache/forrest/test/core/plugins/input/HelloWorldInputPlugin.java?view=diff&rev=485915&r1=485914&r2=485915
==============================================================================
--- forrest/trunk/whiteboard/forrest2/core/src/test/org/apache/forrest/test/core/plugins/input/HelloWorldInputPlugin.java
(original)
+++ forrest/trunk/whiteboard/forrest2/core/src/test/org/apache/forrest/test/core/plugins/input/HelloWorldInputPlugin.java
Mon Dec 11 14:16:00 2006
@@ -17,6 +17,7 @@
 package org.apache.forrest.test.core.plugins.input;
 
 import org.apache.forrest.core.Controller;
+import org.apache.forrest.core.document.AbstractSourceDocument;
 import org.apache.forrest.core.document.IDocument;
 import org.apache.forrest.core.document.InternalDocument;
 import org.apache.forrest.core.plugin.AbstractInputPlugin;
@@ -31,6 +32,6 @@
 	public static final String CONTENT = "<html xmlns=\"http://www.w3.org/2002/06/xhtml2\"
xml:lang=\"en\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:schemaLocation=\"http://www.w3.org/2002/06/xhtml2/
http://www.w3.org/MarkUp/SCHEMA/xhtml2.xsd\">  <head>    <title>XHTML 2 Simple
Sample Page</title>   </head>  <body>  <h>Hello World</h>  </body></html>";
 
 	public IDocument process(final Controller controller, final IDocument doc) {
-		return new InternalDocument(doc.getRequestURI(), CONTENT);
+		return new InternalDocument((AbstractSourceDocument)doc, CONTENT);
 	}
 }



Mime
View raw message