Error in Hyperlink's axis processing
------------------------------------
Key: JBIDE-4424
URL:
https://jira.jboss.org/jira/browse/JBIDE-4424
Project: Tools (JBoss Tools)
Issue Type: Bug
Components: jsp/jsf/xml source editing
Affects Versions: 3.1.0.M1
Reporter: Victor Rubezhny
Assignee: Alexey Kazakov
Priority: Minor
Fix For: 3.1.0.M1
The method
org.jboss.tools.common.text.ext.hyperlink.HyperlinkPartitionerDefinition.Axis.containtsPath(String
path) contains an error.
TestCase:
EXECUTE: Create Seam 2.0 application
EXECUTE: Open home.xhtml and insert the following tag into acceptable place in the text:
<a4j:commandButton reRender="info"/>
EXECUTE: Check up that there is no "xmlns:a4j" attribute in the parent tags
which defines namespace for "aj4" library tags
EXECUTE: Move your mouse cursor over the "reRender" attribute value while the
Ctrl-key is pressed or Ctrl-click on that value.
ASSERT: There should not be any Hyperlink actions allowed on this attribute value.
The reason of the fault is in HyperlinkPartitionerDefinition.Axis.containtsPath(String
path) method that contains the following error:
Let's suppose that we have to check if the following
path=="/[http://java.sun.com/jsf/facelets]:composition/[http://java....
contains the given
axis=="/*/[http://richfaces.org/rich]:*/reRender/" in it.
The method splits the given axis into two substrings
{"/[http://richfaces.org/rich]:", "/reRender/"} and tries to find them
both inside the path value. In our example the path value contains both the substrings.
Even more, the path value ends with the last axis' substring. This makes the method to
return true.
But it's not correct for our particular case, because both substrings found in the
path value are not the part of a single namespace:tag-attribute sequence.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira