Merge pull request #2554 from ludovic-henry/coop-blocking-interrupt
[mono.git] / mcs / class / Commons.Xml.Relaxng / Commons.Xml.Relaxng / ChangeLog
1 2010-07-23  Atsushi Enomoto <atsushi@ximian.com>
2
3         * RelaxngPattern.cs : inherit XmlResolver to parsed rng component.
4           Fixed bug #622630.
5
6 2010-06-25  Atsushi Enomoto <atsushi@ximian.com>
7
8         * RelaxngReader.cs : don't use Name, use LocalName. Fixed bug #617264.
9
10 2009-02-23  Atsushi Enomoto <atsushi@ximian.com>
11
12         * RelaxngValidatingReader.cs : implemented error recovery feature.
13           Use InvalidNodeFound event (of type RelaxngValidationEventHandler)
14           to handle validation error like ValidationEventHandler in
15           System.Xml.XmlSchema.
16
17 2009-02-19  Atsushi Enomoto <atsushi@ximian.com>
18
19         * XsdDatatypeProvider.cs : detect grammar-level error in type usage
20           at compile time.
21
22 2009-02-17  Atsushi Enomoto <atsushi@ximian.com>
23
24         * XsdDatatypeProvider.cs : workaround .NET/Mono Regex bug that
25           does not handle \p{Latin-1Supplement} to work with OOXML grammar.
26
27 2009-01-20  Atsushi Enomoto <atsushi@ximian.com>
28
29         * RelaxngReader.cs : fixed wrong text skip and ns/datatypeLibrary
30           stack pop. Fixed bug #463267.
31
32 2009-01-20  Atsushi Enomoto <atsushi@ximian.com>
33
34         * RelaxngGrammar.cs : fix confused use of datatype provider property.
35           Fixed bug #463264. Based on the patch by Mark Junker.
36
37 2008-11-11  Atsushi Enomoto <atsushi@ximian.com>
38
39         * RelaxngPattern.cs : handle inherited default namespace in compact 
40           syntax as expected.
41
42 2008-08-25  Atsushi Enomoto <atsushi@ximian.com>
43
44         * RelaxngPattern.cs : unlike "include" element, "external" element
45           was always resolved as XML syntax, and hence blocked use of
46           external element in compact syntax.
47
48 2007-12-27  Atsushi Enomoto <atsushi@ximian.com>
49
50         * RelaxngPattern.cs : (RelaxngInclude) when a relative Uri is
51           specified as its BaseUri, make it into an absolute path and
52           then resolve the URI.
53
54 2007-12-17  Atsushi Enomoto <atsushi@ximian.com>
55
56         * RelaxngPattern.cs : (RelaxngInclude) when it is constructed from
57           the compact syntax, resolve included file as compact syntax too.
58         * RelaxngGrammar.cs : to make above possible, add a new
59           IsSourceCompactSyntax field that is to be set in RncParser.
60
61 2006-04-19  Atsushi Enomoto <atsushi@ximian.com>
62
63         * RelaxngValidatingReader.cs : (.ctor) reject null pattern.
64           To filter xmlns attributes out, just use NamespaceURI.
65
66 2006-04-07  Atsushi Enomoto <atsushi@ximian.com>
67
68         * RelaxngPattern.cs : use new RelaxngReader .ctor () with XmlResolver
69           argument. Fix by Alexandre Alapetite.
70
71 2006-04-03  Atsushi Enomoto <atsushi@ximian.com>
72
73         * RelaxngPattern.cs : set XmlResolver that is passed by
74           RelaxngPattern.Read() as its property.
75
76 2006-03-29  Atsushi Enomoto <atsushi@ximian.com>
77
78         * RelaxngDatatype.cs : Compare() should not be just a stupid object
79           comparison, but should rather be type-dependent equality.
80           Thanks to Alexandre.
81
82 2006-03-28  Atsushi Enomoto <atsushi@ximian.com>
83
84         Based on the patch by Alexandre Alapetite:
85         * RelaxngException.cs : added another constructor that takes
86           pattern, string and innerException.
87         * RelaxngReader.cs
88           RelaxngPattern.cs :
89           - wrap xml resolution error in RelaxngInclude.Read(). This change
90             is argurable but might be convenient for certain users.
91           - Added another constructor to RelaxngReader, and another overload
92             for RelaxngPattern.Read(), otherwise RelaxngPattern.Read() can
93             never use different XmlResolvers.
94
95 2006-03-27  Atsushi Enomoto <atsushi@ximian.com>
96
97         Patch by Alexandre Alapetite (http://alexandre.alapetite.net/cv/)
98         * RelaxngPattern.cs : RelaxngInclude.Read() could be NRE when
99           there is an error in XmlTextReader .ctor().
100         * RelaxngValidatingReader.cs : If the input XmlReader is already 
101           positioned on the first node to validate, skip Read() here.
102
103 2006-02-02  Atsushi Enomoto <atsushi@ximian.com>
104
105         * RelaxngValidatingReader.cs : removed extra tables.
106
107 2006-01-16  Atsushi Enomoto <atsushi@ximian.com>
108
109         * RelaxngValidatingReader.cs : fixed warning.
110
111 2006-01-16  Atsushi Enomoto <atsushi@ximian.com>
112
113         * RelaxngValidatingReader.cs : just keep previous TextDeriv() result
114           for each pattern; they are mostly not reused. It makes validator
115           about 30% faster in certain validation and reduces memory use.
116
117 2006-01-13  Atsushi Enomoto <atsushi@ximian.com>
118
119         * RelaxngValidatingReader.cs : actually using Hashtable of Hashtable
120           (instead of ArrayList of custom MemoizationStart class) is much
121           better for performance. It makes StartTagOpenDeriv and
122           StartAttDeriv more than 10x faster than before.
123
124 2006-01-13  Atsushi Enomoto <atsushi@ximian.com>
125
126         * RelaxngDatatype.cs, RelaxngDefaultDatatypes.cs,
127           XsdDatatypeProvider.cs, RelaxngValidatingReader.cs :
128           Memoize TextDeriv() results for context independent inputs.
129
130           Due to the API freeze they are kept as internal virtual for now.
131
132 2006-01-12  Atsushi Enomoto <atsushi@ximian.com>
133
134         * RelaxngValidatingReader.cs : Use RdpPattern.EmptyTextDeriv(). It
135           significantly improves performance wrt empty text nodes.
136
137 2006-01-10  Atsushi Enomoto <atsushi@ximian.com>
138
139         * RelaxngValidatingReader.cs :
140           - Split memoization support things into MemoizationStore class.
141           - Split single memo ArrayList into a couple of Hashtables and 
142             ArrayLists which memoize each kind of derivative results.
143           - Introduced StartAttDeriv() and EndAttDeriv() to replace AttDeriv()
144             and memoize results efficiently. It is textually written in the
145             "derivative algorithm", but not formally specified.
146           - Introduced IsTextValueDependent and EmptyTextDeriv() to 
147             differentiate those patterns which results differ depending on
148             the text value and those which doesn't.
149             Those EmptyTextDeriv results are memoized.
150
151 2006-01-10  Atsushi Enomoto <atsushi@ximian.com>
152
153         * Misc.cs : NormalizeWhitespace() was creating extraneous char[] and
154           it could be heavily called depending on patterns.
155         * RelaxngDefaultDatatypes.cs : avoid extraneous call to
156           NormalizeWhitespace().
157
158 2006-01-05  Atsushi Enomoto <atsushi@ximian.com>
159
160         * RelaxngValidatingReader.cs :
161           - weak match 3 in Section 6.2.7 was missing (in derivative, it is
162             childrenDeriv cx p [] = childrenDeriv cx p [(TextNode "")] ).
163           - uncommented out whitespace handling in TextOnlyDeriv (it is 
164             "in if whitespace s then choice p p1 else p1" in derivative).
165           - MixedTextDeriv() is not fixed to not require string argument.
166         * XsdDatatypeProvider.cs : call Read() after ReadTypedValue().
167
168 2006-01-04  Alexandre Miguel Pedro Gomes <alexmipego@gmail.com>
169
170         * RelaxngValidatingReader.cs: fix typo
171
172 2006-01-04  Atsushi Enomoto <atsushi@ximian.com>
173
174         * RelaxngValidatingReader.cs :
175           - Simplified CreateValidationError().
176           - Don't validate 1) whitespaces outside element and 2) whitespaces
177             which do not consist of text only content.
178           - Implemented "memoization":
179             http://www.thaiopensource.com/relaxng/derivative.html#Memoization
180           - with related to memoization, use new TextOnlyDeriv() and 
181             MixedTextDeriv() to validate texts. See also RdpPattern changes.
182         * RelaxngGrammar.cs : don't update pool tables for static instances.
183
184 2005-12-27  Atsushi Enomoto <atsushi@ximian.com>
185
186         * Misc.cs RelaxngDatatype.cs RelaxngPattern.cs RelaxngException.cs
187           RelaxngMergedProvider.cs RelaxngPatternType.cs RelaxngReader.cs
188           RelaxngDefaultDatatypes.cs XsdDatatypeProvider.cs
189           RelaxngValidatingReader.cs RelaxngDatatypeProvider.cs
190           RelaxngGrammar.cs RelaxngNameClass.cs :
191
192           This is the smarter way to set eol-style without messing code
193           history.
194
195 2005-12-27  Atsushi Enomoto <atsushi@ximian.com>
196
197         * RelaxngDatatype.cs RelaxngPattern.cs RelaxngException.cs
198           RelaxngMergedProvider.cs RelaxngPatternType.cs RelaxngReader.cs
199           RelaxngDefaultDatatypes.cs XsdDatatypeProvider.cs
200           RelaxngValidatingReader.cs RelaxngDatatypeProvider.cs
201           RelaxngGrammar.cs RelaxngNameClass.cs :
202           turned out that they all have LF on copyright lines while they are
203           written to have CRLF.
204
205 2005-12-27  Atsushi Enomoto <atsushi@ximian.com>
206
207         * Misc.cs : it has inconsistent newlines. Removed unused code.
208
209 2005-12-27  Atsushi Enomoto <atsushi@ximian.com>
210
211         * RelaxngGrammar.cs : A constraint in 4.18 that grammar must have at
212           least one start element was missing. This fixes test #199 and #200.
213
214 2005-12-27  Atsushi Enomoto <atsushi@ximian.com>
215
216         * RelaxngValidatingReader.cs : validate whitespaces as text nodes. It
217           rather invalidated some valid documents incorrectly (since it kept
218           text pattern remaining). This fixed following tests: 237/2.v.xml,
219           256/2.i.xml, 258/2.i.xml, 261/1.v.xml, 261/3.v.xml, 261/4.v.xml,
220           268/2.v.xml and 269/2.v.xml, while it exposed bugs on 260/2.i.xml
221           and 261/6.i.xml (they are not regressions).
222
223 2005-12-27  Atsushi Enomoto <atsushi@ximian.com>
224
225         * XsdDatatypeProvider.cs : Namespace remapping was required to make
226           simple type restriction work fine. This fixes test #261/1.v.xml,
227           #268/2.v.xml and #269/2.v.xml.
228
229 2005-12-27  Atsushi Enomoto <atsushi@ximian.com>
230
231         * RelaxngValidatingReader.cs : it needs to cache text nodes to allow
232           split texts by such nodes as comments or processing instructions.
233           This fixes test #268 and #269.
234
235 2005-12-27  Atsushi Enomoto <atsushi@ximian.com>
236
237         * RelaxngGrammar.cs : expand refs before checking content pattern.
238
239 2005-12-16  Atsushi Enomoto <atsushi@ximian.com>
240
241         * RelaxngPattern.cs : RelaxngData and RelaxngValue was writing QName
242           instead of NCName for type attribute (wrong).
243
244 2005-12-16  Atsushi Enomoto <atsushi@ximian.com>
245
246         * RelaxngPattern.cs : in WriteCompact(), use WriteNamespace() to
247           let RncWriter handle namespace output by itself.
248
249 2005-09-20  Atsushi Enomoto <atsushi@ximian.com>
250
251         * RelaxngValidatingReader.cs : added explicit error message for
252           attribute XmlReader validation (spec section 7.1.5 explicitly
253           prohibits start//attribute so such validation never happens).
254         * RelaxngGrammar.cs : name class analysis is now done inside
255           CheckConstraints(), so nothing to add here.
256         * RelaxngPattern.cs : (RdpUnresolvedRef) now GetLabels() could be
257           invoked here, so just ignore.
258
259 2005-07-31  Atsushi Enomoto <atsushi@ximian.com>
260
261         * RelaxngGrammar.cs : spec 7.3 check is kinda implemented but cannot
262           verify now because of weird exception handling in the runtime.
263
264 2005-06-07  Atsushi Enomoto <atsushi@ximian.com>
265
266         * RelaxngReader.cs : When ReadPattern() if no valid pattern appears
267           then raise an error. In Read() when there are only non RELAX NG 
268           elements it resulted in an infinite loop.
269
270 2005-04-06  Atsushi Enomoto <atsushi@ximian.com>
271
272         * RelaxngPattern.cs : fixed incorrect use of virtual.
273
274 2005-03-18  Atsushi Enomoto <atsushi@ximian.com>
275
276         * XsdDatatypeProvider.cs : quick hack to workaround not to be rejected 
277           under MS.NET because of NOTATION type (thus, NOTATION type is not
278           available in this provider).
279
280 2005-03-01  Atsushi Enomoto <atsushi@ximian.com>
281
282         * RelaxngReader.cs : there was two public namespace constant. One
283           should be obsoleted.
284
285 2005-03-01  Atsushi Enomoto <atsushi@ximian.com>
286
287         * RelaxngPattern.cs : RdpUnresolvedRef should process empty/notAllowed
288           elimination on its referenced pattern.
289
290 2005-02-27  Atsushi Enomoto <atsushi@ximian.com>
291
292         * XsdDatatypeProvider.cs : Added simpleType parameter support.
293         * RelaxngValidatingReader.cs : added ReportDetails flag to report all
294           expected element names / attribute names. Removed all unused code.
295
296 2005-02-06  Atsushi Enomoto <atsushi@ximian.com>
297
298         * RelaxngReader.cs : ns attribute on root element should also be 
299           handled as well as datatypeLibrary.
300
301 2005-02-06  Atsushi Enomoto <atsushi@ximian.com>
302
303         * RelaxngReader.cs : it was not handling datatypeLibrary attribute
304           on root element. Added DefaultNamespace handling.
305         * RelaxngGrammar.cs : added DefaultNamespace property.
306         * RelaxngPattern.cs : WriteCompact() now outputs "default namespace =..".
307
308 2005-01-26  Atsushi Enomoto <atsushi@ximian.com>
309
310         * RelaxngPattern.cs : fixed 2.0 typo.
311
312 2005-01-26  Atsushi Enomoto <atsushi@ximian.com>
313
314         * RelaxngGrammar.cs, RelaxngPattern.cs, RelaxngNameClass.cs :
315           added RelaxngPattern.WriteCompact(TextWriter) and all internal 
316           WriteRnc() overrides.
317
318 2004-12-06  Atsushi Enomoto <atsushi@ximian.com>
319
320         * RelaxngValidatingReader.cs :
321           - Existing GetLabels() was insufficient to support attribute labels
322             by design (since those state object always reflects the status
323             after Read() and inside Read() attributes are checked and attribute
324             derivatives are consumed). So just made existing stuff as obsolete.
325           - Added object GetCurrentState() that returns RdpPattern wrapper.
326           - Added Emptiable(object state) that returns whether the 
327             specified state is emptiable.
328           - Added GetElementLabels(object state) and GetAttributeLabels(object
329             state) that returns the collection of XmlQualifiedName that 
330             represents possible element names or attribute names from the
331             argument state.
332           - Added AfterOpenStartTag(state,name,ns), OpenStartTag(state,name,
333             ns), AfterAttribute(state, name, ns), Attribute(state,name,ns),
334             AfterCloseStartTag(state), CloseStartTag(state),
335             AfterEndTag(state) and EndTag(state) to simulate state transition.
336             AfterXXX() returns another state instance if the transition was
337             successful or null. XXX() returns bool that indicates if the 
338             transition was successful or not and proceeds the state in case
339             of success.
340
341 2004-12-06  Atsushi Enomoto <atsushi@ximian.com>
342
343         * RelaxngException.cs : Added new .ctor() that takes RelaxngElementBase
344           to provide target grammar component location.
345
346 2004-12-06  Atsushi Enomoto <atsushi@ximian.com>
347
348         * RelaxngNameClass.cs,
349           RelaxngPattern.cs,
350           RelaxngGrammar.cs :
351           Added related grammar component location to error message.
352           In RelaxngDefine, Compile() caused error on duplicate key on
353           Hashtable.Add().
354         * RelaxngReader.cs : In GetStrippedAttribute(), use 
355           GetAttribute(string,string).
356
357 2004-12-06  Atsushi Enomoto <atsushi@ximian.com>
358
359         * RelaxngException.cs : don't store debug string. It was so harmful
360           for performance.
361
362 2004-12-05  Atsushi Enomoto <atsushi@ximian.com>
363
364         * RelaxngValidatingReader.cs :
365           - Better way to expose API; use ExpectedElements and 
366             ExpectedAttributes of type ICollection. Now GetLabels is obsolete.
367           - Implemented notAllowed check. It might be too heavy since it
368             checks all the QNames returned by GetLabels. In such case, use
369             RoughLabelCheck = true.
370           - Added RoughLabelCheck of type bool that indicates to omit
371             notAllowed check.
372
373 2004-12-05  Atsushi Enomoto <atsushi@ximian.com>
374
375         * RelaxngValidatingReader.cs : no, it was very easy. But to avoid
376           state-changeful property, it is now bool Emptiable().
377
378 2004-12-05  Atsushi Enomoto <atsushi@ximian.com>
379
380         * RelaxngValidatingReader.cs : reverted IsEmptiable. It was not ready.
381
382 2004-12-05  Atsushi Enomoto <atsushi@ximian.com>
383
384         * RelaxngPattern.cs : added GetLabels() override to RdpUnresolvedRef.
385         * RelaxngValidatingReader.cs :
386           Added GetLabels() that collects "allowed element names and
387           attributes" at current state.
388           Added IsEmptiable that indicates whether current reader can be
389           closed by an end tag.
390
391 2004-11-28  Atsushi Enomoto <atsushi@ximian.com>
392
393         * RelaxngGrammar.cs : fixed error that happened on recompilation.
394
395 2004-07-14  Atsushi Enomoto <atsushi@ximian.com>
396
397         * RelaxngGrammar.cs : When definition is missing, the error message
398           should show what definition is missing.
399
400 2004-06-25  Atsushi Enomoto <atsushi@ximian.com>
401
402         * Misc.cs, RelaxngDatatype.cs, RelaxngDatatypeProvider.cs,
403           RelaxngDefaultDatatype.cs, RelaxngException.cs, RelaxngGrammar.cs,
404           RelaxngMergedProvider.cs, RelaxngNameClass.cs, RelaxngPattern.cs,
405           RelaxngPatternType.cs, RelaxngReader.cs, RelaxngValidatingReader.cs,
406           XsdDatatypeProvider.cs : Added/replaced novell license term.
407
408 2004-06-21  Atsushi Enomoto <atsushi@ximian.com>
409
410         * Misc.cs,
411           RelaxngPattern.cs,
412           RelaxngReader.cs :
413           Use XmlResolver (or XmlUrlResolver) directly. XmlResolver was
414           incorrectly _used_ before null check. Don't create XmlResolver
415           instance for _every_ pattern object.
416         * RelaxngPattern.cs : UnresolvedRef.ExpandRef() should return not
417           try to find target derivative pattern twice. It was the culprit of
418           infinite loop. Removed dirty switches.
419         * RelaxngGrammar.cs : code cleanup.
420
421 2004-06-17  Atsushi Enomoto <atsushi@ximian.com>
422
423         * Misc.cs, RelaxngGrammar.cs, RelaxngPattern.cs, RelaxngReader.cs :
424           Added XmlResolver property to fix bug #60334.
425           Check incrrect recursion check that caused possible infinite loop.
426
427 2004-05-31  Atsushi Enomoto <atsushi@ximian.com>
428
429         * Misc.cs : made Util class internal.
430         * RelaxngDatatypeProvider.cs : looks commit was missing.
431         * RelaxngException.cs : made one .ctor() internal that accepts
432           RdpPattern.
433         * RelaxngNameClas.cs : Names list should not be settable.
434         * RelaxngPattern.cs : RelaxngRefPattern class is internal use only.
435         * RelaxngPatternType.cs : there is not "Include" pattern.
436
437 2004-05-30  Atsushi Enomoto <atsushi@ximian.com>
438
439         * RelaxngDatatypeProvider.cs : removed meaningless using alias.
440         * RelaxngGrammar.cs : modified ArrayList to RelaxngGrammarContentList.
441           RelaxngMergedProvider.cs : Added #if PNET switch to support non-
442           xmlschema available environment.
443         * RelaxngPattern.cs : added IGrammarContent and
444           RelaxngGrammarContentList.
445
446 2004-03-17  Atsushi Enomoto <atsushi@ximian.com>
447
448         * RelaxngNameClass.cs : Introduced RelaxngNameClassList class.
449
450 2004-03-15  Atsushi Enomoto <atsushi@ximian.com>
451
452         * RelaxngGrammar.cs,
453           RelaxngNameClass.cs,
454           RelaxngPattern.cs : Added Write() support.
455
456 2004-02-28  Atsushi Enomoto <atsushi@ximian.com>
457
458         * RelaxngReader.cs : ReadPattern() should be public.
459
460 2004-02-25  Atsushi Enomoto <atsushi@ximian.com>
461
462         * Removed 
463           - RngGrammar.cs
464           - RngNameClass.cs
465           - RngPattern.cs
466           - RngPatternType.cs
467           They are moved to RelaxngXXX.cs and improved
468
469 2004-02-25  Atsushi Enomoto <atsushi@ximian.com>
470
471         * Added 
472           - RelaxngDatatype.cs
473           - RelaxngDatatypeProvider.cs
474           - RelaxngDefaultDatatypes.cs
475           - RelaxngException.cs
476           - RelaxngGrammar.cs
477           - RelaxngMergedProvider.cs
478           - RelaxngNameClass.cs
479           - RelaxngPattern.cs
480           - RelaxngPatternType.cs
481           - XsdDatatypeProvider.cs
482         * Misc.cs,
483           RelaxngReader.cs,
484           RelaxngValidatingReader.cs : Radical design changes.
485
486         In short:
487           - API redesign (renaming RngXxx to RelaxngXxx)
488           - Strict grammar validation
489           - Datatype support (XML Schema primitive datatypes)
490           - Some derivative bugfixes such as list validation.
491
492 2003-05-19  Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
493
494         * RelaxngReader.cs :
495           + Now skips immaterial content correctly.
496           + Removed MoveToContent().
497           + Trimming attribute values and names.
498           + Fixed ReadNameClassChoice(), ReadNameClassExcept(),
499             ReadPatternExcept (). They require one or more contents.
500           + QName resolver fix.
501           + ReadListPattern() failed to read actual content.
502         * RelaxngValidatingReader.cs :
503           + Fixed incorrect error message.
504           + Fixed incorrect attribute namespace handling.
505         * RngGrammar.cs : Some simplification stuff fix. 
506           Support for illegal recursion check.
507         * RngNameClass.cs : fixed RngNsName ctor() (argument not passed).
508         * RngPattern.cs : fixed ParentRef.Compile() (was treated same as Ref).
509
510 2003-05-05  Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
511
512         * RelaxngReader.cs : ReadExternalRef() hadn't resolved base uri.
513
514 2003-04-29  Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
515
516         * Started.
517         * added ChangeLog, RelaxngReader.cs, RelaxngValidatingReader.cs,
518           RngGrammar.cs, RngNameClasses.cs, RngPattern.cs, RngPatternType.cs
519           and Misc.cs.
520