service client
[client API]


Files

file  axis2_svc_client.h

Classes

struct  axis2_svc_client_ops
struct  axis2_svc_client

Defines

#define AXIS2_ANON_SERVICE   "__ANONYMOUS_SERVICE__"
#define AXIS2_ANON_OUT_ONLY_OP   "__OPERATION_OUT_ONLY__"
#define AXIS2_ANON_ROBUST_OUT_ONLY_OP   "__OPERATION_ROBUST_OUT_ONLY__"
#define AXIS2_ANON_OUT_IN_OP   "__OPERATION_OUT_IN__"
#define AXIS2_SVC_CLIENT_GET_AXIS_SERVICE(svc_client, env)   ((svc_client)->ops->get_svc(svc_client, env))
#define AXIS2_SVC_CLIENT_SET_OPTIONS(svc_client, env, options)   ((svc_client)->ops->set_options(svc_client, env, options))
#define AXIS2_SVC_CLIENT_GET_OPTIONS(svc_client, env)   ((svc_client)->ops->get_options(svc_client, env))
#define AXIS2_SVC_CLIENT_SET_OVERRIDE_OPTIONS(svc_client, env, override_options)   ((svc_client)->ops->set_override_options(svc_client, env, override_options))
#define AXIS2_SVC_CLIENT_GET_OVERRIDE_OPTIONS(svc_client, env)   ((svc_client)->ops->get_override_options(svc_client, env))
#define AXIS2_SVC_CLIENT_ENGAGE_MODULE(svc_client, env, module_name)   ((svc_client)->ops->engage_module(svc_client, env, module_name))
#define AXIS2_SVC_CLIENT_DISENGAGE_MODULE(svc_client, env, module_name)   ((svc_client)->ops->disengage_module(svc_client, env, module_name))
#define AXIS2_SVC_CLIENT_ADD_HEADER(svc_client, env, header)   ((svc_client)->ops->add_header(svc_client, env, header))
#define AXIS2_SVC_CLIENT_REMOVE_ALL_HEADERS(svc_client, env)   ((svc_client)->ops->remove_all_headers(svc_client, env))
#define AXIS2_SVC_CLIENT_SEND_ROBUST(svc_client, env, payload)   ((svc_client)->ops->send_robust(svc_client, env, NULL, payload))
#define AXIS2_SVC_CLIENT_SEND_ROBUST_WITH_OP_QNAME(svc_client, env, op_qname, payload)   ((svc_client)->ops->send_robust(svc_client, env, op_qname, payload))
#define AXIS2_SVC_CLIENT_FIRE_AND_FORGET(svc_client, env, payload)   ((svc_client)->ops->fire_and_forget(svc_client, env, NULL, payload))
#define AXIS2_SVC_CLIENT_FIRE_AND_FORGET_WITH_OP_QNAME(svc_client, env, op_qname, payload)   ((svc_client)->ops->fire_and_forget(svc_client, env, op_qname, payload))
#define AXIS2_SVC_CLIENT_SEND_RECEIVE(svc_client, env, payload)   ((svc_client)->ops->send_receive(svc_client, env, NULL, payload))
#define AXIS2_SVC_CLIENT_SEND_RECEIVE_WITH_OP_QNAME(svc_client, env, op_qname, payload)   ((svc_client)->ops->send_receive(svc_client, env, op_qname, payload))
#define AXIS2_SVC_CLIENT_SEND_RECEIVE_NON_BLOCKING(svc_client, env, payload, callback)   ((svc_client)->ops->send_receive_non_blocking(svc_client, env, NULL, payload, callback))
#define AXIS2_SVC_CLIENT_SEND_RECEIVE_NON_BLOCKING_WITH_OP_QNAME(svc_client, env, op_qname, payload, callback)   ((svc_client)->ops->send_receive_non_blocking(svc_client, env, op_qname, payload, callback))
#define AXIS2_SVC_CLIENT_CREATE_OP_CLIENT(svc_client, env, op_qname)   ((svc_client)->ops->create_op_client(svc_client, env, op_qname))
#define AXIS2_SVC_CLIENT_FINALIZE_INVOKE(svc_client, env)   ((svc_client)->ops->finalize_invoke(svc_client, env))
#define AXIS2_SVC_CLIENT_GET_OWN_ENDPOINT_REF(svc_client, env, transport)   ((svc_client)->ops->get_own_endpoint_ref(svc_client, env, transport))
#define AXIS2_SVC_CLIENT_GET_TARGET_ENDPOINT_REF(svc_client, env)   ((svc_client)->ops->get_target_endpoint_ref(svc_client, env))
#define AXIS2_SVC_CLIENT_SET_TARGET_ENDPOINT_REF(svc_client, env, target_epr)   ((svc_client)->ops->set_target_endpoint_ref(svc_client, env, target_epr))
#define AXIS2_SVC_CLIENT_GET_SVC_CTX(svc_client, env)   ((svc_client)->ops->get_svc_ctx(svc_client, env))
#define AXIS2_SVC_CLIENT_FREE(svc_client, env)   ((svc_client)->ops->free_fn(svc_client, env))
#define AXIS2_SVC_CLIENT_GET_OP_CLIENT(svc_client, env)   ((svc_client)->ops->get_op_client(svc_client, env))

Typedefs

typedef axis2_svc_client_ops axis2_svc_client_ops_t
typedef axis2_svc_client axis2_svc_client_t

Functions

AXIS2_EXTERN axis2_svc_client_taxis2_svc_client_create (const axis2_env_t *env, const axis2_char_t *client_home)
AXIS2_EXTERN axis2_svc_client_taxis2_svc_client_create_with_conf_ctx_and_svc (const axis2_env_t *env, const axis2_char_t *client_home, axis2_conf_ctx_t *conf_ctx, axis2_svc_t *svc)
AXIS2_EXTERN axis2_svc_client_taxis2_svc_client_create_for_dynamic_invocation (const axis2_env_t *env, axis2_conf_ctx_t *conf_ctx, const axis2_uri_t *wsdl_uri, const axis2_qname_t *wsdl_svc_qname, const axis2_char_t *endpoint_name, const axis2_char_t *client_home)

Detailed Description

The service client interface serves as the primary client interface for consuming services. You can set the options to be used by the service client and then invoke an operation on a given service. There are several ways of invoking a service operation, which are based on the concept of a message exchange pattern (MEP). The two basic MEPs supported by service client are out-only and out-in. Each MEP can be used in either blocking or non-blocking mode. The operation invocations using the service client API are based on the XML-in/XML-out principle: both the payload to be sent to the service and the result from the service are in XML, represented in AXIOM.

Define Documentation

#define AXIS2_ANON_OUT_IN_OP   "__OPERATION_OUT_IN__"

out-in MEP operation name

#define AXIS2_ANON_OUT_ONLY_OP   "__OPERATION_OUT_ONLY__"

out-only MEP operation name

#define AXIS2_ANON_ROBUST_OUT_ONLY_OP   "__OPERATION_ROBUST_OUT_ONLY__"

out-only robust MEP operation name

#define AXIS2_ANON_SERVICE   "__ANONYMOUS_SERVICE__"

Name of anonymous service

#define AXIS2_SVC_CLIENT_ADD_HEADER ( svc_client,
env,
header   )     ((svc_client)->ops->add_header(svc_client, env, header))

Adds a SOAP header to be sent by the service client.

See also:
axis2_svc_client_ops::add_header

#define AXIS2_SVC_CLIENT_CREATE_OP_CLIENT ( svc_client,
env,
op_qname   )     ((svc_client)->ops->create_op_client(svc_client, env, op_qname))

Creates an operation client for a specific operation.

See also:
axis2_svc_client_ops::create_op_client

#define AXIS2_SVC_CLIENT_DISENGAGE_MODULE ( svc_client,
env,
module_name   )     ((svc_client)->ops->disengage_module(svc_client, env, module_name))

Dis-engages the given module.

See also:
axis2_svc_client_ops::disengage_module

#define AXIS2_SVC_CLIENT_ENGAGE_MODULE ( svc_client,
env,
module_name   )     ((svc_client)->ops->engage_module(svc_client, env, module_name))

Engages the given module.

See also:
axis2_svc_client_ops::engage_module

#define AXIS2_SVC_CLIENT_FINALIZE_INVOKE ( svc_client,
env   )     ((svc_client)->ops->finalize_invoke(svc_client, env))

Cleans up after the invocations.

See also:
axis2_svc_client_ops::finalize_invoke

#define AXIS2_SVC_CLIENT_FIRE_AND_FORGET ( svc_client,
env,
payload   )     ((svc_client)->ops->fire_and_forget(svc_client, env, NULL, payload))

Sends the given payload and forgets about it. No SOAP faults are reported.

See also:
axis2_svc_client_ops::fire_and_forget

#define AXIS2_SVC_CLIENT_FIRE_AND_FORGET_WITH_OP_QNAME ( svc_client,
env,
op_qname,
payload   )     ((svc_client)->ops->fire_and_forget(svc_client, env, op_qname, payload))

Sends the given payload targeted to named operation and forgets about it

See also:
axis2_svc_client_ops::fire_and_forget

#define AXIS2_SVC_CLIENT_FREE ( svc_client,
env   )     ((svc_client)->ops->free_fn(svc_client, env))

Frees given service client.

See also:
axis2_svc_client_ops::free_fn

#define AXIS2_SVC_CLIENT_GET_AXIS_SERVICE ( svc_client,
env   )     ((svc_client)->ops->get_svc(svc_client, env))

Gets the service consumed by service client.

See also:
axis2_svc_client_ops::get_svc

#define AXIS2_SVC_CLIENT_GET_OP_CLIENT ( svc_client,
env   )     ((svc_client)->ops->get_op_client(svc_client, env))

Gets the op_client .

See also:
axis2_svc_client_ops::get_op_client

#define AXIS2_SVC_CLIENT_GET_OPTIONS ( svc_client,
env   )     ((svc_client)->ops->get_options(svc_client, env))

Gets the options being used by service client.

See also:
axis2_svc_client_ops::get_options

#define AXIS2_SVC_CLIENT_GET_OVERRIDE_OPTIONS ( svc_client,
env   )     ((svc_client)->ops->get_override_options(svc_client, env))

Gets the overriding options being used by service client

See also:
axis2_svc_client_ops::get_override_options

#define AXIS2_SVC_CLIENT_GET_OWN_ENDPOINT_REF ( svc_client,
env,
transport   )     ((svc_client)->ops->get_own_endpoint_ref(svc_client, env, transport))

Gets the service client's own endpoint ref.

See also:
axis2_svc_client_ops::get_own_endpoint_ref

#define AXIS2_SVC_CLIENT_GET_SVC_CTX ( svc_client,
env   )     ((svc_client)->ops->get_svc_ctx(svc_client, env))

Gets the service context being used by the service client.

See also:
axis2_svc_client_ops::get_svc_ctx

#define AXIS2_SVC_CLIENT_GET_TARGET_ENDPOINT_REF ( svc_client,
env   )     ((svc_client)->ops->get_target_endpoint_ref(svc_client, env))

Gets the target endpoint ref.

See also:
axis2_svc_client_ops::get_target_endpoint_ref

#define AXIS2_SVC_CLIENT_REMOVE_ALL_HEADERS ( svc_client,
env   )     ((svc_client)->ops->remove_all_headers(svc_client, env))

Removes all the SOAP headers currently set on service client.

See also:
axis2_svc_client_ops::remove_all_headers

#define AXIS2_SVC_CLIENT_SEND_RECEIVE ( svc_client,
env,
payload   )     ((svc_client)->ops->send_receive(svc_client, env, NULL, payload))

Sends the given payload and receives the response.

See also:
axis2_svc_client_ops::send_receive

#define AXIS2_SVC_CLIENT_SEND_RECEIVE_NON_BLOCKING ( svc_client,
env,
payload,
callback   )     ((svc_client)->ops->send_receive_non_blocking(svc_client, env, NULL, payload, callback))

Sends the given payload and receives the response. Does not block till response arrives. Uses the callback to capture response.

See also:
axis2_svc_client_ops::send_receive_non_blocking

#define AXIS2_SVC_CLIENT_SEND_RECEIVE_NON_BLOCKING_WITH_OP_QNAME ( svc_client,
env,
op_qname,
payload,
callback   )     ((svc_client)->ops->send_receive_non_blocking(svc_client, env, op_qname, payload, callback))

Sends the given payload targeted to named operation and receives the response. Does not block till response arrives. Uses the callback to capture response

See also:
axis2_svc_client_ops::send_receive_non_blocking

#define AXIS2_SVC_CLIENT_SEND_RECEIVE_WITH_OP_QNAME ( svc_client,
env,
op_qname,
payload   )     ((svc_client)->ops->send_receive(svc_client, env, op_qname, payload))

Sends the given payload targeted to named operation and receives the response.

See also:
axis2_svc_client_ops::send_receive

#define AXIS2_SVC_CLIENT_SEND_ROBUST ( svc_client,
env,
payload   )     ((svc_client)->ops->send_robust(svc_client, env, NULL, payload))

Sends the given payload in a robust manner. Robust means that SOAP faults are captured and reported.

See also:
axis2_svc_client_ops::send_robust

#define AXIS2_SVC_CLIENT_SEND_ROBUST_WITH_OP_QNAME ( svc_client,
env,
op_qname,
payload   )     ((svc_client)->ops->send_robust(svc_client, env, op_qname, payload))

Sends the given payload in a robust manner targeted to named operation.

See also:
axis2_svc_client_ops::send_robust

#define AXIS2_SVC_CLIENT_SET_OPTIONS ( svc_client,
env,
options   )     ((svc_client)->ops->set_options(svc_client, env, options))

Sets the options to be used by service client.

See also:
axis2_svc_client_ops::set_options

#define AXIS2_SVC_CLIENT_SET_OVERRIDE_OPTIONS ( svc_client,
env,
override_options   )     ((svc_client)->ops->set_override_options(svc_client, env, override_options))

Sets the overriding options to be used by service client.

See also:
axis2_svc_client_ops::set_override_options

#define AXIS2_SVC_CLIENT_SET_TARGET_ENDPOINT_REF ( svc_client,
env,
target_epr   )     ((svc_client)->ops->set_target_endpoint_ref(svc_client, env, target_epr))

Sets the target endpoint ref.

See also:
axis2_svc_client_ops::set_target_endpoint_ref


Typedef Documentation

typedef struct axis2_svc_client_ops axis2_svc_client_ops_t

Type name for struct axis2_svc_client_ops

typedef struct axis2_svc_client axis2_svc_client_t

Type name for struct axis2_svc_client


Function Documentation

AXIS2_EXTERN axis2_svc_client_t* axis2_svc_client_create ( const axis2_env_t env,
const axis2_char_t *  client_home 
)

Creates a service client struct.

Parameters:
env pointer to environment struct
client_home name of the directory that contains the Axis2/C repository
Returns:
a pointer to newly created service client struct, or NULL on error with error code set in environment's error

AXIS2_EXTERN axis2_svc_client_t* axis2_svc_client_create_for_dynamic_invocation ( const axis2_env_t env,
axis2_conf_ctx_t conf_ctx,
const axis2_uri_t wsdl_uri,
const axis2_qname_t *  wsdl_svc_qname,
const axis2_char_t *  endpoint_name,
const axis2_char_t *  client_home 
)

Creates a service client struct. This constructor is used in dynamic invocation.

Parameters:
env pointer to environment struct
conf_ctx pointer to configuration context. Newly created client assumes ownership of the conf_ctx
wsdl_uri pointer to uri of the wsdl file.
wsdl_svc_qname pointer to qname of the wsdl service. If this is NULL first service is assumed
endpoint_name pointer to endpoint name. If this is NULL first endpoint is assumed.
client_home name of the directory that contains the Axis2/C repository
Returns:
a pointer to newly created service client struct, or NULL on error with error code set in environment's error

AXIS2_EXTERN axis2_svc_client_t* axis2_svc_client_create_with_conf_ctx_and_svc ( const axis2_env_t env,
const axis2_char_t *  client_home,
axis2_conf_ctx_t conf_ctx,
axis2_svc_t svc 
)

Creates a service client struct for a specified service and configuration context.

Parameters:
env pointer to environment struct
conf_ctx pointer to configuration context. Newly created client assumes ownership of the conf_ctx
svc pointer to service struct representing the service to be consumed. Newly created client assumes ownership of the service
client_home name of the directory that contains the Axis2/C repository
Returns:
a pointer to newly created service client struct, or NULL on error with error code set in environment's error


Generated on Wed Dec 20 20:14:13 2006 for Axis2/C by  doxygen 1.5.1