org.htmlparser.beans

Class HTMLLinkBean

Implemented Interfaces:
PropertyChangeListener, Serializable

public class HTMLLinkBean
extends JList
implements Serializable, PropertyChangeListener

Display the links from a URL.
Author:
Derrick Oswald Created on December 24, 2002, 3:49 PM

Field Summary

protected LinkBean
mBean
The underlying bean that provides our htmlparser specific properties.

Constructor Summary

HTMLLinkBean()
Creates a new HTMLTextBean.

Method Summary

void
addPropertyChangeListener(PropertyChangeListener listener)
Add a PropertyChangeListener to the listener list.
protected LinkBean
getBean()
Return the underlying bean object.
URLConnection
getConnection()
Getter for property Connection.
URL[]
getLinks()
Getter for property links.
Dimension
getMinimumSize()
Return the minimum dimension for this visible bean.
String
getURL()
Getter for property URL.
void
propertyChange(PropertyChangeEvent event)
Responds to changes in the underlying bean's properties.
void
removePropertyChangeListener(PropertyChangeListener listener)
Remove a PropertyChangeListener from the listener list.
void
setConnection(URLConnection connection)
Setter for property Connection.
void
setURL(String url)
Setter for property URL.

Field Details

mBean

protected LinkBean mBean
The underlying bean that provides our htmlparser specific properties.

Constructor Details

HTMLLinkBean

public HTMLLinkBean()
Creates a new HTMLTextBean. This uses an underlying StringBean and displays the text.

Method Details

addPropertyChangeListener

public void addPropertyChangeListener(PropertyChangeListener listener)
Add a PropertyChangeListener to the listener list. The listener is registered for all properties.

Delegates to the underlying StringBean

Parameters:
listener - The PropertyChangeListener to be added.

getBean

protected LinkBean getBean()
Return the underlying bean object. Creates a new one if it hasn't been initialized yet.
Returns:
The StringBean this bean uses to fetch text.

getConnection

public URLConnection getConnection()
Getter for property Connection.
Returns:
Value of property Connection.

getLinks

public URL[] getLinks()
Getter for property links.

Delegates to the underlying StringBean

Returns:
Value of property links.

getMinimumSize

public Dimension getMinimumSize()
Return the minimum dimension for this visible bean.
Returns:
a minimum bounding box for this bean.

getURL

public String getURL()
Getter for property URL.

Delegates to the underlying StringBean

Returns:
Value of property URL.

propertyChange

public void propertyChange(PropertyChangeEvent event)
Responds to changes in the underlying bean's properties.
Parameters:
event - The event triggering this listener method call.

removePropertyChangeListener

public void removePropertyChangeListener(PropertyChangeListener listener)
Remove a PropertyChangeListener from the listener list. This removes a registered PropertyChangeListener.

Delegates to the underlying StringBean

Parameters:
listener - The PropertyChangeListener to be removed.

setConnection

public void setConnection(URLConnection connection)
Setter for property Connection.
Parameters:
connection - New value of property Connection.

setURL

public void setURL(String url)
Setter for property URL.

Delegates to the underlying StringBean

Parameters:
url - New value of property URL.

HTML Parser is an open source library released under LGPL. SourceForge.net