Is it possible to marshall an Object , such that the resulting XML output shows only the attributes of an associated Object.
This example would make clear what I really want

class A
{
        public  String fieldA1;
        public String fieldA2;

        public class B;        
}

class B
{
        public  String fieldB1;
        public String fieldB2;
}

I want to write a Mapper which wud create the following XML output
when I marshall an Object of class A

<A
        fieldA1= "abc"
        fieldA2= "def"

        fieldB1= "xyz">
</A>

Is this possible , I don't want to map the associated class B as an element during marshalling.


Thanks,
Navin

Reply via email to