Back to index

php5  5.3.10
Functions
collator_error.h File Reference
#include <php.h>
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

 PHP_FUNCTION (collator_get_error_code)
 PHP_FUNCTION (collator_get_error_message)

Function Documentation

Definition at line 31 of file collator_error.c.

{
       COLLATOR_METHOD_INIT_VARS

       /* Parse parameters. */
       if( zend_parse_method_parameters( ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O",
              &object, Collator_ce_ptr ) == FAILURE )
       {
              intl_error_set( NULL, U_ILLEGAL_ARGUMENT_ERROR,
                     "collator_get_error_code: unable to parse input params", 0 TSRMLS_CC );

              RETURN_FALSE;
       }

       /* Fetch the object (without resetting its last error code). */
       co = (Collator_object *) zend_object_store_get_object(object TSRMLS_CC);
       if( co == NULL )
              RETURN_FALSE;

       /* Return collator's last error code. */
       RETURN_LONG( COLLATOR_ERROR_CODE( co ) );
}

Here is the call graph for this function:

Definition at line 60 of file collator_error.c.

{
       const char* message = NULL;

       COLLATOR_METHOD_INIT_VARS

       /* Parse parameters. */
       if( zend_parse_method_parameters( ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "O",
              &object, Collator_ce_ptr ) == FAILURE )
       {
              intl_error_set( NULL, U_ILLEGAL_ARGUMENT_ERROR,
                     "collator_get_error_message: unable to parse input params", 0 TSRMLS_CC );

              RETURN_FALSE;
       }

       /* Fetch the object (without resetting its last error code). */
       co = (Collator_object *) zend_object_store_get_object( object TSRMLS_CC );
       if( co == NULL )
              RETURN_FALSE;

       /* Return last error message. */
       message = intl_error_get_message( COLLATOR_ERROR_P( co ) TSRMLS_CC );
       RETURN_STRING( (char*)message, FALSE );
}

Here is the call graph for this function: