I read in the XQuery 1.0 spec that functions can be declared to be external, like variables. For example:
declare function do-something($arg1, $arg2) external; Does MarkLogic provide a way to set external functions? The spec says implementations are not required to support this: "An XQuery implementation may provide a facility whereby external functions can be implemented using a host programming language, but it is not required to do so." http://www.w3.org/TR/xquery/#dt-external-function I'm thinking there might be some value in this for being able to swap out implementations of certain functions at runtime and avoid having to do some module imports that may contribute to rigidity by importing the specific implementing module at a specific location. For example, instead of: import module namespace web-service "/some/ns" at "/modules/my-web-service-handler.xqy"; web-service:get-record("12345); have declare function get-record($key) external; get-record("12345")
_______________________________________________ General mailing list General@developer.marklogic.com http://developer.marklogic.com/mailman/listinfo/general