7#include "xfa/fxfa/parser/cxfa_calculate.h"
9#include "fxjs/xfa/cjx_node.h"
10#include "xfa/fxfa/parser/cxfa_document.h"
11#include "xfa/fxfa/parser/cxfa_message.h"
12#include "xfa/fxfa/parser/cxfa_script.h"
13#include "xfa/fxfa/parser/cxfa_text.h"
33CXFA_Calculate::CXFA_Calculate(CXFA_Document* doc,
XFA_PacketType packet)
36 {XFA_XDPPACKET::kTemplate, XFA_XDPPACKET::kForm},
38 XFA_Element::Calculate,
39 kCalculatePropertyData,
40 kCalculateAttributeData,
41 cppgc::MakeGarbageCollected<CJX_Node>(
42 doc->GetHeap()->GetAllocationHandle(),
54 return GetChild<CXFA_Script>(0,
XFA_Element::Script,
false);
58 const auto* pNode = GetChild<CXFA_Message>(0,
XFA_Element::Message,
false);
62 const auto* text = pNode->GetChild<CXFA_Text>(0,
XFA_Element::Text,
false);
63 return text ? text->GetContent() : WideString
();
~CXFA_Calculate() override
CXFA_Script * GetScriptIfExists()
XFA_AttributeValue GetOverride()
WideString GetMessageText() const