[ http://issues.apache.org/jira/browse/COCOON-1270?page=all ]
Pier Fumagalli updated COCOON-1270:
-----------------------------------
Assign To: Torsten Curdt (was: Torsten Curdt)
> Javaflow can't call inherited methods
> -------------------------------------
>
> Key: COCOON-1270
> URL: http://issues.apache.org/jira/browse/COCOON-1270
> Project: Cocoon
> Type: Bug
> Components: - Flowscript
> Versions: 2.1.8-dev (Current SVN)
> Environment: Operating System: Linux
> Platform: PC
> Reporter: Nikolaus Rath
> Assignee: Torsten Curdt
>
> A class named FlowHandler contains this method:
> public void doInvokeMain()
> {
> try {
> setParent(null);
> doInvoke();
> } catch (CommandException e) {
> // Because we are the top level handler, something bad
> // must have happened
> throw new RuntimeException("Unhandled command: " +
> e.getCommand());
> }
> }
> MenuBarHandler is a class inherited from FlowHandler. The following does *not*
> work (from sitemap.xmap):
> <map:flow language="java">
> <map:script src="org.rath.votra.MenuBarHandler"/>
> </map:flow>
> [...]
> <map:match pattern="start">
> <map:call function="invokeMain" />
> </map:match>
> When accessing the start URI, cocoon produces an InstantiationException.
> When I add the doInvokeMain method directly to the MenuBarHandler class,
> everything works fine:
> /* If we do not define this method here, we get an
> java.lang.InstantiationException
> from cocoon. Seems to be a bug. */
> public void doInvokeMain() {
> super.doInvokeMain();
> }
> It seems that cocoon can't call inherited methods as flow handlers.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira