org.wurbelizer
Class SourceWurbletSubElement

java.lang.Object
  extended by org.wurbelizer.SourceSubElement
      extended by org.wurbelizer.SourceWurbletSubElement

public class SourceWurbletSubElement
extends SourceSubElement

Wurblet anchor within a SourceElement. A wurblet anchor is of the form:

 @wurblet[(wurbler-args...)]   [wurblet-args ...]
 
The optional wurbler args must be enclosed in parantheses and are directives for the container that executes the wurblets. The guardname is mandatory and must be unique within the source file, except if an inline wurblet (-,+,<,>). The wurbletname is the classname of the wurblet and may be given either as an absolute classname (containing dots) or a relative name which the wurbler will expand according to some given wurblet path. The optional wurblet arguments are passed through the ArgScanner.


Constructor Summary
SourceWurbletSubElement(SourceElement element, String text)
          Creates a sub element.
 
Method Summary
 String[] getWurblerArgs()
          Gets the wurbler (wurblet container) args.
 String[] getWurbletArgs()
          Gets the wurblet args.
 String getWurbletName()
          Gets the name of the wurblet.
 boolean isInline()
          Checks if this is an inline wurblet.
 boolean isInlineNextBlock()
          Checks whether this is an inline wurblet related the next code block.
 boolean isInlinePreviousBlock()
          Checks whether this is an inline wurblet related the previous code block.
 void setWurblerArgs(String[] wurblerArgs)
          Sets the wurbler (wurblet container) args
 void setWurbletArgs(String[] wurbletArgs)
          Sets the wurblet args.
 void setWurbletName(String wurbletName)
          Sets the name of the wurblet.
 String toString()
          Prints the name of the subelement/element/document.
 
Methods inherited from class org.wurbelizer.SourceSubElement
getElement, getName, getText, setName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SourceWurbletSubElement

public SourceWurbletSubElement(SourceElement element,
                               String text)
                        throws SourceException
Creates a sub element.

Parameters:
element - the SourceElement containing the sub element.
text - the contents of the sub element
Throws:
SourceException - if creation failed
Method Detail

isInlinePreviousBlock

public boolean isInlinePreviousBlock()
Checks whether this is an inline wurblet related the previous code block.

Returns:
true if inline wurblet for the previous block

isInlineNextBlock

public boolean isInlineNextBlock()
Checks whether this is an inline wurblet related the next code block.

Returns:
true if inline wurblet for the next block

isInline

public boolean isInline()
Checks if this is an inline wurblet.

Returns:
true if this is an inline wurblet

getWurbletName

public String getWurbletName()
Gets the name of the wurblet.

Returns:
the wurblet's name

setWurbletName

public void setWurbletName(String wurbletName)
Sets the name of the wurblet.

Parameters:
wurbletName - the name of the wurbet

getWurbletArgs

public String[] getWurbletArgs()
Gets the wurblet args.

Returns:
the wurblet args

setWurbletArgs

public void setWurbletArgs(String[] wurbletArgs)
Sets the wurblet args.

Parameters:
wurbletArgs - the args

getWurblerArgs

public String[] getWurblerArgs()
Gets the wurbler (wurblet container) args.

Returns:
the args

setWurblerArgs

public void setWurblerArgs(String[] wurblerArgs)
Sets the wurbler (wurblet container) args

Parameters:
wurblerArgs - the args

toString

public String toString()
Prints the name of the subelement/element/document.

Overrides:
toString in class SourceSubElement
Returns:
the text representation for diagnostics.


Copyright © 2001-2008 Harald Krake, Bergstr. 48, 78098 Triberg, Germany, harald@krake.de