/* * Copyright (c) 2001, DecisionSoft Limited All rights reserved. * Please see LICENSE.TXT for more information. */ #ifndef _FUNCTIONSUBTRACTDATESYIELDINGYEARMONTHDURATION_HPP #define _FUNCTIONSUBTRACTDATESYIELDINGYEARMONTHDURATION_HPP #include #include /** * Calculates the yearMonthDuration that is the difference between two * dates. * * subtract-dates-yielding-yearMonthDuration(date $srcval1, i * date $srcval2) => yearMonthDuration */ class PATHAN_EXPORT FunctionSubtractDatesYieldingYearMonthDuration : public DataItemFunction { public: static const XMLCh name[]; /** * Constructor. */ FunctionSubtractDatesYieldingYearMonthDuration(const VectorOfDataItems &args, XPath2MemoryManager* memMgr); DataItem* staticResolution(StaticContext *context, StaticResolutionContext *src); /** * Returns the yearMonthDuration that corresponds to the difference between the * value of $srcval1 and the value of $srcval2. */ Sequence collapseTreeInternal(DynamicContext* context, int flags=0) const; }; #endif // _FUNCTIONSUBTRACTDATESYIELDINGYEARMONTHDURATION_HPP