org.apache.ecs
Interface Element

All Superinterfaces:
ElementRegistry
All Known Implementing Classes:
GenericElement

public interface Element
extends ElementRegistry

This class describes an ElementFactory.

Version:
$Id: Element.java,v 1.4 2003/04/27 09:43:24 rdonkin Exp $
Author:
Stephan Nagy, Jon S. Stevens

Field Summary
static int CENTER
          Element tag to be rendered to the center of start_tag end_tag <_tag>
This is the default.
static int LEFT
          Element tag to be rendered to the left of start_tag end_tag _tag<>
static int LOWERCASE
          Element to be rendered in all lowercase
static int MIXEDCASE
          Element to be rendered as specified by subclass
static int RIGHT
          Element tag to be rendered to the right of start_tag end_tag <>_tag
static int UPPERCASE
          Element to be rendered in all CAPS
 
Method Summary
 char getBeginEndModifier()
          Get the modifier for the end of the tag if one exists.
 char getBeginStartModifier()
          Get a modifier for the start of the tag if one exists.
 int getCase()
          Used to determine case setting
 java.lang.String getElementType()
          Get the HtmlElement type
 char getEndEndModifier()
          Get the modifier for the end of the tag if one exists.
 char getEndStartModifier()
          Get a modifier for the start of the tag if one exists.
 char getEndTagChar()
          Get the end tag character.
 boolean getFilterState()
          Get the filter state of the element.
 boolean getNeedClosingTag()
          Get whether or not this Element needs a closing tag
 boolean getNeedLineBreak()
          Determine if this element needs a line break, if pretty printing.
 boolean getPrettyPrint()
          Get the prettyPrint state of the element.
 char getStartTagChar()
          Get the start tag character.
 int getTabLevel()
          Get the tab level for pretty printing.
 int getTagPosition()
          Get tag position.
 java.lang.String getVersion()
          Get the version number of this codebase
 void output(java.io.OutputStream out)
          Provide a way to output the element to a stream.
 void output(java.io.PrintWriter out)
          Provide a way to output the element to a PrintWriter.
 Element setBeginEndModifier(char start_modifier)
          Set a modifer for the end of the tag.
 Element setBeginStartModifier(char start_modifier)
           
 void setCase(int type)
          Set case type
 void setElementType(java.lang.String element_type)
          Set the HtmlElement type
 Element setEndEndModifier(char start_modifier)
          Set a modifer for the end of the tag.
 Element setEndStartModifier(char start_modifier)
           
 void setEndTagChar(char end_tag)
          Set the end tag character.
 Element setFilterState(boolean state)
          Set the filter state of the element.
 void setNeedClosingTag(boolean close_tag)
          Set wether or not this Element needs a closing tag
 Element setPrettyPrint(boolean pretty_print)
          Set the prettyPrint state of the element.
 void setStartTagChar(char start_tag)
          Set the start tag character.
 void setTabLevel(int tabLevel)
          Set the tab level for pretty printing
 void setTagPosition(int position)
          Set tag position.
 
Methods inherited from interface org.apache.ecs.ElementRegistry
addElementToRegistry, addElementToRegistry, registryHasElement, registryHasElement, removeElementFromRegistry, removeElementFromRegistry
 

Field Detail

UPPERCASE

public static final int UPPERCASE
Element to be rendered in all CAPS

LOWERCASE

public static final int LOWERCASE
Element to be rendered in all lowercase

MIXEDCASE

public static final int MIXEDCASE
Element to be rendered as specified by subclass

CENTER

public static final int CENTER
Element tag to be rendered to the center of start_tag end_tag <_tag>
This is the default.

LEFT

public static final int LEFT
Element tag to be rendered to the left of start_tag end_tag _tag<>

RIGHT

public static final int RIGHT
Element tag to be rendered to the right of start_tag end_tag <>_tag
Method Detail

setCase

public void setCase(int type)
Set case type

getCase

public int getCase()
Used to determine case setting

getVersion

public java.lang.String getVersion()
Get the version number of this codebase

setElementType

public void setElementType(java.lang.String element_type)
Set the HtmlElement type

getElementType

public java.lang.String getElementType()
Get the HtmlElement type

setNeedClosingTag

public void setNeedClosingTag(boolean close_tag)
Set wether or not this Element needs a closing tag

getNeedClosingTag

public boolean getNeedClosingTag()
Get whether or not this Element needs a closing tag

getNeedLineBreak

public boolean getNeedLineBreak()
Determine if this element needs a line break, if pretty printing.

setTagPosition

public void setTagPosition(int position)
Set tag position. ElementFactory CENTER | LEFT | RIGHT

getTagPosition

public int getTagPosition()
Get tag position. How is the element supposed to be rendered.

setStartTagChar

public void setStartTagChar(char start_tag)
Set the start tag character.

getStartTagChar

public char getStartTagChar()
Get the start tag character.

setEndTagChar

public void setEndTagChar(char end_tag)
Set the end tag character.

getEndTagChar

public char getEndTagChar()
Get the end tag character.

setBeginStartModifier

public Element setBeginStartModifier(char start_modifier)

getBeginStartModifier

public char getBeginStartModifier()
Get a modifier for the start of the tag if one exists.

setBeginEndModifier

public Element setBeginEndModifier(char start_modifier)
Set a modifer for the end of the tag.

getBeginEndModifier

public char getBeginEndModifier()
Get the modifier for the end of the tag if one exists.

setEndStartModifier

public Element setEndStartModifier(char start_modifier)

getEndStartModifier

public char getEndStartModifier()
Get a modifier for the start of the tag if one exists.

setEndEndModifier

public Element setEndEndModifier(char start_modifier)
Set a modifer for the end of the tag.

getEndEndModifier

public char getEndEndModifier()
Get the modifier for the end of the tag if one exists.

setFilterState

public Element setFilterState(boolean state)
Set the filter state of the element.

getFilterState

public boolean getFilterState()
Get the filter state of the element.

setPrettyPrint

public Element setPrettyPrint(boolean pretty_print)
Set the prettyPrint state of the element.

getPrettyPrint

public boolean getPrettyPrint()
Get the prettyPrint state of the element.

setTabLevel

public void setTabLevel(int tabLevel)
Set the tab level for pretty printing

getTabLevel

public int getTabLevel()
Get the tab level for pretty printing.

output

public void output(java.io.OutputStream out)
Provide a way to output the element to a stream.

output

public void output(java.io.PrintWriter out)
Provide a way to output the element to a PrintWriter.


Copyright © 1999-2003 Apache Software Foundation. All Rights Reserved.