Re: Am I using EOUtilities.createAndInsertInstance() correctly?
Re: Am I using EOUtilities.createAndInsertInstance() correctly?
- Subject: Re: Am I using EOUtilities.createAndInsertInstance() correctly?
- From: Des Oates <email@hidden>
- Date: Mon, 21 Mar 2005 18:27:32 +0000
Doh!
That looks like that is what it was. It was a typo in the fully
qualified class name in the EO Model.
BTW this line came back with"com.webobjects.control.EOGenericRecord"
which presumably it defaults to if it can't find the class itself
Thanks to both who helped.
Des
On 21 Mar 2005, at 18:14, Christian Pekeler wrote:
I'm getting a class cast exception when I call this method like this:
MyObject mo = (MyObject) EOUtilities.createAndInsertInstance(myEC,
"MyObject");
Did you set the class for the MyObject entity to MyObject in your
EOModel?
If you did, check what you're actually getting
System.out.println(EOUtilities.createAndInsertInstance(myEC,
"MyObject").getClass().getName())
Christian
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden