Sophie

Sophie

distrib > Mageia > 7 > armv7hl > by-pkgid > b3bdfe6d859a3d6920ff2c44b38e9a6f > files > 2420

saxon-manual-9.4.0.9-2.mga7.noarch.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc (build 1.6.0_18) on Fri Dec 09 20:48:26 GMT 2011 -->
<TITLE>
ExtensionFunction
</TITLE>

<META NAME="date" CONTENT="2011-12-09">

<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">

<SCRIPT type="text/javascript">
function windowTitle()
{
    if (location.href.indexOf('is-external=true') == -1) {
        parent.document.title="ExtensionFunction";
    }
}
</SCRIPT>
<NOSCRIPT>
</NOSCRIPT>

</HEAD>

<BODY BGCOLOR="white" onload="windowTitle();">
<HR>


<!-- ========= START OF TOP NAVBAR ======= -->
<A NAME="navbar_top"><!-- --></A>
<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
  <TR ALIGN="center" VALIGN="top">
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
  </TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>

<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../net/sf/saxon/s9api/DOMDestination.html" title="class in net.sf.saxon.s9api"><B>PREV CLASS</B></A>&nbsp;
&nbsp;<A HREF="../../../../net/sf/saxon/s9api/ItemType.html" title="class in net.sf.saxon.s9api"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  <A HREF="../../../../index.html?net/sf/saxon/s9api/ExtensionFunction.html" target="_top"><B>FRAMES</B></A>  &nbsp;
&nbsp;<A HREF="ExtensionFunction.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
&nbsp;<SCRIPT type="text/javascript">
  <!--
  if(window==top) {
    document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
  }
  //-->
</SCRIPT>
<NOSCRIPT>
  <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>


</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_top"></A>
<!-- ========= END OF TOP NAVBAR ========= -->

<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
net.sf.saxon.s9api</FONT>
<BR>
Interface ExtensionFunction</H2>
<HR>
<DL>
<DT><PRE>public interface <B>ExtensionFunction</B></DL>
</PRE>

<P>
This is an interface for simple external/extension functions. Users can implement this
 interface and register the implementation with the <A HREF="../../../../net/sf/saxon/s9api/Processor.html" title="class in net.sf.saxon.s9api"><CODE>Processor</CODE></A>; the function will
 then be available for calling from all queries, stylesheets, and XPath expressions compiled
 under this Processor.

 Extension functions implemented using this interface are expected to be free of side-effects,
 and to have no dependencies on the static or dynamic context. A richer interface for extension
 functions is provided via the <A HREF="../../../../net/sf/saxon/lib/ExtensionFunctionDefinition.html" title="class in net.sf.saxon.lib"><CODE>ExtensionFunctionDefinition</CODE></A> class.
<P>

<P>
<HR>

<P>

<!-- ========== METHOD SUMMARY =========== -->

<A NAME="method_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Method Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../../net/sf/saxon/s9api/XdmValue.html" title="class in net.sf.saxon.s9api">XdmValue</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../net/sf/saxon/s9api/ExtensionFunction.html#call(net.sf.saxon.s9api.XdmValue[])">call</A></B>(<A HREF="../../../../net/sf/saxon/s9api/XdmValue.html" title="class in net.sf.saxon.s9api">XdmValue</A>[]&nbsp;arguments)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Call the function.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../../net/sf/saxon/s9api/SequenceType.html" title="class in net.sf.saxon.s9api">SequenceType</A>[]</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../net/sf/saxon/s9api/ExtensionFunction.html#getArgumentTypes()">getArgumentTypes</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Declare the types of the arguments</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../../net/sf/saxon/s9api/QName.html" title="class in net.sf.saxon.s9api">QName</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../net/sf/saxon/s9api/ExtensionFunction.html#getName()">getName</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Return the name of the external function</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../../net/sf/saxon/s9api/SequenceType.html" title="class in net.sf.saxon.s9api">SequenceType</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../net/sf/saxon/s9api/ExtensionFunction.html#getResultType()">getResultType</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Declare the result type of the external function</TD>
</TR>
</TABLE>
&nbsp;
<P>

<!-- ============ METHOD DETAIL ========== -->

<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Method Detail</B></FONT></TH>
</TR>
</TABLE>

<A NAME="getName()"><!-- --></A><H3>
getName</H3>
<PRE>
<A HREF="../../../../net/sf/saxon/s9api/QName.html" title="class in net.sf.saxon.s9api">QName</A> <B>getName</B>()</PRE>
<DL>
<DD>Return the name of the external function
<P>
<DD><DL>

<DT><B>Returns:</B><DD>the name of the function, as a QName.</DL>
</DD>
</DL>
<HR>

<A NAME="getResultType()"><!-- --></A><H3>
getResultType</H3>
<PRE>
<A HREF="../../../../net/sf/saxon/s9api/SequenceType.html" title="class in net.sf.saxon.s9api">SequenceType</A> <B>getResultType</B>()</PRE>
<DL>
<DD>Declare the result type of the external function
<P>
<DD><DL>

<DT><B>Returns:</B><DD>the result type of the external function</DL>
</DD>
</DL>
<HR>

<A NAME="getArgumentTypes()"><!-- --></A><H3>
getArgumentTypes</H3>
<PRE>
<A HREF="../../../../net/sf/saxon/s9api/SequenceType.html" title="class in net.sf.saxon.s9api">SequenceType</A>[] <B>getArgumentTypes</B>()</PRE>
<DL>
<DD>Declare the types of the arguments
<P>
<DD><DL>

<DT><B>Returns:</B><DD>a sequence of SequenceType objects, one for each argument to the function,
 representing the expected types of the arguments</DL>
</DD>
</DL>
<HR>

<A NAME="call(net.sf.saxon.s9api.XdmValue[])"><!-- --></A><H3>
call</H3>
<PRE>
<A HREF="../../../../net/sf/saxon/s9api/XdmValue.html" title="class in net.sf.saxon.s9api">XdmValue</A> <B>call</B>(<A HREF="../../../../net/sf/saxon/s9api/XdmValue.html" title="class in net.sf.saxon.s9api">XdmValue</A>[]&nbsp;arguments)
              throws <A HREF="../../../../net/sf/saxon/s9api/SaxonApiException.html" title="class in net.sf.saxon.s9api">SaxonApiException</A></PRE>
<DL>
<DD>Call the function. The implementation of this method represents the body of the external function.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>arguments</CODE> - the arguments, as supplied in the XPath function call. These will always be of
 the declared types. Arguments are converted to the required types according to the standard XPath
 function conversion rules - for example, if the expected type is atomic and a node is supplied in the
 call, the node will be atomized
<DT><B>Returns:</B><DD>the result of the function. This must be an instance of the declared return type; if it is not,
 a dynamic error will be reported
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../../net/sf/saxon/s9api/SaxonApiException.html" title="class in net.sf.saxon.s9api">SaxonApiException</A></CODE> - can be thrown if the implementation of the function detects a dynamic error</DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>


<!-- ======= START OF BOTTOM NAVBAR ====== -->
<A NAME="navbar_bottom"><!-- --></A>
<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
  <TR ALIGN="center" VALIGN="top">
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
  </TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>

<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../net/sf/saxon/s9api/DOMDestination.html" title="class in net.sf.saxon.s9api"><B>PREV CLASS</B></A>&nbsp;
&nbsp;<A HREF="../../../../net/sf/saxon/s9api/ItemType.html" title="class in net.sf.saxon.s9api"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  <A HREF="../../../../index.html?net/sf/saxon/s9api/ExtensionFunction.html" target="_top"><B>FRAMES</B></A>  &nbsp;
&nbsp;<A HREF="ExtensionFunction.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
&nbsp;<SCRIPT type="text/javascript">
  <!--
  if(window==top) {
    document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
  }
  //-->
</SCRIPT>
<NOSCRIPT>
  <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>


</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_bottom"></A>
<!-- ======== END OF BOTTOM NAVBAR ======= -->

<HR>
Copyright (c) 2004-2011 Saxonica Limited. All rights reserved.
</BODY>
</HTML>