Commit Graph
938 Commits
Author SHA1 Message Date
Atsushi Eno 5d8f9644c4 2006-01-13 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : Fixed bug #77082.
	  When the state was Start, after WriteProcessingInstruction() and
	  WriteWhitespace() change it to Prolog.
	  After WriteDocType() set state to WriteState.Element.

	* XmlTextWriterTests.cs : added some tests for XMLdecl state check.

	* XslTransformTests.cs : Output_Indent_Xml_DocType() is working now.


svn path=/trunk/mcs/; revision=55487
2006-01-13 05:03:39 +00:00
Atsushi Eno e2e89695a1 2006-01-12 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : Do not local duplicate of automatically-created
	  prefixes (i.e. check local autocreated prefixes other than
	  namespaces from ancestors). Fixed bug #77086 and #77087.

	* XmlTextWriterTests.cs : Split AutoCreatePrefixes() and marked as
	  Ignore rather than NotWorking. Also it is not for bug #77086 and
	  #77077 (they were fixed). See bug #77088.


svn path=/trunk/mcs/; revision=55418
2006-01-12 06:03:06 +00:00
Atsushi Eno d2efba1d17 2006-01-12 Atsushi Enomoto <[email protected]>
* XmlWriter.cs : use XmlChar.IsNmToken() to check argument and throw
	  ArgumentException in WriteNmTokenInternal().

	* XmlTextWriterTests.cs : re-enabled WriteNmToken_InvalidChars().


svn path=/trunk/mcs/; revision=55415
2006-01-12 05:04:09 +00:00
Atsushi Eno 1ca0a71ebf 2006-01-12 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : Fixed bug #77094. Only XmlTextWriter checks
	  such invalid "xml" prefix which is being mapped to different
	  namespace URI than the predefined one.
	  Removed comment that does not make sense.
	* XmlNamespaceManager.cs : IsValidDeclaration() could be private.
	  Added some comments.

	* XmlTextWriterTests.cs : re-enabled bug #77094 related tests.


svn path=/trunk/mcs/; revision=55414
2006-01-12 04:47:39 +00:00
Atsushi Eno 8817da9673 2006-01-11 Atsushi Enomoto <[email protected]>
* DTDObjectModel.cs : dtd2xsd fix; set use="optional" when an
	  attribute is #IMPLIED.


svn path=/trunk/mcs/; revision=55359
2006-01-11 03:58:58 +00:00
Atsushi Eno d364a58d86 2006-01-06 Atsushi Enomoto <[email protected]>
* XmlWriter.cs : In WriteNode(XPathNavigator, bool), Avoid
	  ReadSubtree() for non-element content since they are not allowed
	  in ReadSubtree() (but allowed here).

	* XPathNavigator.cs : use WriteNode(XPathNavigator, bool)
	  rather than WriteNode(XmlWriter, bool) in WriteSubtree().

	* XmlWriterTests.cs : added tests for WriteNode(XPathNavigator, bool)
	  as well as XPathNavigator.WriteSubtree(XmlWriter).


svn path=/trunk/mcs/; revision=55143
2006-01-06 11:56:08 +00:00
Atsushi Eno 12b7f166b6 2006-01-06 Atsushi Enomoto <[email protected]>
* XmlValidatingReader.cs : In ReadTypedValue(), treat Whitespace
	  nodes as target string nodes as well as other text nodes.

	* XsdValidatingReader.cs :
	  Don't use normalized string as input to AssessStringValid(). It 
	  incorrectly invalidates strings against simple types with length-
	  related facets.
	  Now that we don't ignore whitespaces, we need to explicitly allow
	  pure whitespace texts in ElementOnly/Empty model.

	* XmlSchemaSimpleTypeRestriction.cs : maxLength and minLength were
	  likely to be ignored in ValidateNonListValueWithFacets().
	* XmlSchemaValidator.cs : Don't use normalized string value as the
	  input to AssessStringValid().

	* XsdValidatingReaderTests.cs : test for ReadTypeValue() that it
	  does not ignore whitespace nodes, and it does not normalize string
	  incorrectly.


svn path=/trunk/mcs/; revision=55129
2006-01-06 04:47:46 +00:00
Atsushi Eno 2b56366922 2006-01-06 Atsushi Enomoto <[email protected]>
* XmlValidatingReader.cs : ReadTypedValue() was not working with
	  non-XmlSchemaDatatype types.

	* XsdValidatingReaderTests.cs : test for ReadTypeValue() with simple
	  type restriction.


svn path=/trunk/mcs/; revision=55127
2006-01-06 03:36:13 +00:00
Gert Driesen cd7644c997 * XmlTextWriter.cs: Modified WriteWhitespace to throw ArgumentException
if value is null or zero-length string. Modified WriteNmToken to throw
ArgumentException if name is null or zero-length string. Cosmetic
change to WriteStringInternal.
* XmlElement.cs: In 2.0 profile, do not throw ArgumentNullException
if new value for Prefix is null.
* XmlElementTests.cs: Improved tests for setting prefix to null
or zero-length string. On 2.0 profile, setting prefix to null should
not result in ArgumentNullException.
* XmlTextWriterTests.cs: Enabled WriteNmToken tests and
WriteWhitespace tests for null or zero-length value.

svn path=/trunk/mcs/; revision=55115
2006-01-05 20:16:41 +00:00
Atsushi Eno 1bdcf7c5fa 2005-12-26 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : when namespaceURI is String.Empty, Prefix
          should be just ignored (it is likely to happen that DOM nodes
          with empty namespace URI are specified non-empty prefix by
          users, which had better be just ignored). Fixed bug #77095.

        * XmlTextWriterTests.cs : enabled
          WriteStartElement_Prefix_EmptyNamespace() and
          NamespacesPrefixWithEmptyAndNullNamespaceEmpty().


svn path=/trunk/mcs/; revision=54850
2005-12-26 14:57:23 +00:00
Atsushi Eno d120a4fc6e 2005-12-26 Atsushi Enomoto <[email protected]>
* XmlElement.cs : patch for Prefix property by Vorobiev Maksim.
          - null should cause ArgumentNullException.
          - "" should not raise an error.
          - throws ArgumentException when it is readonly.

        * XmlElementTests.cs : Patch by Vorobiev Maksim.
          - setting null to Prefix should raise ArgumentNullException.
          - setting String.Empty to Prefix should be allowed.


svn path=/trunk/mcs/; revision=54849
2005-12-26 14:33:20 +00:00
Atsushi Eno 61ccf99f78 2005-12-23 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : When xml:space or xml:lang attribute was
	  directly written without an element, it caused ArgumentOutOfRange.
	  Fixed bug #77084.

	* XmlTextWriterTests.cs : XmlSpace_Valid() is working now.


svn path=/trunk/mcs/; revision=54793
2005-12-23 20:14:56 +00:00
Atsushi Eno a2f89ee36f 2005-12-23 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : (WriteStartAttribute) set prefix as "xmlns" when
	  namespaceURI is that of xmlns attributes.

	* XmlTextWriterTests.cs : XmlNs_Valid2() is working now.


svn path=/trunk/mcs/; revision=54792
2005-12-23 20:04:42 +00:00
Atsushi Eno 02d0baa2da 2005-12-15 Atsushi Enomoto <[email protected]>
* DTDObjectModel.cs : (CreateXsdParticle) element particle was
	  missing occurence indicators.


svn path=/trunk/mcs/; revision=54470
2005-12-15 16:01:25 +00:00
Atsushi Eno 775f8f8bd7 2005-10-05 Atsushi Enomoto <[email protected]>
* System.Configuration.dll.sources: added
	  IntegerValidatorAttribute.cs, IntegerValidator.cs,
	  LongValidator.cs and LongValidatorAttribute.cs.

	* IntegerValidatorAttribute.cs, IntegerValidator.cs,
	  LongValidator.cs, LongValidatorAttribute.cs : new files.


svn path=/trunk/mcs/; revision=54458
2005-12-15 14:40:17 +00:00
Konstantin Triger 231afa731c allow null string in WriteCData
svn path=/trunk/mcs/; revision=54441
2005-12-15 10:18:32 +00:00
Atsushi Eno 16aacc0e88 2005-12-14 Atsushi Enomoto <[email protected]>
* XmlNode.cs : (GetNamespaceOfPrefix) return const xml/xmlns URIs
	  only under 2.0.


svn path=/trunk/mcs/; revision=54356
2005-12-14 11:13:40 +00:00
Atsushi Eno 260014cbd3 2005-12-14 Atsushi Enomoto <[email protected]>
Added UnderlyingObject support.


svn path=/trunk/mcs/; revision=54353
2005-12-14 08:36:22 +00:00
Atsushi Eno 5392ed3dbb 2005-12-14 Atsushi Enomoto <[email protected]>
* XmlNode.cs : under 2.0 xml/xmlns are treated as special cases in
	  GetNamespaceOfPrefix()/GetPrefixOfNamespace() (but it still does not
	  implement IXmlNamespaceResolver, bummer).


svn path=/trunk/mcs/; revision=54352
2005-12-14 08:30:12 +00:00
Atsushi Eno 9546c7879c 2005-12-14 Atsushi Enomoto <[email protected]>
* XPathEditableDocument.cs : added 2.0 SchemaInfo.

	* XmlDocument.cs : changed some exception types.
	* XmlDocumentNavigator.cs : added 2.0 SchemaInfo.


svn path=/trunk/mcs/; revision=54344
2005-12-14 06:52:29 +00:00
Atsushi Eno 431580c4bc 2005-12-13 Atsushi Enomoto <[email protected]>
* XmlTextReader.cs : 1.x build fix.


svn path=/trunk/mcs/; revision=54274
2005-12-13 10:16:42 +00:00
Atsushi Eno 9991cfa13f 2005-12-13 Atsushi Enomoto <[email protected]>
* XmlTextReader.cs : when XmlReader.Create() creates this instance,
	  don't expect strict text declaration. Check SkipTextDeclaration()
	  on Read().


svn path=/trunk/mcs/; revision=54269
2005-12-13 03:59:27 +00:00
Atsushi Eno fb17c20276 2005-12-12 Atsushi Enomoto <[email protected]>
* XmlReader.cs : fixed several misconception in MoveToNextSibling().
	  It should check its ReadState to avoid infinite loop.

	* XmlReaderCommonTests.cs : enabled MoveToNextSibling() tests.


svn path=/trunk/mcs/; revision=54231
2005-12-12 11:49:32 +00:00
Atsushi Eno 2278c5c420 2005-12-12 Atsushi Enomoto <[email protected]>
* XmlException.cs : added another .ctor() overload that takes both
	  IXmlLineInfo and innerException.
	* XmlQualifiedName.cs : added Parse() overload that takes XmlReader
	  (since XmlReader is not IXmlNamespaceResolver anymore).
	* XmlReader.cs : made several fixes on 2.0 ReadContentAs(),
	  ReadElementContentAs() and all of its variants.

	* XmlReaderCommonTests.cs : added several tests for 2.0 methods.


svn path=/trunk/mcs/; revision=54230
2005-12-12 11:26:27 +00:00
Atsushi Eno fee29e205c 2005-12-09 Atsushi Enomoto <[email protected]>
* XmlInputStream.cs :
	  Added Encoding property on NonBlockingStreamReader
	* XmlTextReader.cs :
	  set Encoding property when it proceeds to xml declaration.

	* XmlTextReaderTests.cs : added test for Encoding property.


svn path=/trunk/mcs/; revision=54166
2005-12-09 16:37:22 +00:00
Atsushi Eno 94811f231e 2005-12-09 Atsushi Enomoto <[email protected]>
* XmlReader.cs : ReadToDescendant() should work when its ReadState is
	  Initial.

	* XmlReaderCommonTests.cs : added tests for ReadToDescendant() and
	  ReadToFollowing().


svn path=/trunk/mcs/; revision=54152
2005-12-09 07:52:09 +00:00
Atsushi Eno de3ddcb8ca 2005-12-09 Atsushi Enomoto <[email protected]>
* XmlChar.cs : removed incorrect comment.
	* XmlReader.cs : Create() clones XmlReaderSettings (if supplied).
	  For wrapped XmlReader, check ConformanceLevel to be consistent.
	* XmlTextReader.cs, XmlTextReader2.cs : added get_Conformance for
	  internal use. Removed unused fields.
	* XmlInputStream.cs : updated NonBlockingStreamReader to the latest
	  StreamReader (it is almost a copy).

	* XmlReaderSettingsTests.cs : added some ConformanceLevel tests.
	  Added CreateClonesSettings() to make sure XmlReader.Create() clones
	  XmlReaderSettings.


svn path=/trunk/mcs/; revision=54151
2005-12-09 06:43:34 +00:00
Atsushi Eno e8fcabe5d2 2005-12-08 Atsushi Enomoto <[email protected]>
* XmlTextReader.cs : avoid Char.IsSurrogate() and do it inside
	  PeekChar(), which improves notable performance.


svn path=/trunk/mcs/; revision=54116
2005-12-08 17:51:19 +00:00
Atsushi Eno 7974be6322 2005-12-08 Atsushi Enomoto <[email protected]>
* XmlReaderSettings.cs : Schemas will be created only when it is
	  required.


svn path=/trunk/mcs/; revision=54105
2005-12-08 09:48:38 +00:00
Andrew Skiba 0eee0d589c update GH project, delete TARGET_JVM from IXmlNamespaceResolver
svn path=/trunk/mcs/; revision=54103
2005-12-08 09:32:16 +00:00
Atsushi Eno 379179256e 2005-12-08 Atsushi Enomoto <[email protected]>
* Driver.cs, Profiler.cs, XmlQualifiedNameTable.cs :
	  removed old code.


svn path=/trunk/mcs/; revision=54102
2005-12-08 08:43:34 +00:00
Atsushi Eno 99c907944c 2005-12-08 Atsushi Enomoto <[email protected]>
* System.Xml.dll.sources : added XmlSchemaCompilationSettings.cs

	* XmlReaderSettings.cs : thanks to idiotic MS design,
	  AllowXmlAttributes is turned on by default.

	* XmlSchemaCompilationSettings.cs : new file.
	* XmlSchemaSet.cs : added CompilationSettings property.
	* XmlSchemaComplexType.cs : support for EnableUpaCheck.

	* XmlReaderSettingsTests.cs : (DefaultValue)
	  Added assertion label everywhere.
	* XmlWriterTests.cs : WriteNodeError is broken under MS.NET 2.0 (it
	  should cause an error).

	* XmlSchemaSetTests.cs : added CompilationSettings tests.


svn path=/trunk/mcs/; revision=54094
2005-12-08 06:56:12 +00:00
Atsushi Eno c2029b413f 2005-12-08 Atsushi Enomoto <[email protected]>
* XmlReaderSettings.cs :
	  set_Schemas() is fixed in 2.0 RTM (it just works).
	* XmlResolver.cs : throw ArgumentNullException instead of
	  ArgumentException when both base and relative urls are null.

	* XmlReaderSettingsTests.cs : SetSchemas() should not cause an error.
	  Added SetSchemasNull() as well.
	* XmlUrlResolverTests.cs : (ResolveUriWithNullArgs)
	  expect ArgumentNullException instead of ArgumentException.
	  This is a fix in .NET 2.0.


svn path=/trunk/mcs/; revision=54093
2005-12-08 05:53:02 +00:00
Atsushi Eno b78ca0c164 2005-12-08 Atsushi Enomoto <[email protected]>
* XmlReaderSettings.cs : ProhibitDtd is set as default.
	* XmlWriterSettings.cs : no set_OutputMethod.

	* XmlReaderCommonTests.cs : use ProhibitDtd=false in CreateSimple()
	  and added CreateSimpleProhibitDtd().


svn path=/trunk/mcs/; revision=54090
2005-12-08 04:06:22 +00:00
Konstantin Triger 3151ae3a89 TARGET_JVM build system changes
svn path=/trunk/mcs/; revision=53683
2005-11-30 15:05:18 +00:00
Vladimir Krasnov bd6ec6e434 XmlInputStream.cs: fixed Initialize method to be able to read unicode file without BOM. TARGET_JVM only.
svn path=/trunk/mcs/; revision=53180
2005-11-17 14:57:06 +00:00
Atsushi Eno 7691b50279 2005-11-14 Atsushi Enomoto <[email protected]>
* XmlNodeReader.cs : removed historical one.


svn path=/trunk/mcs/; revision=53013
2005-11-14 13:26:09 +00:00
Atsushi Eno f4112a5629 2005-11-10 Atsushi Enomoto <[email protected]>
* XmlReader.cs, XmlNode.cs :
	  [DebuggerDisplay] are not worthy of existing.

	* XPathNavigator.cs, XPathNodeIterator.cs :
	  [DebuggerDisplay] are not worthy of existing.


svn path=/trunk/mcs/; revision=52880
2005-11-10 18:30:39 +00:00
Atsushi Eno eef73ce68c 2005-11-09 Atsushi Enomoto <[email protected]>
* XmlTokenizedType.cs, XmlNodeOrder.cs : so those enums happen to
	  have [Serializable] in .NET 1.x, and removed in 2.0 (enums are
	  anyways serializable, so those attributes do not make sense).


svn path=/trunk/mcs/; revision=52877
2005-11-10 18:19:49 +00:00
Atsushi Eno 0dbee9dd3a 2005-11-09 Atsushi Enomoto <[email protected]>
* XmlValidatingReader.cs : added CanReadBinaryContent.
	* XmlTextReader.cs, XmlTextReader2.cs : GetNamespacesInScope() are
	  now both public and private (i.e. hush IsVirtual).
	* XmlWriterSettings.cs, XmlWriter.cs, XmlTextWriter.cs :
	  NormalizeNewLines vanished.

	* XmlWriterSettingsTests.cs : NormalizeNewLines does not exist anymore


svn path=/trunk/mcs/; revision=52876
2005-11-10 18:12:16 +00:00
Atsushi Eno e8c5d62a86 2005-11-09 Atsushi Enomoto <[email protected]>
* XmlReader.cs : MoveToAttribute(int) is virtual in NET_2_0.


svn path=/trunk/mcs/; revision=52871
2005-11-10 17:58:13 +00:00
Atsushi Eno 8a668546b1 2005-11-09 Atsushi Enomoto <[email protected]>
* XmlConvert.cs : implemented VerifyTOKEN().

	* XmlConvertTests.cs : tests for ToUInt16/32/64() and VerifyTOKEN().


svn path=/trunk/mcs/; revision=52870
2005-11-10 17:44:03 +00:00
Atsushi Eno 84269d9282 2005-11-09 Atsushi Enomoto <[email protected]>
* XmlConvert.cs : VerifyNCName() and VerifyName() throws
	  ArgumentNullException for "".

	* XmlConvertTests.cs : some tests for ToInt16(), ToInt32(),
	  VerifyName() and VerifyNCName().


svn path=/trunk/mcs/; revision=52857
2005-11-10 16:55:55 +00:00
Atsushi Eno 38e3987552 2005-11-07 Atsushi Enomoto <[email protected]>
* XmlReader.cs : dependent XmlSchemaValidationFlags fix.
	  Added ReadElementContentAsObject() and ReadContentAsObject().
	* XmlReader.cs, XmlTextReader.cs :
	  LookupNamespace(string,bool) is now private.
	* XmlReader.cs, XmlNode,cs :
	  [DebuggerDisplay].

	* XmlSchemaValidationFlags.cs : updated to match 2.0 RTM.
	* XmlSchemaValidator.cs : related fix.

	* XmlSchemaValidatingReader.cs : XmlSchemaValidationFlags is updated.

	* XmlReaderSettingsTests.cs : XmlSchemaValidationFlags is updated.



svn path=/trunk/mcs/; revision=52659
2005-11-07 17:22:05 +00:00
Atsushi Eno 6d7725e5bb 2005-11-07 Atsushi Enomoto <[email protected]>
* XmlElement.cs, XmlCDataSection.cs, XmlText.cs, XmlWhitespace.cs,
	  XmlSignificantWhitespace.cs : added ParentNode overrides (actually
	  they don't make sense since it just calls base.)
	* XmlNode.cs, XmlDocument.cs : changed .NET 2.0 CreateNavigator() impl
	  to match signature and skip OwnerDocument check in XmlNode (since
	  it is overriden). Maybe MS does not have ownerDocument as a field and
	  costs too much on OwnerDocument property.
	  Added missing bits in XmlDocument.


svn path=/trunk/mcs/; revision=52647
2005-11-07 11:42:17 +00:00
Atsushi Eno bc2aba513c 2005-11-07 Atsushi Enomoto <[email protected]>
* XmlAttribute.cs : added new overrides in 2.0 RTM (this scarcely
	  makes sense without real optimization though).
	* XmlDocument.cs, XmlElement.cs, XmlNode.cs : avoid ChildNodes and
	  save extra XmlNodeList creation cost.


svn path=/trunk/mcs/; revision=52646
2005-11-07 10:37:57 +00:00
Atsushi Eno a7a4be34df 2005-11-07 Atsushi Enomoto <[email protected]>
* XsdValidatingReader.cs : XmlReader.ReadTypedValue() does not exist 
	  anymore, so it is not override.

	* XmlNamespaceManager.cs : NameTable is virtual in 2.0 RTM.
	* XmlReader.cs : IsEmptyElement is reverted to be abstract in 2.0 RTM.
	  ReadTypedValue() is removed.
	* XmlValidatingReader.cs : ReadTypedValue() is not virtual now.
	* XmlWriter.cs : Settings is virtual.

	* XPathNodeIterator.cs : added [DebuggerDisplay]. pretty useless tho.
	* XPathNavigator.cs : [DebuggerDisplay] as well.
	  SelectSingleNode() and AppendChildElement() are now virtual.


svn path=/trunk/mcs/; revision=52637
2005-11-07 08:48:22 +00:00
Atsushi Eno 29581a1ead 2005-10-23 Atsushi Enomoto <[email protected]>
* XPathNavigator.cs : now 2.0 MoveToFirst() invokes internal
	  MoveToFirstImpl() and it is from what XmlDocumentNavigator did.
	  This fixes XPathEditableDocument.MoveToFirst().

	* XmlDocumentNavigator.cs : now MoveToFirst() invokes internal
	  MoveToFirstImpl().


svn path=/trunk/mcs/; revision=52108
2005-10-23 20:45:26 +00:00
Atsushi Eno 7c1521311f 2005-10-23 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : oops, so WriteState.Error is NET_2_0 only.


svn path=/trunk/mcs/; revision=52105
2005-10-23 20:19:28 +00:00
Atsushi Eno 795d84863f 2005-10-23 Atsushi Enomoto <[email protected]>
* XmlTextWriter.cs : (Error state check) actually I need to set Error.

	* XmlNamespaceManagerTests.cs : GetNamespacesInScope() - Added test 
	   labels. Fixed counts; they count default namespaces. MS seems to
	   have a bug on declaration removal (xmlns='') on .Local.
	* XmlNodeReaderTests.cs : in .NET 2.0 undeclared entity are not
	  allowed at all, so disabled tests that depends on such references.


svn path=/trunk/mcs/; revision=52101
2005-10-23 20:13:10 +00:00