ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Guy Rouillier <guyr-...@burntmail.com>
Subject Re: association objects instantiated to null after call
Date Mon, 29 Mar 2010 16:36:45 GMT
Sorry, this description is much too vague to be able to offer any useful 
advice.  What version of iBATIS are you using?  You would need to show 
the result map from the initial getAllObjects() and the subsequent 
getSomeValue().

What is the value of "hash" being passed into getSomeValue()?  In order 
for a field in MyObject to be set to null (if I'm understanding what you 
are saying), the result map for getSomeValue() would have to be pointed 
at either that field directly or the parent MyObject.

On 3/29/2010 4:59 AM, foeke99 wrote:
>
> I have this strange problem which i can't get to solve
> I have an arraylist of objects and each object has several child objects
> which are perfectly loaded with the config file.
>
>
> ArrayList<MyObject>  objects = _testMapper.getAllObjects();
>
> at one point i have to split these into 2 arraylists based on a flag
> variable in each object
>
> then i pass these arraylists through the next stage
>
> But in the last stage of my program when i want to make a minor call to
> retrieve a value from within the same mapper file the child objects of each
> object in my arraylist is instantiated to null
>
> So when i debug i can see that before the call everything is fine and after
> the call
>
> int value =_testMapper.getSomeValue(hash);
>
> the child objects are instantiated to null !
>
> if i don't make a call from _testMapper everything runs fine.
>
> Has anyone experienced the same problem or is there something i've done
> wrong ?
>
>
> greetz
>
>
>
>


-- 
Guy Rouillier

---------------------------------------------------------------------
To unsubscribe, e-mail: user-java-unsubscribe@ibatis.apache.org
For additional commands, e-mail: user-java-help@ibatis.apache.org


Mime
View raw message