2004-02-16 Atsushi Enomoto <atsushi@ximian.com>
[mono.git] / mcs / class / System.XML / Mono.Xml.Xsl / ChangeLog
1 2004-02-16 Atsushi Enomoto <atsushi@ximian.com>
2
3         * XslKey.cs : Now it collects key and matching nodes at the first
4           evaluation time. After that, we can just get them from the table.
5         * Compiler.cs : Added KeyCompilationMode. It is used to prevent
6           prohibited key() usage in "match" and "use" attributes in xsl:key.
7           Modified accessibility of some classes.
8         * GenericOutputter.cs,
9           HtmlEmitter.cs,
10           TextEmitter.cs,
11           TextOutputter.cs,
12           XmlWriterEmitter.cs : made classes internal.
13         * XslOutput.cs : support line info for exception.
14         * XsltCompiledContext.cs : implemented CompareDocument() - so easily.
15
16 2004-02-13 Atsushi Enomoto <atsushi@ximian.com>
17
18         * XsltCompiledContext.cs : fixed the length of context info array.
19
20 2004-02-10 Atsushi Enomoto <atsushi@ximian.com>
21
22         * XsltCompiledContext.cs :
23           replaced EnumeratorIterator with ListIterator
24
25 2004-02-08 Atsushi Enomoto <atsushi@ximian.com>
26
27         * GenericOutputter.cs,
28           XslAttributeSet.cs,
29           XslStylesheet.cs,
30           XslTemplate.cs : tiny foreach elimination.
31
32 2004-01-16 Atsushi Enomoto <atsushi@ximian.com>
33
34         * XslOutput.cs : Reverted. default encoding should be utf-8.
35
36 2004-01-14  Jackson Harper <jackson@ximian.com>
37
38         * GenericOutputter.cs: Add constructors that do not take an
39         encoding to fix build.
40         
41 2004-01-14 Atsushi Enomoto <atsushi@ximian.com>
42
43         * XmlWriterEmitter.cs : It now uses WriteProcessingInstruction() to
44           write XML declaration. It means that output supports non document
45           entity. This fixes bug #52729.
46         * Emitter.cs, TextEmitter.cs, HtmlEmitter.cs, XmlWriterEmitter.cs :
47           modified WriteStartDocument() signature to receive Encoding.
48         * GenericOutputter.cs : 
49           - Added .ctor() which receives Encoding. (It is used for TextWriter 
50             output to get actual encoding.)
51           - Added .ctor() to take an boolean argument which indicates it is
52             variable content or not. (When variable, it does not call 
53             WriteStartDocument().)
54         * XslKey.cs,
55           XsltCompiledContext.cs : comment out WriteLine().
56         * XslOutput.cs : set default encoding utf-16.
57
58 2004-01-08  Nick Drochak <ndrochak@ieee.org>
59
60         * XsltCompiledContext.cs: Remove unused variable and unreachable code.
61
62 2003-12-26 Atsushi Enomoto <atsushi@ximian.com>
63
64         * XslDecimalFormat.cs : implemented format-number() other than number
65           grouping.
66         * XsltCompiledContext.cs : Modified XsltFormatNumber.Evaluate() to
67           catch ArgumentException which will be thrown by formatting process.
68
69 2003-12-23 Atsushi Enomoto <atsushi@ximian.com>
70
71         * ScriptCompilerInfo.cs : Use "mjs" as JScript compiler.
72
73 2003-12-20 Ben Maurer  <bmaurer@users.sourceforge.net>
74
75         * XsltCompiledContext.cs: Remove workaround now that monodoc
76         is fixed.
77
78 2003-12-20 Atsushi Enomoto <atsushi@ximian.com>
79
80         * XslStylesheet.cs : considering xsl:imports, we can't handle namespace
81           aliases at compilation time, so evaluate at the first run-time.
82
83 2003-12-18 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
84
85         * GenericOutputter.cs : support for runtime-determined output type.
86         * HtmlEmitter.cs : Fixed invalid doctype output.
87           Fixed incorrect double attribute output on non-HTML elements.
88           Improved indentation. Fixed "selected" attribute output.
89           Don't have to convert "'" to "&apos;".
90         * XmlWriterEmitter.cs : Now don't output incorrect doctype.
91           Escapes CDATA section text "]]>" to "...]]]]><![CDATA[>..." .
92         * XslStylesheet.cs, XsltCompiledContext.cs :
93           space resolution consideration for import and wildcard.
94
95 2003-12-18 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
96
97         * Compiler.cs, XslTransformProcessor.cs :
98           Use XmlValidatingReader to support id() for external stylesheets.
99         * XslKey.cs, XsltCompiledContext.cs :
100           to evaluate MatchPattern and UsePattern, SetContext() is required.
101         * XslTemplate.cs : Forgot to commit. Change is below(12/16).
102
103 2003-12-16 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
104
105         * Emitter.cs, HtmlEmitter.cs, XmlWriterEmitter.cs :
106           Added WriteWhitespace().
107         * GenericOutputter.cs, XslTemplate.cs : Call above.
108         * XslTransformProcessor.cs : Changed NodesetStack to ArrayList since
109           CurrentNode in for-each context have to be pulled at evaluation.
110
111 2003-12-16 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
112
113         * XsltCompiledContext.cs : Temporarily allow incorrectly resolved
114           function for bugzilla #52144. It should be reverted soon.
115
116 2003-12-12 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
117
118         * ScriptCompilerInfo.cs : SecurityManager.ResolvePolicy() was not 
119           implemented yet.
120         * MSMslScriptManager.cs : modified generated assembly class to be unique
121           through running AppDomain.
122         * XsltCompiledContext.cs : XsltExtensionFunction.Invoke() has to cast
123           arguments to actual argument types. Bugzilla #51450 should be fixed.
124
125 2003-12-12 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
126
127         * HtmlEmitter.cs : Fixed incorrect character entity output.
128
129 2003-12-11 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
130
131         * Added ScriptCompilerInfo.cs.
132         * MSXslScriptManager.cs : Fixed *true* author's name.
133           Implemented basic msxsl:script support.
134         * Compiler.cs : Added Evidence member.
135
136 2003-12-07 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
137
138         * Compiler.cs : Check stylesheet recursion. Check decimal-format name.
139         * GenericOutputter.cs, Outputter.cs, TextOutputter.cs :
140           Added WriteWhitespace() to assure not writing whitespaces as cdata.
141         * XslAttributeSet.cs : Error check if attribute-set contains other than
142           xsl:attribute.  Error should be XsltException.
143         * XslDecimalFormat.cs : Complete equality check.  Allow just one
144           character value for some attributes.
145         * XslStylesheet.cs : Made whitespace control setting overridable.
146           Added Version property (for the future compatibility mode).
147           Check unrecongnized top level element.
148         * XslTemplate.cs : Check priority as a number.
149         * XslTransformProcessor.cs : PushCDataState is now PushElementState, 
150           for xsl:preserve-space and xsl:strip-space support.
151         * XsltCompiledContext.cs : Implemented PreserveWhitespace() (far from
152           incomplete), PushScope and Pop
153
154 2003-12-03 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
155
156         * HtmlEmitter.cs : CloseStartElement is needed almost everywhere.
157
158 2003-12-02 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
159
160         * Compiler.cs : In FromListString(), it should use default ns,
161           not unqualified one.
162         * GenericOutputter.cs : CheckState() - attribute's Prefix should take
163           precedence.  Doctype should be written even if SYSTEM id is absent.
164           Fixed possible multiple xmlns output.
165         * HtmlEmitter.cs :
166           - Encoding output using META element.
167           - Doctype name is fixed (html).
168           - Double quotation on PUBLIC and SYSTEM missing.
169           - Fixed incorrect tag name check for IMG.
170           - '>' should not be escaped.
171         * XmlWriterEmitter.cs :
172           Added newline before doctype.  In WriteComment(), "--" and tail
173           '-' are not allowed (it escapes, while XmlWriter simply rejects).
174         * XslTransformProcessor.cs : cdata-section-elements should enclose
175           direct child tests only.   Added PreserveWhitespace() (incomplete).
176         * XsltCompiledContext.cs : Implemented PreserveWhitespace() (incomplete).
177
178 2003-11-28 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
179
180         * IdPattern.cs : This should work against multiple ids.
181
182 2003-11-27 Ben Maurer  <bmaurer@users.sourceforge.net>
183
184         * Compiler.cs
185         * MSXslScriptManager.cs
186         * XslStylesheet.cs
187         * XslTransformProcessor.cs
188         * XsltCompiledContext.cs: Some work on msxsl script.
189
190 2003-11-24 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
191
192         (in general: cdata-section-elements support, correct document() 
193         base uri handling, and so on)
194         * Compiler.cs : Use XmlSpace.Preserve to parse included stylesheet.
195           And move to document element.  Added XslNameUtil.FromListString().
196         * Emitter.cs, HtmlEmitter.cs, TextEmitter.cs XmlWriterEmitter.cs :
197           Added WriteCDataSection().
198         * Outputter.cs, GenericOutputter.cs, TextOutputter.cs :
199           Added InsideCDataSection.
200         * GenericOutputter.cs :
201           In .ctor(), WriteState should be succeeded from output XmlWriter.
202           WriteNamespaceDecl() now drops declaration identical to existing one.
203           Removed obsolete htmlEmulation.
204         * XslOutput.cs : Added CDataSectionElements support.
205         * XslStylesheet.cs : Added BaseUri, StyleDocument and PrefixInEffect().
206         * XslTransformProcessor.cs :
207           Added Output and CurrentOutputUri. TryStylesheetNamespaceOutput()
208           now considers xsl:exclude-element-prefixes on literal element.
209           Added PushCDataState() and PopCDataState().
210         * XsltCompiledContext.cs : When base uri of document() target is empty,
211           then it should use stylesheet's BaseURI, not that of current document.
212
213 2003-11-21 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
214
215         * Compiler.cs : Modified decimal-format comparison code.
216         * Outputter.cs,
217           TextOutputter.cs,
218           GenericOutputter.cs : Added WriteState. Now WriteStartDocument() will
219           be called only when required. 
220         * HtmlEmitter.cs : Improved indentation stuff.
221         * XslDecimalFormat.cs : Added incomplete implementation of 
222           CheckSameAs() and FormatNumber().
223         * XslStylesheet.cs,
224           XslTransformProcessor.cs : Changed XslStylesheet.StylesheetNamespaces
225           from StringDictionary to ArrayList of QName (to keep order).
226
227 2003-11-19 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
228
229         * XsltCompiledContext.cs : XsltGenerateId.Evaluate() should consider
230           node type (i.e. attribute and namespace). Removed extraneous Clone().
231           Fixed XsltKey.Evaluate() to use MoveToNextAttribute to iterate attrs.
232
233 2003-11-19 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
234
235         * Compiler.cs : Changed Keys from ArrayList to Hashtable.
236           XslStylesheet.cs : Added Keys support here.
237         * XslTransformProcessor.cs : Should call SetContext() to expressions
238           before evaluating current nodes.
239         * XsltCompiledContext.cs : 1) XsltDocument.GetDocument() should use
240           xsltContext. 2) XsltKey exposes KeyName, Field and NamespaceManager
241           for KeyPattern. It now uses CompiledStyle.FindKeys().
242
243 2003-11-13 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
244
245         * GenericOutputter.cs : Added HTML output support. Closer xmlns handling
246           to Xalan tests and MS.NET implementation (only for test convenience).
247         * XslOutput.cs : Indent holds string rathen than bool. Its default value
248           varies in the context. When method="html", then default is "yes".
249         * XslTransformProcessor.cs : Extension element prefixes should not 
250           be written as stylesheet namespaces.
251         * XsltCompiledContext.cs : Return type of generate-id() is string.
252           Implemented unparsed-entity-uri().
253
254 2003-11-02 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
255
256         * Compiler.cs : More complete attribute set gathering.
257           GetNamespacesToCopy() should only return Local namespaces.
258         * GenericOutputter.cs : Added support for indentation.
259           Added easy hack for html output.
260           More correct Prefix handling (considers already defined ones).
261           Namespace emmission is moved to CheckState().
262         * Emitter.cs, XmlWriterEmitter.cs, GenericOutputter.cs, Outputter.cs :
263           Added WriteFullEndElement(). (i.e. IsEmptyElement support)
264         * GenericOutputter.cs, Outputter.cs :
265           Added CanProcessAttributes property for 
266           use-attribute-sets of xsl:copy.
267         * XslStylesheet.cs : Added support for stylesheet-defined xmlns decls.
268           Added support for exclude-result-prefixes.
269         * XslTransformProcessor.cs : Added support for stylesheet-defined xmlns.
270
271 2003-10-30 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
272
273         * Compiler.cs : It is not important, but attribute order became closer
274           to MS.NET and Xalan (assuming from OASIS tests).
275
276 2003-10-30 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
277
278         * GenericOutputter.cs : Attribute wasn't overwritten its properties
279           because Attribute is struct it was let to another local variable.
280
281 2003-09-28 Ben Maurer  <bmaurer@users.sourceforge.net>
282
283         * GenericOutputter.cs: make html output a warning, because doing
284         xml will be right most of the time.
285
286 2003-09-28 Ben Maurer  <bmaurer@users.sourceforge.net>
287
288         * Debug.cs: comment out {Enter, Exit}Navigator. Haven't had bugs
289         here for a long time and it hurts thread safty and memory
290         allocation.
291
292 2003-09-21 Ben Maurer  <bmaurer@users.sourceforge.net>
293
294         * Compiler.cs: save the parser (will reduce memory allocation when
295         Jackson's jay patch is committed).
296
297 2003-09-20 Ben Maurer  <bmaurer@users.sourceforge.net>
298
299         * Attribute.cs: Change to struct. Remove QName class.
300         * GenericOutputter.cs: use an Attribute [] rather than an
301         ArrayList. Allows us not to allocate Attributes, which is great
302         for speed. Roll our own allocation.
303
304 2003-09-20 Ben Maurer  <bmaurer@users.sourceforge.net>
305
306         * Compiler.cs: add GetNsm to main class as well.
307
308 2003-09-20 Ben Maurer  <bmaurer@users.sourceforge.net>
309
310         * Compiler.cs (ParseAvtAttribute): Get the attribue using our
311         internal version so we get null if the attr doesnt exist.
312
313 2003-09-17 Ben Maurer  <bmaurer@users.sourceforge.net>
314
315         * Compiler.cs (IStaticXsltContext.TryGetVariable): handle the case
316         where curVarScope == null
317
318 2003-09-16 Ben Maurer  <bmaurer@users.sourceforge.net>
319
320         * Compiler.cs: 
321         - Better handling of empty attributes (vs not being specified)
322         - Bug in handling #default
323         
324 2003-09-15 Ben Maurer  <bmaurer@users.sourceforge.net>
325
326         * Compiler.cs: Off by one when parsing localname of QName 
327         * XslAttributeSet.cs: must evaluate used attr sets *BEFORE*
328         children (so that they get overriden)
329
330 2003-09-15 Ben Maurer  <bmaurer@users.sourceforge.net>
331
332         * GenericOutputter.cs: Output attributes in order recieved; not
333         required by spec, but useful for running test cases.
334
335 2003-09-14 Oleg Tkachenko <oleg@tkachenko.com>
336
337         * GenericOutputter.cs - fix bug with outputting state.
338         * Emitter.cs, TextEmitter.cs, XmlWriterEmitter.cs, Outputter.cs, 
339         * TextOutputter.cs - get rid of WriteStartAttribute/WriteEndAttribute.  
340
341 2003-09-13 Ben Maurer  <bmaurer@users.sourceforge.net>
342
343         * Compiler.cs, XslKey.cs, XslTransformProcessor.cs: dont clone
344         exprs on use, pass to nav.
345
346 2003-09-13 Ben Maurer  <bmaurer@users.sourceforge.net>
347
348         * Compiler.cs: pass satic context to Pattern ctor.
349
350 2003-08-30 Oleg Tkachenko <oleg@tkachenko.com>
351
352         * New files: 
353         GenericOutputter.cs - generic Outputter implementation,
354         Attribute.cs - represents outputted attribute,
355         Emitter.cs - abstract output emitter,
356         TextEmitter.cs - text emitter,
357         XmlWriterEmitter.cs - emitter to XmlWriter.
358         * Checking of duplicating attributes is done in GenericOutputter.
359         * Namespace outputting logic is implemented in GenericOutputter.
360         * Outputter.cs: Writing namespace declarations is delegated to 
361         derived classes (GenericOutputter).
362         * XslOutput.cs: standalone flag is now 3-value enum (NONE, YES, NO).                    
363          
364 2003-08-21 Ben Maurer  <bmaurer@users.sourceforge.net>
365
366         * XslTransformProcessor.cs: evaluate variables at beginning
367         when / is current node.
368
369 2003-08-21 Ben Maurer  <bmaurer@users.sourceforge.net>
370
371         * Compiler.cs, XsltCompiledContext.cs, XslTransformProcessorcs:
372         Fix up namespace handeling
373
374 2003-08-20 Ben Maurer  <bmaurer@users.sourceforge.net>
375
376         * Compiler.cs, XslStylesheet.cs, XsltCompiledContext.cs: Stubs for
377         format-number.
378         * XslDecimalFormat.cs: Stub for decimal-format.
379
380 2003-08-20 Ben Maurer  <bmaurer@users.sourceforge.net>
381
382         * TextOutputter.cs: Add option to ignore element content (Oleg).
383
384 2003-08-19 Ben Maurer  <bmaurer@users.sourceforge.net>
385
386         * Compiler.cs: Really give null for blank avt's
387
388 2003-08-19 Ben Maurer  <bmaurer@users.sourceforge.net>
389
390         * Compiler.cs: Fixed lre/lre04.
391
392 2003-08-19 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
393
394         * Compiler.cs : Fixed XslNameUtil.FromString() so that unprefixed name
395           won't have default namespace. See http://www.w3.org/TR/xslt#qname
396
397 2003-08-19 Ben Maurer  <bmaurer@users.sourceforge.net>
398
399         * XslTransformProcessor.cs: add support for resolving documents.
400         * XsltCompiledContext: add support for document () function.
401
402 2003-08-19 Ben Maurer  <bmaurer@users.sourceforge.net>
403
404         * Outputter.cs, TextOutputter.cs, XmlOutputter.cs: Implement some
405         of the abstract methods in Outputter, making them call other
406         functions with default values, remove impl's in derived classes.
407
408 2003-08-19 Ben Maurer  <bmaurer@users.sourceforge.net>
409
410         * Outputter.cs: s/Close/Done
411         * TextOutputter.cs, XmlOutputter.cs: Flush, don't close the backing.
412         * XslTransformProcessor.cs: Flush output when popping, pop at end.
413
414 2003-08-19 Ben Maurer  <bmaurer@users.sourceforge.net>
415
416         * Outputter.cs: Add support for namespaces.
417
418 2003-08-19 Ben Maurer  <bmaurer@users.sourceforge.net>
419
420         * Compiler.cs, XslOutput.cs, XslStylesheet.cs,
421         XslTransformProcessor.cs: move output logic from XslStylesheet to
422         Compiler.
423
424 2003-08-18 Ben Maurer  <bmaurer@users.sourceforge.net>
425
426         * XslOutput.cs: add support for encoding.
427
428 2003-08-18 Ben Maurer  <bmaurer@users.sourceforge.net>
429
430         * *.cs: Support for xsl:output. (Oleg)
431
432 2003-08-17 Ben Maurer  <bmaurer@users.sourceforge.net>
433
434         * Compiler.cs: handle extension and excluded namespaces.
435
436 2003-08-17 Ben Maurer  <bmaurer@users.sourceforge.net>
437
438         * XsltCompiledContext.cs, Compiler.cs: copy the XPathNavigator
439         from the stylesheet for correct namespace resolution.
440
441 2003-08-14 Atsushi Enomoto <ginga@kit.hi-ho.ne.jp>
442
443         * Compiler.cs : 1) Changed public .ctor() to receive Evidence argument 
444           introduced in .NET 1.1. 2) XmlResolver object is required for 'res'.
445
446 2003-08-07 Ben Maurer  <bmaurer@users.sourceforge.net>
447
448         * XslTransformProcessor.cs: Add a table to detect when an object
449         is busy.
450         * XslAttributeSet.cs: Use the above table. Dont throw nullref
451         exception when no use-attribute-sets are specified.
452
453 2003-08-04 Ben Maurer  <bmaurer@users.sourceforge.net>
454
455         * Compiler.cs: Add support for boolean attributes (yes/no).
456
457 2003-08-04 Ben Maurer  <bmaurer@users.sourceforge.net>
458
459         * Compiler.cs: Add method LocalNameOf, to get the local name of a
460         string.
461         * XslTransformProcessor.cs: Support for setting the XmlResolver.
462
463 2003-08-01 Ben Maurer  <bmaurer@users.sourceforge.net>
464
465         * Compiler.cs, XslAttributeSet.cs: Handle attribute set merging
466
467 2003-08-01 Ben Maurer  <bmaurer@users.sourceforge.net>
468
469         * XslTransformProcessor.cs: Add EvaluateNumber method.
470
471 2003-07-31 Ben Maurer  <bmaurer@users.sourceforge.net>
472
473         * XsltCompiledContext.cs: Implement more functions.
474
475 2003-07-31 Ben Maurer  <bmaurer@users.sourceforge.net>
476
477         * Compiler.cs: Add support for key, utility function to parse
478         QName's from the XsltContext. Store keys in the CompiledStyle, not
479         in the Stylesheet.
480         * XslKey.cs: Real implementation
481         * XslStylesheet.cs: Move the keys to CompiledStyle.
482         * XsltCompiledContext.cs: Implement the key function
483
484 2003-07-31 Ben Maurer  <bmaurer@users.sourceforge.net>
485
486         * XsltCompiledContext.cs: Hmm, maybe I should actually *enable*
487         the functions ;-). Also wrote current ().
488
489 2003-07-31 Ben Maurer  <bmaurer@users.sourceforge.net>
490
491         * XsltCompiledContext.cs: Remove excess conversion stuff. It is
492         done in XPath. Add stubs for XSLT functions.
493
494 2003-07-31 Ben Maurer  <bmaurer@users.sourceforge.net>
495
496         * Compiler.cs: To resolve a variable you now need to pass the
497         processor, so that it can be passed to IsEvaluated. A local will
498         only be resolved if it has already been evaluated.
499         * XsltCompiledContext.cs: Pass along the processor.
500         
501 2003-07-30 Ben Maurer  <bmaurer@users.sourceforge.net>
502
503         * Compiler.cs, XslTemplate.cs, XslTransformProcessor.cs: Store
504         variable values in the XslTransformProcessor.
505         * XsltCompiledContext.cs: If the scope is null, don't look there!
506         * Debug.cs: New method Assert
507
508 2003-07-30 Ben Maurer  <bmaurer@users.sourceforge.net>
509
510         * Compiler.cs, XsltCompiledContext.cs: Remove verbose messages
511         * XslTransformProcessor.cs: Use strongtyped evaluation, using new
512         internal methods in XPathNavigator. Remove verbose debugging messages.
513
514 2003-07-29 Ben Maurer  <bmaurer@users.sourceforge.net>
515
516         * Initial Checkin
517