Add functions/types for XPath support.

Please wrap length at 80 characters when possible, and at 120 characters at worst.