SYNTAX_CHECK CAttributeNode::CheckSyntax() { Dali::CEclExceptionVector errors; StlLinked<Dali::IDali> dali = Dali::AttachDali(GetIConfig(QUERYBUILDER_CFG)->Get(GLOBAL_SERVER_WORKUNIT), _T("Dali")); if (dali->CheckSyntax(_T("hthor"), GetIConfig(QUERYBUILDER_CFG)->Get(GLOBAL_QUEUE), m_attribute->GetModuleQualifiedLabel(), m_attribute->GetLabel(), _T(""), m_attribute->GetText(), -1, _T(""), false, false, errors)) { m_syntaxCheck = SYNTAX_CHECK_PASS; m_syntaxSummary.clear(); for(Dali::CEclExceptionVector::iterator itr = errors.begin(); itr != errors.end(); ++itr) { if (itr->get()->m_severity.CompareNoCase(SYNTAXWARNING) == 0) { m_syntaxCheck = SYNTAX_CHECK_WARN; if (m_syntaxSummary.length()) { m_syntaxSummary += LF; } m_syntaxSummary += itr->get()->m_severity + _T(": ") + itr->get()->m_message; } else if (itr->get()->m_severity.CompareNoCase(SYNTAXERROR) == 0) { m_syntaxCheck = SYNTAX_CHECK_FAIL; m_syntaxSummary = itr->get()->m_severity + _T(": ") + itr->get()->m_message; break; } } } return m_syntaxCheck; }
SYNTAX_CHECK CAttributeHistoryNode::CheckSyntax() { m_errors.clear(); StlLinked<Dali::IDali> dali = Dali::AttachDali(GetIConfig(QUERYBUILDER_CFG)->Get(GLOBAL_SERVER_WORKUNIT), _T("Dali")); if (dali->CheckSyntax(_T("hthor"), GetIConfig(QUERYBUILDER_CFG)->Get(GLOBAL_QUEUE), m_attributeHistory->GetAttribute()->GetModuleQualifiedLabel(), m_attributeHistory->GetAttribute()->GetLabel(), _T(""), m_attributeHistory->GetText(), -1, _T(""), false, false, m_errors)) { m_syntaxCheck = SYNTAX_CHECK_PASS; for(Dali::CEclExceptionVector::iterator itr = m_errors.begin(); itr != m_errors.end(); ++itr) { if (itr->get()->m_severity) { m_syntaxCheck = SYNTAX_CHECK_FAIL; break; } } } return m_syntaxCheck; }