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

C++ soap_lookup_plugin函数代码示例

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

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



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

示例1: http_da_prepareinit

static int http_da_prepareinit(struct soap *soap)
{
  struct http_da_data *data = (struct http_da_data*)soap_lookup_plugin(soap, http_da_id);

  if (!data)
    return SOAP_PLUGIN_ERROR;

  if ((soap->mode & SOAP_IO) != SOAP_IO_STORE && (soap->mode & (SOAP_ENC_DIME | SOAP_ENC_MIME)))
  { /* TODO: handle attachments automatically, does not work yet */
    soap->mode &= ~SOAP_IO;
    soap->mode |= SOAP_IO_STORE;
  }
  else
  {
    if (soap->fpreparerecv == http_da_preparerecv)
      soap->fpreparerecv = data->fpreparerecv;
    if (soap->fdisconnect == http_da_disconnect)
      soap->fdisconnect = data->fdisconnect;

    if (soap->userid && soap->passwd)
    {
      md5_handler(soap, &data->context, MD5_INIT, NULL, 0);
      if (soap->fpreparesend != http_da_preparesend)
      {
        data->fpreparesend = soap->fpreparesend;
        soap->fpreparesend = http_da_preparesend;
      }
    }

    if (data->fprepareinit)
      return data->fprepareinit(soap);
  }

  return SOAP_OK;
}
开发者ID:bmanojlovic,项目名称:bforce8583,代码行数:35,代码来源:httpda.c


示例2: http_da_parse

static int http_da_parse(struct soap *soap)
{ 
  struct http_da_data *data = (struct http_da_data*)soap_lookup_plugin(soap, http_da_id);

  if (!data)
    return SOAP_PLUGIN_ERROR;

  data->qop = NULL;

  /* HTTP GET w/o body with qop=auth-int still requires a digest */
  md5_handler(soap, &data->context, MD5_INIT, NULL, 0);
  md5_handler(soap, &data->context, MD5_FINAL, data->digest, 0);

  if ((soap->error = data->fparse(soap)))
    return soap->error;

  if (data->qop && !soap_tag_cmp(data->qop, "auth-int"))
  {
    if (soap->fpreparerecv != http_da_preparerecv)
    {
      data->fpreparerecv = soap->fpreparerecv;
      soap->fpreparerecv = http_da_preparerecv;
    }
    if (soap->fpreparefinalrecv != http_da_preparefinalrecv)
    {
      data->fpreparefinalrecv = soap->fpreparefinalrecv;
      soap->fpreparefinalrecv = http_da_preparefinalrecv;
    }
    md5_handler(soap, &data->context, MD5_INIT, NULL, 0);
  }
 
  return SOAP_OK;
}
开发者ID:vit2000005,项目名称:happy_trader,代码行数:33,代码来源:httpda.c


示例3: soap_wsa_fault_subcode_action

SOAP_FMAC5 int SOAP_FMAC6 soap_wsa_fault_subcode_action(struct soap *soap,
		int flag, const char *faultsubcode, const char *faultstring,
		const char *faultdetail, const char *action) {
	struct soap_wsa_data *data = (struct soap_wsa_data*) soap_lookup_plugin(
			soap, soap_wsa_id);
	struct SOAP_ENV__Header *oldheader, *newheader;
	DBGFUN2("soap_wsa_fault_subcode", "faultsubcode=%s",
			faultsubcode ? faultsubcode : "(null)", "faultstring=%s",
			faultstring ? faultstring : "(null)");
	if (!data)
		return soap->error = SOAP_PLUGIN_ERROR;
	oldheader = soap->header;
	/* no FaultTo: use ReplyTo */
	if (oldheader && oldheader->SOAP_WSA(ReplyTo)
			&& (!oldheader->SOAP_WSA(FaultTo)
					|| soap_tagsearch(soap_wsa_allAnonymousURI,
							oldheader->SOAP_WSA(FaultTo)->Address))) {
		if (!oldheader->SOAP_WSA(FaultTo)) {
			oldheader->SOAP_WSA(FaultTo) = (SOAP_WSA_(,FaultTo)*) my_soap_malloc(
					soap, sizeof(SOAP_WSA_(,FaultTo)));
			SOAP_WSA_(soap_default,EndpointReferenceType)(soap,
					soap->header->SOAP_WSA(FaultTo));
		}
		oldheader->SOAP_WSA(FaultTo)->Address =
				oldheader->SOAP_WSA(ReplyTo)->Address;
	}
开发者ID:gaochunzy,项目名称:nvtonvifserverc,代码行数:26,代码来源:onvifHandleProbe.c


示例4: http_md5_delete

static void http_md5_delete(struct soap *soap, struct soap_plugin *p)
{ struct http_md5_data *data = (struct http_md5_data*)soap_lookup_plugin(soap, http_md5_id);
  if (data)
  { md5_handler(soap, &data->context, MD5_DELETE, NULL, 0);
    SOAP_FREE(soap, data);
  }
}
开发者ID:BioinformaticsArchive,项目名称:KBWS,代码行数:7,代码来源:httpmd5.c


示例5: http_da_parse

static int http_da_parse(struct soap *soap)
{ 
  struct http_da_data *data = (struct http_da_data*)soap_lookup_plugin(soap, http_da_id);

  if (!data)
    return SOAP_PLUGIN_ERROR;

  data->qop = NULL;

  /* HTTP GET w/o body with qop=auth-int still requires a digest */
  if (soap_smd_init(soap, &data->smd_data, SOAP_SMD_DGST_MD5, NULL, 0)
   || soap_smd_final(soap, &data->smd_data, data->digest, NULL))
    return soap->error;

  if ((soap->error = data->fparse(soap)))
    return soap->error;

  if (data->qop && !soap_tag_cmp(data->qop, "auth-int"))
  {
    if (soap->fpreparerecv != http_da_preparerecv)
    {
      data->fpreparerecv = soap->fpreparerecv;
      soap->fpreparerecv = http_da_preparerecv;
    }
    if (soap->fpreparefinalrecv != http_da_preparefinalrecv)
    {
      data->fpreparefinalrecv = soap->fpreparefinalrecv;
      soap->fpreparefinalrecv = http_da_preparefinalrecv;
    }
    if (soap_smd_init(soap, &data->smd_data, SOAP_SMD_DGST_MD5, NULL, 0))
      return soap->error;
  }
 
  return SOAP_OK;
}
开发者ID:latelee,项目名称:onvif_fw_stl,代码行数:35,代码来源:httpda.c


示例6: http_connect

static int http_connect(struct soap *soap, const char *endpoint, const char *host, int port, const char *path, const char *action, size_t count)
{ struct http_get_data *data = (struct http_get_data*)soap_lookup_plugin(soap, http_get_id);
  if (!data)
    return SOAP_PLUGIN_ERROR;
  soap->status = SOAP_GET;
  soap->fpost = data->fpost;
  return soap->fpost(soap, endpoint, host, port, path, action, count);
}
开发者ID:tcdog001,项目名称:apv5sdk-v15,代码行数:8,代码来源:httpget.c


示例7:

int32 LoginRESTService::ContentTypePlugin::OnSetHeader(soap* s, char const* key, char const* value)
{
    ContentTypePlugin* self = reinterpret_cast<ContentTypePlugin*>(soap_lookup_plugin(s, PluginId));
    if (key && !strcmp("Content-Type", key))
        value = self->ContentType;

    return self->fposthdr(s, key, value);
}
开发者ID:Jildor,项目名称:TrinityCore,代码行数:8,代码来源:LoginRESTService.cpp


示例8: logging_send

static int logging_send(struct soap *soap, const char *buf, size_t len)
{ struct logging_data *data = (struct logging_data*)soap_lookup_plugin(soap, logging_id);
  /* update should be in mutex, but we don't mind some inaccuracy in the count */
  data->stat_sent += len;
  if (data->outbound)
    fwrite(buf, len, 1, data->outbound);
  return data->fsend(soap, buf, len); /* pass data on to old send callback */
}
开发者ID:bmanojlovic,项目名称:bforce8583,代码行数:8,代码来源:logging.c


示例9: logging_recv

static size_t logging_recv(struct soap *soap, char *buf, size_t len)
{ struct logging_data *data = (struct logging_data*)soap_lookup_plugin(soap, logging_id);
  size_t res = data->frecv(soap, buf, len); /* get data from old recv callback */
  data->stat_recv += res;
  /* update should be in mutex, but we don't mind some inaccuracy in the count */
  if (data->inbound)
    fwrite(buf, res, 1, data->inbound);
  return res;
}
开发者ID:bmanojlovic,项目名称:bforce8583,代码行数:9,代码来源:logging.c


示例10: soap_get_connect

int soap_get_connect(struct soap *soap, const char *endpoint, const char *action)
{ struct http_get_data *data = (struct http_get_data*)soap_lookup_plugin(soap, http_get_id);
  if (!data)
    return soap->error = SOAP_PLUGIN_ERROR;
  soap_begin(soap);
  data->fpost = soap->fpost;
  soap->fpost = http_connect;
  return soap_connect(soap, endpoint, action);
}
开发者ID:tcdog001,项目名称:apv5sdk-v15,代码行数:9,代码来源:httpget.c


示例11: http_fdel

static int http_fdel(struct soap *soap)
{ struct http_post_data *data = (struct http_post_data*)soap_lookup_plugin(soap, http_post_id);
  if (!data)
    return SOAP_PLUGIN_ERROR;
  soap->fform = http_lookup_handler(soap, "DELETE", data);
  if (soap->fform)
    return SOAP_STOP;
  return 405;
}
开发者ID:DemofiloVizuete,项目名称:gSOAP,代码行数:9,代码来源:httppost.c


示例12: soap_get_logging_stats

 /* get logging sent and recv octet counts */
 void soap_get_logging_stats(struct soap *soap, size_t *sent, size_t *recv)
 {
     struct logging_data *data = (struct logging_data*)soap_lookup_plugin(soap, logging_id);
     if (data)
     {
         *sent = data->stat_sent;
         *recv = data->stat_recv;
     }
 }
开发者ID:JammyWei,项目名称:ver30,代码行数:10,代码来源:logging.c


示例13: http_md5_preparerecv

static int http_md5_preparerecv(struct soap *soap, const char *buf, size_t len)
{ struct http_md5_data *data = (struct http_md5_data*)soap_lookup_plugin(soap, http_md5_id);
  if (!data)
    return SOAP_PLUGIN_ERROR;
  md5_handler(soap, &data->context, MD5_UPDATE, (char*)buf, len);
  if (data->fpreparerecv)
    return data->fpreparerecv(soap, buf, len);
  return SOAP_OK;
}
开发者ID:BioinformaticsArchive,项目名称:KBWS,代码行数:9,代码来源:httpmd5.c


示例14: http_fput

static int http_fput(struct soap *soap)
{ struct http_post_data *data = (struct http_post_data*)soap_lookup_plugin(soap, http_post_id);
  if (!data)
    return SOAP_PLUGIN_ERROR;
  soap->fform = http_lookup_handler(soap, "PUT", data);
  if (soap->fform)
    return SOAP_FORM;
  return 405;
}
开发者ID:DemofiloVizuete,项目名称:gSOAP,代码行数:9,代码来源:httppost.c


示例15: grisu_soap_logging

void grisu_soap_logging(gboolean state)
{
struct logging_data *logdata;

/* retrieve data struct */
logdata = (struct logging_data *) soap_lookup_plugin(&soap, logging_id);
if (!logdata)
  {
  if (soap_register_plugin(&soap, logging))
     soap_print_fault(&soap, stderr);
  else
    {
/* register plugin if not loaded */
    printf("Loaded gsoap logging plugin...\n");
    logdata = (struct logging_data *) soap_lookup_plugin(&soap, logging_id);
    }
  }

/* set logging state */
if (logdata)
  {
  if (state)
    {
/* TODO - open and write something to indicate logging on/off switches? */
/* then append rather than overwrite (for clarity) */
//    logdata->inbound = stdout; 
//    logdata->outbound = stdout;
//    logdata->inbound = fopen("/home/sean/prog/gdis/RECV.log", "at");
//    logdata->outbound = fopen("/home/sean/prog/gdis/SENT.log", "at");
    logdata->outbound = fopen(GSOAP_LOGGING_SENT, "wt");
    logdata->inbound = fopen(GSOAP_LOGGING_RECV, "wt");
    }
  else
    {
    logdata->inbound = NULL; 
    logdata->outbound = NULL;
    }
// process messages 
//  size_t bytes_in = logdata->stat_recv;
//  size_t bytes_out = logdata->stat_sent;
  }
else
  printf("Gsoap logging plugin not found.\n");
}
开发者ID:Bhattiasif,项目名称:gdis,代码行数:44,代码来源:grisu_client.c


示例16: wininet_error_message

static const char *
wininet_error_message(
    struct soap *   soap,
    DWORD           a_dwErrorMsgId )
{
    HINSTANCE   hModule;
    DWORD       dwResult;
    DWORD       dwFormatFlags;
    struct wininet_data * pData =
        (struct wininet_data *) soap_lookup_plugin( soap, wininet_id );

    /* free any existing error message */
    wininet_free_error_message( pData );

    dwFormatFlags =
        FORMAT_MESSAGE_ALLOCATE_BUFFER |
        FORMAT_MESSAGE_IGNORE_INSERTS |
        FORMAT_MESSAGE_FROM_SYSTEM;

    /* load wininet.dll for the error messages */
    hModule = LoadLibraryExA( "wininet.dll", NULL,
        LOAD_LIBRARY_AS_DATAFILE | DONT_RESOLVE_DLL_REFERENCES );
    if ( hModule )
    {
        dwFormatFlags |= FORMAT_MESSAGE_FROM_HMODULE;
    }

    /* format the messages */
    dwResult = FormatMessageA(
        dwFormatFlags,
        hModule,
        a_dwErrorMsgId,
        MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
        (LPSTR) &pData->pszErrorMessage,
        0,
        NULL );

    /* free the library if we loaded it */
    if ( hModule )
    {
        FreeLibrary( hModule );
    }

    /* remove the CR LF from the error message */
    if ( dwResult > 2 )
    {
        pData->pszErrorMessage[dwResult-2] = 0;
        return pData->pszErrorMessage;
    }
    else
    {
        const static char szUnknown[] = "(unknown)";
        return szUnknown;
    }
}
开发者ID:kusl,项目名称:TortoiseSVN,代码行数:55,代码来源:gsoapWinInet-2.8.0.cpp


示例17: http_da_parse_header

static int http_da_parse_header(struct soap *soap, const char *key, const char *val)
{
  struct http_da_data *data = (struct http_da_data*)soap_lookup_plugin(soap, http_da_id);

  if (!data)
    return SOAP_PLUGIN_ERROR;

  /* check if server received Authorization Digest HTTP header from client */
  if (!soap_tag_cmp(key, "Authorization") && !soap_tag_cmp(val, "Digest *"))
  {
    soap->authrealm = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "realm"));
    soap->userid = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "username"));
    soap->passwd = NULL;
    data->nonce = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "nonce"));
    data->opaque = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "opaque"));
    data->qop = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "qop"));
    data->alg = NULL;
    data->ncount = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "nc"));
    data->cnonce = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "cnonce"));
    data->response = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "response"));
    if (data->qop && !soap_tag_cmp(data->qop, "auth-int"))
    {
      if (soap->fpreparerecv != http_da_preparerecv)
      {
        data->fpreparerecv = soap->fpreparerecv;
        soap->fpreparerecv = http_da_preparerecv;
      }
      if (soap->fdisconnect != http_da_disconnect)
      {
        data->fdisconnect = soap->fdisconnect;
        soap->fdisconnect = http_da_disconnect;
      }
      md5_handler(soap, &data->context, MD5_INIT, NULL, 0);
    }
    return SOAP_OK;
  }

  /* check if client received WWW-Authenticate Digest HTTP header from server */
  if (!soap_tag_cmp(key, "WWW-Authenticate") && !soap_tag_cmp(val, "Digest *"))
  {
    soap->authrealm = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "realm"));
    data->nonce = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "nonce"));
    data->opaque = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "opaque"));
    data->qop = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "qop"));
    data->alg = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "algorithm"));
    data->nc = 1;
    data->ncount = NULL;
    data->cnonce = NULL;
    data->response = NULL;
    return SOAP_OK;
  }

  return data->fparsehdr(soap, key, val);
}
开发者ID:bmanojlovic,项目名称:bforce8583,代码行数:54,代码来源:httpda.c


示例18: soap_wsa_response

SOAP_FMAC5 int SOAP_FMAC6 soap_wsa_response(struct soap *soap, int status,
		size_t count) {
	struct soap_wsa_data *data = (struct soap_wsa_data*) soap_lookup_plugin(
			soap, soap_wsa_id);
	DBGFUN2("soap_wsa_response", "status=%d", status, "count=%lu",
			(unsigned long) count);
	if (!data)
		return SOAP_PLUGIN_ERROR;
	soap->fresponse = data->fresponse; /* reset (HTTP response) */
	return soap->fpost(soap, soap_strdup(soap, soap->endpoint), soap->host,
			soap->port, soap->path, soap->action, count);
}
开发者ID:gaochunzy,项目名称:nvtonvifserverc,代码行数:12,代码来源:onvifHandleProbe.c


示例19: http_da_parse_header

static int http_da_parse_header(struct soap *soap, const char *key, const char *val)
{
  struct http_da_data *data = (struct http_da_data*)soap_lookup_plugin(soap, http_da_id);

  if (!data)
    return SOAP_PLUGIN_ERROR;

  /* check if server received Authorization Digest HTTP header from client */
  if (!soap_tag_cmp(key, "Authorization") && !soap_tag_cmp(val, "Digest *"))
  {
    data->alg = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "algorithm"));
    soap->authrealm = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "realm"));
    soap->userid = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "username"));
    soap->passwd = NULL;
    data->nonce = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "nonce"));
    data->opaque = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "opaque"));
    data->qop = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "qop"));
    data->ncount = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "nc"));
    data->cnonce = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "cnonce"));
    (void)soap_hex2s(soap, soap_get_header_attribute(soap, val + 7, "response"), data->response, 32, NULL);
    return SOAP_OK;
  }

  /* check if client received WWW-Authenticate Digest HTTP header from server */
  if ((!soap_tag_cmp(key, "WWW-Authenticate") || !soap_tag_cmp(key, "Proxy-Authenticate")) && !soap_tag_cmp(val, "Digest *"))
  {
    const char *authrealm = soap_get_header_attribute(soap, val + 7, "realm");
    if (authrealm && (!soap->authrealm || strcmp(authrealm, soap->authrealm)))
    {
      const char *alg;
      soap->authrealm = soap_strdup(soap, authrealm);
      alg = soap_get_header_attribute(soap, val + 7, "algorithm");
      if (!alg || soap_tag_cmp(alg, "SHA-512-256*"))
      {
        /* got the first authenticate header for this realm that we can accept */
        data->alg = soap_strdup(soap, alg);
        data->nonce = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "nonce"));
        data->opaque = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "opaque"));
        data->qop = soap_strdup(soap, soap_get_header_attribute(soap, val + 7, "qop"));
        data->nc = 1;
        data->ncount = NULL;
        data->cnonce = NULL;
      }
      else
      {
        soap->authrealm = NULL;
      }
    }
    return SOAP_OK;
  }

  return data->fparsehdr(soap, key, val);
}
开发者ID:latelee,项目名称:onvif_fw_stl,代码行数:53,代码来源:httpda.c


示例20: wininet_set_rse_callback

void
wininet_set_rse_callback(
    struct soap *           soap,
    wininet_rse_callback    a_pRsecallback)
{
    struct wininet_data * pData = (struct wininet_data *) soap_lookup_plugin( soap, wininet_id );

    DBGLOG(TEST, SOAP_MESSAGE(fdebug,
        "wininet %p: resolve_send_error callback = '%p'\n", soap, a_pRsecallback ));

    pData->pRseCallback = a_pRsecallback;
}
开发者ID:kusl,项目名称:TortoiseSVN,代码行数:12,代码来源:gsoapWinInet-2.8.0.cpp



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


鲜花

握手

雷人

路过

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

请发表评论

全部评论

专题导读
上一篇:
C++ soap_malloc函数代码示例发布时间:2022-05-30
下一篇:
C++ soap_init函数代码示例发布时间: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