## Package com.saxonica.functions.hof

The package `com.saxonica.hof` contains code to support higher-order functions.

See:
Description

Class Summary
AbstractFunctionItem: Abstract superclass (and factory class) for implementations of FunctionItem
CoercedFunction: A function item obtained by coercing a supplied function; this adds a wrapper to perform dynamic type checking of the arguments in any call, and type checking of the result.
CurriedFunction: A function obtained by currying another function, that is, the result of calling fn:partial-apply
DynamicFunctionCallDefinition: This class implements the extension function saxon:call(), which calls a FirstClassFunction previously set up using saxon:function().
DynamicFunctionCallDefinition.DynamicFunctionCall
DynamicFunctionConstructor: This class implements the extension function saxon:function(), which returns a FirstClassFunction object representing the function named in the first argument.
FilterFn: This class implements the function fn:filter(), which is a standard function in XQuery 1.1
FirstClassFunction: A FirstClassFunction is a value that encapsulates a function; it can therefore be manipulated like any other value: for example it can be assigned to a variable and passed as a parameter to a function.
FoldLeftFn: This class implements the function fn:fold-left(), which is a standard function in XQuery 1.1
FoldRightFn: This class implements the function fn:fold-right(), which is a standard function in XQuery 1.1
FunctionItemExpression: A FunctionItemExpression is a wrapper around a FunctionItem; it is an expression, whose value is the function item that it wraps.
FunctionSequenceCoercer: An FunctionSequenceCoercer performs function coercion on a sequence of function items
FunctionType: An instance of this class represents a specific function item type, for example function(xs:int) as xs:boolean
MapFn: This class implements the function fn:map(), which is a standard function in XQuery 1.1
MapPairsFn: This class implements the function fn:map-pairs(), which is a standard function in XQuery 1.1
UserFunctionItem: A UserFunctionItem is a function item representing a call on a user-defined function.

## Package com.saxonica.functions.hof Description

The package `com.saxonica.hof` contains code to support higher-order functions.

Higher-order functions are supported in XQuery 1.1 using native language syntax, and they are also available in other environments (including XSLT) using the Saxon extension functions `saxon:function()` and `saxon:call()`.

Michael H. Kay
Saxonica Limited
12 June 2009

Copyright (c) 2004-2010 Saxonica Limited. All rights reserved.