Lines Matching refs:sdl

49 encodePtr get_encoder_from_prefix(sdlPtr sdl, xmlNodePtr node, const xmlChar *type)  in get_encoder_from_prefix()  argument
58 enc = get_encoder(sdl, (char*)nsptr->href, cptype); in get_encoder_from_prefix()
60 enc = get_encoder_ex(sdl, cptype, strlen(cptype)); in get_encoder_from_prefix()
63 enc = get_encoder_ex(sdl, (char*)type, xmlStrlen(type)); in get_encoder_from_prefix()
70 static sdlTypePtr get_element(sdlPtr sdl, xmlNodePtr node, const xmlChar *type) in get_element() argument
74 if (sdl->elements) { in get_element()
92 if (zend_hash_find(sdl->elements, nscat, len + 1, (void **)&sdl_type) == SUCCESS) { in get_element()
94 …} else if (zend_hash_find(sdl->elements, (char*)type, type_len + 1, (void **)&sdl_type) == SUCCESS… in get_element()
99 …if (zend_hash_find(sdl->elements, (char*)type, xmlStrlen(type) + 1, (void **)&sdl_type) == SUCCESS… in get_element()
110 encodePtr get_encoder(sdlPtr sdl, const char *ns, const char *type) in get_encoder() argument
124 enc = get_encoder_ex(sdl, nscat, len); in get_encoder()
145 if (enc && sdl) { in get_encoder()
146 encodePtr new_enc = pemalloc(sizeof(encode), sdl->is_persistent); in get_encoder()
148 if (sdl->is_persistent) { in get_encoder()
155 if (sdl->encoders == NULL) { in get_encoder()
156 sdl->encoders = pemalloc(sizeof(HashTable), sdl->is_persistent); in get_encoder()
157 zend_hash_init(sdl->encoders, 0, NULL, delete_encoder, sdl->is_persistent); in get_encoder()
159 zend_hash_update(sdl->encoders, nscat, len + 1, &new_enc, sizeof(encodePtr), NULL); in get_encoder()
167 encodePtr get_encoder_ex(sdlPtr sdl, const char *nscat, int len) in get_encoder_ex() argument
174 …} else if (sdl && sdl->encoders && zend_hash_find(sdl->encoders, (char*)nscat, len + 1, (void **)&… in get_encoder_ex()
180 sdlBindingPtr get_binding_from_type(sdlPtr sdl, int type) in get_binding_from_type() argument
184 if (sdl == NULL) { in get_binding_from_type()
188 for (zend_hash_internal_pointer_reset(sdl->bindings); in get_binding_from_type()
189 zend_hash_get_current_data(sdl->bindings, (void **) &binding) == SUCCESS; in get_binding_from_type()
190 zend_hash_move_forward(sdl->bindings)) { in get_binding_from_type()
198 sdlBindingPtr get_binding_from_name(sdlPtr sdl, char *name, char *ns) in get_binding_from_name() argument
208 zend_hash_find(sdl->bindings, key.c, key.len, (void **)&binding); in get_binding_from_name()
237 s = strstr(ctx->sdl->source, "://"); in sdl_set_uri_credentials()
240 l1 = s ? (s - ctx->sdl->source) : strlen(ctx->sdl->source); in sdl_set_uri_credentials()
248 ctx->sdl->source[4] == ':' && in sdl_set_uri_credentials()
249 ctx->sdl->source[l1-3] == ':' && in sdl_set_uri_credentials()
250 ctx->sdl->source[l1-2] == '8' && in sdl_set_uri_credentials()
251 ctx->sdl->source[l1-1] == '0') { in sdl_set_uri_credentials()
263 ctx->sdl->source[4] == 's' && in sdl_set_uri_credentials()
264 ctx->sdl->source[l1-4] == ':' && in sdl_set_uri_credentials()
265 ctx->sdl->source[l1-3] == '4' && in sdl_set_uri_credentials()
266 ctx->sdl->source[l1-2] == '4' && in sdl_set_uri_credentials()
267 ctx->sdl->source[l1-1] == '3') { in sdl_set_uri_credentials()
279 if (l1 != l2 || memcmp(ctx->sdl->source, uri, l1) != 0) { in sdl_set_uri_credentials()
323 sdlPtr tmpsdl = ctx->sdl; in load_wsdl_ex()
513 h->encode = get_encoder_from_prefix(ctx->sdl, part, tmp->children->content); in wsdl_soap_binding_header()
517 h->element = get_element(ctx->sdl, part, tmp->children->content); in wsdl_soap_binding_header()
713 param->encode = get_encoder_from_prefix(ctx->sdl, part, type->children->content); in wsdl_message()
717 param->element = get_element(ctx->sdl, part, element->children->content); in wsdl_message()
737 ctx.sdl = emalloc(sizeof(sdl)); in load_wsdl()
738 memset(ctx.sdl, 0, sizeof(sdl)); in load_wsdl()
739 ctx.sdl->source = estrdup(struri); in load_wsdl()
740 zend_hash_init(&ctx.sdl->functions, 0, NULL, delete_function, 0); in load_wsdl()
1137 …if (zend_hash_add(&ctx.sdl->functions, php_strtolower(tmp, len), len+1, &function, sizeof(sdlFunct… in load_wsdl()
1138 zend_hash_next_index_insert(&ctx.sdl->functions, &function, sizeof(sdlFunctionPtr), NULL); in load_wsdl()
1142 if (ctx.sdl->requests == NULL) { in load_wsdl()
1143 ctx.sdl->requests = emalloc(sizeof(HashTable)); in load_wsdl()
1144 zend_hash_init(ctx.sdl->requests, 0, NULL, NULL, 0); in load_wsdl()
1148 …zend_hash_add(ctx.sdl->requests, php_strtolower(tmp, len), len+1, &function, sizeof(sdlFunctionPtr… in load_wsdl()
1155 if (!ctx.sdl->bindings) { in load_wsdl()
1156 ctx.sdl->bindings = emalloc(sizeof(HashTable)); in load_wsdl()
1157 zend_hash_init(ctx.sdl->bindings, 0, NULL, delete_binding, 0); in load_wsdl()
1160 …if (zend_hash_add(ctx.sdl->bindings, tmpbinding->name, strlen(tmpbinding->name), &tmpbinding, size… in load_wsdl()
1161 zend_hash_next_index_insert(ctx.sdl->bindings, &tmpbinding, sizeof(sdlBindingPtr), NULL); in load_wsdl()
1172 if (ctx.sdl->bindings == NULL || ctx.sdl->bindings->nNumOfElements == 0) { in load_wsdl()
1182 return ctx.sdl; in load_wsdl()
1537 sdlPtr sdl; in get_sdl_from_cache() local
1589 sdl = emalloc(sizeof(*sdl)); in get_sdl_from_cache()
1590 memset(sdl, 0, sizeof(*sdl)); in get_sdl_from_cache()
1592 sdl->source = sdl_deserialize_string(&in); in get_sdl_from_cache()
1593 sdl->target_ns = sdl_deserialize_string(&in); in get_sdl_from_cache()
1630 sdl->groups = emalloc(sizeof(HashTable)); in get_sdl_from_cache()
1631 zend_hash_init(sdl->groups, num_groups, NULL, delete_type, 0); in get_sdl_from_cache()
1633 sdl_deserialize_key(sdl->groups, types[i], &in); in get_sdl_from_cache()
1640 sdl->types = emalloc(sizeof(HashTable)); in get_sdl_from_cache()
1641 zend_hash_init(sdl->types, num_types, NULL, delete_type, 0); in get_sdl_from_cache()
1643 sdl_deserialize_key(sdl->types, types[i], &in); in get_sdl_from_cache()
1650 sdl->elements = emalloc(sizeof(HashTable)); in get_sdl_from_cache()
1651 zend_hash_init(sdl->elements, num_elements, NULL, delete_type, 0); in get_sdl_from_cache()
1653 sdl_deserialize_key(sdl->elements, types[i], &in); in get_sdl_from_cache()
1661 sdl->encoders = emalloc(sizeof(HashTable)); in get_sdl_from_cache()
1662 zend_hash_init(sdl->encoders, num_encoders, NULL, delete_encoder, 0); in get_sdl_from_cache()
1664 sdl_deserialize_key(sdl->encoders, encoders[i], &in); in get_sdl_from_cache()
1674 sdl->bindings = emalloc(sizeof(HashTable)); in get_sdl_from_cache()
1675 zend_hash_init(sdl->bindings, num_bindings, NULL, delete_binding, 0); in get_sdl_from_cache()
1679 sdl_deserialize_key(sdl->bindings, binding, &in); in get_sdl_from_cache()
1696 zend_hash_init(&sdl->functions, num_func, NULL, delete_function, 0); in get_sdl_from_cache()
1702 sdl_deserialize_key(&sdl->functions, func, &in); in get_sdl_from_cache()
1766 sdl->requests = emalloc(sizeof(HashTable)); in get_sdl_from_cache()
1767 zend_hash_init(sdl->requests, i, NULL, NULL, 0); in get_sdl_from_cache()
1772 sdl_deserialize_key(sdl->requests, functions[function_num-1], &in); in get_sdl_from_cache()
1784 return sdl; in get_sdl_from_cache()
2112 static void add_sdl_to_cache(const char *fn, const char *uri, time_t t, sdlPtr sdl TSRMLS_DC) in add_sdl_to_cache()
2144 sdl_serialize_string(sdl->source, out); in add_sdl_to_cache()
2145 sdl_serialize_string(sdl->target_ns, out); in add_sdl_to_cache()
2147 if (sdl->groups) { in add_sdl_to_cache()
2148 i = zend_hash_num_elements(sdl->groups); in add_sdl_to_cache()
2156 zend_hash_internal_pointer_reset(sdl->groups); in add_sdl_to_cache()
2157 while (zend_hash_get_current_data(sdl->groups, (void**)&tmp) == SUCCESS) { in add_sdl_to_cache()
2160 zend_hash_move_forward(sdl->groups); in add_sdl_to_cache()
2164 if (sdl->types) { in add_sdl_to_cache()
2165 i = zend_hash_num_elements(sdl->types); in add_sdl_to_cache()
2173 zend_hash_internal_pointer_reset(sdl->types); in add_sdl_to_cache()
2174 while (zend_hash_get_current_data(sdl->types, (void**)&tmp) == SUCCESS) { in add_sdl_to_cache()
2177 zend_hash_move_forward(sdl->types); in add_sdl_to_cache()
2181 if (sdl->elements) { in add_sdl_to_cache()
2182 i = zend_hash_num_elements(sdl->elements); in add_sdl_to_cache()
2190 zend_hash_internal_pointer_reset(sdl->elements); in add_sdl_to_cache()
2191 while (zend_hash_get_current_data(sdl->elements, (void**)&tmp) == SUCCESS) { in add_sdl_to_cache()
2194 zend_hash_move_forward(sdl->elements); in add_sdl_to_cache()
2198 if (sdl->encoders) { in add_sdl_to_cache()
2199 i = zend_hash_num_elements(sdl->encoders); in add_sdl_to_cache()
2207 zend_hash_internal_pointer_reset(sdl->encoders); in add_sdl_to_cache()
2208 while (zend_hash_get_current_data(sdl->encoders, (void**)&tmp) == SUCCESS) { in add_sdl_to_cache()
2211 zend_hash_move_forward(sdl->encoders); in add_sdl_to_cache()
2221 if (sdl->groups) { in add_sdl_to_cache()
2223 zend_hash_internal_pointer_reset(sdl->groups); in add_sdl_to_cache()
2224 while (zend_hash_get_current_data(sdl->groups, (void**)&tmp) == SUCCESS) { in add_sdl_to_cache()
2225 sdl_serialize_key(sdl->groups, out); in add_sdl_to_cache()
2227 zend_hash_move_forward(sdl->groups); in add_sdl_to_cache()
2231 if (sdl->types) { in add_sdl_to_cache()
2233 zend_hash_internal_pointer_reset(sdl->types); in add_sdl_to_cache()
2234 while (zend_hash_get_current_data(sdl->types, (void**)&tmp) == SUCCESS) { in add_sdl_to_cache()
2235 sdl_serialize_key(sdl->types, out); in add_sdl_to_cache()
2237 zend_hash_move_forward(sdl->types); in add_sdl_to_cache()
2241 if (sdl->elements) { in add_sdl_to_cache()
2243 zend_hash_internal_pointer_reset(sdl->elements); in add_sdl_to_cache()
2244 while (zend_hash_get_current_data(sdl->elements, (void**)&tmp) == SUCCESS) { in add_sdl_to_cache()
2245 sdl_serialize_key(sdl->elements, out); in add_sdl_to_cache()
2247 zend_hash_move_forward(sdl->elements); in add_sdl_to_cache()
2251 if (sdl->encoders) { in add_sdl_to_cache()
2253 zend_hash_internal_pointer_reset(sdl->encoders); in add_sdl_to_cache()
2254 while (zend_hash_get_current_data(sdl->encoders, (void**)&tmp) == SUCCESS) { in add_sdl_to_cache()
2255 sdl_serialize_key(sdl->encoders, out); in add_sdl_to_cache()
2257 zend_hash_move_forward(sdl->encoders); in add_sdl_to_cache()
2262 if (sdl->bindings) { in add_sdl_to_cache()
2263 i = zend_hash_num_elements(sdl->bindings); in add_sdl_to_cache()
2272 zend_hash_internal_pointer_reset(sdl->bindings); in add_sdl_to_cache()
2273 while (zend_hash_get_current_data(sdl->bindings, (void**)&tmp) == SUCCESS) { in add_sdl_to_cache()
2274 sdl_serialize_key(sdl->bindings, out); in add_sdl_to_cache()
2288 zend_hash_move_forward(sdl->bindings); in add_sdl_to_cache()
2293 i = zend_hash_num_elements(&sdl->functions); in add_sdl_to_cache()
2300 zend_hash_internal_pointer_reset(&sdl->functions); in add_sdl_to_cache()
2301 while (zend_hash_get_current_data(&sdl->functions, (void**)&tmp) == SUCCESS) { in add_sdl_to_cache()
2302 sdl_serialize_key(&sdl->functions, out); in add_sdl_to_cache()
2353 zend_hash_move_forward(&sdl->functions); in add_sdl_to_cache()
2358 if (sdl->requests) { in add_sdl_to_cache()
2359 i = zend_hash_num_elements(sdl->requests); in add_sdl_to_cache()
2368 zend_hash_internal_pointer_reset(sdl->requests); in add_sdl_to_cache()
2369 while (zend_hash_get_current_data(sdl->requests, (void**)&tmp) == SUCCESS) { in add_sdl_to_cache()
2373 sdl_serialize_key(sdl->requests, out); in add_sdl_to_cache()
2374 zend_hash_move_forward(sdl->requests); in add_sdl_to_cache()
2952 static sdlPtr make_persistent_sdl(sdlPtr sdl TSRMLS_DC) in make_persistent_sdl()
2965 psdl = malloc(sizeof(*sdl)); in make_persistent_sdl()
2966 memset(psdl, 0, sizeof(*sdl)); in make_persistent_sdl()
2968 if (sdl->source) { in make_persistent_sdl()
2969 psdl->source = strdup(sdl->source); in make_persistent_sdl()
2971 if (sdl->target_ns) { in make_persistent_sdl()
2972 psdl->target_ns = strdup(sdl->target_ns); in make_persistent_sdl()
2975 if (sdl->groups) { in make_persistent_sdl()
2980 …zend_hash_init(psdl->groups, zend_hash_num_elements(sdl->groups), NULL, delete_type_persistent, 1); in make_persistent_sdl()
2982 zend_hash_internal_pointer_reset(sdl->groups); in make_persistent_sdl()
2983 while (zend_hash_get_current_data(sdl->groups, (void **)&tmp) == SUCCESS) { in make_persistent_sdl()
2985 …if (zend_hash_get_current_key_ex(sdl->groups, &key, &key_len, &index, 0, NULL) == HASH_KEY_IS_STRI… in make_persistent_sdl()
2991 zend_hash_move_forward(sdl->groups); in make_persistent_sdl()
2995 if (sdl->types) { in make_persistent_sdl()
3000 zend_hash_init(psdl->types, zend_hash_num_elements(sdl->types), NULL, delete_type_persistent, 1); in make_persistent_sdl()
3002 zend_hash_internal_pointer_reset(sdl->types); in make_persistent_sdl()
3003 while (zend_hash_get_current_data(sdl->types, (void **)&tmp) == SUCCESS) { in make_persistent_sdl()
3005 …if (zend_hash_get_current_key_ex(sdl->types, &key, &key_len, &index, 0, NULL) == HASH_KEY_IS_STRIN… in make_persistent_sdl()
3011 zend_hash_move_forward(sdl->types); in make_persistent_sdl()
3015 if (sdl->elements) { in make_persistent_sdl()
3020 …zend_hash_init(psdl->elements, zend_hash_num_elements(sdl->elements), NULL, delete_type_persistent… in make_persistent_sdl()
3022 zend_hash_internal_pointer_reset(sdl->elements); in make_persistent_sdl()
3023 while (zend_hash_get_current_data(sdl->elements, (void **)&tmp) == SUCCESS) { in make_persistent_sdl()
3025 …if (zend_hash_get_current_key_ex(sdl->elements, &key, &key_len, &index, 0, NULL) == HASH_KEY_IS_ST… in make_persistent_sdl()
3031 zend_hash_move_forward(sdl->elements); in make_persistent_sdl()
3035 if (sdl->encoders) { in make_persistent_sdl()
3040 …zend_hash_init(psdl->encoders, zend_hash_num_elements(sdl->encoders), NULL, delete_encoder_persist… in make_persistent_sdl()
3042 zend_hash_internal_pointer_reset(sdl->encoders); in make_persistent_sdl()
3043 while (zend_hash_get_current_data(sdl->encoders, (void **)&tmp) == SUCCESS) { in make_persistent_sdl()
3045 …if (zend_hash_get_current_key_ex(sdl->encoders, &key, &key_len, &index, 0, NULL) == HASH_KEY_IS_ST… in make_persistent_sdl()
3051 zend_hash_move_forward(sdl->encoders); in make_persistent_sdl()
3082 if (sdl->bindings) { in make_persistent_sdl()
3087 …zend_hash_init(psdl->bindings, zend_hash_num_elements(sdl->bindings), NULL, delete_binding_persist… in make_persistent_sdl()
3089 zend_hash_internal_pointer_reset(sdl->bindings); in make_persistent_sdl()
3090 while (zend_hash_get_current_data(sdl->bindings, (void **)&tmp) == SUCCESS) { in make_persistent_sdl()
3092 …if (zend_hash_get_current_key_ex(sdl->bindings, &key, &key_len, &index, 0, NULL) == HASH_KEY_IS_ST… in make_persistent_sdl()
3098 zend_hash_move_forward(sdl->bindings); in make_persistent_sdl()
3102 …zend_hash_init(&psdl->functions, zend_hash_num_elements(&sdl->functions), NULL, delete_function_pe… in make_persistent_sdl()
3103 if (zend_hash_num_elements(&sdl->functions)) { in make_persistent_sdl()
3107 zend_hash_internal_pointer_reset(&sdl->functions); in make_persistent_sdl()
3108 while (zend_hash_get_current_data(&sdl->functions, (void **)&tmp) == SUCCESS) { in make_persistent_sdl()
3110 …if (zend_hash_get_current_key_ex(&sdl->functions, &key, &key_len, &index, 0, NULL) == HASH_KEY_IS_… in make_persistent_sdl()
3116 zend_hash_move_forward(&sdl->functions); in make_persistent_sdl()
3120 if (sdl->requests) { in make_persistent_sdl()
3125 zend_hash_init(psdl->requests, zend_hash_num_elements(sdl->requests), NULL, NULL, 1); in make_persistent_sdl()
3127 zend_hash_internal_pointer_reset(sdl->requests); in make_persistent_sdl()
3128 while (zend_hash_get_current_data(sdl->requests, (void **)&tmp) == SUCCESS) { in make_persistent_sdl()
3133 …if (zend_hash_get_current_key_ex(sdl->requests, &key, &key_len, &index, 0, NULL) == HASH_KEY_IS_ST… in make_persistent_sdl()
3136 zend_hash_move_forward(sdl->requests); in make_persistent_sdl()
3148 sdlPtr sdl; member
3155 sdlPtr tmp = p->sdl; in delete_psdl()
3194 sdlPtr sdl = NULL; in get_sdl() local
3222 return p->sdl; in get_sdl()
3253 if ((sdl = get_sdl_from_cache(key, uri, t-SOAP_GLOBAL(cache_ttl), &cached TSRMLS_CC)) != NULL) { in get_sdl()
3347 sdl = load_wsdl(this_ptr, uri TSRMLS_CC); in get_sdl()
3348 if (sdl) { in get_sdl()
3349 sdl->is_persistent = 0; in get_sdl()
3360 if (sdl) { in get_sdl()
3361 add_sdl_to_cache(key, uri, t, sdl TSRMLS_CC); in get_sdl()
3368 if (sdl) { in get_sdl()
3396 return sdl; in get_sdl()
3400 psdl = make_persistent_sdl(sdl TSRMLS_CC); in get_sdl()
3403 p.sdl = psdl; in get_sdl()
3408 delete_sdl_impl(sdl); in get_sdl()
3410 sdl = psdl; in get_sdl()
3420 return sdl; in get_sdl()