// called by CWListView::OnGetdispinfo CString CWMCC::getText(int iColumn) { switch(iColumn) { //case 0: return m_bEnabled?CString(_T(" ")):CString(_T("OFF")); // break; case 0: return m_sMembers; break; // environment column case 1: return getEnvironmentText(iColumn); /*if(m_lcComments.GetLength()) return sEmpty; // first environment will start on next row else if( m_environments.GetSize()) return m_environments[0]->getText(iColumn); // no comment, but at least one env else return sEmpty; // don't have a comment or an environment */ break; // comment column case 2: return getCommentText(iColumn); /* if(m_lcComments.GetLength()) return m_lcComments; else if( m_environments.GetSize()) return m_environments[0]->getText(iColumn); // no comment, but at least one env else return sEmpty; // don't have a comment or an environment */ break; default: ASSERTX(FALSE); return m_lcComments; break; } }
void ComTdbCancel::displayContents(Space * space,ULng32 flag) { ComTdb::displayContents(space,flag & 0xFFFFFFFE); if(flag & 0x00000008) { char buf[200]; str_sprintf(buf, "\nFor ComTdbCancel :"); space->allocateAndCopyToAlignedSpace(buf, str_len(buf), sizeof(short)); if (action_ == CancelByQid) { str_sprintf(buf, "action_ = cancel by queryId "); space->allocateAndCopyToAlignedSpace(buf, str_len(buf), sizeof(short)); str_sprintf(buf, "qid_ = %s ", getQidText()); space->allocateAndCopyToAlignedSpace(buf, str_len(buf), sizeof(short)); } else if (action_ == CancelByPname) { str_sprintf(buf, "action_ = cancel by process name " "with minimum blocking interval of %d seconds ", cancelPidBlockThreshold_); space->allocateAndCopyToAlignedSpace(buf, str_len(buf), sizeof(short)); str_sprintf(buf, "cancelPname_ = %s ", getCancelPname()); space->allocateAndCopyToAlignedSpace(buf, str_len(buf), sizeof(short)); } else if (action_ == CancelByNidPid) { str_sprintf(buf, "action_ = cancel by nid,pid " "with minimum blocking interval of %d seconds ", cancelPidBlockThreshold_); space->allocateAndCopyToAlignedSpace(buf, str_len(buf), sizeof(short)); str_sprintf(buf, "cancelNid_,cancelPid_ = %d,%d ", getCancelNid(), getCancelPid()); space->allocateAndCopyToAlignedSpace(buf, str_len(buf), sizeof(short)); } else { if (action_ == Activate) { str_sprintf(buf, "action_ = activate "); space->allocateAndCopyToAlignedSpace(buf, str_len(buf), sizeof(short)); } else // must be Suspend { if (forced_ == Force) str_sprintf(buf, "action_ = suspend (forced) "); else str_sprintf(buf, "action_ = suspend (safe) "); space->allocateAndCopyToAlignedSpace(buf, str_len(buf), sizeof(short)); } str_sprintf(buf, "qid_ = %s ", getQidText()); space->allocateAndCopyToAlignedSpace(buf, str_len(buf), sizeof(short)); } str_sprintf(buf, "comment_ = %s ", getCommentText()); space->allocateAndCopyToAlignedSpace(buf, str_len(buf), sizeof(short)); } if(flag & 0x00000001) { displayExpression(space,flag); displayChildren(space,flag); } }