cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "rachid harradi" <rachid.harr...@gmx.net>
Subject Re: from flowscript to pipline
Date Thu, 25 Jan 2007 15:23:33 GMT
Dear All,

i get a error like :
org.apache.excalibur.source.SourceException: The attribute: myXml is empty


any idea


Rachid Harradi
-------- Original-Nachricht --------
Datum: Thu, 25 Jan 2007 15:12:03 +0100
Von: "rachid harradi" <rachid.harradi@gmx.net>
An: users@cocoon.apache.org
Betreff: from flowscript to pipline

> Dear All,
> 
> i need your help. so i have following flowscript. 
> 
> function main() 
> {	
> 	try 
> 		{ 
> 				var myXml = java.io.ByteArrayOutputStream();
> 		 		var pipeutil =
> cocoon.createObject(Packages.org.apache.cocoon.components.flow.util.PipelineUtil);
> 		 		var dbmanger=cocoon.getComponent("dbmanager.DBManager");
> 		 		
> 				var nodeDoc = dbmanger.runObjection_HTML();
> 				var filename = nodeDoc.getFilename();
> 				var pfad = new Packages.java.lang.String("E:/temp/"+filename);
> 			
> 				var psID_Idea=nodeDoc.getDocument_id();
> 				var psDocumentType= nodeDoc.getDocumenttype();
> 				var psCreator =nodeDoc.getCreater();
> 				
> 				var c_Persist_Ameli_IP=new
> Packages.wohland.de.ameli.Process.C_Persist_Ameli_IP();
> 				
> 				var c_Error=c_Persist_Ameli_IP.add_StandardDocument(
> 										 psID_Idea,
> 										 psDocumentType, 
> 										 psCreator
> 										);
> 										
> 				myXml= nodeDoc.serializeToOutputStream();
> 					
> ("Objection_HTML.js",{"path":pfad},myXml);
> 		   		myXml.close();
> 		   	    cocoon.sendPage("success.txt", null);
> 		   	    /** cocoon.sendPage("ok", {"model": model});**/
> 
>    	  } catch( ex ) {
> 		      cocoon.log.error(ex);
> 		      // Smth. went wrong. Sending a error.txt file to the browser
> 		      cocoon.sendPage("error.txt", null);
>    	 }      
> }
> 
> 
> 
> then i have this Sitemape:
> 
> <map:pipeline>
> 	    
> 	    <map:match pattern="">
> 	      <map:call function="main"/>
> 	   	</map:match>
> 	   
> 	    
> 	    <map:match pattern="Objection_HTML.js">
> 	   	 
> 		   	 <map:generate  src="module:flow-attr:myXml"/>  
> 		   	
> 		   	 
> 		     <map:transform  type="xslt" src="objection04.xslt"/>
> 		    
> 		     <map:transform src="saveFile.xsl">
> 		         	<map:parameter name="serializer" value="html" />
> 		         	<map:parameter name="filepath" value="{flow-attribute:path}"
> />
> 		     </map:transform>
> 		     
> 		    <map:transform type ="savefiles"/>
> 		    <map:serialize type="html"/>
> 		    
> 		</map:match>
> 		
> 	   <map:match pattern="success.txt">
> 	         <map:generate type="jx" src="documents/templates/success.jxt"/>
> 	         <map:serialize type="html"/>
> 	   </map:match>
> 	      
> 	   <map:match pattern="error.txt">
> 	         <map:generate type="jx" src="documents/templates/error.jxt"/>
> 	         <map:serialize type="html"/>
> 	   </map:match>
> 	    
> 	</map:pipeline> 
> 
> 
> when i call flowscript. there is on problem with to call the pipline
> "Objection_HTML.js". so i get error.text
> 
> 
> Rachid Harradi
> -- 
> "Feel free" - 5 GB Mailbox, 50 FreeSMS/Monat ...
> Jetzt GMX ProMail testen: http://www.gmx.net/de/go/promail
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org

-- 
Der GMX SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen! 
Ideal für Modem und ISDN: http://www.gmx.net/de/go/smartsurfer

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message