Commit Graph
19 Commits
Author SHA1 Message Date
Atsushi Eno af866ca922 2009-03-16 Atsushi Enomoto <[email protected]>
* XmlParserContext.cs : .NET has weird nametable initialization.
	  Fixed bug #484519.

	* XmlParserContextTests.cs : added test for bug #484519.


svn path=/trunk/mcs/; revision=129483
2009-03-16 18:04:51 +00:00
Atsushi Eno caea8c9e44 2008-02-19 Atsushi Enomoto <[email protected]>
* XmlParserContext.cs : .net does not populate XmlNamespaceManager
	  automatically.
	* XmlDocument.cs : so, always create one here.

	* XmlParserContextTests.cs : they are working. case #3 should not
	  try to parse broken internalSubset (we do not allow broken
	  intsubset and it is almost no worthy of assuring only-nominal
	  .net compat that such broken internalSubset should be allowed).


svn path=/trunk/mcs/; revision=96116
2008-02-19 05:33:38 +00:00
Atsushi Eno 4e8f715a16 2008-01-15 Atsushi Enomoto <[email protected]>
* XmlParserContext.cs : do not pass invalid URI to XmlTextReader#ctor
	  even as a dummy. Fixed bug #353654.


svn path=/trunk/mcs/; revision=92935
2008-01-15 10:28:04 +00:00
Atsushi Eno ea5f087e84 2004-12-26 Atsushi Enomoto <[email protected]>
* XmlSchema.cs : XmlResolver.ResolveUri() may return null.

	* XmlParserContext.cs : all the string properties must not be set as
	  null. Thanks to Joshua.
	* XmlTextReader.cs,
	  DTDObjectModel.cs,
	  DTDReader.cs : XmlResolver.ResolveUri() may return null.

	* XsdValidatingReader.cs : XmlResolver.ResolveUri() may return null.

	* XslFunction.cs,
	  Compiler.cs : XmlResolver.ResolveUri() may return null.



svn path=/trunk/mcs/; revision=38084
2004-12-26 16:26:30 +00:00
Atsushi Eno f3ed69141a 2004-11-18 Atsushi Enomoto <[email protected]>
* XmlParserContext.cs : the fix was not checked in :(



svn path=/trunk/mcs/; revision=36259
2004-11-18 11:35:13 +00:00
Atsushi Eno 70b42d2cef 2004-11-08 Atsushi Enomoto <[email protected]>
* XmlTextReader2.cs : added. It is used to serve public API, plus
	  entity handling support.

	* DTDObjectModel.cs,
	  DTDValidatingReader.cs,
	  XmlDocumentType.cs,
	  XmlParserContext.cs,
	  XmlTextReader.cs :
	  Implemented XmlTextReader.EntityHandling and ResolveEntity(). To
	  implement them, XmlTextReader in 2.0 itself is in XmlTextReader2.cs
	  and XmlTextReader.cs contains Mono.Xml2.XmlTextReader which is the
	  same as 1.x XmlTextReader. XmlTextReader2 switches entity reader and
	  source reader, and never handles tokenization.
	  The reason for "Mono.Xml2" is to avoid large changes in constructor.f

svn path=/trunk/mcs/; revision=35812
2004-11-08 06:49:47 +00:00
Atsushi Eno cf68eface4 2004-11-03 Atsushi Enomoto <[email protected]>
* XmlParserContext.cs : rewrote; especially to avoid XmlSpace boxing.

svn path=/trunk/mcs/; revision=35592
2004-11-03 11:49:51 +00:00
Duncan Mak 8fa6e766dd Add MIT license to System.XML.DLL
svn path=/trunk/mcs/; revision=30055
2004-06-21 18:07:31 +00:00
Atsushi Eno 15384d4307 2004-04-10 Atsushi Enomoto <[email protected]>
* XmlParserContext.cs : Fixed .ctor() not to reference null namespace
	  manager. This fixes bug #56770.

svn path=/trunk/mcs/; revision=25268
2004-04-10 01:46:06 +00:00
Ben Maurer 94eeaaaa01 Remove HighWaterStack for the time being.
svn path=/trunk/mcs/; revision=17529
2003-08-22 19:45:03 +00:00
Ben Maurer 3056406ff1 2003-08-19 Ben Maurer <[email protected]>
* XmlParserContext.cs: Make each context inherit next.

svn path=/trunk/mcs/; revision=17409
2003-08-19 17:54:15 +00:00
Ben Maurer e3dbc393a2 2003-08-18 Ben Maurer <[email protected]>
* System.Xml.dll.source: add System.Xml/HighWaterStack.cs
        * XmlChar.cs (IsWhitespace): Spare enumerator allocation.
        * XmlTextWriter.cs (WriteWhitespace): Enumerators are very high in
        fat, use low-fat loops instead. Even better, call the function
        inside XmlChar for code reuse.
        * HighWaterStack.cs (added): New class that acts like a Stack, but
        helps with memory allocation.
        * XmlNamespaceManager.cs, XmlParserContext.cs: Rewrote to use
        HighWaterStack.
        * XmlTextReader.cs: Remove orderedAttributesEnumerator variable,
        use a variable that stores the position in the ArrayList.

svn path=/trunk/mcs/; revision=17385
2003-08-18 21:54:50 +00:00
Atsushi Eno 54cf27af0a 2003-08-08 Atsushi Enomoto <[email protected]>
* XmlInputStream.cs :
	  Fixed Initialize() that might result in incorrect buffer.
	  CanRead and Position should consider buffer (especially when the
	  stream was EOF).
	  CanSeek should use stream's CanSeek.

	* XmlChar.cs : added GetPredefinedEntity().
	* DTDObjectModel.cs :
	  - Modified ComputeDefaultValue() to use it.
	  - Fixed NormalizedDefaultValue not to expect parsed value as string.
	  - ResolveExternalEntity now detects invalid standalone specification.
	  - DTDParameterEntityDeclaration.Value is now changed to property and
	    keep its resolved value of literal value of external value using
	    new Resolve (XmlResolver) method (called only by XmlTextReader).
	* DTDValidatingReader.cs :
	  - It now handles entity-expanded Whitespace and SignificantWhitespace
	    correctly. Does not raise unexpected text not allowed error.
	  - Fixed MoveToAttribute()s to move internal reader correctly, and
	    should be able to move in other cases than on element node.
	  - On Read()ing document type and ResolveEntity(), it now sets
	    XmlResolver on text reader.
	  - On ID constraints check and type verification, it now uses
	    normalized attribute or its tokenized value(s).
	  - Fixed ValidateAttributes() to add default values when
	    ValidationType is Auto.
	* XmlParserContext.cs : added internal Dtd setter.
	* XmlParserInput.cs :
	  InsertParameterEntityBuffer() should add surrounding whitespaces.
	  Removed unused code block.
	* XmlTextReader.cs :
	  - Modified ReadReference(), ReadAttribute() and Dereference() to use
	    XmlChar.GetPredefinedEntity().
	  - When returning entity reference, it checks extity declaration
	    existence in certain conditions.
	  - ReadAttribute() now skips general entity replacement on reading
	    entity value.
	  - ReadText() now handles whitespace texts as XmlNodeType.Whitespace.
	  - ReadXmlDeclaration() holds isStandalone, which might be used in
	    entity reference's well-formedness check.
	  - internal 'DTD' now uses XmlParserContext.Dtd.
	  - isInternalSubset was meaningless. Now uses input stack's Count.
	  - Added some required SkipWhitespace().
	  - Several parameter entity handling changes.  Added GetPEValue(name).
	    TryExpandPERef() now uses ImportAsPERef(). ReadParameterEntityDecl()
	    now uses its Resolve() when it was external PE.  Now it uses value
	    buffer instead of currentTag, to efficiently read (included) PE.
	    CompileDeclaration() now uses ImportAsPERef instead of ExpandPERef().
	    ImportAsPERef() simply inserts the value to currentInput.
	    ReadEntityDecl() also uses value buffer.   Removed non-used methods.
	  - Default attributes are now stored in normalized form.
	  - Dereference() now considers non-expanding predefined entities.
	* XmlValidatingReader.cs : now holds Schemas, and ValidationType.Auto
	  is more correctly supported.

	* XmlAttributeCollection.cs :
	  When removing default attribute, it immediately inserts the attribute.
	  RemoveAll() should consider default (not-removable) attributes.
	* XmlDocument.cs :
	  Should have its default XmlResolver. Added Internal Resolver.
	  Some Load() should use its XmlResolver.
	  ImportNode() should copy its children in node level, not value level.
	  It also have to consider not to copy default attribute on importing
	  XmlElement.
	* XmlDocumentType.cs : Now uses document's XmlResolver to read DTD.
	* XmlAttribute.cs,
	  XmlDocumentFragment.cs.
	  XmlElement.cs : use XmlResolver on InnerXml. Removed some MonoTODO.
	* XmlNodeReader.cs : GetInternalParserConext() should provide its DTD.
	  ResolveEntity() uses XmlResolver on entityReader.

svn path=/trunk/mcs/; revision=17202
2003-08-09 09:48:35 +00:00
Atsushi Eno 3de188080d 2003-07-31 Atsushi Enomoto <[email protected]>
* XmlParserContext.cs,
	  XmlAttribute.cs,
	  XmlElement.cs : Added internal Dtd and new internal XmlParserContext
	  .ctor() that takes DTDObjectModel. And then rewrote classes which
	  uses DTD information. Changed DocTypeName, InternalSubset, PublicId
	  and SystemId to use DTDObjectModel.
	* DTDObjectModel.cs :
	  Added DTDObjectModel.InternalSubsetHasPEReference.
	  Added DTDEntityDeclaration.IsInternalSubset.
	* XmlTextReader.cs :
	  Added internal GetInternalParserContext (to build entity reader).
	  Added private isIntSubset to check if the DTD subset is internal or
	  external, which might affect well-formedness constraints.
	  Changed GenerateDTDObjectModel to return the resulting DTD model.

	* XmlEntityReference.cs : implemented BaseURI.
	* XmlNodeReader.cs :
	  - Implemented ResolveEntity() and CanResolveEntity(). In fact
	    it leads too many changes on almost all methods and properties,
	    since they now must be aware of entityReader.
	  - fixed ownerElement that might be used to return from attribute
	    value to the element through parent attribtues.
	  - Now changed indexer to call GetAttribute() and moved actual logic
	    to the matching GetAttribute() methods.

svn path=/trunk/mcs/; revision=16946
2003-07-31 18:01:50 +00:00
Atsushi Eno 5ca10162aa 2003-05-27 Atsushi Enomoto <[email protected]>
* NameTable.cs : Add() sets the given name string interned.
	* XmlParserContext.cs : added internal PushScope() and PopScope() to
	  hold stacks of xml:base, xml:lang and xml:space.
	* XmlTextReader.cs : implemented XmlLang and XmlSpace (only as a
	  property for stacked attributes). Renamed Initialize() to Initialize-
	  Context(). Modified to use XmlParserContext.PushScope()/PopScope().

svn path=/trunk/mcs/; revision=14891
2003-05-26 17:59:08 +00:00
Atsushi Eno 5a8beb8931 2003-03-15 Atsushi Enomoto <[email protected]>
* XmlConstructs.cs : fix "int IsXXX()" to reject negative value.
	* XmlDocument.cs : simplify Load(string url) to use XmlTextReader.
	  fixed ReadNode(), it should call reader.Read() only on Initial state.
	* XmlInputStream.cs : Changed namespace. Added XmlStreamReader(stream)
	  and XmlStreamReader (string). Fixed XmlInputStream(url) not to use
	  System.Net.WebClient directly.
	* XmlParserContext.cs : baseURI don't be null.
	* XmlTextWriter.cs : use WebName for Encoding instead of HeaderName.
	* XmlUrlResolver.cs : namespace change for XmlInputStream.

svn path=/trunk/mcs/; revision=12517
2003-03-15 08:35:39 +00:00
Duncan Mak e230186787 2002-04-16 Duncan Mak <[email protected]>
* XmlParserContext.cs (NameTable): Fixed a typo in the set block.

svn path=/trunk/mcs/; revision=3866
2002-04-16 18:32:20 +00:00
Jason Diamond f9bb1602bd Added missing members to XmlParserContext and started using it from XmlTextReader.
svn path=/trunk/mcs/; revision=3023
2002-03-09 15:36:08 +00:00
Miguel de Icaza 405dc3ea6c Add System.XML
svn path=/trunk/mcs/; revision=170
2001-07-16 01:07:36 +00:00