KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > w3c > dom > html > HTMLFormElement


1 /*
2  * Copyright (c) 2000 World Wide Web Consortium,
3  * (Massachusetts Institute of Technology, Institut National de
4  * Recherche en Informatique et en Automatique, Keio University). All
5  * Rights Reserved. This program is distributed under the W3C's Software
6  * Intellectual Property License. This program is distributed in the
7  * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
8  * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
9  * PURPOSE. See W3C License http://www.w3.org/Consortium/Legal/ for more
10  * details.
11  */

12
13 package org.w3c.dom.html;
14
15 /**
16  * The <code>FORM</code> element encompasses behavior similar to a collection
17  * and an element. It provides direct access to the contained input elements
18  * as well as the attributes of the form element. See the FORM element
19  * definition in HTML 4.0.
20  * <p>See also the <a HREF='http://www.w3.org/TR/2000/CR-DOM-Level-2-20000510'>Document Object Model (DOM) Level 2 Specification</a>.
21  */

22 public interface HTMLFormElement extends HTMLElement {
23     /**
24      * Returns a collection of all control elements in the form.
25      */

26     public HTMLCollection getElements();
27
28     /**
29      * The number of form controls in the form.
30      */

31     public int getLength();
32
33     /**
34      * Names the form.
35      */

36     public String JavaDoc getName();
37     public void setName(String JavaDoc name);
38
39     /**
40      * List of character sets supported by the server. See the
41      * accept-charset attribute definition in HTML 4.0.
42      */

43     public String JavaDoc getAcceptCharset();
44     public void setAcceptCharset(String JavaDoc acceptCharset);
45
46     /**
47      * Server-side form handler. See the action attribute definition in HTML
48      * 4.0.
49      */

50     public String JavaDoc getAction();
51     public void setAction(String JavaDoc action);
52
53     /**
54      * The content type of the submitted form, generally
55      * "application/x-www-form-urlencoded". See the enctype attribute
56      * definition in HTML 4.0.
57      */

58     public String JavaDoc getEnctype();
59     public void setEnctype(String JavaDoc enctype);
60
61     /**
62      * HTTP method used to submit form. See the method attribute definition
63      * in HTML 4.0.
64      */

65     public String JavaDoc getMethod();
66     public void setMethod(String JavaDoc method);
67
68     /**
69      * Frame to render the resource in. See the target attribute definition
70      * in HTML 4.0.
71      */

72     public String JavaDoc getTarget();
73     public void setTarget(String JavaDoc target);
74
75     /**
76      * Submits the form. It performs the same action as a submit button.
77      */

78     public void submit();
79
80     /**
81      * Restores a form element's default values. It performs the same action
82      * as a reset button.
83      */

84     public void reset();
85
86 }
87
88
Popular Tags