- Main Page
- Modules
- Classes
- Files
- Directories
- Related Pages
- Examples

- Search for |

# message
[description]

## Files
file | axis2_msg.h
## Defines
#define | AXIS2_MSG_IN "in"
#define | AXIS2_MSG_OUT "out"
#define | AXIS2_MSG_IN_FAULT "InFaultMessage"
#define | AXIS2_MSG_OUT_FAULT "OutFaultMessage"
## Typedefs
typedef struct axis2_msg | axis2_msg_t
## Functions
AXIS2_EXTERN axis2_msg_t * | axis2_msg_create (const axutil_env_t *env)
AXIS2_EXTERN void | axis2_msg_free (axis2_msg_t *msg, const axutil_env_t *env)
AXIS2_EXTERN axis2_status_t | axis2_msg_add_param (axis2_msg_t *msg, const axutil_env_t *env, axutil_param_t *param)
AXIS2_EXTERN axutil_param_t * | axis2_msg_get_param (const axis2_msg_t *msg, const axutil_env_t *env, const axis2_char_t *name)
AXIS2_EXTERN axutil_array_list_t * | axis2_msg_get_all_params (const axis2_msg_t *msg, const axutil_env_t *env)
AXIS2_EXTERN axis2_bool_t | axis2_msg_is_param_locked (axis2_msg_t *msg, const axutil_env_t *env, const axis2_char_t *param_name)
AXIS2_EXTERN axis2_status_t | axis2_msg_set_parent (axis2_msg_t *msg, const axutil_env_t *env, axis2_op_t *op)
AXIS2_EXTERN axis2_op_t * | axis2_msg_get_parent (const axis2_msg_t *msg, const axutil_env_t *env)
AXIS2_EXTERN axutil_array_list_t * | axis2_msg_get_flow (const axis2_msg_t *msg, const axutil_env_t *env)
AXIS2_EXTERN axis2_status_t | axis2_msg_set_flow (axis2_msg_t *msg, const axutil_env_t *env, axutil_array_list_t *flow)
AXIS2_EXTERN const axis2_char_t * | axis2_msg_get_direction (const axis2_msg_t *msg, const axutil_env_t *env)
AXIS2_EXTERN axis2_status_t | axis2_msg_set_direction (axis2_msg_t *msg, const axutil_env_t *env, const axis2_char_t *direction)
AXIS2_EXTERN const axutil_qname_t * | axis2_msg_get_element_qname (const axis2_msg_t *msg, const axutil_env_t *env)
AXIS2_EXTERN axis2_status_t | axis2_msg_set_element_qname (axis2_msg_t *msg, const axutil_env_t *env, const axutil_qname_t *element_qname)
AXIS2_EXTERN const axis2_char_t * | axis2_msg_get_name (const axis2_msg_t *msg, const axutil_env_t *env)
AXIS2_EXTERN axis2_status_t | axis2_msg_set_name (axis2_msg_t *msg, const axutil_env_t *env, const axis2_char_t *name)
AXIS2_EXTERN axis2_desc_t * | axis2_msg_get_base (const axis2_msg_t *msg, const axutil_env_t *env)
AXIS2_EXTERN axutil_param_container_t * | axis2_msg_get_param_container (const axis2_msg_t *msg, const axutil_env_t *env)
AXIS2_EXTERN axis2_status_t | axis2_msg_increment_ref (axis2_msg_t *msg, const axutil_env_t *env)

## Detailed Description

message represents a message in a WSDL. It captures SOAP headers related to a given message, the direction as well as the phases to be invoked along the flow. Based on the message direction, there could be only one flow associated with a message.

## Define Documentation

#define AXIS2_MSG_IN "in"

Message of IN flow

#define AXIS2_MSG_IN_FAULT "InFaultMessage"

Message of IN FAULT flow

#define AXIS2_MSG_OUT "out"

Message of OUT flow

#define AXIS2_MSG_OUT_FAULT "OutFaultMessage"

Message of OUT FAULT flow

## Typedef Documentation

typedef struct axis2_msg axis2_msg_t

Type name for struct axis2_msg

## Function Documentation

AXIS2_EXTERN axis2_status_t axis2_msg_add_param | ( | axis2_msg_t * | msg,
|  | const axutil_env_t * | env,
|  | axutil_param_t * | param |
| ) |  |  |

Adds a parameter.

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct
  | param | pointer to parameter, message assumes ownership of parameter

Returns:
  AXIS2_SUCCESS on success, else AXIS2_FAILURE

AXIS2_EXTERN axis2_msg_t* axis2_msg_create | ( | const axutil_env_t * | env | ) |

Creates message struct instance.

Parameters:

  | env | pointer to environment struct

Returns:
  pointer to newly created message

AXIS2_EXTERN void axis2_msg_free | ( | axis2_msg_t * | msg,
|  | const axutil_env_t * | env |
| ) |  |  |

Frees message.

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct

Returns:
  void

AXIS2_EXTERN axutil_array_list_t* axis2_msg_get_all_params | ( | const axis2_msg_t * | msg,
|  | const axutil_env_t * | env |
| ) |  |  |

Gets all parameters stored in message.

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct

Returns:
  pointer to list of parameters, returns a reference, not a cloned copy

AXIS2_EXTERN axis2_desc_t* axis2_msg_get_base | ( | const axis2_msg_t * | msg,
|  | const axutil_env_t * | env |
| ) |  |  |

Gets base description.

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct

Returns:
  pointer to base description struct

AXIS2_EXTERN const axis2_char_t* axis2_msg_get_direction | ( | const axis2_msg_t * | msg,
|  | const axutil_env_t * | env |
| ) |  |  |

Gets direction of message.

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct

Returns:
  direction string

AXIS2_EXTERN const axutil_qname_t* axis2_msg_get_element_qname | ( | const axis2_msg_t * | msg,
|  | const axutil_env_t * | env |
| ) |  |  |

Gets QName representing message.

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct

Returns:
  pointer to QName, returns a reference, not a cloned copy

AXIS2_EXTERN axutil_array_list_t* axis2_msg_get_flow | ( | const axis2_msg_t * | msg,
|  | const axutil_env_t * | env |
| ) |  |  |

Gets flow of execution associated with the message.

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct

Returns:
  pointer to array list containing the list of phases representing the flow

AXIS2_EXTERN const axis2_char_t* axis2_msg_get_name | ( | const axis2_msg_t * | msg,
|  | const axutil_env_t * | env |
| ) |  |  |

Gets message name.

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct

Returns:
  message name string.

AXIS2_EXTERN axutil_param_t* axis2_msg_get_param | ( | const axis2_msg_t * | msg,
|  | const axutil_env_t * | env,
|  | const axis2_char_t * | name |
| ) |  |  |

Gets the named parameter.

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct
  | name | parameter name string

Returns:
  pointer to parameter corresponding to the same name, returns a reference, not a cloned copy

AXIS2_EXTERN axutil_param_container_t* axis2_msg_get_param_container | ( | const axis2_msg_t * | msg,
|  | const axutil_env_t * | env |
| ) |  |  |

Gets container of parameters belonging to message.

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct

Returns:
  returns container of parameters

See also:
  Parameter Container

AXIS2_EXTERN axis2_op_t* axis2_msg_get_parent | ( | const axis2_msg_t * | msg,
|  | const axutil_env_t * | env |
| ) |  |  |

Gets parent. Parent of a message is of type operation.

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct

Returns:
  pointer to parent operation, returns a reference, not a cloned copy

AXIS2_EXTERN axis2_status_t axis2_msg_increment_ref | ( | axis2_msg_t * | msg,
|  | const axutil_env_t * | env |
| ) |  |  |

Increments the reference count to this oject

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct

Returns:
  AXIS2_SUCCESS on success, else AXIS2_FAILURE

AXIS2_EXTERN axis2_bool_t axis2_msg_is_param_locked | ( | axis2_msg_t * | msg,
|  | const axutil_env_t * | env,
|  | const axis2_char_t * | param_name |
| ) |  |  |

Checks if the named parameter is locked.

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct
  | param_name | parameter name string

Returns:
  AXIS2_TRUE if the parameter is locked, else AXIS2_FALSE

AXIS2_EXTERN axis2_status_t axis2_msg_set_direction | ( | axis2_msg_t * | msg,
|  | const axutil_env_t * | env,
|  | const axis2_char_t * | direction |
| ) |  |  |

Sets direction of message.

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct
  | direction | pointer to direction

Returns:
  AXIS2_SUCCESS on success, else AXIS2_FAILURE

AXIS2_EXTERN axis2_status_t axis2_msg_set_element_qname | ( | axis2_msg_t * | msg,
|  | const axutil_env_t * | env,
|  | const axutil_qname_t * | element_qname |
| ) |  |  |

Sets QName representing message.

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct
  | element_qname | pointer to QName representing message, this function creates a clone of QName

Returns:
  AXIS2_SUCCESS on success, else AXIS2_FAILURE

AXIS2_EXTERN axis2_status_t axis2_msg_set_flow | ( | axis2_msg_t * | msg,
|  | const axutil_env_t * | env,
|  | axutil_array_list_t * | flow |
| ) |  |  |

Sets flow of execution associated with the message.

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct
  | flow | pointer to array list of phases representing the flow, message assumes ownership of flow

Returns:
  AXIS2_SUCCESS on success, else AXIS2_FAILURE

AXIS2_EXTERN axis2_status_t axis2_msg_set_name | ( | axis2_msg_t * | msg,
|  | const axutil_env_t * | env,
|  | const axis2_char_t * | name |
| ) |  |  |

Sets message name.

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct
  | name | message name string

Returns:
  AXIS2_SUCCESS on success, else AXIS2_FAILURE

AXIS2_EXTERN axis2_status_t axis2_msg_set_parent | ( | axis2_msg_t * | msg,
|  | const axutil_env_t * | env,
|  | axis2_op_t * | op |
| ) |  |  |

Sets parent. Parent of a message is of type operation.

Parameters:

  | msg | pointer to message
  | env | pointer to environment struct
  | op | pointer to parent operation, message does not assume ownership of parent

Returns:
  AXIS2_SUCCESS on success, else AXIS2_FAILURE