commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Marcos Hass W" <>
Subject .betwix file assigned to a JDK class
Date Fri, 15 Sep 2006 20:12:13 GMT
Hi all,

I have a class that extends
java.beans.beancontext.BeanContextChildSupportits name is
AbstractBean, below a snippet.:

/** <tt>JavaBean</tt> base responsável pelos mecanismos de notificação de
 * de propriedades e clonagem. A extensão a partir de
 * permite que o bean seja posicionado dentro de um <tt>BeanContext</tt> e
 * apto a questionar propriedades existentes em outros beans presentes
também no
 * contexto.
 * @author marcos
public abstract class AbstractBean extends BeanContextChildSupport
        implements Cloneable, Comparable, Serializable {

    /** Delegate <tt>PropertyChangeSupport</tt> responsável pela notificação
     * listeners atentos às alterações nas propriedades do
     * @see <a href="">
    protected transient PropertyChangeSupport changes = new

    /** Delegate a <tt>VetoableChangeSupport</tt> responsável pela
     * dos <tt>VetoableChangeListeners</tt> que irão escutar os valores
     * e irão <tt>vetar</tt> ou não a alteração.
    protected transient VetoableChangeSupport vetoable = new

    /** Constructor de <code>AbstractBean</code>.*/
    public AbstractBean() {

        beanContextChildPeer = this;

        pcSupport = new PropertyChangeSupport(beanContextChildPeer);
        vcSupport = new VetoableChangeSupport(beanContextChildPeer);

    public AbstractBean(BeanContextChild bcc) {

        beanContextChildPeer = (bcc != null) ? bcc : this;

        pcSupport = new PropertyChangeSupport(beanContextChildPeer);
        vcSupport = new VetoableChangeSupport(beanContextChildPeer);



I have several bean classes that extend AbstractBean and any time I try to
submit these extended classes to BeanWriter I get a CyclicReferenceException
I've discovered that BeanContextChildSupport has some fields that produce
this cyclic problem and for this reason I've associated a
AbstractBean.betwixt file to the AbstractBean class as follows:

<?xml version='1.0' encoding='UTF-8' ?>
<info primitiveTypes='attribute'>

    <element name='abstractbean'>
        <hide property='beanContext'/>
        <hide property='beanContextChildPeer'/>
        <hide property='pcSupport'/>
        <hide property='rejectedSetBCOnce'/>
        <hide property='vcSupport'/>
        <hide property='changes'/>
        <hide property='vetoable'/>



The problem is that I'm still getting the cyclic problem ;-(
Does someone know what's wrong ?
How do I associate a .betwixt file with the
java.beans.beancontext.BeanContextChildSupport class ?

Thank you very much

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message