Re: R: Strings to SAX events

2002-11-08 Thread reinhard_poetz
Luca,

In a generator I use flowing code within the generate()-Method. Maybe this
helps:

 parser = (Parser)this.manager.lookup(Parser.ROLE);
 parser.setConsumer(super.xmlConsumer);   
 parser.parse(new InputSource(new StringReader(sb.toString(;

Regards,
Reinhard

> Ludovic,
> 
> thanks for your kind answer, but we are not in an XSP page (we're writing
> a
> Transformer instead), hence, your suggestion is not truly useful to us.
> 
> Best regards,
> 
> Luca Morandini
> [EMAIL PROTECTED]
> 
> > -Messaggio originale-
> > Da: Ludovic de Beaurepaire [mailto:ludovic.debeaurepaire@;axonie.com]
> > Inviato: venerdì 8 novembre 2002 11.02
> > A: [EMAIL PROTECTED]
> > Oggetto: Re: Strings to SAX events
> >
> >
> > Try in a XSP the following, data is your xml string :
> >
> > 
> > 
> > data
> > 
> > 
> >
> >
> >
> > - Original Message -
> > From: "Luca Morandini" <[EMAIL PROTECTED]>
> > To: <[EMAIL PROTECTED]>
> > Sent: Friday, November 08, 2002 10:55 AM
> > Subject: Strings to SAX events
> >
> >
> > > Folks,
> > >
> > >  We're in the process of writing a Transformer, which, of
> > course, outputs
> > > SAX
> > >  events... but, in the midst of this stream , we need to insert an
> > >  XML element stored in a string.
> > >
> > >  To do this we're groping in the dark trying something like this:
> > >
> > >   JaxpParser respParser = new JaxpParser();
> > >   respParser.parse( new InputSource(new StringReader(str)),
> > >   new EmbeddedXMLPipe(contentHandler));
> > >
> > >  Which fails giving this:
> > >  org.apache.cocoon.ProcessingException: Failed to execute pipeline.:
> > >  java.lang.ClassCastException
> > >  ...
> > >  Caused by: java.lang.ClassCastException
> > >   at
> > >
> > >
> > com.lucamorandini.charts.ChartTransformer.endElement(ChartTransfor
> > mer.java:6
> > > 55)
> > >   at
> > >
> > >
> > org.apache.cocoon.components.sax.XMLByteStreamInterpreter.parse(XM
> > LByteStrea
> > > mInterpreter.java:129)
> > >   at
> > >
> > >
> > org.apache.cocoon.components.sax.XMLByteStreamInterpreter.deserial
> > ize(XMLByt
> > > eStreamInterpreter.java:102)
> > >   at
> > >  org.apache.cocoon.components.pipeline.CachingEventPipeline.process
> > >  (CachingEventPipeline.java:219)
> > >   ... 44 more
> > >
> > >  java.lang.ClassCastException
> > >   at
> > >
> > >
> > com.lucamorandini.charts.ChartTransformer.endElement(ChartTransfor
> > mer.java:6
> > > 55)
> > >   at
> > >
> > >
> > org.apache.cocoon.components.sax.XMLByteStreamInterpreter.parse(XM
> > LByteStrea
> > > mInterpreter.java:129)
> > >   at
> > >
> > >
> > org.apache.cocoon.components.sax.XMLByteStreamInterpreter.deserial
> > ize(XMLByt
> > > eStreamInterpreter.java:102)
> > >   at
> > >  org.apache.cocoon.components.pipeline.CachingEventPipeline.process
> > >  (CachingEventPipeline.java:219)
> > >   at
> > >
> > >
> > org.apache.cocoon.components.pipeline.CachingStreamPipeline.proces
> > s(CachingS
> > > treamPipeline.java:399)
> > >
> > >  The classes we use are:
> > >   org.apache.avalon.excalibur.xml.JaxpParser;
> > >   org.xml.sax.InputSource;
> > >   java.io.StringReader;
> > >   org.apache.cocoon.xml.EmbeddedXMLPipe;
> > >
> > >  And the environment is:
> > >   Solaris 5.8
> > >   JDK 1.4.1_01
> > >   Tomcat 4.1.12-LE-jdk14
> > >   Cocoon 2.0.3
> > >
> > >  May someone please help us ?
> > >
> > >  Thanks in advance,
> > >
> > > Piero De Nicola & Luca Morandini
> > >
> > >
> > >  We are protected from the virus by Norton Antivirus
> > Corporate Edition
> > >
> > > -
> > > Please check that your question  has not already been answered in the
> > > FAQ before posting. 
> > >
> > > To unsubscribe, e-mail: <[EMAIL PROTECTED]>
> > > For additional commands, e-mail:   <[EMAIL PROTECTED]>
> > >
> > >
> > >
> >
> >
> > -
> > Please check that your question  has not already been answered in the
> > FAQ before posting. 
> >
> > To unsubscribe, e-mail: <[EMAIL PROTECTED]>
> > For additional commands, e-mail:   <[EMAIL PROTECTED]>
> >
> 
> 
>  We are protected from the virus by Norton Antivirus Corporate Edition
> 
> -
> Please check that your question  has not already been answered in the
> FAQ before posting. 
> 
> To unsubscribe, e-mail: <[EMAIL PROTECTED]>
> For additional commands, e-mail:   <[EMAIL PROTECTED]>
> 

-- 
+++ GMX - Mail, Messaging & more  http://www.gmx.net +++
NEU: Mit GMX ins Internet. Rund um die Uhr für 1 ct/ Min. surfen!


-
Please check that your question  has not already been answered in the
FAQ before posting. 

T

RE: XMLForms vs Struts

2002-11-06 Thread reinhard_poetz
Steven has moved it to "Links'. Thank you - I overlooked the already
existing point at the links page.

Regards,
Reinhard

> Ivelin,
> 
> I created a new main point in the left menu and called it "Cocoon
> compared".
> 
> Reinhard
> 
> > -Original Message-
> > From: Ivelin Ivanov [mailto:ivelin@;apache.org]
> > Sent: Saturday, November 02, 2002 5:23 PM
> > To: [EMAIL PROTECTED]
> > Subject: Re: XMLForms vs Struts
> >
> >
> > Please do.
> > Wiki is great, but I am not sure in which section would this one
> > article go.
> > Please let me know where it went.
> >
> > Thank you,
> >
> > Ivelin
> >
> >
> > - Original Message -
> > From: "Reinhard Poetz" <[EMAIL PROTECTED]>
> > To: <[EMAIL PROTECTED]>
> > Sent: Thursday, October 31, 2002 8:02 AM
> > Subject: RE: XMLForms vs Struts
> >
> >
> > Ivelin,
> >
> > As this is an often discussed question: Do you mind adding it to the
> > CocoonWiki? If no I could do it for you ...
> >
> > Regards,
> > Reinhard
> >
> > > -Original Message-
> > > From: Ivelin Ivanov [mailto:ivelin@;apache.org]
> > > Sent: Thursday, October 31, 2002 2:52 PM
> > > To: [EMAIL PROTECTED]
> > > Subject: Re: XMLForms vs Struts
> > >
> > >
> > >
> > > I hope this will not make things even more confusing for you,
> > > but here is my view:
> > >
> > > Struts is 3 parts:
> > > 1) An URL map, matching URLs to Actions.
> > > Everything you can do with struts-config.xml (Struts), you can do with
> > > sitemap.xmap (Cocoon).
> > >
> > > 2) Custom JSP tags for rendering HTML, like i18n, access to JavaBean
> > > properties and others. Cocoon's set of transformers is a superset
> > > of Strut's
> > > visual tags.
> > >
> > > 3) Form handling.
> > > Automated binding between HTML input fields and JavaBeans.
> > > Cocoon's XMLForm does that and much more. It not only provides
> > > the binding,
> > > but it does it in a browser independent way. Struts is only designed
> to
> > > handle automatically HTML input.
> > >
> > >
> > > For fairness sake, I will tell you that over the last 2 years I
> > have used
> > > Struts successfully in big enterprise projects. It is a good and sound
> > > technology when you are only interested to support the major
> > HTML browsers
> > > and you are not concerned with other interfaces to your application
> like
> > > WML, VXML, Web Services, etc.
> > >
> > >
> > > My recommendation is, if you are in a hurry and you don't want to
> invest
> > > time in learning a new technology, go Struts.
> > >
> > > If you plan to build a lot of web applications in the future, you
> > > must learn
> > > Cocoon. It will add a very powerful weapon to your software
> > tools arsenal.
> >
> > > You don't have to use it all the time, but when things start to look
> > > dangerously complex, you will find it to be a life saver.
> > >
> > >
> > >
> > > Best,
> > >
> > > Ivelin
> > >
> > >
> > > - Original Message -
> > > From: "SAXESS - Hussayn Dabbous" <[EMAIL PROTECTED]>
> > > To: <[EMAIL PROTECTED]>
> > > Sent: Thursday, October 31, 2002 3:48 AM
> > > Subject: Re: XMLForms vs Struts
> > >
> > >
> > > Hy;
> > >
> > > First let me tell you: I like the idea of merging cocoon and struts,
> > > because i see both technologies to be helpfull also in conjunction...
> > >
> > > Omar Tazi wrote:
> > > > If you like the MVC aspect in Struts and like the flexibility
> provided
> > > > by XML/XSLT, and don't like the limitations that come with JSPs,
> check
> > > > out our Framework. It's called OXF (Open XML Framework). OXF is the
> > > > result of our combined passion for Cocoon and Struts/J2EE and our
> > > > involvement in huge enterprise projects. It will dramatically help
> you
> > > > in your tasks (listed below). Good luck!
> > > >
> > >
> > > But i am also a bit confused. I'm following the discussons in this
> > > mailing list for about a week now and this is already the second
> > > mentioning of a product/component (whatever) that claims to be an
> > > on top of cocoon development. But when i enter the pages mentioned
> > > above, it is very hard to find the backpointers to cocoon as the
> > > base component...
> > >
> > > Despite that all this stuff sounds very interesting, but i get more
> > > and more unshure how to proceed. Some questions rise in my mind:
> > >
> > > 1.) Why are all such nice and nifty add ons developed all outside
> > > of cocoon ?
> > > 2.) When i move to such an add on component, how can i enshure
> > > to keep up with the releases of cocoon (taking adavantage
> > > of the enhancements done there)?
> > > 3.) Why can't i find pointers to these add ons from the cocoon pages ?
> > >
> > > There is sooo many good software around the world and cocoon
> > for me is one
> > > of the finest. Why does not all this effort take place at the heart
> but
> > > is cluttered around in several loosely coupled or even uncoupled
> > > add on projects ???
> > >
> > > And now my final question (to come back to the technical part):
> > > Why is it s

Re: repost : activeX (.cab) and C 2.0.3

2002-09-03 Thread reinhard_poetz

Barbara,

Are you sure that your pipeline works? Try to include an image which has the
same path as the active-x. When this works change to
.cab/application/octet-stream.

Regards,
Reinhard

> Cocoon does not add my activeX component to the html page it outputs. Even
> application/octet-stream set as mime type for the pipeline that reads the
> .cab does not work (no visible effect of the activeX that adjusts printing
> margins).
> 
> Thanks for any hint,
> 
> Barbara
> 
> 
> -
> Please check that your question  has not already been answered in the
> FAQ before posting. 
> 
> To unsubscribe, e-mail: <[EMAIL PROTECTED]>
> For additional commands, e-mail:   <[EMAIL PROTECTED]>
> 

-- 
GMX - Die Kommunikationsplattform im Internet.
http://www.gmx.net


-
Please check that your question  has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail:   <[EMAIL PROTECTED]>




Re: Slide Demo (ComponentException)

2002-08-21 Thread reinhard_poetz

> On Wed, 21 Aug 2002 [EMAIL PROTECTED] wrote:
> 
> > Hi Stephan,
> >
> > I wanted to try out your slide examples but I always get a
> > ComponentException at the login:
> >
> > ERROR   (2002-08-21) 13:40.28:729   [sitemap.generator.principallist]
> > (/samples/slide/login) HttpProcessor[8080][4]/PrincipalListGenerator:
> Could not
> > lookup for component.
> > org.apache.avalon.framework.component.ComponentException: component:
> > ComponentSelector could not access the Component for hint: slide
> > at
> >
>
org.apache.avalon.excalibur.component.ExcaliburComponentSelector.select(ExcaliburComponentSelector.java:216)
> > at
> >
>
org.apache.cocoon.components.ExtendedComponentSelector.select(ExtendedComponentSelector.java:293)
> > at
> >
>
org.apache.cocoon.generation.PrincipalListGenerator.generate(PrincipalListGenerator.java:135)
> >
> > Do you have any ideas? I'm using cocoon2.1dev - the last nightly build.
> >
> 
> Do you have the following entry in your
> build/cocoon/webapp/WEB-INF/cocoon.xconf?
> 
>   default="slide" logger="core.repositories.principalprovider"
>   
> role="org.apache.cocoon.components.repository.PrincipalProviderSelector">
> 
>
>
class="org.apache.cocoon.components.repository.impl.SlidePrincipalProvider"
>  logger="core.repositories.principalprovider.slide" name="slide"
>  namespace="myrepository" repository="slide"/>
> 
>  
> 
> Thanks for testing, Stephan.

Yes, it's included. Do you have any other ideas/hints?

Regards,
Reinhard


> 
> ___
>  Stephan Michels   EMail: [EMAIL PROTECTED]
>  ICQ: 115535699Tel: +49-030-314-21583
> +|+|+|+|+|+|+|-|
> 
> 
> -
> Please check that your question  has not already been answered in the
> FAQ before posting. 
> 
> To unsubscribe, e-mail: <[EMAIL PROTECTED]>
> For additional commands, e-mail:   <[EMAIL PROTECTED]>
> 

-- 
GMX - Die Kommunikationsplattform im Internet.
http://www.gmx.net


-
Please check that your question  has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail:   <[EMAIL PROTECTED]>




Slide Demo (ComponentException)

2002-08-21 Thread reinhard_poetz

Hi Stephan,

I wanted to try out your slide examples but I always get a
ComponentException at the login:

ERROR   (2002-08-21) 13:40.28:729   [sitemap.generator.principallist]
(/samples/slide/login) HttpProcessor[8080][4]/PrincipalListGenerator: Could not
lookup for component.
org.apache.avalon.framework.component.ComponentException: component:
ComponentSelector could not access the Component for hint: slide
at
org.apache.avalon.excalibur.component.ExcaliburComponentSelector.select(ExcaliburComponentSelector.java:216)
at
org.apache.cocoon.components.ExtendedComponentSelector.select(ExtendedComponentSelector.java:293)
at
org.apache.cocoon.generation.PrincipalListGenerator.generate(PrincipalListGenerator.java:135)

Do you have any ideas? I'm using cocoon2.1dev - the last nightly build.

Regards,
Reinhard

-- 
GMX - Die Kommunikationsplattform im Internet.
http://www.gmx.net


-
Please check that your question  has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail:   <[EMAIL PROTECTED]>




Re: HtmlGenerator and FOP

2002-05-31 Thread reinhard_poetz

Harald,

> We are using Cocoon 2.0.2 within Tomcat 4.0.1 on Linux.
> 
> We want to integrate an external HTML-Site in our homepage. Like the 
> Yahoo screen scrape example we therefore use the HTML-Generator to get 
> the content of the page.
> 
> As this page links its pictures with a relative path our browser does 
> not show these pictures because they do not reside on our cocoon-server. 
> Do you have any hints for us how to solve this problem?
> 
> Is it possible to pipe the http-response of the external page as html to 
> our users as well as generating a pdf-document of this reponse (we want 
> to add this to the session) in one step?
> 
> Is it possible to set a different browser-type to the HTMLGenerator? It 
> now sends the JDK-Version as browser-type. This type is not accepted by 
> the external page.

I wrote an HTML-Generator which makes use of the httpclient-API
(http://jakarta.apache.org/commons/httpclient/). I have not had the time extending the
existing HTML-Generator by this feature and to post the patch but you can find
the sources at
http://marc.theaimsgroup.com/?l=xml-cocoon-dev&m=101412719423893&w=2. (I'm not sure if 
it will work with Cocoon 2.0.2.).

My version of the HTML-Generator uses the browser's user-agent.

Hope that helps,
Reinhard

> 
> Harald
> 
> 
> -
> Please check that your question has not already been answered in the
> FAQ before posting. 
> 
> To unsubscribe, e-mail: <[EMAIL PROTECTED]>
> For additional commands, e-mail: <[EMAIL PROTECTED]>
> 

-- 
GMX - Die Kommunikationsplattform im Internet.
http://www.gmx.net


-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




Re: A SOAP Transformer?

2002-05-06 Thread reinhard_poetz

Steve,

I would be very interested in a "SOAP Transformer". 

I think it would be a very useful component - but at the moment I'm not sure
too if there are some hidden issues.

I think we should work together!

Reinhard

> Dear Cocoon Users:
>   
>   Does it make sense that a "SOAP Transformer"
>   could be added to the Cocoon arsenal?
> 
>   An incoming XML doc would contain the URL of
>   the web service to be accessed, perhaps
>   also necessary authentication information,
>   and the SOAP body.  The SOAP Transformer
>   would simply send the message, and insert
>   the response into the document stream.
> 
>   Does this make sense as a useful component?
>   Or are there some hidden issues that would
>   introduce complexity?
> 
>   Steve Punte
>   [EMAIL PROTECTED] 
> 
> __
> Do You Yahoo!?
> Yahoo! Health - your guide to health and wellness
> http://health.yahoo.com
> 
> -
> Please check that your question has not already been answered in the
> FAQ before posting. 
> 
> To unsubscribe, e-mail: <[EMAIL PROTECTED]>
> For additional commands, e-mail: <[EMAIL PROTECTED]>
> 

-- 
GMX - Die Kommunikationsplattform im Internet.
http://www.gmx.net


-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>




How does the pseudo-protocol context work?

2001-10-05 Thread reinhard_poetz

Hi,

I've fowllowing problem:
In a sub-sitemap I make use of the "DatabaseAddAction". Everything works
fine if I insert the absolute path of the describtor file. But if I want to make
use of the pseudo-protocol "context" it only works if I integrate the
describtor file in the root-directory(context://filename.xml). Then I tried
"context:///filename.xml" and "context:/filename.xml" - no success.

My goal is creating a small application that can be easily integrated in a
root-sitemap and the only thing you have to do is mounting the sub-sitemap in
the root-sitemap.

Does anybody have a solution for my problem?

Reinhard

-- 
GMX - Die Kommunikationsplattform im Internet.
http://www.gmx.net


-
Please check that your question has not already been answered in the
FAQ before posting. 

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>