• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C++ NADELETEBASIC函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C++中NADELETEBASIC函数的典型用法代码示例。如果您正苦于以下问题:C++ NADELETEBASIC函数的具体用法?C++ NADELETEBASIC怎么用?C++ NADELETEBASIC使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了NADELETEBASIC函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: NADELETEBASIC

ExControlEntry::~ExControlEntry()
{
  NADELETEBASIC(sqlText_, heap_);
  for (Int32 i = 0; i < this->getNumValues(); i++)
      NADELETEBASIC(this->getValue(i+1), heap_) ;
      
}
开发者ID:RuoYuHP,项目名称:incubator-trafodion,代码行数:7,代码来源:ExControlArea.cpp


示例2: NADELETEBASIC

NABoolean  ExSequenceTcb::removeOLAPBuffer()
{

  if (lastOLAPBuffer_ == NULL || firstOLAPBuffer_ == NULL)
  {
    // LCOV_EXCL_START
    return FALSE;
    // LCOV_EXCL_STOP
  }

  if (lastOLAPBuffer_ == firstOLAPBuffer_)
  {
   // LCOV_EXCL_START
   // since we keep a minimum number of buffers this code won't be visited
   // this code should not be removed. if we decide to not keep a min number 
   // of buffers in the list it will be used
    NADELETEBASIC( lastOLAPBuffer_ ,heap_);
    numberOfOLAPBuffers_ = 0;
    maxNumberHistoryRows_ = myTdb().maxHistoryRows_;
    lastOLAPBuffer_ = NULL;
    firstOLAPBuffer_ = NULL;
    return TRUE;
    // LCOV_EXCL_STOP
  }

  HashBuffer * tmpBuf = lastOLAPBuffer_;
  lastOLAPBuffer_ = lastOLAPBuffer_->getPrev();
  NADELETEBASIC( tmpBuf ,heap_);
  lastOLAPBuffer_->setNext(NULL);
  numberOfOLAPBuffers_ --;
  maxNumberHistoryRows_ = numberOfOLAPBuffers_ * maxRowsInOLAPBuffer_;
  return TRUE;
}
开发者ID:AlexPeng19,项目名称:incubator-trafodion,代码行数:33,代码来源:ExSequence.cpp


示例3: deepDelete

NARoutine::~NARoutine()
{
  // Call deepDelete() on NAColumnArray's.  
  // The destructor does not do this.
  inParams_->deepDelete();
  outParams_->deepDelete();
  delete inParams_;
  delete outParams_;
  delete params_;    // Do not do a deepDelete() on params_ the
                     // elements are shared with in|outParams_.
  delete extRoutineName_;
  delete extActionName_;
  delete intActionName_;
  uecValues_.clear(); // delete all its elements.  
  if (passThruData_ NEQ NULL)
  {
    for (Int32 i = 0; i < passThruDataNumEntries_; i++)
      NADELETEBASIC(passThruData_[i], heap_); // Can't use NADELETEARRAY on C types.
    NADELETEBASIC(passThruData_, heap_);      // Can't use NADELETEARRAY on C types.
  }
  if (passThruDataSize_ NEQ NULL) // Use NADELETEARRAY for any 'new(heap)<class>[<size>]'
    NADELETEARRAY(passThruDataSize_, (UInt32)passThruDataNumEntries_, Int64, heap_);

  if (privInfo_)
   NADELETE(privInfo_, PrivMgrUserPrivs, heap_);
}
开发者ID:lanbb,项目名称:incubator-trafodion,代码行数:26,代码来源:NARoutine.cpp


示例4: NADELETEBASIC

AQRStatementAttributes::~AQRStatementAttributes()
{
  if (uniqueStmtId_)
    NADELETEBASIC(uniqueStmtId_,heap_);
  if (parentQID_)
    NADELETEBASIC(parentQID_,heap_);
}
开发者ID:apache,项目名称:incubator-trafodion,代码行数:7,代码来源:SessionDefaults.cpp


示例5: deallocateAtp

ExExeUtilTcb::~ExExeUtilTcb()
{
  delete qparent_.up;
  delete qparent_.down;
  if (workAtp_)
    {
      workAtp_->release();
      deallocateAtp(workAtp_, getGlobals()->getSpace());
      workAtp_ = NULL;
    }
  freeResources();

  if (extractedPartsObj_)
    {
      delete extractedPartsObj_;
      extractedPartsObj_ = NULL;
    }
  if (explQuery_)
    NADELETEBASIC(explQuery_, getHeap());
  if (childQueryId_ != NULL)
  {
    NADELETEBASIC(childQueryId_, getHeap());
    childQueryId_ = NULL;
    childQueryIdLen_ = 0;
  }
  if (outputBuf_ != NULL)
  {
    NADELETEBASIC(outputBuf_, getHeap());
    outputBuf_ = NULL;
    outputBuf_ = 0;
  }

};
开发者ID:RuoYuHP,项目名称:incubator-trafodion,代码行数:33,代码来源:ExExeUtilCommon.cpp


示例6: NADELETEBASIC

LmResult LmRoutineCppObj::dealloc(ComDiagsArea *diagsArea)
{
  LmResult result = LM_OK;

  delete invocationInfo_;
  invocationInfo_ = NULL;

  for (CollIndex i=0; i<planInfos_.getUsedLength(); i++)
    if (planInfos_.used(i))
      delete planInfos_[i];
  planInfos_.clear();

  if (paramRow_)
    {
      NADELETEBASIC(paramRow_, collHeap());
      paramRow_ = NULL;
    }

  if (inputRows_)
    {
      for (int i=0; i<numInputTables_; i++)
        if (inputRows_[i])
          NADELETEBASIC((inputRows_[i]), collHeap());
      NADELETEBASIC(inputRows_, collHeap());
      inputRows_ = NULL;
    }
  if (outputRow_)
    {
      // actually allocated buffer started where the wall starts
      NADELETEBASIC((outputRow_ - WALL_STRING_LEN), collHeap());
      outputRow_ = NULL;
    }

  try
    {
      // delete the interface object, the virtual destructor may call user code
      delete interfaceObj_;
    }
  catch (tmudr::UDRException e)
    {
      *diagsArea << DgSqlCode(-LME_UDR_METHOD_ERROR)
                 << DgString0("destructor")
                 << DgString1(getNameForDiags())
                 << DgString2(e.getMessage().c_str());
      result = LM_ERR;
    }
  catch (...)
    {
      *diagsArea << DgSqlCode(-LME_UDR_METHOD_ERROR)
                 << DgString0("destructor")
                 << DgString1(getNameForDiags())
                 << DgString2("General exception.");
      result = LM_ERR;
    }

  interfaceObj_ = NULL;

  return result;
}
开发者ID:AlexPeng19,项目名称:incubator-trafodion,代码行数:59,代码来源:LmRoutineCppObj.cpp


示例7: NADELETEBASIC

hive_column_desc::~hive_column_desc()
{
  CollHeap *h = CmpCommon::contextHeap();
  if (name_)
    NADELETEBASIC(name_, h);
  if (type_)
    NADELETEBASIC(type_, h);
}
开发者ID:lanbb,项目名称:incubator-trafodion,代码行数:8,代码来源:hiveHook.cpp


示例8: NADELETEBASIC

void CmpMessageRequest::destroyMe()
{
   NADELETEBASIC(data_, getHeap());
   if (allocated_ && parentQid_ != NULL)
   {
     NADELETEBASIC(parentQid_, getHeap());
     parentQid_ = NULL;
     parentQidLen_ = 0;
   }
} 
开发者ID:lanbb,项目名称:incubator-trafodion,代码行数:10,代码来源:CmpMessage.cpp


示例9: NADELETEBASIC

ExPCMgr::~ExPCMgr()
{
  if (buckets_ != NULL)
    NADELETEBASIC(buckets_, space_);
  buckets_ = NULL;

  if (entries_ != NULL)
    NADELETEBASIC(entries_, space_);
  entries_ = NULL;
}
开发者ID:RuoYuHP,项目名称:incubator-trafodion,代码行数:10,代码来源:ExProbeCache.cpp


示例10: NADELETEBASIC

void NAColumn::deepDelete()
{
  if(defaultValue_)
  NADELETEBASIC(defaultValue_,heap_);
  if(heading_)
  NADELETEBASIC(heading_,heap_);
  delete type_;
  delete isNotNullNondroppable_;
  if (computedColumnExpression_)
    NADELETEBASIC(computedColumnExpression_,heap_);
}
开发者ID:robertamarton,项目名称:incubator-trafodion,代码行数:11,代码来源:NAColumn.cpp


示例11: NADELETEBASIC

void HdfsClient::deleteHdfsFileInfo()
{
   for (int i = 0; i < numFiles_ ; i ++) {
      NADELETEBASIC(hdfsFileInfo_[i].mName, getHeap());
      NADELETEBASIC(hdfsFileInfo_[i].mOwner, getHeap());
      NADELETEBASIC(hdfsFileInfo_[i].mGroup, getHeap());
   }
   if (hdfsFileInfo_ != NULL)
      NADELETEBASICARRAY(hdfsFileInfo_, getHeap()); 
   numFiles_ = 0;
   hdfsFileInfo_ = NULL;
}
开发者ID:rachelgaoruix,项目名称:incubator-trafodion,代码行数:12,代码来源:HdfsClient_JNI.cpp


示例12: cleanupResultSets

LmRoutineJava::~LmRoutineJava()
{
  JNIEnv *jni = (JNIEnv*)getLM()->jniEnv_;
  jvalue *jval = (jvalue*)javaParams_;

  // Free LmResultSet objects
  // This will also close the Java result set objects
  // and the Java connections that they are part of.
  cleanupResultSets();

  // Free LmConnection objects for default connections
  // Closes any open default connections that do not have 
  // result sets associated with them
  closeDefConnWithNoRS();

  connectionList_.clear();
    
  // Release array refs for params, indicated
  // by non-null object.
  for (Int32 i = 0; i < (Int32)numParamsInSig_; i++)
  {
    if (jval[i].l != NULL)
      jni->DeleteLocalRef(jval[i].l);
  }

  // Free the Java parameter array
  if (javaParams_)
    NADELETEBASIC((jvalue *)javaParams_, collHeap());
}
开发者ID:apache,项目名称:incubator-trafodion,代码行数:29,代码来源:LmRoutineJava.cpp


示例13: deleteArray

void ProcessEnv::resetEnv(const char* envName)
{
  if (!envName)
    return;

  Int32 i;
  size_t nameLen=strlen(envName);
  CollHeap *stmtHeap = CmpCommon::statementHeap();
  NAList<Int32> deleteArray(stmtHeap, 16);  // 16 should be more than enough

  // find the env in existing env array
  for (i=0; i < envs_.getSize(); i++)
  {
    if (envs_.used(i))
    {
      char* pTemp = strchr(envs_[i], '=');
      if (pTemp) // found '='
        {
          Int32 envLen = (Int32)(pTemp - envs_[i]);
          if (envLen == nameLen && strncmp(envName, envs_[i], nameLen) == 0 )
            {  // found matching env var name
              *(pTemp) = '\0';
              PUTENV(envs_[i]);
              NADELETEBASIC(envs_[i], heap_);
              deleteArray.insert(i);
            }
        }
    }
  }

  // remove from the env array
  for (Int32 j = 0; j < deleteArray.entries(); j++) {
    envs_.remove(deleteArray[j]);
  }
}
开发者ID:AlexPeng19,项目名称:incubator-trafodion,代码行数:35,代码来源:ProcessEnv.cpp


示例14: new

ex_expr::exp_return_type ExExeUtilTcb::evalScanExpr(char * ptr, Lng32 len,
                                                    NABoolean copyToVCbuf)
{
  ex_expr::exp_return_type exprRetCode = ex_expr::EXPR_OK;

  if (exeUtilTdb().scanExpr_)
    {
      ex_queue_entry * pentry_down = qparent_.down->getHeadEntry();

      char * exprPtr = ptr;
      if (copyToVCbuf)
        {
          exprPtr = new(getGlobals()->getDefaultHeap())
            char[SQL_VARCHAR_HDR_SIZE + len];
          short shortLen = (short)len;
          str_cpy_all((char*)exprPtr, (char*)&shortLen, SQL_VARCHAR_HDR_SIZE);
          str_cpy_all(&exprPtr[SQL_VARCHAR_HDR_SIZE], ptr, shortLen);
        }

      workAtp_->getTupp(exeUtilTdb().workAtpIndex())
	.setDataPointer(exprPtr);

      exprRetCode =
	exeUtilTdb().scanExpr_->eval(pentry_down->getAtp(), workAtp_);

      if (exprPtr != ptr)
        NADELETEBASIC(exprPtr, getGlobals()->getDefaultHeap());
    }

  return exprRetCode;
}
开发者ID:lanbb,项目名称:incubator-trafodion,代码行数:31,代码来源:ExExeUtilCommon.cpp


示例15: deleteHdfsFileInfo

HdfsClient::~HdfsClient()
{
   QRLogger::log(CAT_SQL_HDFS, LL_DEBUG, "HdfsClient::~HdfsClient() called.");
   deleteHdfsFileInfo();
   if (path_ != NULL) 
      NADELETEBASIC(path_, getHeap());
}
开发者ID:rachelgaoruix,项目名称:incubator-trafodion,代码行数:7,代码来源:HdfsClient_JNI.cpp


示例16: strchr

void ProcessEnv::addOrChangeEnv(char **newenvs, Lng32 nEnvs)
{
  Lng32 i,j;

  for (i=0; i < nEnvs; i++)
  {
    char* pTemp = strchr(newenvs[i], '=');
    if (pTemp)
    {
      NABoolean sameValue = FALSE;
      Int32 envNameLen = pTemp - (newenvs[i]) + 1; // including '='
      char* envName = new char[envNameLen+1];
      strncpy(envName, newenvs[i], envNameLen);
      envName[envNameLen] = '\0';

      NABoolean envChanged = FALSE;
      CollIndex entriesChecked = 0;
      for (j=0; entriesChecked < envs_.entries(); j++)
      {
        if ( envs_.used(j) )
        {
          if (strcmp(newenvs[i], envs_[j]) == 0)
          {
            sameValue = TRUE;
            break;
          }
          else if (strncmp(envName, envs_[j], envNameLen) == 0)
          {
            envChanged = TRUE;
            break;
          }
          entriesChecked++;
        }
      }
      if (!sameValue)
      {
        CollIndex index = j;  // Put to the same location if value changed
        if ( envChanged )
        {
          NADELETEBASIC(envs_[j], heap_);
          envs_.remove(j);
        }
        else
          index = envs_.unusedIndex();  // Insert a new env string

	UInt32 len = strlen(newenvs[i]);
	char *copyEnv = new (heap_) char[len + 1];
	strcpy(copyEnv, newenvs[i]);
	copyEnv[len] = 0;

        PUTENV(copyEnv);
        envs_.insertAt(index, copyEnv);
      }
      delete[] envName;
    }
  }
}
开发者ID:AlexPeng19,项目名称:incubator-trafodion,代码行数:57,代码来源:ProcessEnv.cpp


示例17: NADELETEBASIC

// Update the phase name with additional info.
// There are case (such the optimizer task count) that needs to updated
// to reflect the correct values that embedded in the phase name.
void MemoryUsage::updatePhaseName(char *updatedPhaseName)
{
  if (updatedPhaseName)
  {
    NADELETEBASIC(phaseName_, heap_);
    phaseName_ = new(heap_) char[strlen(updatedPhaseName)+1]; 
    strcpy(phaseName_, updatedPhaseName);
  }
}
开发者ID:RuoYuHP,项目名称:incubator-trafodion,代码行数:12,代码来源:CmpMemoryMonitor.cpp


示例18: NADELETEBASIC

 void
 Allocator::deallocate(char*& buffer)
 {
   if (buffer)
   {
     NADELETEBASIC(buffer, heap_);
     buffer = NULL;
     memAllocated_ -= bufferSize_;
   }
 }
开发者ID:RuoYuHP,项目名称:incubator-trafodion,代码行数:10,代码来源:Allocator.cpp


示例19: ex_assert

void
TriggerStatusWA::deallocateStatusArray()
{
	ex_assert(heap_, "heap of TriggerStatusArray must be initialized");
	if (currentNumEntries_ == 0)
		return;
	currentNumEntries_ = 0;
	NADELETEBASIC(triggerStatusArray_, heap_);
	triggerStatusArray_ = NULL;
}
开发者ID:RuoYuHP,项目名称:incubator-trafodion,代码行数:10,代码来源:TriggerEnable.cpp


示例20: NADELETEBASIC

//--------------------------------------------------------------------------
//~SQDisk()
//     The destructor.  It will destroy all the individual DiskDetails
//     but the table remains and will be destroyed by the destructor
//     for diskpo0l.
//--------------------------------------------------------------------------
SQDisk::~SQDisk()
{
  if (diskTablePtr_ != NULL) {
    for (short i=0; i < numberOfDisks_; i++) 
    {
       delete diskTablePtr_[i];
    }
    NADELETEBASIC(diskTablePtr_, heap_); //? USE NADELETEARRAY 
    diskTablePtr_ = NULL;
  }
}
开发者ID:AlexPeng19,项目名称:incubator-trafodion,代码行数:17,代码来源:diskpool_sq.cpp



注:本文中的NADELETEBASIC函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ NAME函数代码示例发布时间:2022-05-30
下一篇:
C++ NACL_VTBL函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap