0
|
1 |
"{ Package: 'stx:goodies/xmlsuite/xquery' }"
|
|
2 |
|
|
3 |
"{ NameSpace: XQuery }"
|
|
4 |
|
|
5 |
Object subclass:#XQueryFunction
|
|
6 |
instanceVariableNames:''
|
|
7 |
classVariableNames:''
|
|
8 |
poolDictionaries:''
|
|
9 |
category:'XQuery-Functions'
|
|
10 |
!
|
|
11 |
|
|
12 |
!XQueryFunction class methodsFor:'documentation'!
|
|
13 |
|
|
14 |
documentation
|
|
15 |
|
|
16 |
"
|
|
17 |
I'm instance of function and I'm holded in interprete's
|
|
18 |
funcTable. I know my name as well as namespace uri in which
|
|
19 |
I'm.
|
|
20 |
|
|
21 |
To execute myself on conrete data, you have to 'instantiate' myself
|
|
22 |
using the #instantiate to obtain so called 'function instance'. Then
|
|
23 |
you have to fill the instance with particular content (as parameters,
|
|
24 |
interpreter and so on) and evaluate me (I'm actually a command pattern).
|
|
25 |
|
|
26 |
I've two main subclasses - NativeFunction and UserDefinedFunction. Note,
|
|
27 |
that NativeFunctions is his own 'function instance'.
|
|
28 |
"
|
|
29 |
! !
|
|
30 |
|
|
31 |
!XQueryFunction methodsFor:'function API'!
|
|
32 |
|
|
33 |
evaluateInContext: context withParameters:parameters forInterpreter:interpreter
|
|
34 |
|
|
35 |
"Evaluates an function. Should return an XQuery sequence"
|
|
36 |
|
|
37 |
^self subclassResponsibility
|
|
38 |
|
|
39 |
"Created: / 28-08-2007 / 22:50:13 / janfrog"
|
|
40 |
!
|
|
41 |
|
|
42 |
localName
|
|
43 |
|
|
44 |
^self subclassResponsibility
|
|
45 |
|
|
46 |
"Created: / 28-12-2006 / 12:02:11 / janfrog"
|
|
47 |
!
|
|
48 |
|
|
49 |
namespaceURI
|
|
50 |
|
|
51 |
^self subclassResponsibility
|
|
52 |
|
|
53 |
"Created: / 28-12-2006 / 12:02:23 / janfrog"
|
|
54 |
! !
|
|
55 |
|
|
56 |
!XQueryFunction class methodsFor:'documentation'!
|
|
57 |
|
|
58 |
version
|
|
59 |
^ '$Header: /opt/data/cvs/stx/goodies/xmlsuite/xquery/XQuery__XQueryFunction.st,v 1.5 2007-09-21 11:16:55 vranyj1 Exp $'
|
|
60 |
! !
|