Hi all,

I created a hierachy of classes like catalogues which contains list of
catalogue ,under catalogue list of category like that.
    public class catalogues(
Ex:protected List<Catalogue> catalogues ;
   )
   

public class Catalogue {


        private String name;

    @XStreamImplicit
        protected List<Category> catalogue;

        public Catalogue() {
                catalogue = new ArrayList<Category>();
        }
)


The resulting xml im getting contains duplicate tags ..


<?xml version="1.0" ?>
<catalogues>
        <catalogue>
                <name>Products</name>
                <catalogue>
                        <category>
                                <categoryName>CategoryOne</categoryName>
                                <category>
                                        <subcategory>
                                                
<subcategoryname>CategoryOneSubOne</subcategoryname>
                                                <subcategory>
                                                        <product>
                                                                <id>1</id>
                                                                
<name>product1</name>
                                                                
<description>for external use only</description>
                                                        </product>
                                                        <product>
                                                                <id>2</id>
                                                                
<name>product2</name>
                                                                <description>as 
prescribed by the medical pracitioner
                                                                </description>
                                                        </product>
                                                </subcategory>
                                        </subcategory>
                                        <subcategory>
                                                
<subcategoryname>CategoryOneSubTwo</subcategoryname>
                                                <subcategory>
                                                        <product>
                                                                <id>3</id>
                                                                
<name>ffcc</name>
                                                                
<description>uuu</description>
                                                        </product>
                                                </subcategory>
                                        </subcategory>
                                </category>
                        </category>
                </catalogue>
        </catalogue>
</catalogues>


Do u how to get rid off this.
-- 
View this message in context: 
http://old.nabble.com/get-rid-of-class%3D%22list%22-for-more-than-one-contained-List-interface-fields-tp33768643p34275122.html
Sent from the xstream - user mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to