diff options
author | Atsushi Eno <atsushieno@gmail.com> | 2003-08-08 02:08:17 +0400 |
---|---|---|
committer | Atsushi Eno <atsushieno@gmail.com> | 2003-08-08 02:08:17 +0400 |
commit | 87249885f77ee6f0f44b31518b0a42eab7081df0 (patch) | |
tree | 4925e4a35bf5715b168b0ac310fa1fa8906d28f3 /mcs/class/System.XML/System.Xml/XmlAttributeCollection.cs | |
parent | e272f9e85dd3bea7d3884a9e27a056c8662337d4 (diff) |
2003-08-07 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
* DTDObjectModel.cs :
- Added validation error check (and AddError(), Errors).
- Fixed ComputeDefaultValue() to handle various references correctly.
- DTDEntityDeclaration.EntityValue became property, and added
LiteralEntityValue. The new one holds resolved value.
Added ResolveExternalEntity(). It now required root in .ctor().
* DTDValidatingReader.cs :
- Now it handles namespaced attributes (as input to xsd validator).
- Added XmlResolver property as usual XmlReader.
- Added currentEntityHandling field so that it can stand changing
XmlValidatingReader's EntityHandling dynamically.
- FilterNormalization() now requires name for getting datatypes and
can stand for non-current attribute normalization.
- Splitted ReadContent() from Read() that can be called recursively
when expanding entities.
- Now handles Entity not found error *after* resolution of entities,
as MS.NET does.
- Read()ing DTD checks its Errors and raises validation error events.
In some situations, DTD parsing may detect VC error, not WFC error.
It also strictly checks NData existence.
- Handling of entity-resolved text is a bit changed and Read()ing
element, endElement, cdata now changed to switch collecting text
and collected text.
- content type ANY should allow texts.
- Added enumerated attribute validity check.
- Added Name/Names creation rule check for ID/IDREF/IDREFS.
- Added entity existence check for ENTITY/ENTITIES attributes.
- Added NMTOKEN creation rule check for NMTOKEN/NMTOKENS.
- Fixed to remove extraneous #REQUIRED check.
- Contributing default attribute is now only applied to the case
ValidationType is DTD or None.
- ResolveEntity() now handles external entities.
Added Mono.Xml.IXmlParserContext interface support.
* XmlDocumentType.cs : Fixed to use BaseURI to build DTD model.
* XmlTextReader.cs :
- Fixed ReadAttributeValue() to reset returnEntityReference.
- Added bool MaybeTextDecl only for ResolveEntity().
- Fixed ReadWhitespace(). In fact its value is considered even if it
is in the end of the XML.
- Fixed ReadXmlDeclaration(). Now skips text declaration.
- CompileDTDSubset() now checks IGNORE/INCLUDE section end balances.
- ReadContentSpec() should set OrderType = OR for mixed model.
Fixed to set content element name correctly.
- ImportAsPERef() now skips Text declaration.
- Type of enumerated default attributes shold be string.
- Undeclared PE error is now handled as DTD's VC error, not
XmlTextReader's WFC error.
* XmlValidatingReader.cs : BaseURI should provide that of
original XmlReader's when read was not started yet.
Fixed XmlResolver to delegate to DTDValidatingReader.
* XmlAttributeCollection.cs : Acquiring attList declaration is
insufficient especially in case of lack of elementdecl.
* XmlChar.cs : (Maybe this is compact than XmlConstructs.)
added IsWhitespace(),IsNCNameChar(),IsName(),IsNCName(),IsNmToken(),
IsPubid(). Copies IsValidIANAEncoding() from XmlConstructs.
* XmlInputStream.cs : Removed "version" declaration check. It should
be done by XmlTextReader.
* XmlNodeReader.cs : added internal GetInternalParserContext() and now
it can be used in XmlValidatingReader.ResolveEntity().
ResolveEntity() sets XmlTextReader.MaybeTextDecl.
svn path=/trunk/mcs/; revision=17167
Diffstat (limited to 'mcs/class/System.XML/System.Xml/XmlAttributeCollection.cs')
-rw-r--r-- | mcs/class/System.XML/System.Xml/XmlAttributeCollection.cs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/mcs/class/System.XML/System.Xml/XmlAttributeCollection.cs b/mcs/class/System.XML/System.Xml/XmlAttributeCollection.cs index a434ed72536..92216c20892 100644 --- a/mcs/class/System.XML/System.Xml/XmlAttributeCollection.cs +++ b/mcs/class/System.XML/System.Xml/XmlAttributeCollection.cs @@ -253,8 +253,8 @@ namespace System.Xml XmlDocumentType doctype = node.OwnerDocument.DocumentType; if (doctype == null || doctype.DTD == null) return existing; - DTDElementDeclaration elem = doctype.DTD.ElementDecls [ownerElement.Name]; - DTDAttributeDefinition attdef = elem == null ? null : elem.Attributes [node.Name]; + DTDAttListDeclaration attList = doctype.DTD.AttListDecls [ownerElement.Name]; + DTDAttributeDefinition attdef = attList == null ? null : attList.Get (node.Name); if (attdef == null || attdef.Datatype.TokenizedType != XmlTokenizedType.ID) return existing; |