php-internal-docs 8.4.8
Unofficial docs for php/php-src
Loading...
Searching...
No Matches
collator_error.c
Go to the documentation of this file.
1/*
2 +----------------------------------------------------------------------+
3 | This source file is subject to version 3.01 of the PHP license, |
4 | that is bundled with this package in the file LICENSE, and is |
5 | available through the world-wide-web at the following url: |
6 | https://www.php.net/license/3_01.txt |
7 | If you did not receive a copy of the PHP license and are unable to |
8 | obtain it through the world-wide-web, please send a note to |
9 | license@php.net so we can mail you a copy immediately. |
10 +----------------------------------------------------------------------+
11 | Authors: Vadim Savchuk <vsavchuk@productengine.com> |
12 | Dmitry Lakhtyuk <dlakhtyuk@productengine.com> |
13 +----------------------------------------------------------------------+
14 */
15
16#ifdef HAVE_CONFIG_H
17#include <config.h>
18#endif
19
20#include "php_intl.h"
21#include "collator_class.h"
22
23/* {{{ Get collator's last error code. */
25{
27
28 /* Parse parameters. */
30 &object, Collator_ce_ptr ) == FAILURE )
31 {
33 }
34
35 /* Fetch the object (without resetting its last error code). */
36 co = Z_INTL_COLLATOR_P(object);
37 if( co == NULL )
39
40 /* Return collator's last error code. */
42}
43/* }}} */
44
45/* {{{ Get text description for collator's last error code. */
47{
48 zend_string* message = NULL;
49
51
52 /* Parse parameters. */
54 &object, Collator_ce_ptr ) == FAILURE )
55 {
57 }
58
59 /* Fetch the object (without resetting its last error code). */
60 co = Z_INTL_COLLATOR_P( object );
61 if( co == NULL )
63
64 /* Return last error message. */
66 RETURN_STR(message);
67}
68/* }}} */
zend_class_entry * Collator_ce_ptr
#define COLLATOR_ERROR_P(co)
#define COLLATOR_ERROR_CODE(co)
#define Z_INTL_COLLATOR_P(zv)
#define COLLATOR_METHOD_INIT_VARS
#define NULL
Definition gdcache.h:45
zend_string * intl_error_get_message(intl_error *err)
Definition intl_error.c:116
#define PHP_FUNCTION
Definition php.h:364
collator_get_error_message(Collator $object)
collator_get_error_code(Collator $object)
ZEND_API zend_result zend_parse_method_parameters(uint32_t num_args, zval *this_ptr, const char *type_spec,...)
Definition zend_API.c:1314
#define ZEND_NUM_ARGS()
Definition zend_API.h:530
#define RETURN_FALSE
Definition zend_API.h:1058
#define RETURN_LONG(l)
Definition zend_API.h:1037
#define RETURN_THROWS()
Definition zend_API.h:1060
#define RETURN_STR(s)
Definition zend_API.h:1039
#define getThis()
Definition zend_API.h:526
struct _zend_string zend_string
@ FAILURE
Definition zend_types.h:61