-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

You can see how it's done with an example from Gert found here:

https://github.com/fcrepo/gsearch/blob/master/FgsConfig/FgsConfigIndexTemplate/Lucene/foxmlToLucene.xslt

Notice how he declares the namespace:

xmlns:exts="xalan://dk.defxws.fedoragsearch.server.GenericOperationsImpl"

in his XSLT XML and then uses function calls like:

                                <xsl:value-of disable-output-escaping="yes" 
select="exts:getDatastreamFromTika($PID, $REPOSITORYNAME, @ID, 'IndexField', 
concat('ds.', @ID), concat('dsmd_', @ID, '.'), '', $FEDORASOAP, $FEDORAUSER, 
$FEDORAPASS, $TRUSTSTOREPATH, $TRUSTSTOREPASS)"/>

later in his code. This is a pretty usual way to incorporate extension 
functions in XSLT, although of course, the use here is specific to Xalan.

- ---
A. Soroka
Software & Systems Engineering :: Online Library Environment
the University of Virginia Library

On Mar 12, 2012, at 2:03 PM, Remi Malessa wrote:

> That sounds great. Could you tell me how to add these extra functions to 
> XSLT, please?
> 
> Remi
> 
> On 03/12/2012 03:43 PM, [email protected] wrote:
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: SHA1
>> 
>> You can pass authentication credentials to retrieve datastreams and 
>> disseminations in the XSLT by using GSearch extension functions instead of 
>> using the built-in XPath/XSLT functions. For example, the signature of 
>> getDatastreamText is:
>> 
>> getDatastreamText(String pid, String repositoryName, String dsId, String 
>> fedoraSoap, String fedoraUser, String fedoraPass, String trustStorePath, 
>> String trustStorePass)
>> 
>> and getDatastreamTextFromTika(), getDatastreamMetadataFromTika(), 
>> getDisseminationText(), etc. look very similar. You can see where you could 
>> insert credentials as part of the retrieval.
>> 
>> - ---
>> A. Soroka
>> Software&  Systems Engineering :: Online Library Environment
>> the University of Virginia Library
>> 
>> On Mar 12, 2012, at 9:47 AM, Remi Malessa wrote:
> 
> 
> 
> ------------------------------------------------------------------------------
> Try before you buy = See our experts in action!
> The most comprehensive online learning library for Microsoft developers
> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
> Metro Style Apps, more. Free future releases when you subscribe now!
> http://p.sf.net/sfu/learndevnow-dev2
> _______________________________________________
> Fedora-commons-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/fedora-commons-users

-----BEGIN PGP SIGNATURE-----
Version: GnuPG/MacGPG2 v2.0.17 (Darwin)
Comment: GPGTools - http://gpgtools.org

iQEcBAEBAgAGBQJPXjxaAAoJEATpPYSyaoIk7AEH/3V9MKHSvdvlttwu0/QieH4l
krti34RrcDNoCZ+2xqHX6e5CkZKVt9rs4++uKDwKo62vYNp9N0Fri+9UqcI4G8wm
kocgVXGtyEQibNX9HiKWOEVjSoVtM740qVjJjq0jyS1W28b91XsSF2YF5noU6CS2
Sle8XU6d2JfriTDB54Ilo0irNXLaK8Qu/SSIHscoul1H0mzZ7HgekQ69cCeh90VJ
OHkrOkoEjs5xiheds6tc7TUcBmKoM90jUYHvLg6pH0ekPv390kEQAtsYs/8irqRM
I/jlv+XOazMQT+pv5kctUEZZXGl4t9rH0yPcD/sbw568JPtsmGQ3JuvVly5Hvjg=
=IyqL
-----END PGP SIGNATURE-----

------------------------------------------------------------------------------
Try before you buy = See our experts in action!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-dev2
_______________________________________________
Fedora-commons-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fedora-commons-users

Reply via email to