Commons OGNL
  1. Commons OGNL
  2. OGNL-10

Calling methods with parameters containing more calls ?

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Cannot Reproduce
    • Affects Version/s: 2.7
    • Fix Version/s: 2.7
    • Component/s: ExpressionCompiler
    • Labels:
      None
    • Environment:
      ognl-2.7-20070303-020139-5

      Description

      Not sure if the title is correct but ...

      Trying to rewrite OGNL-9 i add in the .java
      @Message("page-title")
      public abstract String getTitle(int partnersCount);

      and use any of the expressions
      ognl:getTitle(partners.size)
      ognl:getTitle(partners.size())
      ognl:getTitle(getPartners().size())
      ognl:getTitle(getPartners().size)

      BTW, the .java contains a getPartners() method that returns a collection

      In the first case I get
      Error compiling expression on object $OurPartners_47@3c1[OurPartners] with expression node getTitle(partners.size) getter body: null setter body: nulljava.lang.ArrayIndexOutOfBoundsException: 0
      and in the others
      Error compiling expression on object $NonflowBorder_156@ea72b4a1[OurPartners/Border] with expression node title getter body: null setter body: nulltitle

      They all produce the same stacktrace:

      org.apache.tapestry.services.impl.HiveMindExpressionCompiler.compileExpression(HiveMindExpressionCompiler.java:258)
      ognl.OgnlRuntime.compileExpression(OgnlRuntime.java:384)
      ognl.Ognl.compileExpression(Ognl.java:123)
      org.apache.tapestry.services.impl.ExpressionCacheImpl.parse(ExpressionCacheImpl.java:129)
      org.apache.tapestry.services.impl.ExpressionCacheImpl.getCompiledExpression(ExpressionCacheImpl.java:91)
      $ExpressionCache_1112ff335b1.getCompiledExpression($ExpressionCache_1112ff335b1.java)
      org.apache.tapestry.binding.ExpressionBinding.resolveExpression(ExpressionBinding.java:121)
      org.apache.tapestry.binding.ExpressionBinding.getObject(ExpressionBinding.java:112)
      org.apache.tapestry.binding.AbstractBinding.getObject(AbstractBinding.java:84)
      $Border_22.getTitle($NonflowBorder_22.java)
      ognl.ASTProperty4142218Accessor.get(ASTProperty4142218Accessor.java)
      org.apache.tapestry.services.impl.ExpressionEvaluatorImpl.read(ExpressionEvaluatorImpl.java:131)
      $ExpressionEvaluator_1112ff335af.read($ExpressionEvaluator_1112ff335af.java)
      org.apache.tapestry.binding.ExpressionBinding.resolveExpression(ExpressionBinding.java:127)
      org.apache.tapestry.binding.ExpressionBinding.getObject(ExpressionBinding.java:112)
      org.apache.tapestry.binding.AbstractBinding.getObject(AbstractBinding.java:84)
      $Insert_6.getValue($Insert_6.java)
      org.apache.tapestry.components.Insert.renderComponent(Insert.java:48)
      org.apache.tapestry.AbstractComponent.render(AbstractComponent.java:708)
      org.apache.tapestry.services.impl.DefaultResponseBuilder.render(DefaultResponseBuilder.java:184)
      org.apache.tapestry.AbstractComponent.renderBody(AbstractComponent.java:521)
      org.apache.tapestry.html.Body.renderComponent(Body.java:38)
      org.apache.tapestry.AbstractComponent.render(AbstractComponent.java:708)

        Activity

        Tony Stevenson made changes -
        Project Import Mon Jun 18 09:00:45 UTC 2012 [ 1340010045016 ]
        Jesse Kuhnert made changes -
        Resolution Cannot Reproduce [ 5 ]
        Status Open [ 1 ] Resolved [ 5 ]
        Jesse Kuhnert made changes -
        Field Original Value New Value
        Component/s ExpressionCompiler [ 21253 ]
        Fix Version/s 2.7 [ 21688 ]
        Andreas Andreou created issue -

          People

          • Assignee:
            Jesse Kuhnert
            Reporter:
            Andreas Andreou
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development