summaryrefslogtreecommitdiff
path: root/libexslt/libexslt.3
blob: 83c57d3bdd2d16956a88f8e3202a834839aa8eb3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
.TH LIBEXSLT 3 "04 November 2003" libxslt
.SH NAME
libexslt \- extension library for XSLT
.SH SYNOPSIS
.B #include <libexslt/exslt.h>
.sp
.B void exsltCommonRegister(void);
.br
.B void exsltDateRegister(void);
.br
.B void exsltDynRegister(void);
.br
.B void exsltFuncRegister(void);
.br
.B void exsltMathRegister(void);
.br
.B void exsltSetsRegister(void);
.br
.B void exsltStrRegister(void);
.br
.B void exsltRegisterAll(void);
.br
.B void exsltSaxonRegister(void);
.SH DESCRIPTION
The 
.B libexslt
library is used to provide extensions to
.SM XSLT
functions. These extensions come from the
.SM EXSLT
project <http://www.exslt.org/>
.LP
.SH USAGE
To make use of these functions in
.SM XSLT
the appropriate namespace must be defined on the
.B xsl:stylesheet
element.  To enable support for them in 
.BR libxslt (3)
you must call the appropriate functions (listed in the
.B SYNOPSIS
section) to register the extensions.  The
.I xslt-config
shell script can be used to obtain the necessary flags for
the pre-processor and linker.
The supported extensions are:
.SS COMMON
.TP 2.2i
Namespace: http://exslt.org/common
.TP 2.2i
See http://www.exslt.org/exsl/index.html for a description.
.TP 2.2i
.B node-set()
convert the given RTF into a node-set.
.TP
.B object-type()
returns the type of the given argument.
.TP
.B document
Create multiple output documents. See http://www.exslt.org/exsl/elements/document/index.html

.SS MATH
.TP 2.2i
Namespace: http://exslt.org/math
.TP 2.2i
See http://www.exslt.org/math/index.html for a description.
.TP 2.2i
.B min()
returns the minimum value of the given node-set
.TP
.B max()
returns the maximum value of the given node-set
.TP
.B highest()
returns the nodes in the node-set whose value is the maximum value for the node-set.
.TP
.B lowest()
returns the nodes in the node-set whose value is the minimum value for the node-set.
.TP
.B constant()
returns a number value of the given constant with the given precision. The constants are PI, E, SQRRT2, LN2, LN10, LOG2E, and SQRT1_2.
.TP
.B random()
returns a random number between 0 and 1 inclusive.
.TP
.B abs()
returns the absolute value of the argument.
.TP
.B sqrt()
returns the square root of the argument.
.TP
.B power()
returns the power base and power arguments.
.TP
.B log()
returns the natural log of the argument.
.TP
.B sin()
returns the sine of the argument.
.TP
.B cos()
returns the cosine of the argument.
.TP
.B tan()
returns the tangent of the argument.
.TP
.B asin()
returns the arc sine of the argument.
.TP
.B acos()
returns the arc cosine of the argument.
.TP
.B atan()
returns the arc tangent of the argument.
.TP
.B atan2()
returns the arc tangent function of the y/x arguments.
.TP
.B exp()
returns the exponential function of the argument.

.SS SETS
.TP 2.2i
Namespace: http://exslt.org/sets
.TP 2.2i
See http://www.exslt.org/set/index.html for a description.
.TP 2.2i
.B difference()
returns the difference between the two given node-sets.
.TP
.B intersection()
returns a node-set of the nodes within both given node-sets.
.TP
.B distinct()
returns a node-set of all nodes in the first argument that are not in the seconds argument.
.TP
.B has-same-node()
returns TRUE if there is an intersection between the two given node-sets.
.TP
.B leading()
returns a node-set of all nodes in the first argument that precede the first node in the second argument.
.TP
.B trailing()
returns a node-set of all nodes in the first argument that follow the first node in the second argument.

.SS "DATES and TIMES"
.TP 2.2i
Namespace: http://exslt.org/dates-and-times
.TP 2.2i
See http://www.exslt.org/date/date.html for a description.
.TP 2.2i
.B date-time()
returns the current date and time as a date/time string.
.TP
.B date()
returns the date specified in the given date/time string.
.TP
.B time()
returns the time specified in the date/time string given as the argument.
.TP
.B year()
returns the year of a date as a number.
.TP
.B leap-year()
returns true if the year given in a date is a leap year.
.TP
.B month-in-year()
returns the month of a date as a number.
.TP
.B month-name()
returns the full name of the month of a date.
.TP
.B month-abbreviation()
returns the abbreviation of the month of a date.
.TP
.B week-in-year()
returns the week of the year as a number.
.TP
.B week-in-month()
returns the week in a month of a date as a number.
.TP
.B day-in-year()
returns the month of a date as a number.
.TP
.B day-in-month()
returns the day of a date as a number.
.TP
.B day-of-week-in-month()
returns the day-of-the-week in a month of a date as a number.
.TP
.B day-in-week()
returns the day of the week given in a date as a number.
.TP
.B day-name()
returns the full name of the day of the week of a date.
.TP
.B day-abbreviation()
returns the abbreviation of the day of the week of a date.
.TP
.B hour-in-day()
returns the hour of the day as a number.
.TP
.B minute-in-hour()
returns the minute of the hour as a number.
.TP
.B second-in-minute()
returns the second of the minute as a number.
.TP
.B seconds()
returns the number of seconds specified by the argument string.
.TP
.B add()
returns the date/time resulting from adding a duration to a date/time. 
.TP
.B add-duration()
returns the duration resulting from adding two given durations together. 
.TP
.B difference()
returns the duration between the first date and the second date.
.TP
.B duration()
returns a duration string that represents the given number of seconds since 1970-01-01T00:00:00.

.SS STRINGS
.TP 2.2i
Namespace: http://exslt.org/strings
.TP 2.2i
See http://www.exslt.org/str/index.html for a description.
.TP 2.2i
.B tokenize()
returns a node set of token elements, each containing one token from the string.
.TP
.B padding()
returns a string padded to a certain length.
.TP
.B align()
returns a string aligned within another string.
.TP
.B concat()
returns the concatenation of the string values of the nodes in that node set.

.SS FUNCTIONS
.TP 2.2i
Namespace: http://exslt.org/functions
.TP 2.2i
See http://www.exslt.org/func/index.html for a description.
.TP 2.2i
.B function
declares an extension function.
.TP
.B result
returns the result of an extension function declared in function().
.SH FILES
.TP
.I /usr/bin/xslt-config
shell script giving pre-processor and linker flags.
.TP
.I /usr/lib/libexslt.a
static library
.TP
.I /usr/lib/libexslt.so
sharable library
.SH AUTHORS
Manual page by Heiko W. Rupp (hwr@pilhuhn.de)
.SH "SEE ALSO"
.BR libxml (3), 
.BR libxslt (3), 
.BR xmllint (1)
.BR xsltproc (1), 
.\" end of manual page