Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| HTML Parser Home Page
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.htmlparser.tags
Class ScriptTag

    java.lang.Object
      org.htmlparser.AbstractNode
          org.htmlparser.lexer.nodes.TagNode
              org.htmlparser.tags.Tag
                  org.htmlparser.tags.CompositeTag
                      org.htmlparser.tags.ScriptTag

All Implemented Interfaces:
  Cloneable, Node, Serializable

public class ScriptTag
extends CompositeTag

A script tag.

See Also:
  Serialized Form

Field Summary
`protected String` | `mCode` Script code if different from the page contents.

Fields inherited from class org.htmlparser.tags.CompositeTag
`mDefaultScanner, mEndTag`

Fields inherited from class org.htmlparser.lexer.nodes.TagNode
`breakTags, mAttributes`

Fields inherited from class org.htmlparser.AbstractNode
`children, mPage, nodeBegin, nodeEnd, parent`

Constructor Summary
`ScriptTag()` Create a new script tag.

Method Summary
`String[]` | `getEndTagEnders()` Return the set of end tag names that cause this tag to finish.
`String[]` | `getIds()` Return the set of names handled by this tag.
`String` | `getLanguage()` Get the language attribute value.
`String` | `getScriptCode()` Get the script code.
`String` | `getType()` Get the type attribute value.
`protected void` | `putChildrenInto(StringBuffer sb)`
`void` | `setLanguage(String language)` Set the language of the script tag.
`void` | `setScriptCode(String code)` Set the code contents.
`void` | `setType(String type)` Set the type of the script tag.
`String` | `toString()` Print the contents of the script tag.

Methods inherited from class org.htmlparser.tags.CompositeTag
`accept, childAt, children, collectInto, digupStringNode, elements, findPositionOf, findPositionOf, findPositionOf, getChild, getChildCount, getChildrenAsNodeArray, getChildrenHTML, getEndTag, getStartTag, getStringText, getText, putEndTagInto, removeChild, searchByName, searchFor, searchFor, searchFor, searchFor, setEndTag, setStartTag, toHtml, toPlainTextString, toString`

Methods inherited from class org.htmlparser.tags.Tag
`accept, clone, getEnders, getThisScanner, setThisScanner`

Methods inherited from class org.htmlparser.lexer.nodes.TagNode
`breaksFlow, getAttribute, getAttributeEx, getAttributes, getAttributesEx, getEndingLineNumber, getParameter, getParsed, getRawTagName, getStartingLineNumber, getTagBegin, getTagEnd, getTagName, isEmptyXmlTag, isEndTag, removeAttribute, setAttribute, setAttribute, setAttribute, setAttributes, setAttributesEx, setEmptyXmlTag, setTagBegin, setTagEnd, setTagName, setText`

Methods inherited from class org.htmlparser.AbstractNode
`doSemanticAction, elementBegin, elementEnd, getChildren, getEndPosition, getPage, getParent, getStartPosition, setChildren, setEndPosition, setPage, setParent, setStartPosition, toHTML`

Methods inherited from class java.lang.Object
`equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Field Detail

### mCode

    protected String mCode

  Script code if different from the page contents.

Constructor Detail

### ScriptTag

    public ScriptTag()

  Create a new script tag.

Method Detail

### getIds

    public String[] getIds()

  Return the set of names handled by this tag.

  Overrides:
    `getIds` in class `Tag`
  Returns:
    The names to be matched that create tags of this type.

### getEndTagEnders

    public String[] getEndTagEnders()

  Return the set of end tag names that cause this tag to finish.

  Overrides:
    `getEndTagEnders` in class `Tag`
  Returns:
    The names of following end tags that stop further scanning.

### getLanguage

    public String getLanguage()

  Get the language attribute value.

### getScriptCode

    public String getScriptCode()

  Get the script code. Normally this is the contents of the children, but in the rare case that the script is encoded, this is the plaintext decrypted code.

  Returns:
    The plaintext or overridden code contents of the tag.

### setScriptCode

    public void setScriptCode(String code)

  Set the code contents.

  Parameters:
    `code` - The new code contents of this tag.

### getType

    public String getType()

  Get the type attribute value.

### setLanguage

    public void setLanguage(String language)

  Set the language of the script tag.

  Parameters:
    `language` - The new language value.

### setType

    public void setType(String type)

  Set the type of the script tag.

  Parameters:
    `type` - The new type value.

### putChildrenInto

    protected void putChildrenInto(StringBuffer sb)

  Overrides:
    `putChildrenInto` in class `CompositeTag`

### toString

    public String toString()

  Print the contents of the script tag.

  Specified by:
    `toString` in interface `Node`
  Overrides:
    `toString` in class `CompositeTag`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| © 2004 Somik Raha Mar 14, 2004
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

HTML Parser is an open source library released under LGPL.