1 56 57 package org.objectstyle.cayenne.dataview.dvmodeler; 58 59 import java.beans.*; 60 61 66 67 public class DVObject { 68 private String name; 69 transient protected PropertyChangeSupport propertyChangeListeners = new PropertyChangeSupport(this); 70 public String getName() { 71 return name; 72 } 73 public void setName(String name) { 74 String oldName = this.name; 75 this.name = name; 76 propertyChangeListeners.firePropertyChange("name", oldName, name); 77 } 78 public synchronized void removePropertyChangeListener(PropertyChangeListener l) { 79 propertyChangeListeners.removePropertyChangeListener(l); 80 } 81 public synchronized void addPropertyChangeListener(PropertyChangeListener l) { 82 propertyChangeListeners.addPropertyChangeListener(l); 83 } 84 } | Popular Tags |