/* * Copyright (c) 2001, DecisionSoft Limited All rights reserved. * Please see LICENSE.TXT for more information. */ #ifndef _FUNCTIONSUBTRACTDATETIMESYIELDINGYEARMONTHDURATION_HPP #define _FUNCTIONSUBTRACTDATETIMESYIELDINGYEARMONTHDURATION_HPP #include #include /** * Calculates the yearMonthDuration that is the difference between two * dateTimes. * * subtract-dateTimes-yielding-yearMonthDuration(dateTime $srcval1, i * dateTime $srcval2) => yearMonthDuration */ class PATHAN_EXPORT FunctionSubtractDateTimesYieldingYearMonthDuration : public DataItemFunction { public: static const XMLCh name[]; /** * Constructor. */ FunctionSubtractDateTimesYieldingYearMonthDuration(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 // _FUNCTIONSUBTRACTDATETIMESYIELDINGYEARMONTHDURATION_HPP