1 57 58 package com.sun.org.apache.xerces.internal.impl.xs; 59 60 import com.sun.org.apache.xerces.internal.xs.ShortList; 61 import com.sun.org.apache.xerces.internal.xs.StringList; 62 import com.sun.org.apache.xerces.internal.xs.XSElementDeclaration; 63 import com.sun.org.apache.xerces.internal.xs.XSModel; 64 import com.sun.org.apache.xerces.internal.xs.XSNotationDeclaration; 65 import com.sun.org.apache.xerces.internal.xs.XSSimpleTypeDefinition; 66 import com.sun.org.apache.xerces.internal.xs.XSTypeDefinition; 67 import com.sun.org.apache.xerces.internal.impl.xs.util.StringListImpl; 68 import com.sun.org.apache.xerces.internal.xs.ElementPSVI; 69 import com.sun.org.apache.xerces.internal.xs.XSConstants; 70 71 83 public class ElementPSVImpl implements ElementPSVI { 84 85 86 protected XSElementDeclaration fDeclaration = null; 87 88 89 protected XSTypeDefinition fTypeDecl = null; 90 91 94 protected boolean fNil = false; 95 96 98 protected boolean fSpecified = false; 99 100 101 protected String fNormalizedValue = null; 102 103 104 protected Object fActualValue = null; 105 106 107 protected short fActualValueType = XSConstants.UNAVAILABLE_DT; 108 109 110 protected ShortList fItemValueTypes = null; 111 112 113 protected XSNotationDeclaration fNotation = null; 114 115 116 protected XSSimpleTypeDefinition fMemberType = null; 117 118 119 protected short fValidationAttempted = ElementPSVI.VALIDATION_NONE; 120 121 122 protected short fValidity = ElementPSVI.VALIDITY_NOTKNOWN; 123 124 125 protected String [] fErrorCodes = null; 126 127 128 protected String fValidationContext = null; 129 130 131 protected XSModel fSchemaInformation = null; 132 133 137 143 public String getSchemaDefault() { 144 return fDeclaration == null ? null : fDeclaration.getConstraintValue(); 145 } 146 147 154 public String getSchemaNormalizedValue() { 155 return fNormalizedValue; 156 } 157 158 163 public boolean getIsSchemaSpecified() { 164 return fSpecified; 165 } 166 167 173 public short getValidationAttempted() { 174 return fValidationAttempted; 175 } 176 177 184 public short getValidity() { 185 return fValidity; 186 } 187 188 194 public StringList getErrorCodes() { 195 if (fErrorCodes == null) 196 return null; 197 return new StringListImpl(fErrorCodes, fErrorCodes.length); 198 } 199 200 201 public String getValidationContext() { 203 return fValidationContext; 204 } 205 206 211 public boolean getNil() { 212 return fNil; 213 } 214 215 220 public XSNotationDeclaration getNotation() { 221 return fNotation; 222 } 223 224 229 public XSTypeDefinition getTypeDefinition() { 230 return fTypeDecl; 231 } 232 233 242 public XSSimpleTypeDefinition getMemberTypeDefinition() { 243 return fMemberType; 244 } 245 246 252 public XSElementDeclaration getElementDeclaration() { 253 return fDeclaration; 254 } 255 256 262 public XSModel getSchemaInformation() { 263 return fSchemaInformation; 264 } 265 266 269 public Object getActualNormalizedValue() { 270 return this.fActualValue; 271 } 272 273 276 public short getActualNormalizedValueType() { 277 return this.fActualValueType; 278 } 279 280 283 public ShortList getItemValueTypes() { 284 return this.fItemValueTypes; 285 } 286 287 290 public void reset() { 291 fDeclaration = null; 292 fTypeDecl = null; 293 fNil = false; 294 fSpecified = false; 295 fNotation = null; 296 fMemberType = null; 297 fValidationAttempted = ElementPSVI.VALIDATION_NONE; 298 fValidity = ElementPSVI.VALIDITY_NOTKNOWN; 299 fErrorCodes = null; 300 fValidationContext = null; 301 fNormalizedValue = null; 302 fActualValue = null; 303 fActualValueType = XSConstants.UNAVAILABLE_DT; 304 fItemValueTypes = null; 305 } 306 307 } 308 | Popular Tags |