Ted -
I've wrestled with this a couple of times, and
although I don't have
the code in front of me right now, I think it boiled
down to the fact
that the template uses different ways to arrive at
the method names
used in the first and second methods, and in
particular that these
behave differently with regard to case sensitivity -
resulting in
'fetchRequiredNewEntity' and
'fetchRequirednewentity' respectively.
I think this can be worked around by making sure
that your class names
(and entity names?) match in terms of
capitalization, and maybe also
that the relationship name matches as well.
Specifically, it looks like your newentity is not
initial caps, and I
think initial caps may be required per the
assumptions that the
standard template uses. Given that, it seems that
the 'wrong' version
of the method name and call to the overloaded method
is in the first
of the two methods - the one that has 'NewEntity'
with initial caps.
Therefore, you may want to look at the templates you
are using, and
make the code used to arrive at the first method
name (and the call to
the second one) look more like the way the second
one is generated.
Sorry if this is a bit vague. It's early, I'm low on
coffee for the
day, and I don't have any code in front of me (which
is why I'm not
posting this back to the list :-) ). But I know I
banged my head
against the wall long enough with this that I at
least wanted to offer
some pointers.
Regards,
Simon
On Jan 28, 2008, at 12:01 AM, Theodore Petrosky
wrote:
I did have things working...... I don't know what
I
updated (maybe the project wonder frameworks???)
but
now when I eogenerate I get errors...
public static newentity
fetchRequiredNewEntity(EOEditingContext
editingContext, String keyName, Object value) {
return
_newentity.fetchRequiredNewEntity(editingContext,
new
EOKeyValueQualifier(keyName,
EOQualifier.QualifierOperatorEqual, value));
}
public static newentity
fetchRequirednewentity(EOEditingContext
editingContext, EOQualifier qualifier) {
newentity eoObject =
_newentity.fetchnewentity(editingContext,
qualifier);
if (eoObject == null) {
throw new NoSuchElementException("There was
no
NewEntity that matched the qualifier '" +
qualifier +
"'.");
}
return eoObject;
}
I have red x's for the fetchnewentity and
fetchRequiredNewEntity. I did not have these last
week. I wish I understood what was happening here
better... this is frustrating.
can someone shed light here. I am using postgresql
as
my backend...
Ted