cayenne-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Olga Tkacheva (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CAY-1727) Modeler thinks entity is using inheritance when it doesn't
Date Thu, 23 Aug 2012 12:49:44 GMT

    [ https://issues.apache.org/jira/browse/CAY-1727?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13440262#comment-13440262
] 

Olga Tkacheva commented on CAY-1727:
------------------------------------

I got this exception on 3 step  (when create a new ObjEntity)

SEVERE: CayenneModeler Error
java.lang.ClassCastException: javax.swing.table.DefaultTableModel cannot be cast to org.apache.cayenne.modeler.editor.ObjAttributeTableModel
	at org.apache.cayenne.modeler.editor.ObjEntityAttributeTab.selectAttributes(ObjEntityAttributeTab.java:250)
	at org.apache.cayenne.modeler.editor.ObjEntityTabbedView.currentObjAttributeChanged(ObjEntityTabbedView.java:190)
	at org.apache.cayenne.modeler.ProjectController.fireObjAttributeDisplayEvent(ProjectController.java:1464)
	at org.apache.cayenne.modeler.editor.ObjEntityAttributeTab.processExistingSelection(ObjEntityAttributeTab.java:298)
	at org.apache.cayenne.modeler.editor.ObjEntityTabbedView$1.stateChanged(ObjEntityTabbedView.java:120)
	at javax.swing.JTabbedPane.fireStateChanged(JTabbedPane.java:400)
	at javax.swing.JTabbedPane$ModelListener.stateChanged(JTabbedPane.java:253)
	at javax.swing.DefaultSingleSelectionModel.fireStateChanged(DefaultSingleSelectionModel.java:116)
	at javax.swing.DefaultSingleSelectionModel.setSelectedIndex(DefaultSingleSelectionModel.java:50)
	at javax.swing.JTabbedPane.setSelectedIndexImpl(JTabbedPane.java:599)
	at javax.swing.JTabbedPane.setSelectedIndex(JTabbedPane.java:574)
	at org.apache.cayenne.modeler.editor.ObjEntityTabbedView.currentObjEntityChanged(ObjEntityTabbedView.java:151)
	at org.apache.cayenne.modeler.ProjectController.fireObjEntityDisplayEvent(ProjectController.java:1239)
	at org.apache.cayenne.modeler.ProjectTreeView.processSelection(ProjectTreeView.java:848)
	at org.apache.cayenne.modeler.ProjectTreeView$1.valueChanged(ProjectTreeView.java:150)
	at javax.swing.JTree.fireValueChanged(JTree.java:2820)
	at javax.swing.JTree$TreeSelectionRedirector.valueChanged(JTree.java:3191)
	at javax.swing.tree.DefaultTreeSelectionModel.fireValueChanged(DefaultTreeSelectionModel.java:629)
	at javax.swing.tree.DefaultTreeSelectionModel.notifyPathChange(DefaultTreeSelectionModel.java:1078)
	at javax.swing.tree.DefaultTreeSelectionModel.setSelectionPaths(DefaultTreeSelectionModel.java:287)
	at javax.swing.tree.DefaultTreeSelectionModel.setSelectionPath(DefaultTreeSelectionModel.java:170)
	at javax.swing.JTree.setSelectionPath(JTree.java:1598)
	at org.apache.cayenne.modeler.ProjectTreeView.showNode(ProjectTreeView.java:742)
	at org.apache.cayenne.modeler.ProjectTreeView.entityAdded(ProjectTreeView.java:674)
	at org.apache.cayenne.modeler.ProjectTreeView.objEntityAdded(ProjectTreeView.java:609)
	at org.apache.cayenne.modeler.ProjectController.fireObjEntityEvent(ProjectController.java:948)
	at org.apache.cayenne.modeler.action.CreateObjEntityAction.fireObjEntityEvent(CreateObjEntityAction.java:139)
	at org.apache.cayenne.modeler.action.CreateObjEntityAction.createObjEntity(CreateObjEntityAction.java:119)
	at org.apache.cayenne.modeler.action.CreateObjEntityAction.performAction(CreateObjEntityAction.java:66)
	at org.apache.cayenne.modeler.util.CayenneAction.actionPerformed(CayenneAction.java:162)
	at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2028)
	at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2351)
	at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:387)
	at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242)
	at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:236)
	at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:272)
	at java.awt.Component.processMouseEvent(Component.java:6373)
	at javax.swing.JComponent.processMouseEvent(JComponent.java:3267)
	at java.awt.Component.processEvent(Component.java:6138)
	at java.awt.Container.processEvent(Container.java:2085)
	at java.awt.Component.dispatchEventImpl(Component.java:4735)
	at java.awt.Container.dispatchEventImpl(Container.java:2143)
	at java.awt.Component.dispatchEvent(Component.java:4565)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4621)
	at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4282)
	at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4212)
	at java.awt.Container.dispatchEventImpl(Container.java:2129)
	at java.awt.Window.dispatchEventImpl(Window.java:2478)
	at java.awt.Component.dispatchEvent(Component.java:4565)
	at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:679)
	at java.awt.EventQueue.access$000(EventQueue.java:85)
	at java.awt.EventQueue$1.run(EventQueue.java:638)
	at java.awt.EventQueue$1.run(EventQueue.java:636)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
	at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:98)
	at java.awt.EventQueue$2.run(EventQueue.java:652)
	at java.awt.EventQueue$2.run(EventQueue.java:650)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:649)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

                
> Modeler thinks entity is using inheritance when it doesn't
> ----------------------------------------------------------
>
>                 Key: CAY-1727
>                 URL: https://issues.apache.org/jira/browse/CAY-1727
>             Project: Cayenne
>          Issue Type: Bug
>          Components: Modeler
>    Affects Versions: 3.1M2, 3.1B1
>            Reporter: Andrus Adamchik
>            Assignee: Andrus Adamchik
>
> The modeler mixes up Java inheritance with "persistent inheritance", which I guess can
be confusing indeed.
> One possible scenario to reproduce (I think this is not limited to these steps) :
> * Create new DataMap, enter arbitrary custom superclass
> * Create DbEntity with a couple of columns
> * Click "Create ObjEntity" that will create a new ObjEntity based on this DbEntity
> The resulting ObjEntity "Table/View" field is disabled. The Modeler thinks that custom
superclass corresponds to persistent inheritance... Deleting it, going to some other entity,
and then returning back to this ObjEntity will reactivate "Table/View".
> "Table/View" should be disabled only when "Inheritance" dropdown is populated (i.e. when
"super entity" is chose, not just a superclass). 

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

        

Mime
View raw message