随笔-124  评论-49  文章-56  trackbacks-0
set、list、array、map

Collection:
 private int id;
 private String name;
 private Set setValue;
 private List listValue;
 private String[] arrayValue;
 private Map mapValue;
<class name="Collection">
        
<id name="id">
            
<generator class="native"/>
        
</id>
        
<property name="name"/>
        
<set name="setValue" table="t_setvalue">
            
<key column="setid"/>
            
<element type="string" column="setvalue"/>
        
</set>
        
<list name="listValue" table="t_listvalue">
            
<key column="listid"/>
            
<list-index column="listindex"/>
            
<element type="string" column="listvalue"/>
        
</list>
        
<array name="arrayValue" table="t_arrayvalue">
            
<key column="arrayid"/>
            
<list-index column="arrayindex"/>
            
<element type="string" column="arrayvalue"/>
        
</array>
        
<map name="mapValue" table="t_mapvalue">
            
<key column="mapid"/>
            
<map-key type="string" column="mapkey"/>
            
<element type="string" column="mapvalue"/>
        
</map>
    
</class>
posted on 2009-11-03 16:17 junly 阅读(169) 评论(0)  编辑  收藏 所属分类: hibernate/orm

只有注册用户登录后才能发表评论。


网站导航: