libxslt-ruby 0.7.0-x86-mswin32-60 → 0.8.0-x86-mswin32-60
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README +141 -141
- data/doc/classes/LibXSLT.html +120 -0
- data/doc/classes/LibXSLT/XSLT.html +207 -0
- data/doc/classes/{XSLT → LibXSLT/XSLT}/Stylesheet.html +22 -17
- data/doc/classes/LibXSLT/XSLT/TransformContext.html +111 -0
- data/doc/classes/{XSLT/TransformContext.html → LibXSLT/XSLTError.html} +5 -5
- data/doc/classes/XSLT.html +12 -103
- data/doc/created.rid +1 -1
- data/doc/files/CHANGES.html +18 -3
- data/doc/files/README.html +4 -4
- data/doc/files/ext/libxslt/libxslt_c.html +1 -1
- data/doc/files/ext/libxslt/ruby_xslt_stylesheet_c.html +1 -1
- data/doc/files/ext/libxslt/ruby_xslt_transform_context_c.html +1 -1
- data/doc/files/lib/{deprecated_rb.html → libxslt/deprecated_rb.html} +3 -3
- data/doc/files/lib/libxslt_rb.html +3 -3
- data/doc/fr_class_index.html +5 -2
- data/doc/fr_file_index.html +1 -1
- data/doc/fr_method_index.html +2 -2
- data/ext/libxslt/libxslt.c +22 -18
- data/ext/libxslt/libxslt.h +4 -6
- data/ext/libxslt/ruby_xslt_stylesheet.c +59 -41
- data/ext/libxslt/ruby_xslt_transform_context.c +3 -3
- data/ext/libxslt/version.h +2 -2
- data/lib/libxslt.rb +8 -2
- data/lib/libxslt/deprecated.rb +66 -0
- data/lib/libxslt_ruby.so +0 -0
- data/mingw/libxslt_ruby.so +0 -0
- data/setup.rb +1585 -0
- data/vc/libxslt_ruby.vcproj +2 -2
- metadata +16 -19
- data/lib/deprecated.rb +0 -66
- data/tests/files/commentary.dtd +0 -34
- data/tests/files/fuzface.xml +0 -154
- data/tests/files/fuzface.xsl +0 -4
- data/tests/files/params.xml +0 -2
- data/tests/files/params.xsl +0 -11
- data/tests/files/ramblings.xsl +0 -46
- data/tests/test_deprecated.rb +0 -99
- data/tests/test_libxslt.rb +0 -21
- data/tests/test_stylesheet.rb +0 -64
- data/tests/test_suite.rb +0 -3
@@ -5,10 +5,10 @@
|
|
5
5
|
|
6
6
|
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
7
7
|
<head>
|
8
|
-
<title>Class: XSLT::Stylesheet</title>
|
8
|
+
<title>Class: LibXSLT::XSLT::Stylesheet</title>
|
9
9
|
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
10
|
<meta http-equiv="Content-Script-Type" content="text/javascript" />
|
11
|
-
<link rel="stylesheet" href="
|
11
|
+
<link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
|
12
12
|
<script type="text/javascript">
|
13
13
|
// <![CDATA[
|
14
14
|
|
@@ -50,12 +50,12 @@
|
|
50
50
|
<table class="header-table">
|
51
51
|
<tr class="top-aligned-row">
|
52
52
|
<td><strong>Class</strong></td>
|
53
|
-
<td class="class-name-in-header">XSLT::Stylesheet</td>
|
53
|
+
<td class="class-name-in-header">LibXSLT::XSLT::Stylesheet</td>
|
54
54
|
</tr>
|
55
55
|
<tr class="top-aligned-row">
|
56
56
|
<td><strong>In:</strong></td>
|
57
57
|
<td>
|
58
|
-
<a href="
|
58
|
+
<a href="../../../files/ext/libxslt/ruby_xslt_stylesheet_c.html">
|
59
59
|
ext/libxslt/ruby_xslt_stylesheet.c
|
60
60
|
</a>
|
61
61
|
<br />
|
@@ -131,7 +131,9 @@ href="Stylesheet.html#M000002">XSLT::Stylesheet#apply</a>
|
|
131
131
|
<div class="method-description">
|
132
132
|
<p>
|
133
133
|
Creates a new <a href="../XSLT.html">XSLT</a> stylesheet based on the
|
134
|
-
|
134
|
+
specified document. For memory management reasons, a copy of the specified
|
135
|
+
document will be made, so its best to create a single copy of a stylesheet
|
136
|
+
and use it multiple times.
|
135
137
|
</p>
|
136
138
|
<pre>
|
137
139
|
stylesheet_doc = XML::Document.file('stylesheet_file')
|
@@ -144,7 +146,10 @@ provided document.
|
|
144
146
|
/* call-seq:
|
145
147
|
* XSLT::Stylesheet.new(document) -> XSLT::Stylesheet
|
146
148
|
*
|
147
|
-
* Creates a new XSLT stylesheet based on the
|
149
|
+
* Creates a new XSLT stylesheet based on the specified document.
|
150
|
+
* For memory management reasons, a copy of the specified document
|
151
|
+
* will be made, so its best to create a single copy of a stylesheet
|
152
|
+
* and use it multiple times.
|
148
153
|
*
|
149
154
|
* stylesheet_doc = XML::Document.file('stylesheet_file')
|
150
155
|
* stylesheet = XSLT::Stylesheet.new(stylesheet_doc)
|
@@ -178,13 +183,15 @@ may be invoked multiple times.
|
|
178
183
|
<p>
|
179
184
|
Params:
|
180
185
|
</p>
|
181
|
-
<
|
182
|
-
document
|
183
|
-
|
184
|
-
</
|
185
|
-
<
|
186
|
-
|
187
|
-
|
186
|
+
<ul>
|
187
|
+
<li>document - An instance of an XML::Document
|
188
|
+
|
189
|
+
</li>
|
190
|
+
<li>params - An optional hash table that specifies the values for xsl:param
|
191
|
+
values embedded in the stylesheet.
|
192
|
+
|
193
|
+
</li>
|
194
|
+
</ul>
|
188
195
|
<p>
|
189
196
|
Example:
|
190
197
|
</p>
|
@@ -207,10 +214,8 @@ Example:
|
|
207
214
|
* This method may be invoked multiple times.
|
208
215
|
*
|
209
216
|
* Params:
|
210
|
-
*
|
211
|
-
*
|
212
|
-
* params = An optional hash table that specifies the values
|
213
|
-
* for xsl:param values embedded in the stylesheet.
|
217
|
+
* * document - An instance of an XML::Document
|
218
|
+
* * params - An optional hash table that specifies the values for xsl:param values embedded in the stylesheet.
|
214
219
|
*
|
215
220
|
* Example:
|
216
221
|
*
|
@@ -0,0 +1,111 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
7
|
+
<head>
|
8
|
+
<title>Class: LibXSLT::XSLT::TransformContext</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<meta http-equiv="Content-Script-Type" content="text/javascript" />
|
11
|
+
<link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
|
12
|
+
<script type="text/javascript">
|
13
|
+
// <![CDATA[
|
14
|
+
|
15
|
+
function popupCode( url ) {
|
16
|
+
window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
|
17
|
+
}
|
18
|
+
|
19
|
+
function toggleCode( id ) {
|
20
|
+
if ( document.getElementById )
|
21
|
+
elem = document.getElementById( id );
|
22
|
+
else if ( document.all )
|
23
|
+
elem = eval( "document.all." + id );
|
24
|
+
else
|
25
|
+
return false;
|
26
|
+
|
27
|
+
elemStyle = elem.style;
|
28
|
+
|
29
|
+
if ( elemStyle.display != "block" ) {
|
30
|
+
elemStyle.display = "block"
|
31
|
+
} else {
|
32
|
+
elemStyle.display = "none"
|
33
|
+
}
|
34
|
+
|
35
|
+
return true;
|
36
|
+
}
|
37
|
+
|
38
|
+
// Make codeblocks hidden by default
|
39
|
+
document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
|
40
|
+
|
41
|
+
// ]]>
|
42
|
+
</script>
|
43
|
+
|
44
|
+
</head>
|
45
|
+
<body>
|
46
|
+
|
47
|
+
|
48
|
+
|
49
|
+
<div id="classHeader">
|
50
|
+
<table class="header-table">
|
51
|
+
<tr class="top-aligned-row">
|
52
|
+
<td><strong>Class</strong></td>
|
53
|
+
<td class="class-name-in-header">LibXSLT::XSLT::TransformContext</td>
|
54
|
+
</tr>
|
55
|
+
<tr class="top-aligned-row">
|
56
|
+
<td><strong>In:</strong></td>
|
57
|
+
<td>
|
58
|
+
<a href="../../../files/ext/libxslt/ruby_xslt_stylesheet_c.html">
|
59
|
+
ext/libxslt/ruby_xslt_stylesheet.c
|
60
|
+
</a>
|
61
|
+
<br />
|
62
|
+
</td>
|
63
|
+
</tr>
|
64
|
+
|
65
|
+
<tr class="top-aligned-row">
|
66
|
+
<td><strong>Parent:</strong></td>
|
67
|
+
<td>
|
68
|
+
Object
|
69
|
+
</td>
|
70
|
+
</tr>
|
71
|
+
</table>
|
72
|
+
</div>
|
73
|
+
<!-- banner header -->
|
74
|
+
|
75
|
+
<div id="bodyContent">
|
76
|
+
|
77
|
+
|
78
|
+
|
79
|
+
<div id="contextContent">
|
80
|
+
|
81
|
+
|
82
|
+
|
83
|
+
</div>
|
84
|
+
|
85
|
+
|
86
|
+
</div>
|
87
|
+
|
88
|
+
|
89
|
+
<!-- if includes -->
|
90
|
+
|
91
|
+
<div id="section">
|
92
|
+
|
93
|
+
|
94
|
+
|
95
|
+
|
96
|
+
|
97
|
+
|
98
|
+
|
99
|
+
|
100
|
+
<!-- if method_list -->
|
101
|
+
|
102
|
+
|
103
|
+
</div>
|
104
|
+
|
105
|
+
|
106
|
+
<div id="validator-badges">
|
107
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
108
|
+
</div>
|
109
|
+
|
110
|
+
</body>
|
111
|
+
</html>
|
@@ -5,7 +5,7 @@
|
|
5
5
|
|
6
6
|
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
7
7
|
<head>
|
8
|
-
<title>Class:
|
8
|
+
<title>Class: LibXSLT::XSLTError</title>
|
9
9
|
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
10
|
<meta http-equiv="Content-Script-Type" content="text/javascript" />
|
11
11
|
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
@@ -50,13 +50,13 @@
|
|
50
50
|
<table class="header-table">
|
51
51
|
<tr class="top-aligned-row">
|
52
52
|
<td><strong>Class</strong></td>
|
53
|
-
<td class="class-name-in-header">
|
53
|
+
<td class="class-name-in-header">LibXSLT::XSLTError</td>
|
54
54
|
</tr>
|
55
55
|
<tr class="top-aligned-row">
|
56
56
|
<td><strong>In:</strong></td>
|
57
57
|
<td>
|
58
|
-
<a href="../../files/ext/libxslt/
|
59
|
-
ext/libxslt/
|
58
|
+
<a href="../../files/ext/libxslt/libxslt_c.html">
|
59
|
+
ext/libxslt/libxslt.c
|
60
60
|
</a>
|
61
61
|
<br />
|
62
62
|
</td>
|
@@ -65,7 +65,7 @@
|
|
65
65
|
<tr class="top-aligned-row">
|
66
66
|
<td><strong>Parent:</strong></td>
|
67
67
|
<td>
|
68
|
-
|
68
|
+
RuntimeError
|
69
69
|
</td>
|
70
70
|
</tr>
|
71
71
|
</table>
|
data/doc/classes/XSLT.html
CHANGED
@@ -59,12 +59,8 @@
|
|
59
59
|
ext/libxslt/libxslt.c
|
60
60
|
</a>
|
61
61
|
<br />
|
62
|
-
<a href="../files/
|
63
|
-
|
64
|
-
</a>
|
65
|
-
<br />
|
66
|
-
<a href="../files/ext/libxslt/ruby_xslt_transform_context_c.html">
|
67
|
-
ext/libxslt/ruby_xslt_transform_context.c
|
62
|
+
<a href="../files/lib/libxslt_rb.html">
|
63
|
+
lib/libxslt.rb
|
68
64
|
</a>
|
69
65
|
<br />
|
70
66
|
</td>
|
@@ -82,19 +78,10 @@
|
|
82
78
|
|
83
79
|
<div id="description">
|
84
80
|
<p>
|
85
|
-
|
86
|
-
|
81
|
+
Map the <a href="LibXSLT.html">LibXSLT</a> module into the <a
|
82
|
+
href="XSLT.html">XSLT</a> module for both backwards compatibility and ease
|
83
|
+
of use.
|
87
84
|
</p>
|
88
|
-
<p>
|
89
|
-
Using the bindings is straightforward:
|
90
|
-
</p>
|
91
|
-
<pre>
|
92
|
-
stylesheet_doc = XML::Document.file('stylesheet_file')
|
93
|
-
stylesheet = XSLT::Stylesheet.new(stylesheet_doc)
|
94
|
-
|
95
|
-
xml_doc = XML::Document.file('xml_file')
|
96
|
-
result = stylesheet.apply(xml_doc)
|
97
|
-
</pre>
|
98
85
|
|
99
86
|
</div>
|
100
87
|
|
@@ -106,95 +93,17 @@ Using the bindings is straightforward:
|
|
106
93
|
|
107
94
|
|
108
95
|
<!-- if includes -->
|
96
|
+
<div id="includes">
|
97
|
+
<h3 class="section-bar">Included Modules</h3>
|
109
98
|
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
<h3 class="section-bar">Classes and Modules</h3>
|
114
|
-
|
115
|
-
Class <a href="XSLT/Stylesheet.html" class="link">XSLT::Stylesheet</a><br />
|
116
|
-
Class <a href="XSLT/TransformContext.html" class="link">XSLT::TransformContext</a><br />
|
117
|
-
|
99
|
+
<div id="includes-list">
|
100
|
+
<span class="include-name"><a href="LibXSLT/XSLT.html">LibXSLT::XSLT</a></span>
|
101
|
+
</div>
|
118
102
|
</div>
|
119
103
|
|
120
|
-
<div id="
|
121
|
-
|
104
|
+
<div id="section">
|
105
|
+
|
122
106
|
|
123
|
-
<div class="name-list">
|
124
|
-
<table summary="Constants">
|
125
|
-
<tr class="top-aligned-row context-row">
|
126
|
-
<td class="context-item-name">MAX_DEPTH</td>
|
127
|
-
<td>=</td>
|
128
|
-
<td class="context-item-value">INT2NUM(xsltMaxDepth)</td>
|
129
|
-
</tr>
|
130
|
-
<tr class="top-aligned-row context-row">
|
131
|
-
<td class="context-item-name">MAX_SORT</td>
|
132
|
-
<td>=</td>
|
133
|
-
<td class="context-item-value">INT2NUM(XSLT_MAX_SORT)</td>
|
134
|
-
</tr>
|
135
|
-
<tr class="top-aligned-row context-row">
|
136
|
-
<td class="context-item-name">ENGINE_VERSION</td>
|
137
|
-
<td>=</td>
|
138
|
-
<td class="context-item-value">rb_str_new2(xsltEngineVersion)</td>
|
139
|
-
</tr>
|
140
|
-
<tr class="top-aligned-row context-row">
|
141
|
-
<td class="context-item-name">LIBXSLT_VERSION</td>
|
142
|
-
<td>=</td>
|
143
|
-
<td class="context-item-value">INT2NUM(xsltLibxsltVersion)</td>
|
144
|
-
</tr>
|
145
|
-
<tr class="top-aligned-row context-row">
|
146
|
-
<td class="context-item-name">LIBXML_VERSION</td>
|
147
|
-
<td>=</td>
|
148
|
-
<td class="context-item-value">INT2NUM(xsltLibxmlVersion)</td>
|
149
|
-
</tr>
|
150
|
-
<tr class="top-aligned-row context-row">
|
151
|
-
<td class="context-item-name">XSLT_NAMESPACE</td>
|
152
|
-
<td>=</td>
|
153
|
-
<td class="context-item-value">rb_str_new2((const char*)XSLT_NAMESPACE)</td>
|
154
|
-
</tr>
|
155
|
-
<tr class="top-aligned-row context-row">
|
156
|
-
<td class="context-item-name">DEFAULT_VENDOR</td>
|
157
|
-
<td>=</td>
|
158
|
-
<td class="context-item-value">rb_str_new2(XSLT_DEFAULT_VENDOR)</td>
|
159
|
-
</tr>
|
160
|
-
<tr class="top-aligned-row context-row">
|
161
|
-
<td class="context-item-name">DEFAULT_VERSION</td>
|
162
|
-
<td>=</td>
|
163
|
-
<td class="context-item-value">rb_str_new2(XSLT_DEFAULT_VERSION)</td>
|
164
|
-
</tr>
|
165
|
-
<tr class="top-aligned-row context-row">
|
166
|
-
<td class="context-item-name">DEFAULT_URL</td>
|
167
|
-
<td>=</td>
|
168
|
-
<td class="context-item-value">rb_str_new2(XSLT_DEFAULT_URL)</td>
|
169
|
-
</tr>
|
170
|
-
<tr class="top-aligned-row context-row">
|
171
|
-
<td class="context-item-name">NAMESPACE_LIBXSLT</td>
|
172
|
-
<td>=</td>
|
173
|
-
<td class="context-item-value">rb_str_new2((const char*)XSLT_LIBXSLT_NAMESPACE)</td>
|
174
|
-
</tr>
|
175
|
-
<tr class="top-aligned-row context-row">
|
176
|
-
<td class="context-item-name">NAMESPACE_NORM_SAXON</td>
|
177
|
-
<td>=</td>
|
178
|
-
<td class="context-item-value">rb_str_new2((const char*)XSLT_NORM_SAXON_NAMESPACE)</td>
|
179
|
-
</tr>
|
180
|
-
<tr class="top-aligned-row context-row">
|
181
|
-
<td class="context-item-name">NAMESPACE_SAXON</td>
|
182
|
-
<td>=</td>
|
183
|
-
<td class="context-item-value">rb_str_new2((const char*)XSLT_SAXON_NAMESPACE)</td>
|
184
|
-
</tr>
|
185
|
-
<tr class="top-aligned-row context-row">
|
186
|
-
<td class="context-item-name">NAMESPACE_XT</td>
|
187
|
-
<td>=</td>
|
188
|
-
<td class="context-item-value">rb_str_new2((const char*)XSLT_XT_NAMESPACE)</td>
|
189
|
-
</tr>
|
190
|
-
<tr class="top-aligned-row context-row">
|
191
|
-
<td class="context-item-name">NAMESPACE_XALAN</td>
|
192
|
-
<td>=</td>
|
193
|
-
<td class="context-item-value">rb_str_new2((const char*)XSLT_XALAN_NAMESPACE)</td>
|
194
|
-
</tr>
|
195
|
-
</table>
|
196
|
-
</div>
|
197
|
-
</div>
|
198
107
|
|
199
108
|
|
200
109
|
|
data/doc/created.rid
CHANGED
@@ -1 +1 @@
|
|
1
|
-
|
1
|
+
Tue Jul 15 15:49:20 Mountain Daylight Time 2008
|
data/doc/files/CHANGES.html
CHANGED
@@ -56,7 +56,7 @@
|
|
56
56
|
</tr>
|
57
57
|
<tr class="top-aligned-row">
|
58
58
|
<td><strong>Last Update:</strong></td>
|
59
|
-
<td>
|
59
|
+
<td>Tue Jul 15 15:48:39 Mountain Daylight Time 2008</td>
|
60
60
|
</tr>
|
61
61
|
</table>
|
62
62
|
</div>
|
@@ -69,9 +69,24 @@
|
|
69
69
|
<div id="contextContent">
|
70
70
|
|
71
71
|
<div id="description">
|
72
|
-
<h2>0.
|
72
|
+
<h2>0.8.0 / 2008-07-10 Charlie Savage</h2>
|
73
73
|
<ul>
|
74
|
-
<li>
|
74
|
+
<li>Fix memory errors when reusing a stylehseet
|
75
|
+
|
76
|
+
</li>
|
77
|
+
<li>Added support for setting xsl::param values
|
78
|
+
|
79
|
+
</li>
|
80
|
+
<li>Updated RDocs.
|
81
|
+
|
82
|
+
</li>
|
83
|
+
<li>Moved to <a href="../classes/LibXSLT.html">LibXSLT</a> namespace
|
84
|
+
|
85
|
+
</li>
|
86
|
+
</ul>
|
87
|
+
<h2>0.7.0 / 2008-07-10 Charlie Savage</h2>
|
88
|
+
<ul>
|
89
|
+
<li>Ability to reuse the same stylesheet multiple times
|
75
90
|
|
76
91
|
</li>
|
77
92
|
<li>Simpler api
|
data/doc/files/README.html
CHANGED
@@ -56,7 +56,7 @@
|
|
56
56
|
</tr>
|
57
57
|
<tr class="top-aligned-row">
|
58
58
|
<td><strong>Last Update:</strong></td>
|
59
|
-
<td>
|
59
|
+
<td>Tue Jul 15 15:48:25 Mountain Daylight Time 2008</td>
|
60
60
|
</tr>
|
61
61
|
</table>
|
62
62
|
</div>
|
@@ -150,8 +150,8 @@ Given an XML file like:
|
|
150
150
|
<email>sean@chittenden.org</email>
|
151
151
|
</author>
|
152
152
|
<version>$Version$</version>
|
153
|
-
<date>$Date: 2008-07-
|
154
|
-
<id>$Id: README
|
153
|
+
<date>$Date: 2008-07-14 21:23:19 -0600 (Mon, 14 Jul 2008) $</date>
|
154
|
+
<id>$Id: README 94 2008-07-15 03:23:19Z cfis $</id> <title>Fuzface...</title>
|
155
155
|
<subtitle>The Internet's a big place and here's some proof...</subtitle>
|
156
156
|
</meta>
|
157
157
|
|
@@ -206,7 +206,7 @@ We can easily transform the XML with the following ruby code:
|
|
206
206
|
|
207
207
|
# Create a new XSL Transform
|
208
208
|
stylesheet_doc = XML::Document.file('files/fuzface.xsl')
|
209
|
-
stylesheet =
|
209
|
+
stylesheet = LibXSLT::Stylesheet.new(stylesheet_doc)
|
210
210
|
|
211
211
|
# Transform a xml document
|
212
212
|
xml_doc = XML::Document.file('files/fuzface.xml')
|