You can subscribe to this list here.
2004 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(174) |
Nov
(85) |
Dec
(14) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2005 |
Jan
(56) |
Feb
|
Mar
|
Apr
|
May
(4) |
Jun
(1) |
Jul
(132) |
Aug
(5) |
Sep
|
Oct
(314) |
Nov
(133) |
Dec
(18) |
2006 |
Jan
(6) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Oleg T. <he...@us...> - 2005-10-30 12:02:41
|
Update of /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/tests/EXSLT/DatesAndTimes In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8329/v2/test/ExsltTest/tests/EXSLT/DatesAndTimes Modified Files: duration.xslt Log Message: Index: duration.xslt =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/tests/EXSLT/DatesAndTimes/duration.xslt,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- duration.xslt 16 Oct 2005 20:13:09 -0000 1.1 +++ duration.xslt 30 Oct 2005 12:02:31 -0000 1.2 @@ -21,10 +21,7 @@ </test5> <test6> <xsl:value-of select="date:duration(-7776000)"/> - </test6> - <test7> - <xsl:value-of select="date:duration(11 div 0)"/> - </test7> + </test6> <test8> <xsl:value-of select="date:duration(0)"/> </test8> |
From: Oleg T. <he...@us...> - 2005-10-30 12:02:41
|
Update of /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/tests/GotDotNet/Dynamic In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8329/v2/test/ExsltTest/tests/GotDotNet/Dynamic Modified Files: evaluate.xslt Log Message: Index: evaluate.xslt =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/tests/GotDotNet/Dynamic/evaluate.xslt,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- evaluate.xslt 16 Oct 2005 20:13:10 -0000 1.1 +++ evaluate.xslt 30 Oct 2005 12:02:32 -0000 1.2 @@ -34,10 +34,7 @@ <test10> <xsl:variable name="namespaces">xmlns:foo="http://orders.com" xmlns:bar='http://bar.com/'</xsl:variable> <xsl:copy-of select="dyn2:evaluate(., /data/path7, $namespaces)"/> - </test10> - <test11> - <xsl:copy-of select="dyn2:evaluate(., /data/path7, '')"/> - </test11> + </test10> <test12> <xsl:variable name="namespaces"> xmlns:bar='http://bar.com/" |
From: Oleg T. <he...@us...> - 2005-10-30 12:01:17
|
Update of /cvsroot/mvp-xml/Common/v2/src/XPath In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7667/v2/src/XPath Modified Files: EmptyXPathNodeIterator.cs Log Message: Index: EmptyXPathNodeIterator.cs =================================================================== RCS file: /cvsroot/mvp-xml/Common/v2/src/XPath/EmptyXPathNodeIterator.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- EmptyXPathNodeIterator.cs 29 Oct 2005 21:13:10 -0000 1.1 +++ EmptyXPathNodeIterator.cs 30 Oct 2005 12:01:04 -0000 1.2 @@ -13,6 +13,9 @@ /// </summary> public class EmptyXPathNodeIterator : XPathNodeIterator { + /// <summary> + /// EmptyXPathNodeIterator instance. + /// </summary> public static EmptyXPathNodeIterator Instance = new EmptyXPathNodeIterator(); /// <summary> |
From: Oleg T. <he...@us...> - 2005-10-30 12:01:17
|
Update of /cvsroot/mvp-xml/Common/v2/src/Serialization In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7667/v2/src/Serialization Modified Files: PerfCounterManager.cs Log Message: Index: PerfCounterManager.cs =================================================================== RCS file: /cvsroot/mvp-xml/Common/v2/src/Serialization/PerfCounterManager.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- PerfCounterManager.cs 28 Oct 2005 20:07:56 -0000 1.1 +++ PerfCounterManager.cs 30 Oct 2005 12:01:04 -0000 1.2 @@ -43,7 +43,8 @@ counters.Add(GetCacheHitCounterData()); counters.Add(GetCachedInstancesCounterData()); PerformanceCounterCategory.Create( - CATEGORY, CATEGORY_DESCRIPTION, counters); + CATEGORY, CATEGORY_DESCRIPTION, PerformanceCounterCategoryType.SingleInstance, + counters); } } @@ -85,7 +86,7 @@ private string GetCounterInstanceName( int index ) { string fileName = Environment.CommandLine.Split(' ')[0]; - foreach( char c in System.IO.Path.InvalidPathChars ) + foreach( char c in System.IO.Path.GetInvalidPathChars() ) { fileName = fileName.Replace( c, '%' ); } |
From: Oleg T. <he...@us...> - 2005-10-29 21:14:45
|
Update of /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Sets In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23054/v2/test/ExsltTest/results/EXSLT/Sets Modified Files: difference.xml distinct.xml intersection.xml leading.xml trailing.xml Log Message: Index: distinct.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Sets/distinct.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- distinct.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ distinct.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -10,6 +10,5 @@ <foo>4</foo> <foo bar="baz">5</foo> </test2> - <test3> - </test3> + <test3 /> </out> \ No newline at end of file Index: difference.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Sets/difference.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- difference.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ difference.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -3,8 +3,6 @@ <foo>2</foo> <foo>4</foo> </test1> - <test2> - </test2> - <test3> - </test3> + <test2 /> + <test3 /> </out> \ No newline at end of file Index: leading.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Sets/leading.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- leading.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ leading.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -3,8 +3,7 @@ <foo bar="baz">1</foo> <foo>2</foo> </test1> - <test2> - </test2> + <test2 /> <test3> <foo bar="baz">1</foo> <foo>2</foo> @@ -12,6 +11,5 @@ <foo>4</foo> <foo bar="baz">5</foo> </test3> - <test4> - </test4> + <test4 /> </out> \ No newline at end of file Index: trailing.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Sets/trailing.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- trailing.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ trailing.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -17,6 +17,5 @@ <foo>4</foo> <foo bar="baz">5</foo> </test3> - <test4> - </test4> + <test4 /> </out> \ No newline at end of file Index: intersection.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Sets/intersection.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- intersection.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ intersection.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -11,6 +11,5 @@ <foo>4</foo> <foo bar="baz">5</foo> </test2> - <test3> - </test3> + <test3 /> </out> \ No newline at end of file |
Update of /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Math In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23054/v2/test/ExsltTest/results/EXSLT/Math Modified Files: acos.xml asin.xml atan.xml atan2.xml constant.xml cos.xml exp.xml log.xml sin.xml tan.xml Log Message: Index: atan2.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Math/atan2.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- atan2.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ atan2.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -1,8 +1,8 @@ <out> - <test1>0.62024948598282148</test1> + <test1>0.6202494859828215</test1> <test2>-1.9890206563741257</test2> <test3>NaN</test3> - <test4>1.5707963267948966</test4> - <test5>-1.5707963267948966</test5> + <test4>1.5707963267948965</test4> + <test5>-1.5707963267948965</test5> <test6>0</test6> </out> \ No newline at end of file Index: atan.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Math/atan.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- atan.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ atan.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -1,8 +1,8 @@ <out> - <test1>0.46364760900080609</test1> - <test2>-0.73281510178650655</test2> + <test1>0.4636476090008061</test1> + <test2>-0.7328151017865065</test2> <test3>NaN</test3> - <test4>1.5707963267948966</test4> - <test5>-1.5707963267948966</test5> + <test4>1.5707963267948965</test4> + <test5>-1.5707963267948965</test5> <test6>0</test6> </out> \ No newline at end of file Index: acos.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Math/acos.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- acos.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ acos.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -1,8 +1,8 @@ <out> <test1>1.0471975511965976</test1> - <test2>2.6905658417935308</test2> + <test2>2.6905658417935307</test2> <test3>NaN</test3> <test4>NaN</test4> <test5>NaN</test5> - <test6>1.5707963267948966</test6> + <test6>1.5707963267948965</test6> </out> \ No newline at end of file Index: sin.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Math/sin.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- sin.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ sin.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -1,6 +1,6 @@ <out> - <test1>0.95891572341430653</test1> - <test2>0.78879828597541646</test2> + <test1>0.9589157234143065</test1> + <test2>0.7887982859754165</test2> <test3>NaN</test3> <test4>NaN</test4> <test5>NaN</test5> Index: exp.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Math/exp.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- exp.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ exp.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -1,8 +1,8 @@ <out> - <test1>10686474581524.451</test1> - <test2>2.7894680928689272E-10</test2> + <test1>10686474581524.462</test1> + <test2>0.00000000027894680928689246</test2> <test3>NaN</test3> <test4>Infinity</test4> <test5>0</test5> - <test6>12.182493960703475</test6> + <test6>12.182493960703473</test6> </out> \ No newline at end of file Index: log.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Math/log.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- log.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ log.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -1,6 +1,6 @@ <out> <test1>NaN</test1> - <test2>3.1311369105601941</test2> + <test2>3.131136910560194</test2> <test3>NaN</test3> <test4>Infinity</test4> <test5>NaN</test5> Index: tan.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Math/tan.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- tan.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ tan.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -1,6 +1,6 @@ <out> - <test1>-3.3801404139609579</test1> - <test2>-1.2833247024302064</test2> + <test1>-3.380140413960958</test1> + <test2>-1.2833247024302063</test2> <test3>NaN</test3> <test4>NaN</test4> <test5>NaN</test5> Index: cos.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Math/cos.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- cos.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ cos.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -1,6 +1,6 @@ <out> - <test1>-0.28369109148652732</test1> - <test2>-0.61465214881446983</test2> + <test1>-0.2836910914865273</test1> + <test2>-0.6146521488144698</test2> <test3>NaN</test3> <test4>NaN</test4> <test5>NaN</test5> Index: constant.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Math/constant.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- constant.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ constant.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -1,12 +1,12 @@ <out> - <test1>3.1415926535897931</test1> - <test2>2.7182818284590451</test2> - <test3>1.4142135623730952</test3> - <test4>0.69314718055994529</test4> - <test5>2.3025850929940459</test5> - <test6>1.4426950408889634</test6> - <test7>0.70710678118654757</test7> - <test8>3.1415926535897931</test8> - <test9>3.1415926535897931</test9> - <test10>3.1415926535897931</test10> + <test1>3.141592653589793</test1> + <test2>2.718281828459045</test2> + <test3>1.4142135623730951</test3> + <test4>0.6931471805599453</test4> + <test5>2.302585092994046</test5> + <test6>1.4426950408889633</test6> + <test7>0.7071067811865476</test7> + <test8>3.141592653589793</test8> + <test9>3.141592653589793</test9> + <test10>3.141592653589793</test10> </out> \ No newline at end of file Index: asin.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Math/asin.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- asin.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ asin.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -1,5 +1,5 @@ <out> - <test1>0.52359877559829893</test1> + <test1>0.5235987755982989</test1> <test2>-1.1197695149986342</test2> <test3>NaN</test3> <test4>NaN</test4> |
From: Oleg T. <he...@us...> - 2005-10-29 21:14:45
|
Update of /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/tests/EXSLT/Math In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23054/v2/test/ExsltTest/tests/EXSLT/Math Modified Files: acos.xslt Log Message: Index: acos.xslt =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/tests/EXSLT/Math/acos.xslt,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- acos.xslt 16 Oct 2005 20:13:09 -0000 1.1 +++ acos.xslt 29 Oct 2005 21:14:36 -0000 1.2 @@ -4,26 +4,25 @@ <xsl:output indent="yes" omit-xml-declaration="yes"/> <xsl:template match="/"> <out> - <test1> + <test1> <xsl:value-of select="math:acos(0.5)"/> </test1> - <test2> + <test2> <xsl:value-of select="math:acos(-0.9)"/> </test2> - <test3> + <test3> <xsl:value-of select="math:acos(/data/bad-data)"/> - </test3> - <test4> + </test3> + <test4> <xsl:value-of select="math:acos(22 div 0)"/> </test4> - <test5> + <test5> <xsl:value-of select="math:acos(-22 div 0)"/> </test5> - <test6> + <test6> <xsl:value-of select="math:acos(0)"/> </test6> </out> </xsl:template> </xsl:stylesheet> - \ No newline at end of file |
From: Oleg T. <he...@us...> - 2005-10-29 21:14:45
|
Update of /cvsroot/mvp-xml/EXSLT/v2/test/ExsltXPathTest In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23054/v2/test/ExsltXPathTest Modified Files: ExsltXPathTest.csproj Log Message: Index: ExsltXPathTest.csproj =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltXPathTest/ExsltXPathTest.csproj,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- ExsltXPathTest.csproj 16 Oct 2005 20:13:10 -0000 1.1 +++ ExsltXPathTest.csproj 29 Oct 2005 21:14:36 -0000 1.2 @@ -1,7 +1,7 @@ <Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <PropertyGroup> <ProjectType>Local</ProjectType> - <ProductVersion>8.0.50215</ProductVersion> + <ProductVersion>8.0.50727</ProductVersion> <SchemaVersion>2.0</SchemaVersion> <ProjectGuid>{705AA213-1D02-4CD2-9ED5-A7D9668C714D}</ProjectGuid> <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> @@ -69,8 +69,8 @@ <WarningLevel>4</WarningLevel> </PropertyGroup> <ItemGroup> - <Reference Include="Mvp.Xml.Exslt"> - <Name>Mvp.Xml.Exslt</Name> + <Reference Include="Mvp.Xml.Exslt, Version=2.0.2128.40301, Culture=neutral, processorArchitecture=MSIL"> + <SpecificVersion>False</SpecificVersion> <HintPath>..\..\src\Exslt\Mvp.Xml.Exslt.dll</HintPath> </Reference> <Reference Include="System"> |
From: Oleg T. <he...@us...> - 2005-10-29 21:14:44
|
Update of /cvsroot/mvp-xml/EXSLT/v2/src/Exslt In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23054/v2/src/Exslt Modified Files: AssemblyInfo.cs Exslt.csproj ExsltContext.cs ExsltDatesAndTimes.cs ExsltMath.cs ExsltNamespaces.cs ExsltSets.cs ExsltTransform.cs GDNSets.cs Makefile Removed Files: ExsltNodeList.cs Log Message: Index: ExsltNamespaces.cs =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/src/Exslt/ExsltNamespaces.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- ExsltNamespaces.cs 16 Oct 2005 20:07:08 -0000 1.1 +++ ExsltNamespaces.cs 29 Oct 2005 21:14:35 -0000 1.2 @@ -2,7 +2,7 @@ /// <summary> /// Exslt (and other) namespaces constants. /// </summary> - public class ExsltNamespaces { + public static class ExsltNamespaces { public const string DatesAndTimes = "http://exslt.org/dates-and-times"; public const string Math = "http://exslt.org/math"; public const string Random = "http://exslt.org/random"; Index: GDNSets.cs =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/src/Exslt/GDNSets.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- GDNSets.cs 16 Oct 2005 20:07:08 -0000 1.1 +++ GDNSets.cs 29 Oct 2005 21:14:35 -0000 1.2 @@ -1,9 +1,12 @@ #region using using System; -using System.Collections; +using System.Collections.Generic; using System.Xml.XPath; using System.Xml; +using System.Web.UI; + +using Mvp.Xml.Common.XPath; #endregion @@ -29,8 +32,8 @@ if(nodeset1.Count > 125 || nodeset2.Count > 125) return subset2(nodeset1, nodeset2); //else - ExsltNodeList nodelist1 = new ExsltNodeList(nodeset1, true); - ExsltNodeList nodelist2 = new ExsltNodeList(nodeset2, true); + XPathNavigatorIterator nodelist1 = new XPathNavigatorIterator(nodeset1, true); + XPathNavigatorIterator nodelist2 = new XPathNavigatorIterator(nodeset2, true); foreach(XPathNavigator nav in nodelist1) { @@ -38,9 +41,7 @@ { return false; } - } - - + } return true; } @@ -59,16 +60,15 @@ /// <remarks>THIS FUNCTION IS NOT PART OF EXSLT!!!</remarks> public bool subset2(XPathNodeIterator nodeset1, XPathNodeIterator nodeset2) { - ArrayList arDocs = new ArrayList(); + List<Pair> arDocs = new List<Pair>(); - ArrayList arNodes2 = new ArrayList(nodeset2.Count); + List<XPathNavigator> arNodes2 = new List<XPathNavigator>(nodeset2.Count); while(nodeset2.MoveNext()) { arNodes2.Add(nodeset2.Current.Clone()); } - auxEXSLT.findDocs(arNodes2, arDocs); while(nodeset1.MoveNext()) --- ExsltNodeList.cs DELETED --- Index: Makefile =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/src/Exslt/Makefile,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- Makefile 16 Oct 2005 20:07:08 -0000 1.1 +++ Makefile 29 Oct 2005 21:14:35 -0000 1.2 @@ -1,7 +1,7 @@ all: @echo off @echo ########### Building Exslt library... - csc /out:Mvp.Xml.Exslt.dll /target:library *.cs MultiOutput\*.cs /debug- /optimize+ + csc /out:Mvp.Xml.Exslt.dll /target:library *.cs MultiOutput\*.cs /debug- /optimize+ /r:Mvp.Xml.Common.dll nmake rename-methods rename-methods: Index: ExsltDatesAndTimes.cs =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/src/Exslt/ExsltDatesAndTimes.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- ExsltDatesAndTimes.cs 16 Oct 2005 20:07:08 -0000 1.1 +++ ExsltDatesAndTimes.cs 29 Oct 2005 21:14:35 -0000 1.2 @@ -1832,7 +1832,7 @@ public string parseDate(string d, string format){ try{ DateTime date = DateTime.ParseExact(d, format, CultureInfo.CurrentCulture); - return XmlConvert.ToString(date); + return XmlConvert.ToString(date, XmlDateTimeSerializationMode.RoundtripKind); }catch(FormatException){ return ""; } Index: AssemblyInfo.cs =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/src/Exslt/AssemblyInfo.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- AssemblyInfo.cs 16 Oct 2005 20:07:08 -0000 1.1 +++ AssemblyInfo.cs 29 Oct 2005 21:14:35 -0000 1.2 @@ -11,12 +11,6 @@ // [assembly: AssemblyTitle("Mvp.Xml.Exslt")] [assembly: AssemblyDescription("MVP XML Library - EXSLT.NET Module")] -[assembly: AssemblyConfiguration("")] -[assembly: AssemblyCompany("")] -[assembly: AssemblyProduct("")] -[assembly: AssemblyCopyright("")] -[assembly: AssemblyTrademark("")] -[assembly: AssemblyCulture("")] [assembly: ComVisible(false)] [assembly: CLSCompliant(true)] @@ -34,32 +28,3 @@ [assembly: AssemblyVersion("2.0.*")] -// -// In order to sign your assembly you must specify a key to use. Refer to the -// Microsoft .NET Framework documentation for more information on assembly signing. -// -// Use the attributes below to control which key is used for signing. -// -// Notes: -// (*) If no key is specified, the assembly is not signed. -// (*) KeyName refers to a key that has been installed in the Crypto Service -// Provider (CSP) on your machine. KeyFile refers to a file which contains -// a key. -// (*) If the KeyFile and the KeyName values are both specified, the -// following processing occurs: -// (1) If the KeyName can be found in the CSP, that key is used. -// (2) If the KeyName does not exist and the KeyFile does exist, the key -// in the KeyFile is installed into the CSP and used. -// (*) In order to create a KeyFile, you can use the sn.exe (Strong Name) utility. -// When specifying the KeyFile, the location of the KeyFile should be -// relative to the project output directory which is -// %Project Directory%\obj\<configuration>. For example, if your KeyFile is -// located in the project directory, you would specify the AssemblyKeyFile -// attribute as [assembly: AssemblyKeyFile("..\\..\\mykey.snk")] -// (*) Delay Signing is an advanced option - see the Microsoft .NET Framework -// documentation for more information on this. -// -[assembly: AssemblyDelaySign(false)] -//Signed in custom build - see Makefile -//[assembly: AssemblyKeyFile("exslt.snk")] -[assembly: AssemblyKeyName("")] Index: ExsltTransform.cs =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/src/Exslt/ExsltTransform.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- ExsltTransform.cs 16 Oct 2005 20:07:08 -0000 1.1 +++ ExsltTransform.cs 29 Oct 2005 21:14:35 -0000 1.2 @@ -4,133 +4,134 @@ using System.Xml.Xsl; using System.Xml; using System.Xml.XPath; -using System.IO; +using System.IO; using System.Text; +using System.CodeDom.Compiler; #endregion namespace Mvp.Xml.Exslt { - /// <summary> - /// Enumeration used to indicate an EXSLT function namespace. - /// </summary> - [Flags] - public enum ExsltFunctionNamespace{ - None = 0, - Common = 1, - DatesAndTimes = 2, - Math = 4, - RegularExpressions = 8, - Sets = 16, - Strings = 32, - GDNDatesAndTimes = 64, - GDNSets = 128, - GDNMath = 256, - GDNRegularExpressions = 512, - GDNStrings = 1024, - Random = 2048, - GDNDynamic = 4096, - AllExslt = Common | DatesAndTimes | Math | Random | RegularExpressions | Sets | Strings, - All = Common | DatesAndTimes | Math | Random | RegularExpressions | Sets | Strings | - GDNDatesAndTimes | GDNSets | GDNMath | GDNRegularExpressions | GDNStrings | GDNDynamic - } - - /// <summary> - /// Transforms XML data using an XSLT stylesheet. Supports a number of EXSLT as - /// defined at http://www.exslt.org - /// </summary> - /// <remarks> - /// XslTransform supports the XSLT 1.0 syntax. The XSLT stylesheet must use the - /// namespace http://www.w3.org/1999/XSL/Transform. Additional arguments can also be - /// added to the stylesheet using the XsltArgumentList class. - /// This class contains input parameters for the stylesheet and extension objects which can be called from the stylesheet. - /// This class also recognizes functions from the following namespaces - /// * http://exslt.org/common - /// * http://exslt.org/dates-and-times - /// * http://exslt.org/math - /// * http://exslt.org/random - /// * http://exslt.org/regular-expressions - /// * http://exslt.org/sets - /// * http://exslt.org/strings - /// * http://gotdotnet.com/exslt/dates-and-times - /// * http://gotdotnet.com/exslt/math - /// * http://gotdotnet.com/exslt/regular-expressions - /// * http://gotdotnet.com/exslt/sets - /// * http://gotdotnet.com/exslt/strings - /// * http://gotdotnet.com/exslt/dynamic - /// </remarks> - public class ExsltTransform - { + /// <summary> + /// Enumeration used to indicate an EXSLT function namespace. + /// </summary> + [Flags] + public enum ExsltFunctionNamespace + { + None = 0, + DatesAndTimes = 1, + Math = 2, + RegularExpressions = 4, + Sets = 8, + Strings = 16, + GDNDatesAndTimes = 32, + GDNSets = 64, + GDNMath = 128, + GDNRegularExpressions = 256, + GDNStrings = 512, + Random = 1024, + GDNDynamic = 2056, + AllExslt = DatesAndTimes | Math | Random | RegularExpressions | Sets | Strings, + All = DatesAndTimes | Math | Random | RegularExpressions | Sets | Strings | + GDNDatesAndTimes | GDNSets | GDNMath | GDNRegularExpressions | GDNStrings | GDNDynamic + } - #region Private Fields and Properties - /// <summary> - /// Sync object. + /// Transforms XML data using an XSLT stylesheet. Supports a number of EXSLT as + /// defined at http://www.exslt.org /// </summary> - private object sync = new object(); + /// <remarks> + /// XslCompiledTransform supports the XSLT 1.0 syntax. The XSLT stylesheet must use the + /// namespace http://www.w3.org/1999/XSL/Transform. Additional arguments can also be + /// added to the stylesheet using the XsltArgumentList class. + /// This class contains input parameters for the stylesheet and extension objects which can be called from the stylesheet. + /// This class also recognizes functions from the following namespaces + /// * http://exslt.org/common + /// * http://exslt.org/dates-and-times + /// * http://exslt.org/math + /// * http://exslt.org/random + /// * http://exslt.org/regular-expressions + /// * http://exslt.org/sets + /// * http://exslt.org/strings + /// * http://gotdotnet.com/exslt/dates-and-times + /// * http://gotdotnet.com/exslt/math + /// * http://gotdotnet.com/exslt/regular-expressions + /// * http://gotdotnet.com/exslt/sets + /// * http://gotdotnet.com/exslt/strings + /// * http://gotdotnet.com/exslt/dynamic + /// </remarks> + public class ExsltTransform + { - /// <summary> - /// The XslTransform object wrapped by this class. - /// </summary> - private XslCompiledTransform xslTransform; - - /// <summary> - /// Bitwise enumeration used to specify which EXSLT functions should be accessible to - /// the ExsltTransform object. The default value is ExsltFunctionNamespace.All - /// </summary> - private ExsltFunctionNamespace _supportedFunctions = ExsltFunctionNamespace.All; + #region Private Fields and Properties - /// <summary> - /// Extension object which implements the functions in the http://exslt.org/math namespace - /// </summary> - private ExsltMath exsltMath = new ExsltMath(); + /// <summary> + /// Sync object. + /// </summary> + private object sync = new object(); - /// <summary> - /// Extension object which implements the functions in the http://exslt.org/random namespace - /// </summary> - private ExsltRandom exsltRandom = new ExsltRandom(); + /// <summary> + /// The XslTransform object wrapped by this class. + /// </summary> + private XslCompiledTransform xslTransform; - /// <summary> - /// Extension object which implements the functions in the http://exslt.org/dates-and-times namespace - /// </summary> - private ExsltDatesAndTimes exsltDatesAndTimes = new ExsltDatesAndTimes(); + /// <summary> + /// Bitwise enumeration used to specify which EXSLT functions should be accessible to + /// the ExsltTransform object. The default value is ExsltFunctionNamespace.All + /// </summary> + private ExsltFunctionNamespace _supportedFunctions = ExsltFunctionNamespace.All; - /// <summary> - /// Extension object which implements the functions in the http://exslt.org/regular-expressions namespace - /// </summary> - private ExsltRegularExpressions exsltRegularExpressions = new ExsltRegularExpressions(); + /// <summary> + /// Extension object which implements the functions in the http://exslt.org/math namespace + /// </summary> + private ExsltMath exsltMath = new ExsltMath(); - /// <summary> - /// Extension object which implements the functions in the http://exslt.org/strings namespace - /// </summary> - private ExsltStrings exsltStrings = new ExsltStrings(); + /// <summary> + /// Extension object which implements the functions in the http://exslt.org/random namespace + /// </summary> + private ExsltRandom exsltRandom = new ExsltRandom(); - /// <summary> - /// Extension object which implements the functions in the http://exslt.org/sets namespace - /// </summary> - private ExsltSets exsltSets = new ExsltSets(); + /// <summary> + /// Extension object which implements the functions in the http://exslt.org/dates-and-times namespace + /// </summary> + private ExsltDatesAndTimes exsltDatesAndTimes = new ExsltDatesAndTimes(); + + /// <summary> + /// Extension object which implements the functions in the http://exslt.org/regular-expressions namespace + /// </summary> + private ExsltRegularExpressions exsltRegularExpressions = new ExsltRegularExpressions(); + + /// <summary> + /// Extension object which implements the functions in the http://exslt.org/strings namespace + /// </summary> + private ExsltStrings exsltStrings = new ExsltStrings(); + + /// <summary> + /// Extension object which implements the functions in the http://exslt.org/sets namespace + /// </summary> + private ExsltSets exsltSets = new ExsltSets(); /// <summary> /// Extension object which implements the functions in the http://gotdotnet.com/exslt/dates-and-times namespace /// </summary> - private GDNDatesAndTimes gdnDatesAndTimes = new GDNDatesAndTimes(); - + private GDNDatesAndTimes gdnDatesAndTimes = new GDNDatesAndTimes(); + /// <summary> /// Extension object which implements the functions in the http://gotdotnet.com/exslt/regular-expressions namespace /// </summary> private GDNRegularExpressions gdnRegularExpressions = new GDNRegularExpressions(); - + /// <summary> /// Extension object which implements the functions in the http://gotdotnet.com/exslt/math namespace /// </summary> - private GDNMath gdnMath = new GDNMath(); - + private GDNMath gdnMath = new GDNMath(); + /// <summary> /// Extension object which implements the functions in the http://gotdotnet.com/exslt/sets namespace /// </summary> private GDNSets gdnSets = new GDNSets(); - + /// <summary> /// Extension object which implements the functions in the http://gotdotnet.com/exslt/strings namespace /// </summary> @@ -140,33 +141,30 @@ /// Extension object which implements the functions in the http://gotdotnet.com/exslt/dynamic namespace /// </summary> private GDNDynamic gdnDynamic = new GDNDynamic(); - + /// <summary> /// Boolean flag used to specify whether multiple output is supported. /// </summary> private bool _multiOutput = false; - #endregion + #endregion - #region Public Fields and Properties - -/// <summary> -/// Sets the XmlResolver used to resolve external resources when the -/// Transform method is called. -/// </summary> - public XmlResolver XmlResolver { set { this.xslTransform.XmlResolver = value; } } + #region Public Fields and Properties + + /// <summary> + /// Bitwise enumeration used to specify which EXSLT functions should be accessible to + /// the ExsltTransform object. The default value is ExsltFunctionNamespace.All + /// </summary> + public ExsltFunctionNamespace SupportedFunctions + { + set + { + if (Enum.IsDefined(typeof(ExsltFunctionNamespace), value)) + this._supportedFunctions = value; + } + get { return this._supportedFunctions; } + } -/// <summary> -/// Bitwise enumeration used to specify which EXSLT functions should be accessible to -/// the ExsltTransform object. The default value is ExsltFunctionNamespace.All -/// </summary> - public ExsltFunctionNamespace SupportedFunctions{ - set { if (Enum.IsDefined(typeof(ExsltFunctionNamespace), value)) - this._supportedFunctions = value; - } - get { return this._supportedFunctions; } - } - /// <summary> /// Boolean flag used to specify whether multiple output (via exsl:document) is /// supported. @@ -177,254 +175,419 @@ /// disabled by default. If you need multiple output support, set this property to /// true before the Transform() call. /// </summary> - public bool MultiOutput { - get { return _multiOutput; } - set { _multiOutput = value; } - } - - #endregion - - #region Constructors -/// <summary> -/// Constructor initializes class. -/// </summary> - public ExsltTransform(){ - this.xslTransform = new XslCompiledTransform(); - } - - #endregion - - #region Load() method Overloads - /// <summary> Loads the XSLT stylesheet contained in the IXPathNavigable</summary> - public void Load(IXPathNavigable ixn){ this.xslTransform.Load(ixn); } + public bool MultiOutput + { + get { return _multiOutput; } + set { _multiOutput = value; } + } + /// <summary> + /// Gets an <see cref="XmlWriterSettings"/> object that contains the output + /// information derived from the xsl:output element of the style sheet. + /// </summary> + public XmlWriterSettings OutputSettings + { + get { return xslTransform.OutputSettings; } + } - /// <summary> Loads the XSLT stylesheet specified by a URL</summary> - public void Load(string s){ this.xslTransform.Load(s); } + /// <summary> + /// Gets the TempFileCollection that contains the temporary files generated + /// on disk after a successful call to the Load method. + /// </summary> + public TempFileCollection TemporaryFiles + { + get { return xslTransform.TemporaryFiles; } + } - /// <summary> Loads the XSLT stylesheet contained in the XmlReader</summary> - public void Load(XmlReader reader){ this.xslTransform.Load(reader); } + #endregion - /// <summary> Loads the XSLT stylesheet contained in the XPathNavigator</summary> - public void Load(XPathNavigator navigator){ this.xslTransform.Load(navigator); } + #region Constructors + /// <summary> + /// Initializes a new instance of the ExsltTransform class. + /// </summary> + public ExsltTransform() + { + this.xslTransform = new XslCompiledTransform(); + } - /// <summary> Loads the XSLT stylesheet contained in the IXPathNavigable</summary> - public void Load(IXPathNavigable ixn, XmlResolver resolver){ this.xslTransform.Load(ixn, resolver); } + /// <summary> + /// Initializes a new instance of the ExsltTransform + /// class with the specified debug setting. + /// </summary> + public ExsltTransform(bool debug) + { + this.xslTransform = new XslCompiledTransform(debug); + } - /// <summary> Loads the XSLT stylesheet specified by a URL</summary> - public void Load(string s, XmlResolver resolver){ this.xslTransform.Load(s, resolver); } + #endregion - /// <summary> Loads the XSLT stylesheet contained in the XmlReader</summary> - public void Load(XmlReader reader, XmlResolver resolver){ this.xslTransform.Load(reader, resolver); } + #region Load() method Overloads + /// <summary> Loads the XSLT stylesheet contained in the IXPathNavigable</summary> + public void Load(IXPathNavigable ixn) { this.xslTransform.Load(ixn); } - /// <summary> Loads the XSLT stylesheet contained in the XPathNavigator</summary> - public void Load(XPathNavigator navigator, XmlResolver resolver) {this.xslTransform.Load(navigator, resolver); } + /// <summary> Loads the XSLT stylesheet specified by a URL</summary> + public void Load(string s) { this.xslTransform.Load(s); } - #endregion + /// <summary> Loads the XSLT stylesheet contained in the XmlReader</summary> + public void Load(XmlReader reader) { this.xslTransform.Load(reader); } - #region Transform() method Overloads + /// <summary> + /// Compiles the XSLT style sheet contained in the IXPathNavigable. + /// The XmlResolver resolves any XSLT import or include elements and the + /// XSLT settings determine the permissions for the style sheet. + /// </summary> + public void Load(IXPathNavigable stylesheet, XsltSettings settings, XmlResolver stylesheetResolver) + { + this.xslTransform.Load(stylesheet, settings, stylesheetResolver); + } - /// <summary> Transforms the XML data in the IXPathNavigable using the specified args and outputs the result to an XmlReader</summary> - public XmlReader Transform(IXPathNavigable ixn, XsltArgumentList arglist) - { - return this.xslTransform.Transform(ixn, this.AddExsltExtensionObjects(arglist)); - } + /// <summary> + /// Loads and compiles the XSLT style sheet specified by the URI. + /// The XmlResolver resolves any XSLT import or include elements and the + /// XSLT settings determine the permissions for the style sheet. + /// </summary> + public void Load(string stylesheetUri, XsltSettings settings, XmlResolver stylesheetResolver) + { + this.xslTransform.Load(stylesheetUri, settings, stylesheetResolver); + } - /// <summary> Transforms the XML data in the input file and outputs the result to an output file</summary> - public void Transform(string infile, string outfile) - { - // Use using so that the file is not held open after the call + /// <summary> + /// Compiles the XSLT style sheet contained in the XmlReader. + /// The XmlResolver resolves any XSLT import or include elements and the + /// XSLT settings determine the permissions for the style sheet. + /// </summary> + public void Load(XmlReader stylesheet, XsltSettings settings, XmlResolver stylesheetResolver) + { + this.xslTransform.Load(stylesheet, settings, stylesheetResolver); + } - using (StreamWriter outStream = new StreamWriter(outfile)) - { - if (_multiOutput) - this.xslTransform.Transform(new XPathDocument(infile), this.AddExsltExtensionObjects(null), - new MultiXmlTextWriter(outStream)); - else - this.xslTransform.Transform(new XPathDocument(infile), this.AddExsltExtensionObjects(null), outStream); - } - } + #endregion - /// <summary> Transforms the XML data in the XPathNavigator using the specified args and outputs the result to an XmlReader</summary> - public XmlReader Transform(XPathNavigator navigator, XsltArgumentList arglist) - { - return this.xslTransform.Transform(navigator, this.AddExsltExtensionObjects(arglist)); - } + #region Transform() method Overloads - /// <summary> Transforms the XML data in the IXPathNavigable using the specified args and outputs the result to a Stream</summary> - public void Transform(IXPathNavigable ixn, XsltArgumentList arglist, Stream stream) - { - if (_multiOutput) - this.xslTransform.Transform(ixn, this.AddExsltExtensionObjects(arglist), - new MultiXmlTextWriter(stream, Encoding.UTF8)); - else - this.xslTransform.Transform(ixn, this.AddExsltExtensionObjects(arglist), stream); - } + /// <summary> + /// Executes the transform using the input document specified by the + /// IXPathNavigable object and outputs the results to an XmlWriter. + /// </summary> + public void Transform(IXPathNavigable input, XmlWriter results) + { + this.xslTransform.Transform(input, AddExsltExtensionObjects(null), results); + } - /// <summary> Transforms the XML data in the IXPathNavigable using the specified args and outputs the result to a TextWriter</summary> - public void Transform(IXPathNavigable ixn, XsltArgumentList arglist, TextWriter writer) - { - if (_multiOutput) - this.xslTransform.Transform(ixn, this.AddExsltExtensionObjects(arglist), - new MultiXmlTextWriter(writer)); - else - this.xslTransform.Transform(ixn, this.AddExsltExtensionObjects(arglist), writer); - } + /// <summary> + /// Executes the transform using the input document specified by the URI + /// and outputs the results to a file. + /// </summary> + public void Transform(string inputUri, string resultsFile) + { + // Use using so that the file is not held open after the call + using (FileStream outStream = File.OpenWrite(resultsFile)) + { + if (_multiOutput) + { + this.xslTransform.Transform(new XPathDocument(inputUri), + this.AddExsltExtensionObjects(null), + new MultiXmlTextWriter(outStream, this.OutputSettings.Encoding)); + } + else + { + this.xslTransform.Transform(new XPathDocument(inputUri), + this.AddExsltExtensionObjects(null), + outStream); + } + } + } - /// <summary> Transforms the XML data in the IXPathNavigable using the specified args and outputs the result to an XmlWriter</summary> - public void Transform(IXPathNavigable ixn, XsltArgumentList arglist, XmlWriter writer) - { - this.xslTransform.Transform(ixn, this.AddExsltExtensionObjects(arglist), writer); - } - - /// <summary> Transforms the XML data in the IXPathNavigable using the specified args and outputs the result to an MultiXmlTextWriter</summary> - public void Transform(IXPathNavigable ixn, XsltArgumentList arglist, MultiXmlTextWriter writer) - { - this.xslTransform.Transform(ixn, this.AddExsltExtensionObjects(arglist), writer); + /// <summary> + /// Executes the transform using the input document specified by the URI + /// and outputs the results to an XmlWriter. + /// </summary> + public void Transform(string inputUri, XmlWriter results) + { + this.xslTransform.Transform(inputUri, + this.AddExsltExtensionObjects(null), results); } - /// <summary> Transforms the XML data in the XPathNavigator using the specified args and outputs the result to a Stream</summary> - public void Transform(XPathNavigator navigator, XsltArgumentList arglist, Stream stream) - { - if (_multiOutput) - this.xslTransform.Transform(navigator, this.AddExsltExtensionObjects(arglist), - new MultiXmlTextWriter(stream, Encoding.UTF8)); - else - this.xslTransform.Transform(navigator, this.AddExsltExtensionObjects(arglist), stream); - } + /// <summary> + /// Executes the transform using the input document specified by the + /// XmlReader object and outputs the results to an XmlWriter. + /// </summary> + public void Transform(XmlReader input, XmlWriter results) + { + this.xslTransform.Transform(input, + this.AddExsltExtensionObjects(null), results); + } - /// <summary> Transforms the XML data in the XPathNavigator using the specified args and outputs the result to a TextWriter</summary> - public void Transform(XPathNavigator navigator, XsltArgumentList arglist, TextWriter writer) - { - if (_multiOutput) - this.xslTransform.Transform(navigator, this.AddExsltExtensionObjects(arglist), - new MultiXmlTextWriter(writer)); + /// <summary> + /// Executes the transform using the input document specified by the + /// IXPathNavigable object and outputs the results to a stream. + /// The XsltArgumentList provides additional runtime arguments. + /// </summary> + public void Transform(IXPathNavigable input, XsltArgumentList arguments, Stream results) + { + if (_multiOutput) + { + this.xslTransform.Transform(input, + this.AddExsltExtensionObjects(arguments), + new MultiXmlTextWriter(results, this.OutputSettings.Encoding)); + } else - this.xslTransform.Transform(navigator, this.AddExsltExtensionObjects(arglist), writer); - } - - /// <summary> Transforms the XML data in the XPathNavigator using the specified args and outputs the result to an XmlWriter</summary> - public void Transform(XPathNavigator navigator, XsltArgumentList arglist, XmlWriter writer) - { - this.xslTransform.Transform(navigator, this.AddExsltExtensionObjects(arglist), writer); - } - - /// <summary> Transforms the XML data in the XPathNavigator using the specified args and outputs the result to an MultiXmlTextWriter</summary> - public void Transform(XPathNavigator navigator, XsltArgumentList arglist, MultiXmlTextWriter writer) - { - this.xslTransform.Transform(navigator, this.AddExsltExtensionObjects(arglist), writer); + { + this.xslTransform.Transform(input, + this.AddExsltExtensionObjects(arguments), results); + } } - #endregion - - #region Public Methods - - #endregion + /// <summary> + /// Executes the transform using the input document specified by the + /// IXPathNavigable object and outputs the results to an TextWriter. + /// The XsltArgumentList provides additional run-time arguments. + /// </summary> + public void Transform(IXPathNavigable input, XsltArgumentList arguments, TextWriter results) + { + if (_multiOutput) + { + this.xslTransform.Transform(input, + this.AddExsltExtensionObjects(arguments), + new MultiXmlTextWriter(results)); + } + else + { + this.xslTransform.Transform(input, + this.AddExsltExtensionObjects(arguments), results); + } + } - #region Private Methods - /// <summary> - /// Adds the objects that implement the EXSLT extensions to the provided argument - /// list. The extension objects added depend on the value of the SupportedFunctions - /// property. - /// </summary> - /// <param name="list">The argument list</param> - /// <returns>An XsltArgumentList containing the contents of the list passed in - /// and objects that implement the EXSLT. </returns> - /// <remarks>If null is passed in then a new XsltArgumentList is constructed. </remarks> - private XsltArgumentList AddExsltExtensionObjects(XsltArgumentList list){ - if(list == null){ - list = new XsltArgumentList(); - } - - lock (sync) - { - //remove all our extension objects in case the XSLT argument list is being reused - list.RemoveExtensionObject(ExsltNamespaces.Common); - list.RemoveExtensionObject(ExsltNamespaces.Math); - list.RemoveExtensionObject(ExsltNamespaces.Random); - list.RemoveExtensionObject(ExsltNamespaces.DatesAndTimes); - list.RemoveExtensionObject(ExsltNamespaces.RegularExpressions); - list.RemoveExtensionObject(ExsltNamespaces.Strings); - list.RemoveExtensionObject(ExsltNamespaces.Sets); - list.RemoveExtensionObject(ExsltNamespaces.GDNDatesAndTimes); - list.RemoveExtensionObject(ExsltNamespaces.GDNMath); - list.RemoveExtensionObject(ExsltNamespaces.GDNRegularExpressions); - list.RemoveExtensionObject(ExsltNamespaces.GDNSets); - list.RemoveExtensionObject(ExsltNamespaces.GDNStrings); - list.RemoveExtensionObject(ExsltNamespaces.GDNDynamic); - - //add extension objects as specified by SupportedFunctions - if((this.SupportedFunctions & ExsltFunctionNamespace.Common) > 0) - { - list.AddExtensionObject(ExsltNamespaces.Common, this.exsltCommon); + /// <summary> + /// Executes the transform using the input document specified by the + /// IXPathNavigable object and outputs the results to an XmlWriter. + /// The XsltArgumentList provides additional run-time arguments. + /// </summary> + public void Transform(IXPathNavigable input, XsltArgumentList arguments, XmlWriter results) + { + this.xslTransform.Transform(input, + this.AddExsltExtensionObjects(arguments), results); } - if((this.SupportedFunctions & ExsltFunctionNamespace.Math) > 0) - { - list.AddExtensionObject(ExsltNamespaces.Math, this.exsltMath); + /// <summary> + /// Executes the transform using the input document specified by the URI + /// and outputs the results to stream. + /// The XsltArgumentList provides additional run-time arguments. + /// </summary> + public void Transform(string inputUri, XsltArgumentList arguments, Stream results) + { + if (_multiOutput) + { + this.xslTransform.Transform(inputUri, + this.AddExsltExtensionObjects(arguments), + new MultiXmlTextWriter(results, this.OutputSettings.Encoding)); + } + else + { + this.xslTransform.Transform(inputUri, + this.AddExsltExtensionObjects(arguments), results); + } } - if((this.SupportedFunctions & ExsltFunctionNamespace.Random) > 0) - { - list.AddExtensionObject(ExsltNamespaces.Random, this.exsltRandom); + /// <summary> + /// Executes the transform using the input document specified by the URI and + /// outputs the results to a TextWriter. + /// </summary> + public void Transform(string inputUri, XsltArgumentList arguments, TextWriter results) + { + if (_multiOutput) + { + this.xslTransform.Transform(inputUri, + this.AddExsltExtensionObjects(arguments), + new MultiXmlTextWriter(results)); + } + else + { + this.xslTransform.Transform(inputUri, + this.AddExsltExtensionObjects(arguments), results); + } } - if((this.SupportedFunctions & ExsltFunctionNamespace.DatesAndTimes) > 0) - { - list.AddExtensionObject(ExsltNamespaces.DatesAndTimes, this.exsltDatesAndTimes); + /// <summary> + /// Executes the transform using the input document specified by the URI + /// and outputs the results to an XmlWriter. + /// The XsltArgumentList provides additional run-time arguments. + /// </summary> + public void Transform(string inputUri, XsltArgumentList arguments, XmlWriter results) + { + this.xslTransform.Transform(inputUri, + this.AddExsltExtensionObjects(arguments), results); } - if((this.SupportedFunctions & ExsltFunctionNamespace.RegularExpressions) > 0) - { - list.AddExtensionObject(ExsltNamespaces.RegularExpressions, this.exsltRegularExpressions); + /// <summary> + /// Executes the transform using the input document specified by the XmlReader + /// object and outputs the results to a stream. + /// The XsltArgumentList provides additional run-time arguments. + /// </summary> + public void Transform(XmlReader input, XsltArgumentList arguments, Stream results) + { + if (_multiOutput) + { + this.xslTransform.Transform(input, + this.AddExsltExtensionObjects(arguments), + new MultiXmlTextWriter(results, this.OutputSettings.Encoding)); + } + else + { + this.xslTransform.Transform(input, + this.AddExsltExtensionObjects(arguments), results); + } } - if((this.SupportedFunctions & ExsltFunctionNamespace.Strings) > 0) - { - list.AddExtensionObject(ExsltNamespaces.Strings, this.exsltStrings); + /// <summary> + /// Executes the transform using the input document specified by the XmlReader + /// object and outputs the results to a TextWriter. + /// The XsltArgumentList provides additional run-time arguments. + /// </summary> + public void Transform(XmlReader input, XsltArgumentList arguments, TextWriter results) + { + if (_multiOutput) + { + this.xslTransform.Transform(input, + this.AddExsltExtensionObjects(arguments), + new MultiXmlTextWriter(results)); + } + else + { + this.xslTransform.Transform(input, + this.AddExsltExtensionObjects(arguments), results); + } } - if((this.SupportedFunctions & ExsltFunctionNamespace.Sets) > 0) - { - list.AddExtensionObject(ExsltNamespaces.Sets, this.exsltSets); - } - - if((this.SupportedFunctions & ExsltFunctionNamespace.GDNDatesAndTimes) > 0) - { - list.AddExtensionObject(ExsltNamespaces.GDNDatesAndTimes, this.gdnDatesAndTimes); - } - - if((this.SupportedFunctions & ExsltFunctionNamespace.GDNMath) > 0) - { - list.AddExtensionObject(ExsltNamespaces.GDNMath, this.gdnMath); - } - - if((this.SupportedFunctions & ExsltFunctionNamespace.GDNRegularExpressions) > 0) - { - list.AddExtensionObject(ExsltNamespaces.GDNRegularExpressions, this.gdnRegularExpressions); - } - - if((this.SupportedFunctions & ExsltFunctionNamespace.GDNSets) > 0) - { - list.AddExtensionObject(ExsltNamespaces.GDNSets, this.gdnSets); + /// <summary> + /// Executes the transform using the input document specified by the XmlReader + /// object and outputs the results to an XmlWriter. + /// The XsltArgumentList provides additional run-time arguments. + /// </summary> + public void Transform(XmlReader input, XsltArgumentList arguments, XmlWriter results) + { + this.xslTransform.Transform(input, + this.AddExsltExtensionObjects(arguments), results); } - - if((this.SupportedFunctions & ExsltFunctionNamespace.GDNStrings) > 0) - { - list.AddExtensionObject(ExsltNamespaces.GDNStrings, this.gdnStrings); + + + /// <summary> + /// Executes the transform using the input document specified by the XmlReader + /// object and outputs the results to an XmlWriter. + /// The XsltArgumentList provides additional run-time arguments and the + /// XmlResolver resolves the XSLT document() function. + /// </summary> + public void Transform(XmlReader input, XsltArgumentList arguments, + XmlWriter results, XmlResolver documentResolver) + { + this.xslTransform.Transform(input, + this.AddExsltExtensionObjects(arguments), results, documentResolver); } - - if((this.SupportedFunctions & ExsltFunctionNamespace.GDNDynamic) > 0) - { - list.AddExtensionObject(ExsltNamespaces.GDNDynamic, this.gdnDynamic); + + #endregion + + #region Private Methods + + /// <summary> + /// Adds the objects that implement the EXSLT extensions to the provided argument + /// list. The extension objects added depend on the value of the SupportedFunctions + /// property. + /// </summary> + /// <param name="list">The argument list</param> + /// <returns>An XsltArgumentList containing the contents of the list passed in + /// and objects that implement the EXSLT. </returns> + /// <remarks>If null is passed in then a new XsltArgumentList is constructed. </remarks> + private XsltArgumentList AddExsltExtensionObjects(XsltArgumentList list) + { + if (list == null) + { + list = new XsltArgumentList(); + } + + lock (sync) + { + //remove all our extension objects in case the XSLT argument list is being reused + list.RemoveExtensionObject(ExsltNamespaces.Math); + list.RemoveExtensionObject(ExsltNamespaces.Random); + list.RemoveExtensionObject(ExsltNamespaces.DatesAndTimes); + list.RemoveExtensionObject(ExsltNamespaces.RegularExpressions); + list.RemoveExtensionObject(ExsltNamespaces.Strings); + list.RemoveExtensionObject(ExsltNamespaces.Sets); + list.RemoveExtensionObject(ExsltNamespaces.GDNDatesAndTimes); + list.RemoveExtensionObject(ExsltNamespaces.GDNMath); + list.RemoveExtensionObject(ExsltNamespaces.GDNRegularExpressions); + list.RemoveExtensionObject(ExsltNamespaces.GDNSets); + list.RemoveExtensionObject(ExsltNamespaces.GDNStrings); + list.RemoveExtensionObject(ExsltNamespaces.GDNDynamic); + + //add extension objects as specified by SupportedFunctions + + if ((this.SupportedFunctions & ExsltFunctionNamespace.Math) > 0) + { + list.AddExtensionObject(ExsltNamespaces.Math, this.exsltMath); + } + + if ((this.SupportedFunctions & ExsltFunctionNamespace.Random) > 0) + { + list.AddExtensionObject(ExsltNamespaces.Random, this.exsltRandom); + } + + if ((this.SupportedFunctions & ExsltFunctionNamespace.DatesAndTimes) > 0) + { + list.AddExtensionObject(ExsltNamespaces.DatesAndTimes, this.exsltDatesAndTimes); + } + + if ((this.SupportedFunctions & ExsltFunctionNamespace.RegularExpressions) > 0) + { + list.AddExtensionObject(ExsltNamespaces.RegularExpressions, this.exsltRegularExpressions); + } + + if ((this.SupportedFunctions & ExsltFunctionNamespace.Strings) > 0) + { + list.AddExtensionObject(ExsltNamespaces.Strings, this.exsltStrings); + } + + if ((this.SupportedFunctions & ExsltFunctionNamespace.Sets) > 0) + { + list.AddExtensionObject(ExsltNamespaces.Sets, this.exsltSets); + } + + if ((this.SupportedFunctions & ExsltFunctionNamespace.GDNDatesAndTimes) > 0) + { + list.AddExtensionObject(ExsltNamespaces.GDNDatesAndTimes, this.gdnDatesAndTimes); + } + + if ((this.SupportedFunctions & ExsltFunctionNamespace.GDNMath) > 0) + { + list.AddExtensionObject(ExsltNamespaces.GDNMath, this.gdnMath); + } + + if ((this.SupportedFunctions & ExsltFunctionNamespace.GDNRegularExpressions) > 0) + { + list.AddExtensionObject(ExsltNamespaces.GDNRegularExpressions, this.gdnRegularExpressions); + } + + if ((this.SupportedFunctions & ExsltFunctionNamespace.GDNSets) > 0) + { + list.AddExtensionObject(ExsltNamespaces.GDNSets, this.gdnSets); + } + + if ((this.SupportedFunctions & ExsltFunctionNamespace.GDNStrings) > 0) + { + list.AddExtensionObject(ExsltNamespaces.GDNStrings, this.gdnStrings); + } + + if ((this.SupportedFunctions & ExsltFunctionNamespace.GDNDynamic) > 0) + { + list.AddExtensionObject(ExsltNamespaces.GDNDynamic, this.gdnDynamic); + } + } + + return list; } - } - - return list; - } - #endregion + #endregion - } + } } Index: ExsltMath.cs =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/src/Exslt/ExsltMath.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- ExsltMath.cs 16 Oct 2005 20:07:08 -0000 1.1 +++ ExsltMath.cs 29 Oct 2005 21:14:35 -0000 1.2 @@ -5,342 +5,366 @@ using System.Xml.XPath; using System.Collections.Generic; +using Mvp.Xml.Common.XPath; + #endregion namespace Mvp.Xml.Exslt { - /// <summary> - /// This class implements the EXSLT functions in the http://exslt.org/math namespace. - /// </summary> - public class ExsltMath { - /// <summary> - /// Implements the following function - /// number min(node-set) - /// </summary> - /// <param name="iterator"></param> - /// <returns></returns> - public double min(XPathNodeIterator iterator){ - - double min, t; - - if(iterator.Count == 0){ - return Double.NaN; - } - - try{ - - iterator.MoveNext(); - min = XmlConvert.ToDouble(iterator.Current.Value); + /// <summary> + /// This class implements the EXSLT functions in the http://exslt.org/math namespace. + /// </summary> + public class ExsltMath + { + /// <summary> + /// Implements the following function + /// number min(node-set) + /// </summary> + /// <param name="iterator"></param> + /// <returns></returns> + public double min(XPathNodeIterator iterator) + { + double min, t; - - while(iterator.MoveNext()){ - t = XmlConvert.ToDouble(iterator.Current.Value); - min = (t < min)? t : min; - } - - }catch(Exception){ - return Double.NaN; - } + if (iterator.Count == 0) + { + return Double.NaN; + } - return min; - } + try + { - - /// <summary> - /// Implements the following function - /// number max(node-set) - /// </summary> - /// <param name="iterator"></param> - /// <returns></returns> - public double max(XPathNodeIterator iterator){ + iterator.MoveNext(); + min = XmlConvert.ToDouble(iterator.Current.Value); - double max, t; - if(iterator.Count == 0){ - return Double.NaN; - } + while (iterator.MoveNext()) + { + t = XmlConvert.ToDouble(iterator.Current.Value); + min = (t < min) ? t : min; + } - try{ + } + catch + { + return Double.NaN; + } - iterator.MoveNext(); - max = XmlConvert.ToDouble(iterator.Current.Value); + return min; + } - - while(iterator.MoveNext()){ - t = XmlConvert.ToDouble(iterator.Current.Value); - max = (t > max)? t : max; - } - - }catch(Exception){ - return Double.NaN; - } - return max; - } - + /// <summary> + /// Implements the following function + /// number max(node-set) + /// </summary> + /// <param name="iterator"></param> + /// <returns></returns> + public double max(XPathNodeIterator iterator) + { + double max, t; - /// <summary> - /// Implements the following function - /// node-set highest(node-set) - /// </summary> - /// <param name="iterator">The input nodeset</param> - /// <returns>All the nodes that contain the max value in the nodeset</returns> - public XPathNodeIterator highest(XPathNodeIterator iterator){ + if (iterator.Count == 0) + { + return Double.NaN; + } - ExsltNodeList newList = new ExsltNodeList(); - double max, t; + try + { - if(iterator.Count == 0){ - return ExsltCommon.ExsltNodeListToXPathNodeIterator(newList); - } + iterator.MoveNext(); + max = XmlConvert.ToDouble(iterator.Current.Value); + while (iterator.MoveNext()) + { + t = XmlConvert.ToDouble(iterator.Current.Value); + max = (t > max) ? t : max; + } - try{ + } + catch + { + return Double.NaN; + } - iterator.MoveNext(); - max = XmlConvert.ToDouble(iterator.Current.Value); - newList.Add(iterator.Current.Clone()); + return max; + } - while (iterator.MoveNext()){ - t = XmlConvert.ToDouble(iterator.Current.Value); - - if(t > max){ - max = t; - newList.Clear(); - newList.Add(iterator.Current.Clone()); - }else if( t == max){ - newList.Add(iterator.Current.Clone()); - } - } - - }catch(Exception){ //return empty node set - newList.Clear(); - return ExsltCommon.ExsltNodeListToXPathNodeIterator(newList); - } - return ExsltCommon.ExsltNodeListToXPathNodeIterator(newList); - } + /// <summary> + /// Implements the following function + /// node-set highest(node-set) + /// </summary> + /// <param name="iterator">The input nodeset</param> + /// <returns>All the nodes that contain the max value in the nodeset</returns> + public XPathNodeIterator highest(XPathNodeIterator iterator) + { + if (iterator.Count == 0) + { + return EmptyXPathNodeIterator.Instance; + } + + double max, t; + List<XPathNavigator> newList = new List<XPathNavigator>(); + try + { + iterator.MoveNext(); + max = XmlConvert.ToDouble(iterator.Current.Value); + newList.Add(iterator.Current.Clone()); - /// <summary> - /// Implements the following function - /// node-set lowest(node-set) - /// </summary> - /// <param name="iterator">The input nodeset</param> - /// <returns>All the nodes that contain the min value in the nodeset</returns> - public XPathNodeIterator lowest(XPathNodeIterator iterator){ + while (iterator.MoveNext()) + { + t = XmlConvert.ToDouble(iterator.Current.Value); - IList<XPathNavigator> newList = new List<XPathNavigator>(); - double min, t; + if (t > max) + { + max = t; + newList.Clear(); + newList.Add(iterator.Current.Clone()); + } + else if (t == max) + { + newList.Add(iterator.Current.Clone()); + } + } + } + catch + { + //return empty node set + return EmptyXPathNodeIterator.Instance; + } - if(iterator.Count == 0){ - return newList; - } + return new XPathNavigatorIterator(newList); + } - try{ + /// <summary> + /// Implements the following function + /// node-set lowest(node-set) + /// </summary> + /// <param name="iterator">The input nodeset</param> + /// <returns>All the nodes that contain the min value in the nodeset</returns> + public XPathNodeIterator lowest(XPathNodeIterator iterator) + { + if (iterator.Count == 0) + { + return EmptyXPathNodeIterator.Instance; + } - iterator.MoveNext(); - min = XmlConvert.ToDouble(iterator.Current.Value); - newList.Add(iterator.Current.Clone()); + double max, t; + List<XPathNavigator> newList = new List<XPathNavigator>(); - while (iterator.MoveNext()){ - t = XmlConvert.ToDouble(iterator.Current.Value); - - if(t < min){ - min = t; - newList.Clear(); - newList.Add(iterator.Current.Clone()); - }else if( t == min){ - newList.Add(iterator.Current.Clone()); - } - } - - }catch(Exception){ //return empty node set - newList.Clear(); - return ExsltCommon.ExsltNodeListToXPathNodeIterator(newList); - } + try + { + iterator.MoveNext(); + max = XmlConvert.ToDouble(iterator.Current.Value); + newList.Add(iterator.Current.Clone()); - return ExsltCommon.ExsltNodeListToXPathNodeIterator(newList); - } + while (iterator.MoveNext()) + { + t = XmlConvert.ToDouble(iterator.Current.Value); - /// <summary> - /// Implements the following function - /// number abs(number) - /// </summary> - /// <param name="number"></param> - /// <returns></returns> - public double abs(double number){ + if (t < max) + { + max = t; + newList.Clear(); + newList.Add(iterator.Current.Clone()); + } + else if (t == max) + { + newList.Add(iterator.Current.Clone()); + } + } + } + catch + { + //return empty node set + return EmptyXPathNodeIterator.Instance; + } - return Math.Abs(number); - } + return new XPathNavigatorIterator(newList); + } - /// <summary> - /// Implements the following function - /// number sqrt(number) - /// </summary> - /// <param name="number"></param> - /// <returns></returns> - public double sqrt(double number){ + /// <summary> + /// Implements the following function + /// number abs(number) + /// </summary> + /// <param name="number"></param> + /// <returns></returns> + public double abs(double number) + { + return Math.Abs(number); + } + /// <summary> + /// Implements the following function + /// number sqrt(number) + /// </summary> + /// <param name="number"></param> + /// <returns></returns> + public double sqrt(double number) + { if (number < 0) return 0; - return Math.Sqrt(number); - } - - /// <summary> - /// Implements the following function - /// number power(number, number) - /// </summary> - /// <param name="x"></param> - /// <param name="y"></param> - /// <returns></returns> - public double power(double x, double y){ - - return Math.Pow(x, y); - } + return Math.Sqrt(number); + } - /// <summary> - /// Implements the following function - /// number log(number) - /// </summary> - /// <param name="x"></param> - /// <returns></returns> - public double log(double x){ + /// <summary> + /// Implements the following function + /// number power(number, number) + /// </summary> + /// <param name="x"></param> + /// <param name="y"></param> + /// <returns></returns> + public double power(double x, double y) + { + return Math.Pow(x, y); + } - return Math.Log(x); - } + /// <summary> + /// Implements the following function + /// number log(number) + /// </summary> + /// <param name="x"></param> + /// <returns></returns> + public double log(double x) + { + return Math.Log(x); + } - /// <summary> - /// Implements the following function - /// number constant(string, number) - /// </summary> - /// <param name="number"></param> - /// <returns>The specified constant or NaN</returns> - /// <remarks>This method only supports the constants - /// E and PI. Also the precision parameter is ignored.</remarks> - public double constant(string c, double precision){ - switch(c.ToUpper()) { + /// <summary> + /// Implements the following function + /// number constant(string, number) + /// </summary> + /// <param name="number"></param> + /// <returns>The specified constant or NaN</returns> + /// <remarks>This method only supports the constants + /// E and PI. Also the precision parameter is ignored.</remarks> + public double constant(string c, double precision) + { + switch (c.ToUpper()) + { case "E": return Math.E; case "PI": return Math.PI; - case "SQRRT2" : + case "SQRRT2": return Math.Sqrt(2); - case "LN2" : + case "LN2": return Math.Log(2); - case "LN10" : + case "LN10": return Math.Log(10); - case "LOG2E" : + case "LOG2E": return Math.Log(Math.E, 2); - case "SQRT1_2" : + case "SQRT1_2": return Math.Sqrt(.5); default: return Double.NaN; } - } - - /// <summary> - /// Implements the following function - /// number random() - /// </summary> - /// <param name="x"></param> - /// <returns></returns> - public double random(){ - - Random rand = new Random((int) DateTime.Now.Ticks); - return rand.NextDouble(); - } - - /// <summary> - /// Implements the following function - /// number sin(number) - /// </summary> - /// <param name="x"></param> - /// <returns></returns> - public double sin(double x){ - - return Math.Sin(x); - } - - /// <summary> - /// Implements the following function - /// number asin(number) - /// </summary> - /// <param name="x"></param> - /// <returns></returns> - public double asin(double x){ - - return Math.Asin(x); - } - - - /// <summary> - /// Implements the following function - /// number cos(number) - /// </summary> - /// <param name="x"></param> - /// <returns></returns> - ... [truncated message content] |
From: Oleg T. <he...@us...> - 2005-10-29 21:14:44
|
Update of /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/tests/EXSLT/DatesAndTimes In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23054/v2/test/ExsltTest/tests/EXSLT/DatesAndTimes Modified Files: parse-date.xslt Log Message: Index: parse-date.xslt =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/tests/EXSLT/DatesAndTimes/parse-date.xslt,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- parse-date.xslt 16 Oct 2005 20:13:09 -0000 1.1 +++ parse-date.xslt 29 Oct 2005 21:14:35 -0000 1.2 @@ -4,8 +4,7 @@ <xsl:output indent="yes" omit-xml-declaration="yes"/> <xsl:template match="data"> <out> - <test1> - </test1> + <test1>no tests</test1> </out> </xsl:template> </xsl:stylesheet> |
From: Oleg T. <he...@us...> - 2005-10-29 21:14:44
|
Update of /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/DatesAndTimes In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23054/v2/test/ExsltTest/results/EXSLT/DatesAndTimes Modified Files: parse-date.xml Log Message: Index: parse-date.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/DatesAndTimes/parse-date.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- parse-date.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ parse-date.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -1,4 +1,3 @@ <out> - <test1> - </test1> + <test1>no tests</test1> </out> \ No newline at end of file |
From: Oleg T. <he...@us...> - 2005-10-29 21:14:44
|
Update of /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Strings In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23054/v2/test/ExsltTest/results/EXSLT/Strings Modified Files: split.xml Log Message: Index: split.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/Strings/split.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- split.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ split.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -18,6 +18,5 @@ <token>cats</token> <token>dogs</token> </test4> - <test5> - </test5> + <test5 /> </out> \ No newline at end of file |
From: Oleg T. <he...@us...> - 2005-10-29 21:14:44
|
Update of /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/RegularExpressions In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23054/v2/test/ExsltTest/results/EXSLT/RegularExpressions Modified Files: test.xml Log Message: Index: test.xml =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/results/EXSLT/RegularExpressions/test.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- test.xml 16 Oct 2005 20:13:08 -0000 1.1 +++ test.xml 29 Oct 2005 21:14:35 -0000 1.2 @@ -1,17 +1,11 @@ <out> - <test1> - </test1> + <test1 /> <test2>Email address is not valid.</test2> <test3>Email address is not valid.</test3> - <test4> - </test4> - <test5> - </test5> - <test6> - </test6> - <test7> - </test7> + <test4 /> + <test5 /> + <test6 /> + <test7 /> <test8>Ok</test8> - <test9> - </test9> + <test9 /> </out> \ No newline at end of file |
From: Oleg T. <he...@us...> - 2005-10-29 21:14:44
|
Update of /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23054/v2/test/ExsltTest Modified Files: ExsltTest.csproj Log Message: Index: ExsltTest.csproj =================================================================== RCS file: /cvsroot/mvp-xml/EXSLT/v2/test/ExsltTest/ExsltTest.csproj,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- ExsltTest.csproj 16 Oct 2005 20:13:08 -0000 1.1 +++ ExsltTest.csproj 29 Oct 2005 21:14:35 -0000 1.2 @@ -1,7 +1,7 @@ <Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <PropertyGroup> <ProjectType>Local</ProjectType> - <ProductVersion>8.0.50215</ProductVersion> + <ProductVersion>8.0.50727</ProductVersion> <SchemaVersion>2.0</SchemaVersion> <ProjectGuid>{AC8B9015-E508-4E40-8E6D-C4FCF52CE4B0}</ProjectGuid> <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> @@ -70,9 +70,9 @@ <WarningLevel>4</WarningLevel> </PropertyGroup> <ItemGroup> - <Reference Include="Mvp.Xml"> - <Name>Mvp.Xml</Name> - <HintPath>..\..\..\..\Global\v1\bin\Release\Mvp.Xml.dll</HintPath> + <Reference Include="Mvp.Xml.Exslt, Version=2.0.2128.40465, Culture=neutral, PublicKeyToken=dd92544dc05f5671, processorArchitecture=MSIL"> + <SpecificVersion>False</SpecificVersion> + <HintPath>..\..\src\Exslt\Mvp.Xml.Exslt.dll</HintPath> </Reference> <Reference Include="nunit.framework"> <Name>nunit.framework</Name> |
From: Oleg T. <he...@us...> - 2005-10-29 21:13:25
|
Update of /cvsroot/mvp-xml/Common/v2/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22746/v2/src Modified Files: Common.csproj Added Files: mvp-xml.snk Log Message: --- NEW FILE: mvp-xml.snk --- (This appears to be a binary file; contents omitted.) Index: Common.csproj =================================================================== RCS file: /cvsroot/mvp-xml/Common/v2/src/Common.csproj,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- Common.csproj 28 Oct 2005 21:39:09 -0000 1.6 +++ Common.csproj 29 Oct 2005 21:13:10 -0000 1.7 @@ -11,8 +11,7 @@ <AssemblyKeyContainerName> </AssemblyKeyContainerName> <AssemblyName>Mvp.Xml.Common</AssemblyName> - <AssemblyOriginatorKeyFile> - </AssemblyOriginatorKeyFile> + <AssemblyOriginatorKeyFile>mvp-xml.snk</AssemblyOriginatorKeyFile> <DefaultClientScript>JScript</DefaultClientScript> <DefaultHTMLPageLayout>Grid</DefaultHTMLPageLayout> <DefaultTargetSchema>IE50</DefaultTargetSchema> @@ -78,6 +77,7 @@ <Name>System</Name> </Reference> <Reference Include="System.Configuration.Install" /> + <Reference Include="System.Data" /> <Reference Include="System.Management" /> <Reference Include="System.Xml"> <Name>System.XML</Name> @@ -122,10 +122,12 @@ <Compile Include="XPath\DynamicContext.cs"> <SubType>Code</SubType> </Compile> + <Compile Include="XPath\EmptyXPathNodeIterator.cs" /> <Compile Include="XPath\IHasXPathNavigator.cs" /> <Compile Include="XPath\IndexingXPathNavigator.cs"> <SubType>Code</SubType> </Compile> + <Compile Include="XPath\SingletonXPathNodeIterator.cs" /> <Compile Include="XPath\SubtreeeXPathNavigator.cs"> <SubType>Code</SubType> </Compile> @@ -151,6 +153,9 @@ <SubType>Designer</SubType> </EmbeddedResource> </ItemGroup> + <ItemGroup> + <None Include="mvp-xml.snk" /> + </ItemGroup> <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" /> <PropertyGroup> <PreBuildEvent> |
From: Oleg T. <he...@us...> - 2005-10-29 21:13:25
|
Update of /cvsroot/mvp-xml/Common/v2/src/XPath In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22746/v2/src/XPath Modified Files: XPathNavigatorIterator.cs Added Files: EmptyXPathNodeIterator.cs SingletonXPathNodeIterator.cs Log Message: Index: XPathNavigatorIterator.cs =================================================================== RCS file: /cvsroot/mvp-xml/Common/v2/src/XPath/XPathNavigatorIterator.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- XPathNavigatorIterator.cs 25 Oct 2005 21:33:44 -0000 1.2 +++ XPathNavigatorIterator.cs 29 Oct 2005 21:13:10 -0000 1.3 @@ -44,7 +44,36 @@ public XPathNavigatorIterator(XPathNavigator navigator) : this() { _navigators.Add(navigator); - } + } + + /// <summary> + /// Initializes a new instance of the <see cref="XPathNavigatorIterator"/> + /// using given list of navigators. + /// </summary> + public XPathNavigatorIterator(XPathNodeIterator iterator) + : this(iterator, false) { } + + /// <summary> + /// Initializes a new instance of the <see cref="XPathNavigatorIterator"/> + /// using given list of navigators. + /// </summary> + public XPathNavigatorIterator(XPathNodeIterator iterator, bool removeDuplicates) + : this() { + XPathNodeIterator it = iterator.Clone(); + + while (it.MoveNext()) + { + if (removeDuplicates) + { + if (this.Contains(it.Current)) + { + continue; + } + } + + this.Add(it.Current.Clone()); + } + } /// <summary> /// Initializes a new instance of the <see cref="XPathNavigatorIterator"/> @@ -104,6 +133,64 @@ } } + /// <summary> + /// Determines whether the list contains a navigator positioned at the same + /// location as the specified XPathNavigator. This + /// method relies on the IsSamePositon() method of the XPathNavightor. + /// </summary> + /// <param name="value">The object to locate in the list.</param> + /// <returns>true if the object is found in the list; otherwise, false.</returns> + public bool Contains(XPathNavigator value) + { + foreach (XPathNavigator nav in _navigators) + { + if (nav.IsSamePosition(value)) + { + return true; + } + } + return false; + } + + /// <summary> + /// Determines whether the list contains a navigator whose Value property matches + /// the target value + /// </summary> + /// <param name="value">The value to locate in the list.</param> + /// <returns>true if the value is found in the list; otherwise, false.</returns> + public bool ContainsValue(string value) + { + + foreach (XPathNavigator nav in _navigators) + { + if (nav.Value.Equals(value)) + { + return true; + } + } + return false; + } + + + /// <summary> + /// Gets or sets the element at the specified index + /// </summary> + public XPathNavigator this[int index] + { + get { return _navigators[index]; } + set { _navigators[index] = value; } + } + + /// <summary> + /// Removes the list item at the specified index. + /// </summary> + /// <param name="index">The zero-based index of the item to remove.</param> + public void RemoveAt(int index) + { + _navigators.RemoveAt(index); + } + + /// <summary> /// Resets the iterator. /// </summary> --- NEW FILE: SingletonXPathNodeIterator.cs --- #region using using System; using System.Xml.XPath; #endregion namespace Mvp.Xml.Common.XPath { /// <summary> /// <see cref="XPathNodeIterator"/> over a single node. /// </summary> public class SingletonXPathNodeIterator : XPathNodeIterator { private XPathNavigator navigator; private int position; #region ctors /// <summary> /// Creates new instance of SingletonXPathNodeIterator over /// given node. /// </summary> public SingletonXPathNodeIterator(XPathNavigator nav) { this.navigator = nav; } #endregion #region XPathNodeIterator impl /// <summary> /// See <see cref="XPathNodeIterator.Clone()"/> /// </summary> public override XPathNodeIterator Clone() { return new SingletonXPathNodeIterator(navigator.Clone()); } /// <summary> /// Always 1. See <see cref="XPathNodeIterator.Count"/> /// </summary> public override int Count { get { return 1; } } /// <summary> /// See <see cref="XPathNodeIterator.Current"/> /// </summary> public override XPathNavigator Current { get { return navigator; } } /// <summary> /// See <see cref="XPathNodeIterator.CurrentPosition"/> /// </summary> public override int CurrentPosition { get { return position; } } /// <summary> /// See <see cref="XPathNodeIterator.MoveNext()"/> /// </summary> public override bool MoveNext() { if (position == 0) { position = 1; return true; } return false; } #endregion } } --- NEW FILE: EmptyXPathNodeIterator.cs --- #region using using System; using System.Xml.XPath; #endregion namespace Mvp.Xml.Common.XPath { /// <summary> /// Empty <see cref="XPathNodeIterator"/>, used to represent empty /// node sequence. Implemented as a singleton. /// </summary> public class EmptyXPathNodeIterator : XPathNodeIterator { public static EmptyXPathNodeIterator Instance = new EmptyXPathNodeIterator(); /// <summary> /// This is a singleton, get an instance instead. /// </summary> private EmptyXPathNodeIterator() {} #region XPathNodeIterator implementation /// <summary> /// See <see cref="XPathNodeIterator.Clone()"/> /// </summary> public override XPathNodeIterator Clone() { return this; } /// <summary> /// Always 0. See <see cref="XPathNodeIterator.Count"/> /// </summary> public override int Count { get { return 0; } } /// <summary> /// Always null. See <see cref="XPathNodeIterator.Current"/> /// </summary> public override XPathNavigator Current { get { return null; } } /// <summary> /// Always 0. See <see cref="XPathNodeIterator.CurrentPosition"/> /// </summary> public override int CurrentPosition { get { return 0; } } /// <summary> /// Always false. See <see cref="XPathNodeIterator.MoveNext()"/> /// </summary> public override bool MoveNext() { return false; } #endregion } } |
From: Oleg T. <he...@us...> - 2005-10-29 21:13:25
|
Update of /cvsroot/mvp-xml/Common/v2/test In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22746/v2/test Modified Files: CommonTest.csproj Added Files: EmptyXPathNodeIteratorTests.cs SingletonXPathNodeIteratorTests.cs Log Message: --- NEW FILE: EmptyXPathNodeIteratorTests.cs --- using System; using System.Xml.XPath; using Mvp.Xml.Common.XPath; using NUnit.Framework; namespace Mvp.Xml.Tests { [TestFixture] public class EmptyXPathNodeIteratorTests { [Test] public void Test1() { EmptyXPathNodeIterator ni = EmptyXPathNodeIterator.Instance; while (ni.MoveNext()) { Assert.Fail("EmptyXPathNodeIterator must be empty"); } } [Test] public void Test2() { EmptyXPathNodeIterator ni = EmptyXPathNodeIterator.Instance; Assert.IsTrue(ni.MoveNext() == false); Assert.IsTrue(ni.Count == 0); Assert.IsTrue(ni.Current == null); Assert.IsTrue(ni.CurrentPosition == 0); } } } --- NEW FILE: SingletonXPathNodeIteratorTests.cs --- using System; using System.IO; using System.Xml.XPath; using Mvp.Xml.Common.XPath; using NUnit.Framework; namespace Mvp.Xml.Tests { [TestFixture] public class SingletonXPathNodeIteratorTests { [Test] public void Test1() { XPathDocument doc = new XPathDocument(new StringReader("<foo/>")); XPathNavigator node = doc.CreateNavigator().SelectSingleNode("/*"); SingletonXPathNodeIterator ni = new SingletonXPathNodeIterator(node); Assert.IsTrue(ni.MoveNext()); Assert.IsTrue(ni.Current == node); Assert.IsFalse(ni.MoveNext()); } } } Index: CommonTest.csproj =================================================================== RCS file: /cvsroot/mvp-xml/Common/v2/test/CommonTest.csproj,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- CommonTest.csproj 28 Oct 2005 20:01:48 -0000 1.3 +++ CommonTest.csproj 29 Oct 2005 21:13:11 -0000 1.4 @@ -110,6 +110,7 @@ <Compile Include="DebugUtils.cs"> <SubType>Code</SubType> </Compile> + <Compile Include="EmptyXPathNodeIteratorTests.cs" /> <Compile Include="Globals.cs"> <SubType>Code</SubType> </Compile> @@ -122,6 +123,7 @@ <Compile Include="pubsNs.cs"> <SubType>Code</SubType> </Compile> + <Compile Include="SingletonXPathNodeIteratorTests.cs" /> <Compile Include="SubtreeeXPathNavigatorTests\Tests.cs"> <SubType>Code</SubType> </Compile> |
From: Oleg T. <he...@us...> - 2005-10-29 11:51:55
|
Update of /cvsroot/mvp-xml/XInclude/v2/test/tests In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31153/v2/test/tests Modified Files: document.xml Log Message: Index: document.xml =================================================================== RCS file: /cvsroot/mvp-xml/XInclude/v2/test/tests/document.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- document.xml 28 Oct 2005 22:29:28 -0000 1.1 +++ document.xml 29 Oct 2005 11:51:35 -0000 1.2 @@ -1,6 +1,6 @@ <?xml version="1.0"?> <document xmlns:xi="http://www.w3.org/2003/XInclude"> <p>120 Mz is adequate for an average home user.</p> - <xi:include hre2f="disclaimer.xml" parse="xml"><foo></foo></xi:include> + <xi:include href="disclaimer.xml" parse="xml"><foo></foo></xi:include> foo </document> |
From: Oleg T. <he...@us...> - 2005-10-29 11:51:44
|
Update of /cvsroot/mvp-xml/XInclude/v2/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31153/v2/src Modified Files: SR.resx TextIncludingReader.cs XInclude.csproj XIncludingReader.cs Log Message: Index: XInclude.csproj =================================================================== RCS file: /cvsroot/mvp-xml/XInclude/v2/src/XInclude.csproj,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- XInclude.csproj 28 Oct 2005 22:28:56 -0000 1.1 +++ XInclude.csproj 29 Oct 2005 11:51:35 -0000 1.2 @@ -113,6 +113,9 @@ <Link>Common\XPath\IHasXPathNavigator.cs</Link> <SubType>Code</SubType> </Compile> + <Compile Include="..\..\..\Common\v2\src\XPath\SubtreeeXPathNavigator.cs"> + <Link>Common\XPath\SubtreeeXPathNavigator.cs</Link> + </Compile> <Compile Include="..\..\..\Common\v2\src\XPath\XPathCache.cs"> <Link>Common\XPath\XPathCache.cs</Link> <SubType>Code</SubType> Index: XIncludingReader.cs =================================================================== RCS file: /cvsroot/mvp-xml/XInclude/v2/src/XIncludingReader.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- XIncludingReader.cs 28 Oct 2005 22:28:56 -0000 1.1 +++ XIncludingReader.cs 29 Oct 2005 11:51:35 -0000 1.2 @@ -78,12 +78,12 @@ { XmlTextReader xtr = reader as XmlTextReader; if (xtr != null) - { - XmlValidatingReader vr = new XmlValidatingReader(reader); + { + XmlValidatingReader vr = new XmlValidatingReader(reader); vr.ValidationType = ValidationType.None; vr.EntityHandling = EntityHandling.ExpandEntities; vr.ValidationEventHandler += new ValidationEventHandler( - ValidationCallback); + ValidationCallback); _normalization = xtr.Normalization; _whiteSpaceHandling = xtr.WhitespaceHandling; _reader = vr; @@ -655,7 +655,7 @@ if (_relativeBaseUri) { Uri baseUri = new Uri(_reader.BaseURI); - return _topBaseUri.MakeRelativeUri(baseUri).AbsoluteUri; + return _topBaseUri.MakeRelativeUri(baseUri).ToString(); } else return _reader.BaseURI; Index: SR.resx =================================================================== RCS file: /cvsroot/mvp-xml/XInclude/v2/src/SR.resx,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- SR.resx 28 Oct 2005 22:28:56 -0000 1.1 +++ SR.resx 29 Oct 2005 11:51:35 -0000 1.2 @@ -117,97 +117,97 @@ <resheader name="writer"> <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> </resheader> - <data name="NotSupportedEncoding" type="System.String" mimetype="System.String"> + <data name="NotSupportedEncoding" xml:space="preserve"> <value>Not supported encoding '{0}'.</value> </data> - <data name="OutOfMemoryWhileFetchingResource" type="System.String" mimetype="System.String"> + <data name="OutOfMemoryWhileFetchingResource" xml:space="preserve"> <value>Out of memory error while reading resource '{0}'.</value> </data> - <data name="IOErrorWhileFetchingResource" type="System.String" mimetype="System.String"> + <data name="IOErrorWhileFetchingResource" xml:space="preserve"> <value>I/O error while reading resource '{0}'.</value> </data> - <data name="UnknownParseAttrValue" type="System.String" mimetype="System.String"> + <data name="UnknownParseAttrValue" xml:space="preserve"> <value>Unknown 'parse' attribute value: '{0}'.</value> </data> - <data name="UnknownParseAttrValueLong" type="System.String" mimetype="System.String"> + <data name="UnknownParseAttrValueLong" xml:space="preserve"> <value>Unknown 'parse' attribute value: '{0}'. In {1}, Line {2}, Position {3}.</value> </data> - <data name="NonXmlCharacter" type="System.String" mimetype="System.String"> + <data name="NonXmlCharacter" xml:space="preserve"> <value>Included document contains a character not allowed in XML: 0x{0}.</value> </data> - <data name="CircularInclusion" type="System.String" mimetype="System.String"> + <data name="CircularInclusion" xml:space="preserve"> <value>Circular inclusion has been detected, inclusion location: {0}.</value> </data> - <data name="CircularInclusionLong" type="System.String" mimetype="System.String"> + <data name="CircularInclusionLong" xml:space="preserve"> <value>Circular inclusion has been detected, inclusion location: {0}. In {1}, Line {2}, Position {3}.</value> </data> - <data name="FatalResourceException" type="System.String" mimetype="System.String"> + <data name="FatalResourceException" xml:space="preserve"> <value>Resource error has occured and no fallback has been provided: {0}.</value> </data> - <data name="AttributeOrNamespaceInIncludeLocationError" type="System.String" mimetype="System.String"> + <data name="AttributeOrNamespaceInIncludeLocationError" xml:space="preserve"> <value>Include location identifies an attribute or namespace node!</value> </data> - <data name="FallbackNotChildOfInclude" type="System.String" mimetype="System.String"> + <data name="FallbackNotChildOfInclude" xml:space="preserve"> <value>xi:fallback element must be direct child of xi:include element. Location: {0}.</value> </data> - <data name="FallbackNotChildOfIncludeLong" type="System.String" mimetype="System.String"> + <data name="FallbackNotChildOfIncludeLong" xml:space="preserve"> <value>xi:fallback element must be direct child of xi:include element. Location: {0}, Line {1}, Position {2}.</value> </data> - <data name="URISchemaNotSupported" type="System.String" mimetype="System.String"> + <data name="URISchemaNotSupported" xml:space="preserve"> <value>URI schema is not supported: '{0}'.</value> </data> - <data name="SecurityException" type="System.String" mimetype="System.String"> + <data name="SecurityException" xml:space="preserve"> <value>Security exception while fetching '{0}'.</value> </data> - <data name="ResourceError" type="System.String" mimetype="System.String"> + <data name="ResourceError" xml:space="preserve"> <value>Resource '{0}' cannot be fetched.</value> </data> - <data name="MissingHrefAndXpointerException" type="System.String" mimetype="System.String"> + <data name="MissingHrefAndXpointerException" xml:space="preserve"> <value>'href' or 'xpointer' attributes can't both be omitted on xi:include element. Location: {0}."</value> </data> - <data name="MissingHrefAndXpointerExceptionLong" type="System.String" mimetype="System.String"> + <data name="MissingHrefAndXpointerExceptionLong" xml:space="preserve"> <value>'href' or 'xpointer' attributes can't both be omitted on xi:include element. Location: {0}, Line {1}, Position {2}.</value> </data> - <data name="IntradocumentReferencesNotSupported" type="System.String" mimetype="System.String"> + <data name="IntradocumentReferencesNotSupported" xml:space="preserve"> <value>XIncludingReader doesn't support intra-document references.</value> </data> - <data name="CustomXmlResolverError" type="System.String" mimetype="System.String"> + <data name="CustomXmlResolverError" xml:space="preserve"> <value>An exception has occured during GetEntity call to custom XmlResolver.</value> </data> - <data name="CustomXmlResolverReturnedNull" type="System.String" mimetype="System.String"> + <data name="CustomXmlResolverReturnedNull" xml:space="preserve"> <value>Custom XmlResolver returned null.</value> </data> - <data name="CustomXmlResolverReturnedUnsupportedType" type="System.String" mimetype="System.String"> + <data name="CustomXmlResolverReturnedUnsupportedType" xml:space="preserve"> <value>Custom XmlResolver returned object of an unsupported type '{0}'.</value> </data> - <data name="InvalidURI" type="System.String" mimetype="System.String"> + <data name="InvalidURI" xml:space="preserve"> <value>Invalid URI '{0}'.</value> </data> - <data name="UnresolvableURI" type="System.String" mimetype="System.String"> + <data name="UnresolvableURI" xml:space="preserve"> <value>Unable to resolve URI reference '{0}'.</value> </data> - <data name="IncludeChildOfInclude" type="System.String" mimetype="System.String"> + <data name="IncludeChildOfInclude" xml:space="preserve"> <value>xi:include element cannot be child of xi:include element. Location: {0}.</value> </data> - <data name="IncludeChildOfIncludeLong" type="System.String" mimetype="System.String"> + <data name="IncludeChildOfIncludeLong" xml:space="preserve"> <value>xi:include element cannot be child of xi:include element. Location: {0}, Line {1}, Position {2}.</value> </data> - <data name="TwoFallbacks" type="System.String" mimetype="System.String"> + <data name="TwoFallbacks" xml:space="preserve"> <value>xi:include element cannot contain more than one xi:fallback element. Location: {0}.</value> </data> - <data name="TwoFallbacksLong" type="System.String" mimetype="System.String"> + <data name="TwoFallbacksLong" xml:space="preserve"> <value>xi:include element cannot contain more than one xi:fallback element. Location: {0}, Line {1}, Position {2}.</value> </data> - <data name="MalformedXInclusionResult" type="System.String" mimetype="System.String"> + <data name="MalformedXInclusionResult" xml:space="preserve"> <value>Malformed XInclusion result - xi:include element at the top level must include a single element and optional comments and PIs.</value> </data> - <data name="InvalidCharForAccept" type="System.String" mimetype="System.String"> + <data name="InvalidCharForAccept" xml:space="preserve"> <value>'accept' attribute contains a character not allowed in HTTP header: 0x{0}.</value> </data> - <data name="FragmentIDInHref" type="System.String" mimetype="System.String"> + <data name="FragmentIDInHref" xml:space="preserve"> <value>Fragment identifiers must not be used in 'href' attribute.</value> </data> - <data name="UnknownXIncludeElement" type="System.String" mimetype="System.String"> + <data name="UnknownXIncludeElement" xml:space="preserve"> <value>Unknown element in the XInclude namespace has been detected: {0}.</value> </data> </root> \ No newline at end of file Index: TextIncludingReader.cs =================================================================== RCS file: /cvsroot/mvp-xml/XInclude/v2/src/TextIncludingReader.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- TextIncludingReader.cs 28 Oct 2005 22:28:56 -0000 1.1 +++ TextIncludingReader.cs 29 Oct 2005 11:51:35 -0000 1.2 @@ -295,6 +295,7 @@ private Encoding GetEncodingFromXMLDecl(string href) { XmlTextReader tmpReader = new XmlTextReader(href); + tmpReader.ProhibitDtd = false; tmpReader.WhitespaceHandling = WhitespaceHandling.None; try { |
From: Oleg T. <he...@us...> - 2005-10-29 11:51:44
|
Update of /cvsroot/mvp-xml/XInclude/v2/test In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31153/v2/test Modified Files: EntryPoint.cs XIncludeReaderTests.cs XIncludeTest.csproj Log Message: Index: XIncludeTest.csproj =================================================================== RCS file: /cvsroot/mvp-xml/XInclude/v2/test/XIncludeTest.csproj,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- XIncludeTest.csproj 28 Oct 2005 22:28:57 -0000 1.1 +++ XIncludeTest.csproj 29 Oct 2005 11:51:35 -0000 1.2 @@ -17,7 +17,7 @@ <DefaultHTMLPageLayout>Grid</DefaultHTMLPageLayout> <DefaultTargetSchema>IE50</DefaultTargetSchema> <DelaySign>false</DelaySign> - <OutputType>Library</OutputType> + <OutputType>Exe</OutputType> <RootNamespace>Mvp.Xml.XInclude.Test</RootNamespace> <RunPostBuildEvent>OnBuildSuccess</RunPostBuildEvent> <StartupObject> Index: EntryPoint.cs =================================================================== RCS file: /cvsroot/mvp-xml/XInclude/v2/test/EntryPoint.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- EntryPoint.cs 28 Oct 2005 22:28:57 -0000 1.1 +++ EntryPoint.cs 29 Oct 2005 11:51:35 -0000 1.2 @@ -16,8 +16,8 @@ //FourThoughtTests rt = new FourThoughtTests(); //XIncludeSyntaxTests rt = new XIncludeSyntaxTests(); try - { - rt.Nist_include_24(); + { + rt.Nist_include_49(); } catch (Exception e) { Index: XIncludeReaderTests.cs =================================================================== RCS file: /cvsroot/mvp-xml/XInclude/v2/test/XIncludeReaderTests.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- XIncludeReaderTests.cs 28 Oct 2005 22:28:57 -0000 1.1 +++ XIncludeReaderTests.cs 29 Oct 2005 11:51:35 -0000 1.2 @@ -64,10 +64,11 @@ throw e; } xir.Close(); - XmlTextReader r1 = new XmlTextReader(new StringReader(doc.OuterXml)); - r1.WhitespaceHandling = WhitespaceHandling.Significant; - XmlTextReader r2 = new XmlTextReader(result); - r2.WhitespaceHandling = WhitespaceHandling.Significant; + XmlReaderSettings s = new XmlReaderSettings(); + s.ProhibitDtd = false; + s.IgnoreWhitespace = true; + XmlReader r1 = XmlReader.Create(new StringReader(doc.OuterXml), s, doc.BaseURI); + XmlReader r2 = XmlReader.Create(result, s); try { while (r1.Read()) @@ -395,8 +396,8 @@ return File.OpenRead("../../results/document.xml"); } else if (absoluteUri.Scheme == "xmlreader") - { - return new XmlTextReader(absoluteUri.AbsoluteUri, new StringReader(@"<text attr=""val"">From custom resolver (as XmlReader)</text>")); + { + return XmlReader.Create(new StringReader(@"<text attr=""val"">From custom resolver (as XmlReader)</text>"), null, absoluteUri.AbsoluteUri); } else return base.GetEntity(absoluteUri, role, ofObjectToReturn); |
From: Oleg T. <he...@us...> - 2005-10-29 11:51:44
|
Update of /cvsroot/mvp-xml/XInclude/v2/test/XInclude-Test-Suite/Nist/ents In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31153/v2/test/XInclude-Test-Suite/Nist/ents Added Files: 004.ent Log Message: --- NEW FILE: 004.ent --- Data |
From: Oleg T. <he...@us...> - 2005-10-29 11:51:43
|
Update of /cvsroot/mvp-xml/XInclude/v1/test/tests In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31153/v1/test/tests Modified Files: document.xml Log Message: Index: document.xml =================================================================== RCS file: /cvsroot/mvp-xml/XInclude/v1/test/tests/document.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- document.xml 13 Oct 2004 17:47:00 -0000 1.1 +++ document.xml 29 Oct 2005 11:51:35 -0000 1.2 @@ -1,6 +1,6 @@ <?xml version="1.0"?> <document xmlns:xi="http://www.w3.org/2003/XInclude"> <p>120 Mz is adequate for an average home user.</p> - <xi:include href="disclaimer.xml" parse="xml"><foo></foo></xi:include> + <xi:include hre2f="disclaimer.xml" parse="xml"><foo></foo></xi:include> foo </document> |
From: Oleg T. <he...@us...> - 2005-10-29 11:48:25
|
Update of /cvsroot/mvp-xml/XInclude/v2/test/XInclude-Test-Suite/Nist/ents In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30757/ents Log Message: Directory /cvsroot/mvp-xml/XInclude/v2/test/XInclude-Test-Suite/Nist/ents added to the repository |
From: Oleg T. <he...@us...> - 2005-10-29 11:45:50
|
Update of /cvsroot/mvp-xml/Common/v2/src/XPath In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30362/v2/src/XPath Modified Files: XPathIteratorReader.cs Log Message: Index: XPathIteratorReader.cs =================================================================== RCS file: /cvsroot/mvp-xml/Common/v2/src/XPath/XPathIteratorReader.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- XPathIteratorReader.cs 25 Oct 2005 21:33:44 -0000 1.2 +++ XPathIteratorReader.cs 29 Oct 2005 11:45:39 -0000 1.3 @@ -317,7 +317,7 @@ if (read) { // Just move to the next node and create the reader. - _current = _iterator.Current.ReadSubtree(); + _current = new SubtreeXPathNavigator(_iterator.Current).ReadSubtree(); return _current.Read(); } else |
From: Oleg T. <he...@us...> - 2005-10-29 11:45:47
|
Update of /cvsroot/mvp-xml/Common/v2/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30362/v2/src Modified Files: XmlBaseAwareXmlTextReader.cs Log Message: Index: XmlBaseAwareXmlTextReader.cs =================================================================== RCS file: /cvsroot/mvp-xml/Common/v2/src/XmlBaseAwareXmlTextReader.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- XmlBaseAwareXmlTextReader.cs 25 Oct 2005 21:33:43 -0000 1.3 +++ XmlBaseAwareXmlTextReader.cs 29 Oct 2005 11:45:39 -0000 1.4 @@ -33,6 +33,7 @@ : base(uri) { _state.BaseUri = new Uri(base.BaseURI); + } /// <summary> @@ -43,13 +44,17 @@ : base(uri, nt) { _state.BaseUri = new Uri(base.BaseURI); + } /// <summary> /// Creates XmlBaseAwareXmlTextReader instance for given TextReader. /// </summary> public XmlBaseAwareXmlTextReader(TextReader reader) - : base(reader) { } + : base(reader) + { + + } /// <summary> /// Creates XmlBaseAwareXmlTextReader instance for given uri and @@ -59,6 +64,7 @@ : base(uri, reader) { _state.BaseUri = new Uri(base.BaseURI); + } /// <summary> @@ -66,7 +72,10 @@ /// and name table. /// </summary> public XmlBaseAwareXmlTextReader(TextReader reader, XmlNameTable nt) - : base(reader, nt) { } + : base(reader, nt) + { + + } /// <summary> /// Creates XmlBaseAwareXmlTextReader instance for given uri, name table @@ -76,13 +85,17 @@ : base(uri, reader, nt) { _state.BaseUri = new Uri(base.BaseURI); + } /// <summary> /// Creates XmlBaseAwareXmlTextReader instance for given stream. /// </summary> public XmlBaseAwareXmlTextReader(Stream stream) - : base(stream) { } + : base(stream) + { + + } /// <summary> /// Creates XmlBaseAwareXmlTextReader instance for given uri and stream. @@ -91,6 +104,7 @@ : base(uri, stream) { _state.BaseUri = new Uri(base.BaseURI); + } /// <summary> @@ -98,7 +112,10 @@ /// and name table. /// </summary> public XmlBaseAwareXmlTextReader(Stream stream, XmlNameTable nt) - : base(stream, nt) { } + : base(stream, nt) + { + + } /// <summary> /// Creates XmlBaseAwareXmlTextReader instance for given stream, @@ -108,6 +125,7 @@ : base(uri, stream, nt) { _state.BaseUri = new Uri(base.BaseURI); + } #endregion |