[jbosstools-issues] [JBoss JIRA] (JBIDE-10091) NPE in VPE -> org.jboss.tools.common.text.xml.info.ChainTextHover

Victor Rubezhny (Commented) (JIRA) jira-events at lists.jboss.org
Thu Dec 8 12:17:40 EST 2011


    [ https://issues.jboss.org/browse/JBIDE-10091?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12649349#comment-12649349 ] 

Victor Rubezhny commented on JBIDE-10091:
-----------------------------------------

Regarding the first NPE (in AnnotationHoverProcessor.getHoverInfo()) the issue probably is obsolete, because the MarkerProblemAnnotationHoverProcessor (is used instead of AnnotationHoverProcessor and is derived from AnnotationHoverProcessor) redefines getHoverInfo() method as follows:

{code}
	public String getHoverInfo(ITextViewer viewer, IRegion hoverRegion) {
		return null;
	}
{code}

So, the AnnotationHoverProcessor.getHoverInfo() method is never been called and no NPE could be risen here at this moment.

As such (and taking in account the issue duplication against JBIDE-9912), the issue could be resolved as Out-Of-Date or Duplication.
                
> NPE in VPE -> org.jboss.tools.common.text.xml.info.ChainTextHover
> -----------------------------------------------------------------
>
>                 Key: JBIDE-10091
>                 URL: https://issues.jboss.org/browse/JBIDE-10091
>             Project: Tools (JBoss Tools)
>          Issue Type: Bug
>          Components: jsp/jsf/xml source editing, UpStream
>    Affects Versions: 3.3.0.M3
>            Reporter: Vitali Yemialyanchyk
>            Assignee: Victor Rubezhny
>             Fix For: 3.3.x
>
>
> {code}
> java.lang.NullPointerException
> 	at org.eclipse.wst.sse.ui.internal.taginfo.AnnotationHoverProcessor.getHoverInfo(AnnotationHoverProcessor.java:120)
> 	at org.jboss.tools.common.text.xml.info.ChainTextHover.getHoverInfo2(ChainTextHover.java:145)
> 	at org.jboss.tools.common.text.xml.info.ChainTextHover.getHoverInfo2(ChainTextHover.java:132)
> 	at org.eclipse.jface.text.TextViewerHoverManager$4.run(TextViewerHoverManager.java:166)
> {code}
> - I can't provide exact steps to reproduce.
> Only 1 statement - in AnnotationHoverProcessor.getHoverInfo line 120:
> hoverRegion can't be null during code inspecting,
> but variable p  - can be null.
> so look like UpStream exception 
> {code}
> java.lang.NullPointerException
> 	at org.eclipse.jst.jsf.facelet.core.internal.cm.ElementCMAdapter.getLength(ElementCMAdapter.java:109)
> 	at org.eclipse.wst.xml.core.internal.contentmodel.basic.CMNamedNodeMapImpl.<init>(CMNamedNodeMapImpl.java:40)
> 	at org.eclipse.wst.xml.ui.internal.taginfo.XMLTagInfoHoverProcessor.getCMAttributeDeclaration(XMLTagInfoHoverProcessor.java:206)
> 	at org.eclipse.wst.xml.ui.internal.taginfo.XMLTagInfoHoverProcessor.computeTagAttNameHelp(XMLTagInfoHoverProcessor.java:122)
> 	at org.eclipse.wst.xml.ui.internal.taginfo.XMLTagInfoHoverProcessor.computeRegionHelp(XMLTagInfoHoverProcessor.java:108)
> 	at org.eclipse.wst.xml.ui.internal.taginfo.XMLTagInfoHoverProcessor.computeHoverHelp(XMLTagInfoHoverProcessor.java:86)
> 	at org.eclipse.wst.xml.ui.internal.taginfo.XMLTagInfoHoverProcessor.getHoverInfo(XMLTagInfoHoverProcessor.java:257)
> 	at org.eclipse.jst.jsf.facelet.ui.internal.hover.FaceletHover.getHoverInfo(FaceletHover.java:58)
> 	at org.jboss.tools.common.text.xml.info.ChainTextHover.getHoverInfo2(ChainTextHover.java:145)
> 	at org.jboss.tools.common.text.xml.info.ChainTextHover.getHoverInfo2(ChainTextHover.java:132)
> 	at org.eclipse.jface.text.TextViewerHoverManager$4.run(TextViewerHoverManager.java:166)
> {code}
> - in this case something wrong in jboss tools can be cause of exception

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the jbosstools-issues mailing list