/** * auto generated method signature for in only mep invocations * for "add|http://ws.apache.org/axis2" operation. * @param stub The stub (axis2_stub_t) * @param env environment ( mandatory) * @param _add of the adb_add_t* * * @return */ axis2_status_t AXIS2_CALL axis2_stub_op_IIp2Location_add( axis2_stub_t *stub, const axutil_env_t *env, adb_add_t* _add) { axis2_status_t status; axis2_svc_client_t *svc_client = NULL; axis2_options_t *options = NULL; const axis2_char_t *soap_action = NULL; axutil_qname_t *op_qname = NULL; axiom_node_t *payload = NULL; axutil_string_t *soap_act = NULL; payload = adb_add_serialize(_add, env, NULL, NULL, AXIS2_TRUE, NULL, NULL); svc_client = axis2_stub_get_svc_client(stub, env ); options = axis2_stub_get_options( stub, env); if ( NULL == options ) { AXIS2_ERROR_SET(env->error, AXIS2_ERROR_INVALID_NULL_PARAM, AXIS2_FAILURE); AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "options is null in stub"); return AXIS2_FAILURE; } svc_client = axis2_stub_get_svc_client (stub, env ); soap_act = axis2_options_get_soap_action ( options, env ); if ( NULL == soap_act ) { soap_action = "urn:add"; soap_act = axutil_string_create(env, "urn:add"); axis2_options_set_soap_action(options, env, soap_act); } axis2_options_set_soap_version(options, env, AXIOM_SOAP12 ); op_qname = axutil_qname_create(env, "add" , "http://ws.apache.org/axis2", NULL); status = axis2_svc_client_send_robust_with_op_qname( svc_client, env, op_qname, payload); return status; }
/** * auto generated method signature * for "registerClient|http://www.wso2.org" operation. * @param registerClientRequest14 * @return */ axis2_registerClientResponse_t* axis2_stub_ExchangeTrader_registerClient( axis2_stub_t *stub, const axutil_env_t *env, axis2_registerClientRequest_t* registerClientRequest14) { axis2_svc_client_t *svc_client = NULL; axis2_options_t *options = NULL; axiom_node_t *ret_node = NULL; const axis2_char_t *soap_action = NULL; axutil_qname_t *op_qname = NULL; axiom_node_t *payload = NULL; axis2_registerClientResponse_t* ret_val = NULL; payload = axis2_registerClientRequest_serialize(registerClientRequest14, env, NULL, AXIS2_FALSE); options = axis2_stub_get_options( stub, env); if ( NULL == options ) { AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "options is null in stub: Error code:" " %d :: %s", env->error->error_number, AXIS2_ERROR_GET_MESSAGE(env->error)); return NULL; } svc_client = axis2_stub_get_svc_client(stub, env ); soap_action = axis2_options_get_action( options, env ); if ( NULL == soap_action ) { soap_action = "\"\""; axis2_options_set_action( options, env, soap_action ); } axis2_options_set_soap_version(options, env, AXIOM_SOAP11 ); op_qname = axutil_qname_create(env, "registerClient" , "http://www.wso2.org", NULL); ret_node = axis2_svc_client_send_receive_with_op_qname( svc_client, env, op_qname, payload); if ( NULL == ret_node ) { return NULL; } ret_val = axis2_registerClientResponse_create(env); axis2_registerClientResponse_deserialize(ret_val, env, ret_node ); return ret_val; }
void axis2_stub_ExchangeTrader_registerClient_start( axis2_stub_t *stub, const axutil_env_t *env, axis2_registerClientRequest_t* registerClientRequest14, axis2_status_t ( AXIS2_CALL *on_complete ) (struct axis2_callback *, const axutil_env_t *) , axis2_status_t ( AXIS2_CALL *on_error ) (struct axis2_callback *, const axutil_env_t *, int ) ) { axis2_callback_t *callback = NULL; axis2_svc_client_t *svc_client = NULL; axis2_options_t *options = NULL; const axis2_char_t *soap_action = NULL; axiom_node_t *payload = NULL; payload = axis2_registerClientRequest_serialize(registerClientRequest14, env, NULL, AXIS2_FALSE); options = axis2_stub_get_options( stub, env); if ( NULL == options ) { AXIS2_LOG_ERROR( env->log, AXIS2_LOG_SI, "options is null in stub: Error code:" " %d :: %s", env->error->error_number, AXIS2_ERROR_GET_MESSAGE(env->error)); return; } svc_client = axis2_stub_get_svc_client (stub, env ); soap_action =axis2_options_get_action ( options, env ); if ( NULL == soap_action ) { soap_action = "\"\""; axis2_options_set_action( options, env, soap_action ); } axis2_options_set_soap_version(options, env, AXIOM_SOAP11 ); callback = axis2_callback_create(env); /* Set our on_complete fucntion pointer to the callback object */ axis2_callback_set_on_complete(callback, on_complete); /* Set our on_error function pointer to the callback object */ axis2_callback_set_on_error(callback, on_error); /* Send request */ axis2_svc_client_send_receive_non_blocking(svc_client, env, payload, callback); }
/** * auto generated method signature for in only mep invocations * for "sell|http://www.wso2.org" operation. * @param sellRequest_ex17 * @param on_complete callback to handle on complete * @param on_error callback to handle on error */ axis2_status_t axis2_stub_ExchangeTrader_sell( axis2_stub_t *stub, const axutil_env_t *env , axis2_sellRequest_ex_t* sellRequest_ex17) { axis2_status_t status; axis2_svc_client_t *svc_client = NULL; axis2_options_t *options = NULL; const axis2_char_t *soap_action = NULL; axutil_qname_t *op_qname = NULL; axiom_node_t *payload = NULL; payload = axis2_sellRequest_ex_serialize(sellRequest_ex17, env, NULL, AXIS2_FALSE); options = axis2_stub_get_options( stub, env); if ( NULL == options ) { AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "options is null in stub: Error code:" " %d :: %s", env->error->error_number, AXIS2_ERROR_GET_MESSAGE(env->error)); return AXIS2_FAILURE; } svc_client = axis2_stub_get_svc_client (stub, env ); soap_action = axis2_options_get_action ( options, env ); if ( NULL == soap_action ) { soap_action = "\"\""; axis2_options_set_action( options, env, soap_action ); } axis2_options_set_soap_version(options, env, AXIOM_SOAP11 ); op_qname = axutil_qname_create(env, "sell" , "http://www.wso2.org", NULL); status = axis2_svc_client_send_robust_with_op_qname( svc_client, env, op_qname, payload); return status; }
void AXIS2_CALL axis2_stub_start_op_IIp2Location_get( axis2_stub_t *stub, const axutil_env_t *env, adb_get_t* _get, void *user_data, axis2_status_t ( AXIS2_CALL *on_complete ) (const axutil_env_t *, adb_getResponse_t* _getResponse, void *data) , axis2_status_t ( AXIS2_CALL *on_error ) (const axutil_env_t *, int exception, void *data) ) { axis2_callback_t *callback = NULL; axis2_svc_client_t *svc_client = NULL; axis2_options_t *options = NULL; const axis2_char_t *soap_action = NULL; axiom_node_t *payload = NULL; axis2_bool_t is_soap_act_set = AXIS2_TRUE; axutil_string_t *soap_act = NULL; struct axis2_stub_IIp2Location_get_callback_data *callback_data; callback_data = (struct axis2_stub_IIp2Location_get_callback_data*) AXIS2_MALLOC(env->allocator, sizeof(struct axis2_stub_IIp2Location_get_callback_data)); if(NULL == callback_data) { AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE); AXIS2_LOG_ERROR( env->log, AXIS2_LOG_SI, "Can not allocate memeory for the callback data structures"); return; } payload = adb_get_serialize(_get, env, NULL, NULL, AXIS2_TRUE, NULL, NULL); svc_client = axis2_stub_get_svc_client(stub, env ); options = axis2_stub_get_options( stub, env); if (NULL == options) { AXIS2_ERROR_SET(env->error, AXIS2_ERROR_INVALID_NULL_PARAM, AXIS2_FAILURE); AXIS2_LOG_ERROR( env->log, AXIS2_LOG_SI, "options is null in stub"); return; } soap_act =axis2_options_get_soap_action (options, env); if (NULL == soap_act) { is_soap_act_set = AXIS2_FALSE; soap_action = "urn:get"; soap_act = axutil_string_create(env, "urn:get"); axis2_options_set_soap_action(options, env, soap_act); } axis2_options_set_soap_version(options, env, AXIOM_SOAP12); callback = axis2_callback_create(env); /* Set our on_complete fucntion pointer to the callback object */ axis2_callback_set_on_complete(callback, axis2_stub_on_complete_IIp2Location_get); /* Set our on_error function pointer to the callback object */ axis2_callback_set_on_error(callback, axis2_stub_on_error_IIp2Location_get); callback_data-> data = user_data; callback_data-> on_complete = on_complete; callback_data-> on_error = on_error; axis2_callback_set_data(callback, (void*)callback_data); /* Send request */ axis2_svc_client_send_receive_non_blocking(svc_client, env, payload, callback); if (!is_soap_act_set) { axis2_options_set_soap_action(options, env, NULL); axis2_options_set_action(options, env, NULL); } }
adb_getResponse_t* AXIS2_CALL axis2_stub_op_IIp2Location_get( axis2_stub_t *stub, const axutil_env_t *env, adb_get_t* _get) { axis2_svc_client_t *svc_client = NULL; axis2_options_t *options = NULL; axiom_node_t *ret_node = NULL; const axis2_char_t *soap_action = NULL; axutil_qname_t *op_qname = NULL; axiom_node_t *payload = NULL; axis2_bool_t is_soap_act_set = AXIS2_TRUE; axutil_string_t *soap_act = NULL; adb_getResponse_t* ret_val; payload = adb_get_serialize(_get, env, NULL, NULL, AXIS2_TRUE, NULL, NULL); svc_client = axis2_stub_get_svc_client(stub, env ); options = axis2_stub_get_options( stub, env); if (NULL == options) { AXIS2_ERROR_SET(env->error, AXIS2_ERROR_INVALID_NULL_PARAM, AXIS2_FAILURE); AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "options is null in stub"); return (adb_getResponse_t*)NULL; } soap_act = axis2_options_get_soap_action( options, env ); if (NULL == soap_act) { is_soap_act_set = AXIS2_FALSE; soap_action = "urn:get"; soap_act = axutil_string_create(env, "urn:get"); axis2_options_set_soap_action(options, env, soap_act); } axis2_options_set_soap_version(options, env, AXIOM_SOAP12); ret_node = axis2_svc_client_send_receive_with_op_qname( svc_client, env, op_qname, payload); if (!is_soap_act_set) { axis2_options_set_soap_action(options, env, NULL); axis2_options_set_action( options, env, NULL); } if(soap_act) { axutil_string_free(soap_act, env); } if ( NULL == ret_node ) { return (adb_getResponse_t*)NULL; } ret_val = adb_getResponse_create(env); if(adb_getResponse_deserialize(ret_val, env, &ret_node, NULL, AXIS2_FALSE ) == AXIS2_FAILURE) { if(ret_val != NULL) { adb_getResponse_free(ret_val, env); } AXIS2_LOG_ERROR( env->log, AXIS2_LOG_SI, "NULL returnted from the adb_getResponse_deserialize: " "This should be due to an invalid XML"); return (adb_getResponse_t*)NULL; } return ret_val; }