1 57 package com.sun.org.apache.html.internal.dom; 58 59 60 import org.w3c.dom.NodeList ; 61 import org.w3c.dom.html.HTMLCollection; 62 import org.w3c.dom.html.HTMLFormElement; 63 64 65 71 public class HTMLFormElementImpl 72 extends HTMLElementImpl 73 implements HTMLFormElement 74 { 75 76 77 public HTMLCollection getElements() 78 { 79 if ( _elements == null ) 80 _elements = new HTMLCollectionImpl( this, HTMLCollectionImpl.ELEMENT ); 81 return _elements; 82 } 83 84 85 public int getLength() 86 { 87 return getElements().getLength(); 88 } 89 90 91 public String getName() 92 { 93 return getAttribute( "name" ); 94 } 95 96 97 public void setName( String name ) 98 { 99 setAttribute( "name", name ); 100 } 101 102 103 public String getAcceptCharset() 104 { 105 return getAttribute( "accept-charset" ); 106 } 107 108 109 public void setAcceptCharset( String acceptCharset ) 110 { 111 setAttribute( "accept-charset", acceptCharset ); 112 } 113 114 115 public String getAction() 116 { 117 return getAttribute( "action" ); 118 } 119 120 121 public void setAction( String action ) 122 { 123 setAttribute( "action", action ); 124 } 125 126 127 public String getEnctype() 128 { 129 return getAttribute( "enctype" ); 130 } 131 132 133 public void setEnctype( String enctype ) 134 { 135 setAttribute( "enctype", enctype ); 136 } 137 138 139 public String getMethod() 140 { 141 return capitalize( getAttribute( "method" ) ); 142 } 143 144 145 public void setMethod( String method ) 146 { 147 setAttribute( "method", method ); 148 } 149 150 151 public String getTarget() 152 { 153 return getAttribute( "target" ); 154 } 155 156 157 public void setTarget( String target ) 158 { 159 setAttribute( "target", target ); 160 } 161 162 163 public void submit() 164 { 165 } 167 168 169 public void reset() 170 { 171 } 173 174 178 public NodeList getChildNodes() { 179 return getChildNodesUnoptimized(); 180 } 181 182 187 public HTMLFormElementImpl( HTMLDocumentImpl owner, String name ) 188 { 189 super( owner, name ); 190 } 191 192 193 196 private HTMLCollectionImpl _elements; 197 198 } 199 200 | Popular Tags |