You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user-cs@ibatis.apache.org by Phillip S <to...@hotmail.com> on 2007/08/27 15:46:35 UTC

inheritance issue

Team,
 
I am using the "extends" property to extend a class to another class in another file.   No matter what I try I get "can no resolve extends attribute."  Anyone have an example or must I put them all in the same file?
 
Thanks
_________________________________________________________________
Learn. Laugh. Share. Reallivemoms is right place!
http://www.reallivemoms.com?ocid=TXT_TAGHM&loc=us

Current Status

Posted by Sal Bass <sa...@hotmail.com>.
The website has been quiet for awhile. Is there a new release for Ibatis.Net scheduled soon? v3?

 

Thanks!

_________________________________________________________________
HotmailĀ® is up to 70% faster. Now good news travels really fast.
http://windowslive.com/online/hotmail?ocid=TXT_TAGLM_WL_HM_70faster_032009

Re: inheritance issue

Posted by Michael Schall <mi...@gmail.com>.
The original poster said he had them in alpha order, but moved them to
inheritance order to fix the problem...

They are loaded in the order you specify them in your sqlmap.config file.
 Anything that is being extended needs to be defined before what is
extending it.  If you are using namespaces, be sure to include that in your
extends as well.

On Tue, Mar 17, 2009 at 11:24 AM, sebastian_r
<se...@aim-sw.com>wrote:

>
> Hi!
>
> I am having the same problem as described in this post! Recently I renamed
> some classes and mapping files while refactoring some code and afterwards I
> got the error:
>
> [...]
> - The error occurred while loading SqlMap.
> ...
> - Check the 'xxx' ---> IBatisNet.Common.Exceptions.ConfigurationException:
> In mapping file 'xxx' the resultMap 'xxx' can not resolve extends attribute
> 'xxx'
> [...]
>
> So is it a fact, that the mapping files are loaded in alphabetical
> order?!?!?!? I would be suprised if that is true!
>
> I don't want to believe that I will be forced as to what to name my mapping
> files in order for them to work!
>
> So how did you solve the inheritance problem when extending resultmaps?
> Just
> name the files ABasicMap, BFirstExtendingMap,
> CAnotherMappingFileUsingTheSecondFile? That's not really an elegant naming
> policy!
>
> Thanks for your help!
>
> Yours,
>
> Sebastian
> --
> View this message in context:
> http://www.nabble.com/inheritance-issue-tp12347249p22562984.html
> Sent from the iBATIS - User - Cs mailing list archive at Nabble.com.
>
>

Re: inheritance issue

Posted by sebastian_r <se...@aim-sw.com>.
Hi!

I am having the same problem as described in this post! Recently I renamed
some classes and mapping files while refactoring some code and afterwards I
got the error:

[...]
- The error occurred while loading SqlMap.
...
- Check the 'xxx' ---> IBatisNet.Common.Exceptions.ConfigurationException:
In mapping file 'xxx' the resultMap 'xxx' can not resolve extends attribute
'xxx'
[...]

So is it a fact, that the mapping files are loaded in alphabetical
order?!?!?!? I would be suprised if that is true! 

I don't want to believe that I will be forced as to what to name my mapping
files in order for them to work!

So how did you solve the inheritance problem when extending resultmaps? Just
name the files ABasicMap, BFirstExtendingMap,
CAnotherMappingFileUsingTheSecondFile? That's not really an elegant naming
policy!

Thanks for your help!

Yours,

Sebastian
-- 
View this message in context: http://www.nabble.com/inheritance-issue-tp12347249p22562984.html
Sent from the iBATIS - User - Cs mailing list archive at Nabble.com.


RE: inheritance issue

Posted by Kamiel Wanrooij <K....@everywebsolutions.nl>.
Hi,

 

I was having similar issues, although I am not sure if it is the same
situation. My experience is that it is difficult, if not impossible, to
extend result maps from within other files. Either way, make sure to
include the base resultmap first, and then the referencing result map.

 

Regards,

 

Kamiel 

 

From: Phillip S [mailto:todextreme@hotmail.com] 
Sent: Monday, August 27, 2007 3:47 PM
To: user-cs@ibatis.apache.org
Subject: inheritance issue

 

Team,
 
I am using the "extends" property to extend a class to another class in
another file.   No matter what I try I get "can no resolve extends
attribute."  Anyone have an example or must I put them all in the same
file?
 
Thanks

________________________________

New home for Mom, no cleanup required. All starts here.
<http://www.reallivemoms.com?ocid=TXT_TAGHM&loc=us>