本文整理汇总了C++中ComDiagsArea::contains方法的典型用法代码示例。如果您正苦于以下问题:C++ ComDiagsArea::contains方法的具体用法?C++ ComDiagsArea::contains怎么用?C++ ComDiagsArea::contains使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ComDiagsArea
的用法示例。
在下文中一共展示了ComDiagsArea::contains方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: sqlci_parser_handle_error
Int32 sqlci_parser_handle_error(SqlciNode **node, Lng32 retval)
{
NABoolean syntaxError_ = sqlci_DA.contains(-SQLCI_SYNTAX_ERROR);
if (retval && syntaxError_)
{
if (SqlciEnvGlobal->isReportWriterMode())
{
SqlciParseTree = (SqlciNode *)new SqlciRWQueryCmd(SqlciParse_OriginalStr,
(Lng32)strlen(SqlciParse_OriginalStr));
assert(SqlciParseTree->isSqlciNode());
*node = SqlciParseTree;
sqlci_DA.clear(); // clear the diagonistics
return 0;
}
else if (SqlciEnvGlobal->isMXCSMode())
{
SqlciParseTree = (SqlciNode *)new SqlciCSQueryCmd(SqlciParse_OriginalStr,
(Lng32)strlen(SqlciParse_OriginalStr));
assert(SqlciParseTree->isSqlciNode());
*node = SqlciParseTree;
sqlci_DA.clear(); // clear the diagonistics
return 0;
}
else
return retval;
}
else
return retval;
}
示例2: updateDiagsArea
// LCOV_EXCL_START
void ExSequenceTcb::updateDiagsArea( ExeErrorCode rc_)
{
ComDiagsArea *da = workAtp_->getDiagsArea();
if(!da)
{
da = ComDiagsArea::allocate(heap_);
workAtp_->setDiagsArea(da);
}
if (!da->contains((Lng32) -rc_))
{
*da << DgSqlCode(-rc_);
}
}
示例3: work
//.........这里部分代码省略.........
ComDiagsArea::allocate(getGlobals()->getDefaultHeap());
if (getenv("HP_FAKE_ERROR_8142"))
{
*diagsArea << DgSqlCode(-8142);
*diagsArea << DgString0(__FILE__);
*diagsArea << DgString1("cbServer_ is NULL");
}
else
*diagsArea << DgSqlCode(-2024);
}
else
cbServer_ = cliGlobals->getCbServerClass()->allocateServerProcess(
&diagsArea,
cliGlobals->getEnvironment()->getHeap(),
nodeName_,
cpu_,
IPC_PRIORITY_DONT_CARE,
FALSE, // usesTransactions
TRUE, // waitedCreation
2 // maxNowaitRequests -- cancel+(1 extra).
);
if (cbServer_ == NULL || cbServer_->getControlConnection() == NULL)
{
ex_assert(diagsArea != NULL,
"allocateServerProcess failed, but no diags");
// look for SQLCode 2024
// "*** ERROR[2024] Server Process $0~string0
// is not running or could not be created. Operating System
// Error $1~int0 was returned."
// Remap to cancel-specfic error 8028.
if (diagsArea->contains(-2024) &&
cancelTdb().actionIsCancel())
{
diagsArea->deleteError(diagsArea->returnIndex(-2024));
reportError(diagsArea, true, EXE_CANCEL_PROCESS_NOT_FOUND,
nodeName_, cpu_);
}
else
reportError(diagsArea);
step_ = DONE;
break;
}
// the reportError method was not called -- see break above.
if (diagsArea != NULL)
diagsArea->decrRefCount();
//Create the stream on the IpcHeap, since we don't dispose
// of it immediately. We just add it to the list of completed
// messages in the IpcEnv, and it is disposed of later.
cancelStream_ = new (cliGlobals->getIpcHeap())
CancelMsgStream(cliGlobals->getEnvironment(), this);
cancelStream_->addRecipient(cbServer_->getControlConnection());
}
step_ = SEND_MESSAGE;
break;
} // end case NOT_STARTED