本文整理汇总了C++中PHTTP_BMO_REQ_OBJECT::SetMboMode方法的典型用法代码示例。如果您正苦于以下问题:C++ PHTTP_BMO_REQ_OBJECT::SetMboMode方法的具体用法?C++ PHTTP_BMO_REQ_OBJECT::SetMboMode怎么用?C++ PHTTP_BMO_REQ_OBJECT::SetMboMode使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PHTTP_BMO_REQ_OBJECT
的用法示例。
在下文中一共展示了PHTTP_BMO_REQ_OBJECT::SetMboMode方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: if
ANSC_STATUS
HttpTroResumeTransaction
(
ANSC_HANDLE hThisObject,
ANSC_HANDLE hReserved,
ULONG ulSbcPmode
)
{
ANSC_STATUS returnStatus = ANSC_STATUS_SUCCESS;
PHTTP_TRANS_RECORD_OBJECT pMyObject = (PHTTP_TRANS_RECORD_OBJECT )hThisObject;
PHTTP_ADVANCED_PROXY_OBJECT pAdvancedProxy = (PHTTP_ADVANCED_PROXY_OBJECT )pMyObject->hOwnerContext;
PHTTP_ADVANCED_PROXY_PROPERTY pSpoProperty = (PHTTP_ADVANCED_PROXY_PROPERTY )&pAdvancedProxy->Property;
PHTTP_WAM_INTERFACE pWamIf = (PHTTP_WAM_INTERFACE )pMyObject->hWamIf;
PANSC_DAEMON_SOCKET_TCP_OBJECT pClientSocket = (PANSC_DAEMON_SOCKET_TCP_OBJECT)pMyObject->hClientSocket;
PANSC_BROKER_SOCKET_TCP_OBJECT pServerSocket = (PANSC_BROKER_SOCKET_TCP_OBJECT)pMyObject->hServerSocket;
PHTTP_BMO_REQ_OBJECT pBmoReq = (PHTTP_BMO_REQ_OBJECT )pMyObject->hBmoReq;
if ( pMyObject->SbcPmode != HTTP_SBC_PMODE_QUEUE )
{
return ANSC_STATUS_UNAPPLICABLE;
}
else if ( (ulSbcPmode != HTTP_SBC_PMODE_RELAY1) &&
(ulSbcPmode != HTTP_SBC_PMODE_RELAY2) &&
(ulSbcPmode != HTTP_SBC_PMODE_STORE ) )
{
return ANSC_STATUS_UNAPPLICABLE;
}
pMyObject->AcquireAccess((ANSC_HANDLE)pMyObject);
if ( !pServerSocket )
{
returnStatus =
pMyObject->SetUpConnection
(
(ANSC_HANDLE)pMyObject,
(ANSC_HANDLE)NULL
);
}
if ( returnStatus != ANSC_STATUS_SUCCESS )
{
pMyObject->ReleaseAccess((ANSC_HANDLE)pMyObject);
return returnStatus;
}
else
{
pMyObject->SbcPmode = ulSbcPmode;
returnStatus =
pMyObject->SendToServer
(
(ANSC_HANDLE)pMyObject,
(ANSC_HANDLE)pBmoReq,
HTTP_TRO_SFLAG_HEADERS | HTTP_TRO_SFLAG_BODY
);
}
if ( (ulSbcPmode == HTTP_SBC_PMODE_RELAY1) ||
(ulSbcPmode == HTTP_SBC_PMODE_RELAY2) )
{
pBmoReq->SetMboMode((ANSC_HANDLE)pBmoReq, HTTP_MBO_MODE_RELAY);
}
else
{
pBmoReq->SetMboMode((ANSC_HANDLE)pBmoReq, HTTP_MBO_MODE_STORE);
}
pMyObject->ReleaseAccess((ANSC_HANDLE)pMyObject);
return returnStatus;
}