You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by jk...@csc.com on 2001/10/25 21:56:24 UTC

possible bug in util built-in logicsheet???

This is the code inside my logicsheet

 <xsl:template match="codes:getCodedValues">
  <xsl:variable name="type">
           "<xsl:value-of select="./type"/>"
    </xsl:variable>

     <util:include-expr>
          <util:expr>getCodedValues(<xsl:copy-of select
="$type"/>)</util:expr>
     </util:include-expr>
  </xsl:template>

When it correctly intreprets my xsp and logicsheet, the resulting java code
looks like this

          {
                    org.apache.cocoon.components.parser.Parser newParser =
                    null;

               try {
                    newParser
                         = (org.apache.cocoon.components.parser.Parser)
                                         this.manager.lookup(

                    org.apache.cocoon.components.parser.Parser.ROLE);
                               InputSource __is = new InputSource(
                                         new

StringReader(String.valueOf(getCodedValues("RCD_STS"))));


                                           XSPUtil.include(__is,
this.contentHandler,
                                   newParser);
                         } catch (Exception e) {
                         getLogger().error("Could not include page", e);
                         }
                         finally { if (newParser != null)
                              this.manager.release((Component) newParser);
                               } }


BUT, WHEN I MAKE ANY CHANGES TO MY XSP FILE and cause it to recompile the
java code. THE GENERATED JAVA CODE LOOKS
LIKE THIS AND I GET
THIS ERROR MSG:

               org.apache.cocoon.ProcessingException: Language Exception:
org.apache.cocoon.components.language.LanguageException: Error compiling
person_xsp: Line 312, column 38: ')' expected.


            this.contentHandler.startElement
                    ("http://apache.org/xsp/util/2.0",
                                                 "include-expr",
                    "util:include-expr", xspAttr);

                              xspAttr.clear();



                          this.contentHandler.startElement
                                   ("http://apache.org/xsp/util/2.0",
                                                              "expr",
"util:expr",
                                                   xspAttr);

                         xspAttr.clear();


                    this.characters("getCodedValues( "RCD_STS"  )");


                                         this.contentHandler.endElement
                              ("http://apache.org/xsp/util/2.0",
                                                   "expr", "util:expr");



                                     this.contentHandler.endElement
                                              ("
http://apache.org/xsp/util/2.0",
                                                          "include-expr",
                                         "util:include-expr");

BUT, IF I MAKE SOME FAKE CHANGES TO THE LOGICSHEET AND SAVE IT, THE CORRECT
JAVA CODE IS GENERATED AGAIN AND THE PAGE WORKS.

so, I wonder if anybody else has experienced this problem.
thanks,
j


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