⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ndbtransaction.hpp

📁 在AS4下编译通过
💻 HPP
📖 第 1 页 / 共 3 页
字号:
    sendTC_OP         };  SendStatusType theSendStatus;   NdbAsynchCallback  theCallbackFunction;    // Pointer to the callback function  void*              theCallbackObject;      // The callback object pointer  Uint32             theTransArrayIndex;     // Current index in a transaction                                              // array for this object  TimeMillis_t       theStartTransTime;      // Start time of the transaction  NdbError theError;	      	// Errorcode on transaction  int	   theErrorLine;	// Method number of last error in NdbOperation  NdbOperation*	theErrorOperation; // The NdbOperation where the error occurred  Ndb* 		theNdb;			     // Pointer to Ndb object	     NdbTransaction* theNext;	      	     // Next pointer. Used in idle list.  NdbOperation*	theFirstOpInList;	    // First operation in defining list.  NdbOperation*	theLastOpInList;	    // Last operation in defining list.  NdbOperation*	theFirstExecOpInList;	    // First executing operation in list  NdbOperation*	theLastExecOpInList;	    // Last executing operation in list.  NdbOperation*	theCompletedFirstOp;	    // First & last operation in completed   NdbOperation*	theCompletedLastOp;         // operation list.  Uint32	theNoOfOpSent;				// How many operations have been sent	      Uint32	theNoOfOpCompleted;			// How many operations have completed  Uint32        theNoOfOpFetched;           	        // How many operations was actually fetched  Uint32	theMyRef;				// Our block reference		  Uint32	theTCConPtr;				// Transaction Co-ordinator connection pointer.  Uint64	theTransactionId;			// theTransactionId of the transaction  Uint32	theGlobalCheckpointId;			// The gloabl checkpoint identity of the transaction  ConStatusType	theStatus;				// The status of the connection		  enum CompletionStatus {     NotCompleted,    CompletedSuccess,    CompletedFailure,    DefinitionFailure  } theCompletionStatus;	  // The Completion status of the transaction  CommitStatusType theCommitStatus;			// The commit status of the transaction  Uint32	theMagicNumber;				// Magic Number to verify correct object  Uint32	thePriority;				// Transaction Priority  enum ReturnType {  ReturnSuccess,  ReturnFailure };  ReturnType    theReturnStatus;			// Did we have any read/update/delete failing							// to find the tuple.  bool theTransactionIsStarted;   bool theInUseState;  bool theSimpleState;  Uint8 m_abortOption;           // Type of commit  enum ListState {      NotInList,     InPreparedList,     InSendList,     InCompletedList   } theListState;  Uint32 theDBnode;       // The database node we are connected to    Uint32 theNodeSequence; // The sequence no of the db node  bool theReleaseOnClose;  /**   * handle transaction spanning   *   multiple TC/db nodes   *   * 1) Bitmask with used nodes   * 2) Bitmask with nodes failed during op   */  Uint32 m_db_nodes[2];  Uint32 m_failed_db_nodes[2];    int report_node_failure(Uint32 id);  // Scan operations  bool m_waitForReply;       NdbIndexScanOperation* m_theFirstScanOperation;  NdbIndexScanOperation* m_theLastScanOperation;    NdbIndexScanOperation* m_firstExecutedScanOp;  // Scan operations  // The operation actually performing the scan  NdbScanOperation* theScanningOp;   Uint32 theBuddyConPtr;  // optim: any blobs  bool theBlobFlag;  Uint8 thePendingBlobOps;  inline bool hasBlobOperation() { return theBlobFlag; }  static void sendTC_COMMIT_ACK(NdbApiSignal *,				Uint32 transId1, Uint32 transId2, 				Uint32 aBlockRef);  void completedFail(const char * s);#ifdef VM_TRACE  void printState();#endif  bool checkState_TransId(const Uint32 * transId) const;  void remove_list(NdbOperation*& head, NdbOperation*);  void define_scan_op(NdbIndexScanOperation*);  friend class HugoOperations;  friend struct Ndb_free_list_t<NdbTransaction>;};#ifndef DOXYGEN_SHOULD_SKIP_INTERNALinlineUint32NdbTransaction::get_send_size(){  return 0;}inlinevoidNdbTransaction::set_send_size(Uint32 send_size){  return;}#ifdef NDB_NO_DROPPED_SIGNAL#include <stdlib.h>#endifinlineintNdbTransaction::checkMagicNumber(){  if (theMagicNumber == 0x37412619)    return 0;  else {#ifdef NDB_NO_DROPPED_SIGNAL    abort();#endif    return -1;  }}inlineboolNdbTransaction::checkState_TransId(const Uint32 * transId) const {  const Uint32 tTmp1 = transId[0];  const Uint32 tTmp2 = transId[1];  Uint64 tRecTransId = (Uint64)tTmp1 + ((Uint64)tTmp2 << 32);  bool b = theStatus == Connected && theTransactionId == tRecTransId;  return b;}/************************************************************************************************void setTransactionId(Uint64 aTransactionId);Remark:        Set the transaction identity. ************************************************************************************************/inlinevoidNdbTransaction::setTransactionId(Uint64 aTransactionId){  theTransactionId = aTransactionId;}inlinevoid			NdbTransaction::setConnectedNodeId(Uint32 aNode, Uint32 aSequenceNo){  theDBnode = aNode;  theNodeSequence = aSequenceNo;}	/******************************************************************************int getConnectedNodeId();Return Value:	Return  theDBnode.Remark:         Get Connected node id. ******************************************************************************/inlineUint32			NdbTransaction::getConnectedNodeId(){  return theDBnode;}	/******************************************************************************void setMyBlockReference(int aBlockRef);Parameters:     aBlockRef: The block refrerence.Remark:         Set my block refrerence. ******************************************************************************/inlinevoid			NdbTransaction::setMyBlockReference(int aBlockRef)	{  theMyRef = aBlockRef;}/******************************************************************************void  setTC_ConnectPtr(Uint32 aTCConPtr);Parameters:     aTCConPtr: The connection pointer.Remark:         Sets TC Connect pointer. ******************************************************************************/inlinevoid			NdbTransaction::setTC_ConnectPtr(Uint32 aTCConPtr){  theTCConPtr = aTCConPtr;}/******************************************************************************int  getTC_ConnectPtr();Return Value:	Return  theTCConPtr.Remark:         Gets TC Connect pointer. ******************************************************************************/inlineint			NdbTransaction::getTC_ConnectPtr(){  return theTCConPtr;}inlinevoidNdbTransaction::setBuddyConPtr(Uint32 aBuddyConPtr){  theBuddyConPtr = aBuddyConPtr;}inlineUint32 NdbTransaction::getBuddyConPtr(){  return theBuddyConPtr;}/******************************************************************************NdbTransaction* next();inlinevoidNdbTransaction::setBuddyConPtr(Uint32 aBuddyConPtr){  theBuddyConPtr = aBuddyConPtr;}inlineUint32 NdbTransaction::getBuddyConPtr(){  return theBuddyConPtr;}Return Value:	Return  next pointer to NdbTransaction object.Remark:         Get the next pointer. ******************************************************************************/inlineNdbTransaction*NdbTransaction::next(){  return theNext;}/******************************************************************************void next(NdbTransaction aTransaction);Parameters:     aTransaction: The connection object. Remark:         Sets the next pointer. ******************************************************************************/inlinevoidNdbTransaction::next(NdbTransaction* aTransaction){  theNext = aTransaction;}/******************************************************************************ConStatusType  Status();Return Value    Return the ConStatusType.	Parameters:     aStatus:  The status.Remark:         Sets Connect status. ******************************************************************************/inlineNdbTransaction::ConStatusType			NdbTransaction::Status(){  return theStatus;}/******************************************************************************void  Status(ConStatusType aStatus);Parameters:     aStatus: The status.Remark:         Sets Connect status. ******************************************************************************/inlinevoid			NdbTransaction::Status( ConStatusType aStatus ){  theStatus = aStatus;}/****************************************************************************** void    	setGCI();Remark:		Set global checkpoint identity of the transaction******************************************************************************/inlinevoidNdbTransaction::setGCI(int aGlobalCheckpointId){  theGlobalCheckpointId = aGlobalCheckpointId;}/******************************************************************************void OpSent();Remark:       An operation was sent with success that expects a response.******************************************************************************/inlinevoid NdbTransaction::OpSent(){  theNoOfOpSent++;}/******************************************************************************void executePendingBlobOps();******************************************************************************/#include <stdlib.h>inlineintNdbTransaction::executePendingBlobOps(Uint8 flags){  if (thePendingBlobOps & flags) {    // not executeNoBlobs because there can be new ops with blobs    return execute(NoCommit);  }  return 0;}inlineUint32NdbTransaction::ptr2int(){  return theId;}typedef NdbTransaction NdbConnection;#endif // ifndef DOXYGEN_SHOULD_SKIP_INTERNAL#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -