| java.lang.Object com.jgoodies.binding.beans.Model com.jgoodies.binding.tutorial.Album
Album | public class Album extends Model (Code) | | Describes a musical Album and provides bound bean properties.
This class is used throughout the different tutorial examples.
This class has not been marked as final although it is not intended
to be subclassed. However some persistency frameworks (like Hibernate)
can optimize the data transfer and locking for extensible classes only.
author: Karsten Lentzsch version: $Revision: 1.8 $ |
Constructor Summary | |
public | Album() Constructs an empty Album: empty title and artist, not classical
and no composer set. |
Method Summary | |
public String | getArtist() Returns this album's artist, for example "Albert Ayler"
or "Berliner Philharmoniker". | public String | getComposer() Returns this album's composer - if any, for example "Richard Wagner". | public String | getTitle() Returns this album's title, for example "A Love Supreme",
or "Symphony No. | public boolean | isClassical() Answers whether this is a classical album or not. | public void | setArtist(String artist) Sets a new artist and notifies observers if the artist changed. | public void | setClassical(boolean classical) Sets this album's classical property and notifies observers
about changes. | public void | setComposer(String composer) Sets this album's composer and notifies observers if it has changed. | public void | setTitle(String title) Sets this album's title and notifies observers
if the title changed. | public String | toString() Returns a string representation of this album
that contains the property values in a single text line. | public String | toWrappedString() Returns a string representation of this album
that contains the property values. |
ALBUM1 | final public static Album ALBUM1(Code) | | An example Album.
|
ALBUM2 | final public static Album ALBUM2(Code) | | An example Album.
|
ALBUM3 | final public static Album ALBUM3(Code) | | An example Album.
|
ALBUM4 | final public static Album ALBUM4(Code) | | An example Album.
|
ALBUMS | final public static List<Album> ALBUMS(Code) | | A List of Albums made of the examples 1 to 4.
|
PROPERTYNAME_ARTIST | final public static String PROPERTYNAME_ARTIST(Code) | | |
PROPERTYNAME_CLASSICAL | final public static String PROPERTYNAME_CLASSICAL(Code) | | |
PROPERTYNAME_COMPOSER | final public static String PROPERTYNAME_COMPOSER(Code) | | |
PROPERTYNAME_TITLE | final public static String PROPERTYNAME_TITLE(Code) | | |
Album | public Album()(Code) | | Constructs an empty Album: empty title and artist, not classical
and no composer set.
|
getArtist | public String getArtist()(Code) | | Returns this album's artist, for example "Albert Ayler"
or "Berliner Philharmoniker".
this album's artist. |
getComposer | public String getComposer()(Code) | | Returns this album's composer - if any, for example "Richard Wagner".
A composer is available if and only if this is a classical album.
the composer of this album's music. See Also: Album.isClassical |
getTitle | public String getTitle()(Code) | | Returns this album's title, for example "A Love Supreme",
or "Symphony No. 5".
this album's title. |
isClassical | public boolean isClassical()(Code) | | Answers whether this is a classical album or not.
true if this album is classical, false if not |
setArtist | public void setArtist(String artist)(Code) | | Sets a new artist and notifies observers if the artist changed.
Parameters: artist - The artist to set. |
setClassical | public void setClassical(boolean classical)(Code) | | Sets this album's classical property and notifies observers
about changes. If not classical the composer is set to null .
Parameters: classical - true to indicate that this album is classical |
setComposer | public void setComposer(String composer)(Code) | | Sets this album's composer and notifies observers if it has changed.
A composer shall be set only if this is a classical album.
Parameters: composer - The composer to set. See Also: Album.isClassical |
setTitle | public void setTitle(String title)(Code) | | Sets this album's title and notifies observers
if the title changed.
Parameters: title - The title to set. |
toString | public String toString()(Code) | | Returns a string representation of this album
that contains the property values in a single text line.
a string representation of this album |
toWrappedString | public String toWrappedString()(Code) | | Returns a string representation of this album
that contains the property values.
a string representation of this album |
Methods inherited from com.jgoodies.binding.beans.Model | final public synchronized void addPropertyChangeListener(PropertyChangeListener listener)(Code)(Java Doc) final public synchronized void addPropertyChangeListener(String propertyName, PropertyChangeListener listener)(Code)(Java Doc) final public synchronized void addVetoableChangeListener(VetoableChangeListener listener)(Code)(Java Doc) final public synchronized void addVetoableChangeListener(String propertyName, VetoableChangeListener listener)(Code)(Java Doc) final protected boolean equals(Object o1, Object o2)(Code)(Java Doc) final protected void fireIndexedPropertyChange(String propertyName, int index, Object oldValue, Object newValue)(Code)(Java Doc) final protected void fireIndexedPropertyChange(String propertyName, int index, int oldValue, int newValue)(Code)(Java Doc) final protected void fireIndexedPropertyChange(String propertyName, int index, boolean oldValue, boolean newValue)(Code)(Java Doc) final protected void fireMultiplePropertiesChanged()(Code)(Java Doc) final protected void firePropertyChange(PropertyChangeEvent event)(Code)(Java Doc) final protected void firePropertyChange(String propertyName, Object oldValue, Object newValue)(Code)(Java Doc) final protected void firePropertyChange(String propertyName, Object oldValue, Object newValue, boolean checkIdentity)(Code)(Java Doc) final protected void firePropertyChange(String propertyName, boolean oldValue, boolean newValue)(Code)(Java Doc) final protected void firePropertyChange(String propertyName, double oldValue, double newValue)(Code)(Java Doc) final protected void firePropertyChange(String propertyName, float oldValue, float newValue)(Code)(Java Doc) final protected void firePropertyChange(String propertyName, int oldValue, int newValue)(Code)(Java Doc) final protected void firePropertyChange(String propertyName, long oldValue, long newValue)(Code)(Java Doc) final protected void fireVetoableChange(PropertyChangeEvent event) throws PropertyVetoException(Code)(Java Doc) final protected void fireVetoableChange(String propertyName, Object oldValue, Object newValue) throws PropertyVetoException(Code)(Java Doc) final protected void fireVetoableChange(String propertyName, boolean oldValue, boolean newValue) throws PropertyVetoException(Code)(Java Doc) final protected void fireVetoableChange(String propertyName, double oldValue, double newValue) throws PropertyVetoException(Code)(Java Doc) final protected void fireVetoableChange(String propertyName, int oldValue, int newValue) throws PropertyVetoException(Code)(Java Doc) final protected void fireVetoableChange(String propertyName, float oldValue, float newValue) throws PropertyVetoException(Code)(Java Doc) final protected void fireVetoableChange(String propertyName, long oldValue, long newValue) throws PropertyVetoException(Code)(Java Doc) final public synchronized PropertyChangeListener[] getPropertyChangeListeners()(Code)(Java Doc) final public synchronized PropertyChangeListener[] getPropertyChangeListeners(String propertyName)(Code)(Java Doc) final public synchronized VetoableChangeListener[] getVetoableChangeListeners()(Code)(Java Doc) final public synchronized VetoableChangeListener[] getVetoableChangeListeners(String propertyName)(Code)(Java Doc) final public synchronized void removePropertyChangeListener(PropertyChangeListener listener)(Code)(Java Doc) final public synchronized void removePropertyChangeListener(String propertyName, PropertyChangeListener listener)(Code)(Java Doc) final public synchronized void removeVetoableChangeListener(VetoableChangeListener listener)(Code)(Java Doc) final public synchronized void removeVetoableChangeListener(String propertyName, VetoableChangeListener listener)(Code)(Java Doc)
|
|
|