Betwixt suppresing a property

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Betwixt suppresing a property

Demetrio Cruz
Hi.

Sorry I have a problem, I have a bean which I want to write with the
BeanWriter of betwixt, the bean is something like

public class Container{

        private List elements;

        public List getElements(){
                return elements;
        }

        public List
        getTrashElements(){
            return ...
        }

        public List
        getRadioactiveElements(){
            return ...
        }
     
        public void
        addTrashElement(Element e){
             elements.add(e);
        }


        public void
        addRadioactiveElement(Element e){
             elements.add(e);
        }
}

The problem here is that when I generate the xml, it writes the trash and
radioactive elements in its own tags, but it repeats all of the
encapsulated in a elements tag

<container>
   <trashelements>
       <trashelement>...</trashelement>
   </trashelements>
   <radioactiveelements>
       <radioactiveelement>...</radioactiveelement>
   </radioactiveelements>
<!-- this is the part wich is repeated from above -->
   <elements>
       <trashelement>...</trashelement>
       <radioactiveelement>...</radioactiveelement>
   </elements>
<!-- end of the repeated zone -->
</container>

is there any way via Container.betwixt file to tell betwixt to omit the
getElements() method to be printed in the output ??



--

"That language is an instrument of human reason, and not merely a medium for
the expression of thought, is a truth generally admitted."

- George Boole, quoted in Iverson's Turing Award Lecture




---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]