org.infolayer.templates.html
Class TE_form

java.lang.Object
  extended byorg.kxml2.kdom.Element
      extended byorg.infolayer.templates.TemplateElement
          extended byorg.infolayer.templates.html.TE_form

public class TE_form
extends TemplateElement

Writes an HTML form element, including a method and URL depending on the type and method attributes. The type is added to the current URL for all sub elements, so they can determine easily whether they are included in an active form.

Attributes

type
A type constant determining the request type and URL for the form. The request URL is constructed by prefixing the type with "get-" or "post-", depending on the method, and appending ".html".
method
Determines the request method used to submit the form. May be POST or GET. If omitted, the default value is GET if the type is query, POST otherwise.

See Also:
Serialized Form

Constructor Summary
TE_form()
           
 
Method Summary
 void apply(XmlSerializer xw, IlRequest context, Bindings bindings)
          Applies the template mechanism.
static void writeFormStart(XmlSerializer xw, IlRequest context, Bindings bindings, java.lang.String type, boolean post)
          Writes the form start tag, including the method and url
 
Methods inherited from class org.infolayer.templates.TemplateElement
applyChildren, assertNoChildren, assertNoChildren, getAttributeValue, getVarDefs, init, readTextContent, setVarDefs, writeAttributes
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TE_form

public TE_form()
Method Detail

writeFormStart

public static void writeFormStart(XmlSerializer xw,
                                  IlRequest context,
                                  Bindings bindings,
                                  java.lang.String type,
                                  boolean post)
                           throws java.io.IOException
Writes the form start tag, including the method and url

Throws:
java.io.IOException

apply

public void apply(XmlSerializer xw,
                  IlRequest context,
                  Bindings bindings)
           throws java.io.IOException
Description copied from class: TemplateElement
Applies the template mechanism. Must be overwritten in the

Overrides:
apply in class TemplateElement
Throws:
java.io.IOException