Hello,
I am using iBatis to select data from db and after serialize it to xml using
xStream. During serialization I am getting unnecessary stuff
public class Office{
private String name;
private Employee employee;
..
getters/setters
...
}
public class Employee {
private List<Group> groups;
..
getters/setters
...
}
public class Group{
private String x1;
private String x2;
private String x3;
}
............Mappings...............
<resultMap id="office"
class="domain.Office">
<result property="name" column="NAME" />
<result property="employee" resultMap="nm.employee" />
</resultMap>
<resultMap id="employee"
class="domain.Employee">
<result property="groups" column="group_id" select="getGroups" />
</resultMap>
<resultMap id="group"
class="domain.Group">
<result ...
</resultMap>
<select id="getGroups" parameterClass="int"
resultMap="nm.group">
SELECT * from group where group_id=#gId#
</select>
.........
When I am trying to serialize whole office object I am getting lot of proxy
information into my xml.
I am new in ibatis, but I am sure there will be way to remove proxy from
object..
Can someone please help?
--
View this message in context:
http://www.nabble.com/iBatis%2BxStream-tp22711384p22711384.html
Sent from the iBATIS - User - Java mailing list archive at Nabble.com.