This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 159649 - NullPointerException at org.netbeans.modules.hibernate.loaders.cfg.multiview.MappingPanel.getResourceTextField
Summary: NullPointerException at org.netbeans.modules.hibernate.loaders.cfg.multiview....
Status: RESOLVED FIXED
Alias: None
Product: javaee
Classification: Unclassified
Component: Hibernate (show other bugs)
Version: 6.x
Hardware: All All
: P2 blocker (vote)
Assignee: issues@javaee
URL: http://statistics.netbeans.org/except...
Keywords:
: 159394 (view as bug list)
Depends on:
Blocks:
 
Reported: 2009-03-05 01:41 UTC by martinoconnor
Modified: 2009-04-08 15:46 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 146176


Attachments
stacktrace (3.05 KB, text/plain)
2009-03-05 01:41 UTC, martinoconnor
Details

Note You need to log in before you can comment on or make changes to this bug.
Description martinoconnor 2009-03-05 01:41:03 UTC
Build: NetBeans IDE 6.5 (Build 200811100001)
VM: Java HotSpot(TM) Client VM, 11.2-b01, Java(TM) SE Runtime Environment, 1.6.0_12-b04
OS: Windows Vista, 6.0, x86

User Comments:
GUEST: while trying to edit the edit the hibernate.cfg.xml file, i am getting this error

martinoconnor: Attempted to add a mapping to a the session factory element of a hibernate.cfg.xml file using the gui editor.

GUEST: I was clicking on the Add... button under the Mappings section of the hibernate.cfg.xml file.

GUEST: Clicked "Add..." under mappings for Hibernate in a simple test web service

GUEST: Attempting to add a mapping in the hibernate.cfg.xml. No values were yet defined.

GUEST: In Hibernate.cfg.xml, selected Desgin view, Session FActory, Mappings, Add... 

This constantly produces error.



Stacktrace: 
java.lang.NullPointerException
        at org.netbeans.modules.hibernate.loaders.cfg.multiview.MappingPanel.getResourceTextField(MappingPanel.java:103)
        at org.netbeans.modules.hibernate.loaders.cfg.multiview.MappingPanel.getResourceName(MappingPanel.java:123)
        at org.netbeans.modules.hibernate.loaders.cfg.multiview.MappingPanel.isValid(MappingPanel.java:75)
        at java.awt.Component.invalidateIfValid(Component.java:2740)
        at java.awt.Component.setLocale(Component.java:1810)
        at javax.swing.JComponent.<init>(JComponent.java:595)
Comment 1 martinoconnor 2009-03-05 01:41:08 UTC
Created attachment 77746 [details]
stacktrace
Comment 2 martinoconnor 2009-03-05 01:44:23 UTC
*** Issue 159394 has been marked as a duplicate of this issue. ***
Comment 3 Exceptions Reporter 2009-03-31 21:43:34 UTC
This issue has already 20 duplicates 
see http://statistics.netbeans.org/exceptions/detail.do?id=146176
Comment 4 pslechta 2009-04-08 15:28:44 UTC
It looks like the problem with isValid() and Java 1.6 update 12 (all reporters seem to have 1.6 update 12).
Will try to fix it, it should be an easy fix.
Comment 5 pslechta 2009-04-08 15:45:37 UTC
This problem should be already fixed by T. Mysik:

http://hg.netbeans.org/main/rev/9834e9e0e00e

Today, MappingPanel has no isValid() method, it was renamed to isDatavalid(), so the stack trace is old (for NB 6.5, not
for NB 6.7). Also this issue should be already fixed in NB 6.5.1.

Petre J., I think we can easily close this issue... Why is the issue reported for 6.7? All exception reports are for 6.5...
Comment 6 pslechta 2009-04-08 15:46:47 UTC
Closing as FIXED.