Ejemplo n.º 1
0
        public PropertyChangeListener[] getPropertyChangeListeners(
            String propertyName)
        {
            lock (this){
                PropertyChangeSupport listeners = null;

                if (propertyName != null)
                {
                    listeners = children.get(propertyName);
                }

                return((listeners == null) ? new PropertyChangeListener[0]
                : listeners.getPropertyChangeListeners());
            }
        }
Ejemplo n.º 2
0
 public PropertyChangeListener[] getPropertyChangeListeners()
 {
     lock (this){}
     java.util.ArrayList <PropertyChangeListener> result = new java.util.ArrayList <PropertyChangeListener>(
         globalListeners);
     java.util.Iterator <String> it = children.keySet().iterator();
     while (it.hasNext())
     {
         String propertyName = it.next();
         PropertyChangeSupport namedListener = children
                                               .get(propertyName);
         PropertyChangeListener[] listeners = namedListener
                                              .getPropertyChangeListeners();
         for (int i = 0; i < listeners.Length; i++)
         {
             result.add(new PropertyChangeListenerProxy(propertyName,
                                                        listeners[i]));
         }
     }
     return(result.toArray(new PropertyChangeListener[0]));
 }