com.ibm.as400.util.html
Class HTMLMeta

java.lang.Object
  |
  +--com.ibm.as400.util.html.HTMLMeta

public class HTMLMeta
extends java.lang.Object
implements HTMLTagElement, java.io.Serializable

The HTMLMeta class represents meta-information used within an HTMLHead tag. This meta information can be used in identifying, indexing, and defining information within the HTML document.

This example creates an HTMLMeta tag:

  // Create an HTMLMeta.
  HTMLMeta meta = new HTMLMeta("Expires", "Mon, 01 Jun 2000 12:00:00 CST");
  System.out.println(header);
  

Here is the output of the HTMLMeta tag:

  <meta http-equiv="Expires" content="Mon, 01 Jun 2000 12:00:00 CST" />
  

HTMLMeta objects generate the following events:

See Also:
Serialized Form

Constructor Summary
HTMLMeta()
          Constructs a default HTMLMeta object.
HTMLMeta(java.lang.String HttpEquiv, java.lang.String content)
          Constructs an HTMLMeta object with the specified meta HTTP-EQUIV and content.
HTMLMeta(java.lang.String HttpEquiv, java.lang.String content, java.lang.String url)
          Constructs an HTMLMeta object with the specified meta HTTP-EQUIV, content, and URL.
 
Method Summary
 void addPropertyChangeListener(java.beans.PropertyChangeListener listener)
          Adds a PropertyChangeListener.
 void addVetoableChangeListener(java.beans.VetoableChangeListener listener)
          Adds the VetoableChangeListener.
 java.lang.String getContent()
          Returns the content of the HTMLMeta tag.
 java.lang.String getDirection()
          Returns the direction of the text interpretation.
 java.lang.String getHttpEquiv()
          Returns the HTTP-EQUIV of the meta tag.
 java.lang.String getLanguage()
          Returns the language of the meta tag.
 java.lang.String getName()
          Returns the name of the meta tag.
 java.lang.String getTag()
          Returns the tag for the HTML heading.
 java.lang.String getUrl()
          Returns the URL of the meta tag.
 void removePropertyChangeListener(java.beans.PropertyChangeListener listener)
          Removes the PropertyChangeListener.
 void removeVetoableChangeListener(java.beans.VetoableChangeListener listener)
          Removes the VetoableChangeListener.
 void setContent(java.lang.String content)
          Sets the content of the meta information.
 void setDirection(java.lang.String dir)
          Sets the direction of the text interpretation.
 void setHttpEquiv(java.lang.String HttpEquiv)
          Sets the HTTP-EQUIV of the meta tag.
 void setLanguage(java.lang.String lang)
          Sets the language of the meta tag.
 void setName(java.lang.String name)
          Sets the name of the meta tag.
 void setUrl(java.lang.String url)
          Sets the URL to reload after the time specified in the content attribute.
 java.lang.String toString()
          Returns a String representation for the HTMLMeta tag.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

HTMLMeta

public HTMLMeta()
Constructs a default HTMLMeta object.

HTMLMeta

public HTMLMeta(java.lang.String HttpEquiv,
                java.lang.String content)
Constructs an HTMLMeta object with the specified meta HTTP-EQUIV and content.
Parameters:
HttpEquiv - The HTTP-EQUIV meta information.
content - The value of a named property.

HTMLMeta

public HTMLMeta(java.lang.String HttpEquiv,
                java.lang.String content,
                java.lang.String url)
Constructs an HTMLMeta object with the specified meta HTTP-EQUIV, content, and URL.
Parameters:
HttpEquiv - The HTTP-EQUIV meta information.
content - The value of a named property.
url - The URL to reload after the time specified in the content attribute.
Method Detail

addPropertyChangeListener

public void addPropertyChangeListener(java.beans.PropertyChangeListener listener)
Adds a PropertyChangeListener. The specified PropertyChangeListener's propertyChange method will be called each time the value of any bound property is changed.
Parameters:
listener - The PropertyChangeListener.
See Also:
removePropertyChangeListener(java.beans.PropertyChangeListener)

addVetoableChangeListener

public void addVetoableChangeListener(java.beans.VetoableChangeListener listener)
Adds the VetoableChangeListener. The specified VetoableChangeListener's vetoableChange method will be called each time the value of any constrained property is changed.
Parameters:
listener - The VetoableChangeListener.
See Also:
removeVetoableChangeListener(java.beans.VetoableChangeListener)

getContent

public java.lang.String getContent()
Returns the content of the HTMLMeta tag.
Returns:
The value of a named property.

getDirection

public java.lang.String getDirection()
Returns the direction of the text interpretation.
Returns:
The direction of the text.

getHttpEquiv

public java.lang.String getHttpEquiv()
Returns the HTTP-EQUIV of the meta tag.
Returns:
The HTTP-EQUIV meta information.

getLanguage

public java.lang.String getLanguage()
Returns the language of the meta tag.
Returns:
The language of the meta tag.

getName

public java.lang.String getName()
Returns the name of the meta tag.
Returns:
The name of a property.

getUrl

public java.lang.String getUrl()
Returns the URL of the meta tag.
Returns:
The URL to reload.

getTag

public java.lang.String getTag()
Returns the tag for the HTML heading.
Specified by:
getTag in interface HTMLTagElement
Returns:
The tag.

removePropertyChangeListener

public void removePropertyChangeListener(java.beans.PropertyChangeListener listener)
Removes the PropertyChangeListener. If the PropertyChangeListener is not on the list, nothing is done.
Parameters:
listener - The PropertyChangeListener.
See Also:
addPropertyChangeListener(java.beans.PropertyChangeListener)

removeVetoableChangeListener

public void removeVetoableChangeListener(java.beans.VetoableChangeListener listener)
Removes the VetoableChangeListener. If the VetoableChangeListener is not on the list, nothing is done.
Parameters:
listener - The VetoableChangeListener.
See Also:
addVetoableChangeListener(java.beans.VetoableChangeListener)

setContent

public void setContent(java.lang.String content)
                throws java.beans.PropertyVetoException
Sets the content of the meta information.
Parameters:
content - The value for a named property.
Throws:
java.beans.PropertyVetoException - If a change is vetoed.

setDirection

public void setDirection(java.lang.String dir)
                  throws java.beans.PropertyVetoException
Sets the direction of the text interpretation.
Parameters:
dir - The direction. One of the following constants defined in HTMLConstants: LTR or RTL.
Throws:
java.beans.PropertyVetoException - If a change is vetoed.
See Also:
HTMLConstants

setHttpEquiv

public void setHttpEquiv(java.lang.String HttpEquiv)
                  throws java.beans.PropertyVetoException
Sets the HTTP-EQUIV of the meta tag.
Parameters:
HttpEquiv - The HTTP-EQUIV meta information.
Throws:
java.beans.PropertyVetoException - If a change is vetoed.

setLanguage

public void setLanguage(java.lang.String lang)
                 throws java.beans.PropertyVetoException
Sets the language of the meta tag.
Parameters:
lang - The language. Example language tags include: en and en-US.
Throws:
java.beans.PropertyVetoException - If a change is vetoed.

setName

public void setName(java.lang.String name)
             throws java.beans.PropertyVetoException
Sets the name of the meta tag. If the name is not set, it is assumed to be the same as the value of the HTTP-EQUIV.
Parameters:
name - The name of a property.
Throws:
java.beans.PropertyVetoException - If a change is vetoed.

setUrl

public void setUrl(java.lang.String url)
            throws java.beans.PropertyVetoException
Sets the URL to reload after the time specified in the content attribute.
Parameters:
url - The URL to reload.
Throws:
java.beans.PropertyVetoException - If a change is vetoed.

toString

public java.lang.String toString()
Returns a String representation for the HTMLMeta tag.
Overrides:
toString in class java.lang.Object
Returns:
The tag.