Axis2/C: soap fault

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

- Search for |

# soap fault
[SOAP]

## Functions
AXIS2_EXTERN axiom_soap_fault_t * | axiom_soap_fault_create_with_parent (const axutil_env_t *env, struct axiom_soap_body *parent)
AXIS2_EXTERN axiom_soap_fault_t * | axiom_soap_fault_create_with_exception (const axutil_env_t *env, struct axiom_soap_body *parent, axis2_char_t *exception)
AXIS2_EXTERN axiom_soap_fault_t * | axiom_soap_fault_create_default_fault (const axutil_env_t *env, struct axiom_soap_body *parent, const axis2_char_t *code_value, const axis2_char_t *reason_text, const int soap_version)
AXIS2_EXTERN void | axiom_soap_fault_free (axiom_soap_fault_t *fault, const axutil_env_t *env)
AXIS2_EXTERN struct axiom_soap_fault_code * | axiom_soap_fault_get_code (axiom_soap_fault_t *fault, const axutil_env_t *env)
AXIS2_EXTERN struct axiom_soap_fault_reason * | axiom_soap_fault_get_reason (axiom_soap_fault_t *fault, const axutil_env_t *env)
AXIS2_EXTERN struct axiom_soap_fault_node * | axiom_soap_fault_get_node (axiom_soap_fault_t *fault, const axutil_env_t *env)
AXIS2_EXTERN struct axiom_soap_fault_role * | axiom_soap_fault_get_role (axiom_soap_fault_t *fault, const axutil_env_t *env)
AXIS2_EXTERN struct axiom_soap_fault_detail * | axiom_soap_fault_get_detail (axiom_soap_fault_t *fault, const axutil_env_t *env)
AXIS2_EXTERN axis2_char_t * | axiom_soap_fault_get_exception (axiom_soap_fault_t *fault, const axutil_env_t *env)
AXIS2_EXTERN axis2_status_t | axiom_soap_fault_set_exception (axiom_soap_fault_t *fault, const axutil_env_t *env, axis2_char_t *exception)
AXIS2_EXTERN axiom_node_t * | axiom_soap_fault_get_base_node (axiom_soap_fault_t *fault, const axutil_env_t *env)

## Function Documentation

AXIS2_EXTERN axiom_soap_fault_t* axiom_soap_fault_create_default_fault | ( | const axutil_env_t * | env,
|  | struct axiom_soap_body * | parent,
|  | const axis2_char_t * | code_value,
|  | const axis2_char_t * | reason_text,
|  | const int | soap_version |
| ) |  |  |

Parameters:

  | env | environment must not be NULL
  | parent | soap body struct must not be NULL
  | code_value |
  | reason_text |
  | soap_version |

Returns:
  the created default OM SOAP fault

AXIS2_EXTERN axiom_soap_fault_t* axiom_soap_fault_create_with_exception | ( | const axutil_env_t * | env,
|  | struct axiom_soap_body * | parent,
|  | axis2_char_t * | exception |
| ) |  |  |

create an returns a axiom_soap_fault_t struct with a soap fault detail element and have this exceptio string as a text of a child of soap fault detail

Parameters:

  | env | environment must not be NULL
  | parent | soap body struct must not be NULL
  | exceptio | an error string must not be NULL

Returns:
  pointer to axiom_soap_fault_t on success , otherwise return NULL

AXIS2_EXTERN axiom_soap_fault_t* axiom_soap_fault_create_with_parent | ( | const axutil_env_t * | env,
|  | struct axiom_soap_body * | parent |
| ) |  |  |

creates a soap fault struct

Parameters:

  | env | environment must not be NULL
  | parent | soap body struct to which this soap fault is the child
  | env | Environment. MUST NOT be NULL

Returns:
  pointer to axiom_soap_fault_t struct on success otherwise return NULL with error code set in environments error

AXIS2_EXTERN void axiom_soap_fault_free | ( | axiom_soap_fault_t * | fault,
|  | const axutil_env_t * | env |
| ) |  |  |

Free an axiom_soap_fault

Parameters:

  | fault | pointer to soap_fault struct
  | env | Environment. MUST NOT be NULL

Returns:
  status of the op. AXIS2_SUCCESS on success else AXIS2_FAILURE

AXIS2_EXTERN axiom_node_t* axiom_soap_fault_get_base_node | ( | axiom_soap_fault_t * | fault,
|  | const axutil_env_t * | env |
| ) |  |  |

returns the axiom_node_t struct which is wrapped by this soap fault struct

Parameters:

  | fault | soap fault struct
  | env | environment must not be NULL

Returns:
  a pointer to axiom_node_t struct if an om node is associated with this soap fault struct, otherwise return NULL

AXIS2_EXTERN struct axiom_soap_fault_code* axiom_soap_fault_get_code | ( | axiom_soap_fault_t * | fault,
|  | const axutil_env_t * | env |
| ) |  |  | `[read]`

this function returns a axiom_soap_fault_code struct if a fault code is associated with this soap fault only valid when called after building the soap fault

Parameters:

  | fault | soap fault struct
  | env | environment must not be NULL

Returns:
  pointer to soap_fault_code struct if one is associated with this soap_fault struct , NULL is returned otherwise

AXIS2_EXTERN struct axiom_soap_fault_detail* axiom_soap_fault_get_detail | ( | axiom_soap_fault_t * | fault,
|  | const axutil_env_t * | env |
| ) |  |  | `[read]`

Parameters:

  | fault | soap fault struct
  | env | environment must not be NULL

Returns:
  a pointer to soap_fault_code struct if one is associated with this soap_fault struct , NULL is returned otherwise

AXIS2_EXTERN axis2_char_t* axiom_soap_fault_get_exception | ( | axiom_soap_fault_t * | fault,
|  | const axutil_env_t * | env |
| ) |  |  |

Parameters:

  | fault | soap fault struct
  | env | enviroment must not be NULL

Returns:
  a pointer to soap_fault_code struct if one is associated with this soap_fault struct , NULL is returned otherwise

AXIS2_EXTERN struct axiom_soap_fault_node* axiom_soap_fault_get_node | ( | axiom_soap_fault_t * | fault,
|  | const axutil_env_t * | env |
| ) |  |  | `[read]`

Parameters:

  | fault | soap fault struct
  | env | environment must not be NULL

Returns:
  pointer to soap_fault_node struct if one is associated with this soap_fault struct , NULL is returned otherwise

AXIS2_EXTERN struct axiom_soap_fault_reason* axiom_soap_fault_get_reason | ( | axiom_soap_fault_t * | fault,
|  | const axutil_env_t * | env |
| ) |  |  | `[read]`

Parameters:

  | fault | soap fault struct
  | env | environment must not be NULL

Returns:
  pointer to soap_fault_reason struct if one is associated with this soap_fault struct , NULL is returned otherwise

AXIS2_EXTERN struct axiom_soap_fault_role* axiom_soap_fault_get_role | ( | axiom_soap_fault_t * | fault,
|  | const axutil_env_t * | env |
| ) |  |  | `[read]`

Parameters:

  | fault | soap fault struct
  | env | environment must not be NULL

Returns:
  pointer to soap_fault_code struct if one is associated with this soap_fault struct , NULL is returned otherwise

AXIS2_EXTERN axis2_status_t axiom_soap_fault_set_exception | ( | axiom_soap_fault_t * | fault,
|  | const axutil_env_t * | env,
|  | axis2_char_t * | exception |
| ) |  |  |

set an error string

Parameters:

  | fualt | soap fault struct
  | env | enviroment must not be NULL
  | exception | error message to be stored on soap fault