diff --git a/.travis.yml b/.travis.yml
index 9e93e01367e..3f29afe54c6 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,5 +1,7 @@
language: php
+sudo: false
+
php:
- 5.3
- 5.4
@@ -24,16 +26,16 @@ before_script:
- git submodule --quiet update --init --recursive
- (cd php-tests/library/Mustache; git checkout master)
- (cd php-tests/library/Twig; git checkout master)
- - (cd vendor/phalcon/zephir; ./unit-tests/ci/before_install.sh; ./install)
- - ./vendor/bin/zephir generate
- - (cd ext; export CFLAGS="-g3 -O1 -std=gnu90 -Wall -DZEPHIR_RELEASE=1"; phpize && ./configure --enable-phalcon && make --silent -j4 && sudo make --silent install && phpenv config-add ../unit-tests/ci/phalcon.ini)
+ - (cd vendor/phalcon/zephir; ./unit-tests/ci/before_install.sh)
+ - (./unit-tests/ci/install_zephir.sh)
+ - (export PATH=$PATH:~/bin; zephir generate)
+ - (cd ext; export CFLAGS="-g3 -O1 -std=gnu90 -Wall -DZEPHIR_RELEASE=1"; phpize && ./configure --enable-phalcon && make --silent -j4 && make --silent install && phpenv config-add ../unit-tests/ci/phalcon.ini)
- ulimit -c unlimited || true
script:
- ./run-tests.sh
after_failure:
- - sudo apt-get -qq install gdb
- ./unit-tests/ci/after_failure.sh
notifications:
@@ -42,3 +44,8 @@ notifications:
- eduar@phalconphp.com
- nikos@phalconphp.com
+addons:
+ apt:
+ packages:
+ - gdb
+ - re2c
diff --git a/CHANGELOG.md b/CHANGELOG.md
index a1f10ff4a83..d33fa5018ec 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,9 +1,28 @@
+# [2.0.6](https://github.com/phalcon/cphalcon/releases/tag/phalcon-v2.0.6) (2015-??-??)
+- Builds in TravisCI now uses Docker to perform faster builds
+- Added `Http\Response::setCache()` to easily set cache headers.
+- When a beanstalkd connection is closed the adapter does not produce a notice anymore
+- Default separator in `Text::increment` is now _ (underscore)
+- Using tel_field in Volt now generates correct PHP code
+- SQL generated by PostgreSQL dialect in dropTable and dropView is now correct
+- Errors generated in `Cache\Backend\Memcached` now shows the result code to easily debug problems
+- Fixed `LIMIT/OFFSET` SQL generation in `Mvc\Model\Query\Builder`
+- Fixed Logger\Formatter\Line to match 1.3.x behavior
+- Fixed warning when castOnHydrate' is true [#10648](https://github.com/phalcon/cphalcon/pull/10648)
+- Added name before int/float/numeric/string/bool/null/other variables in Debug\Dump::output
+- Now `Validation\Validator\Identical` allows both 'accepted' and 'value' as value to keep backwards compatibility
+- Added `\Phalcon\Mvc\Model\MetaData\Redis` adapter.
+- Added Redis Session adapter
+- Fixed bug in Mvc\Model\Criteria::fromInput unallowing it to use renamed columns
+- Fixed bug in `Http\Request` getRawBody()/getPut() clears input buffer [#10694](https://github.com/phalcon/cphalcon/issues/10694)
+
# [2.0.5](https://github.com/phalcon/cphalcon/releases/tag/phalcon-v2.0.5) (2015-07-14)
- Fixed a bug that makes that attaching an events manager to an Mvc\Application causes view->render() not being called
-- Fixed bug that makes generated SQL statements using FOR UPDATE not being parsed correctly
+- Fixed bug that makes generated SQL statements using FOR UPDATE not being parsed correctly
- The email filter now no longer removes the ' character [#10603](https://github.com/phalcon/cphalcon/pull/10603)
- When an array is bound the cached representation in PHQL makes the SQL being incorrectly
generated the second time.
+- Added `\Phalcon\Mvc\Model\MetaData\Memcache` and `\Phalcon\Mvc\Model\MetaData\Libmemcached` adapters
# [2.0.4](https://github.com/phalcon/cphalcon/releases/tag/phalcon-v2.0.4) (2015-07-07)
- Fixed bug in `Phalcon\Mvc\Model::update()` that throws an exception when the record does exist
diff --git a/build/32bits/phalcon.zep.c b/build/32bits/phalcon.zep.c
index 889eaa24e83..f03e012a1f9 100644
--- a/build/32bits/phalcon.zep.c
+++ b/build/32bits/phalcon.zep.c
@@ -3605,6 +3605,11 @@ long zephir_safe_mod_double_zval(double op1, zval *op2 TSRMLS_DC);
#define ZEPHIR_SCONCAT_SVSVSVS(result, op1, op2, op3, op4, op5, op6, op7) \
zephir_concat_svsvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, 1 TSRMLS_CC);
+#define ZEPHIR_CONCAT_SVSVSVSSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9, op10, op11, op12) \
+ zephir_concat_svsvsvssvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, sizeof(op8)-1, op9, op10, sizeof(op10)-1, op11, op12, sizeof(op12)-1, 0 TSRMLS_CC);
+#define ZEPHIR_SCONCAT_SVSVSVSSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9, op10, op11, op12) \
+ zephir_concat_svsvsvssvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, sizeof(op8)-1, op9, op10, sizeof(op10)-1, op11, op12, sizeof(op12)-1, 1 TSRMLS_CC);
+
#define ZEPHIR_CONCAT_SVSVSVSV(result, op1, op2, op3, op4, op5, op6, op7, op8) \
zephir_concat_svsvsvsv(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, 0 TSRMLS_CC);
#define ZEPHIR_SCONCAT_SVSVSVSV(result, op1, op2, op3, op4, op5, op6, op7, op8) \
@@ -3615,6 +3620,11 @@ long zephir_safe_mod_double_zval(double op1, zval *op2 TSRMLS_DC);
#define ZEPHIR_SCONCAT_SVSVSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9) \
zephir_concat_svsvsvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, op9, sizeof(op9)-1, 1 TSRMLS_CC);
+#define ZEPHIR_CONCAT_SVSVSVSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9, op10, op11) \
+ zephir_concat_svsvsvsvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, op9, sizeof(op9)-1, op10, op11, sizeof(op11)-1, 0 TSRMLS_CC);
+#define ZEPHIR_SCONCAT_SVSVSVSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9, op10, op11) \
+ zephir_concat_svsvsvsvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, op9, sizeof(op9)-1, op10, op11, sizeof(op11)-1, 1 TSRMLS_CC);
+
#define ZEPHIR_CONCAT_SVSVV(result, op1, op2, op3, op4, op5) \
zephir_concat_svsvv(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, 0 TSRMLS_CC);
#define ZEPHIR_SCONCAT_SVSVV(result, op1, op2, op3, op4, op5) \
@@ -3718,8 +3728,10 @@ static void zephir_concat_svsvs(zval **result, const char *op1, zend_uint op1_le
static void zephir_concat_svsvssvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, const char *op6, zend_uint op6_len, zval *op7, const char *op8, zend_uint op8_len, zval *op9, const char *op10, zend_uint op10_len, int self_var TSRMLS_DC);
static void zephir_concat_svsvsv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, int self_var TSRMLS_DC);
static void zephir_concat_svsvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, int self_var TSRMLS_DC);
+static void zephir_concat_svsvsvssvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, const char *op8, zend_uint op8_len, zval *op9, const char *op10, zend_uint op10_len, zval *op11, const char *op12, zend_uint op12_len, int self_var TSRMLS_DC);
static void zephir_concat_svsvsvsv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, int self_var TSRMLS_DC);
static void zephir_concat_svsvsvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, const char *op9, zend_uint op9_len, int self_var TSRMLS_DC);
+static void zephir_concat_svsvsvsvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, const char *op9, zend_uint op9_len, zval *op10, const char *op11, zend_uint op11_len, int self_var TSRMLS_DC);
static void zephir_concat_svsvv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, zval *op5, int self_var TSRMLS_DC);
static void zephir_concat_svsvvsv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, zval *op5, const char *op6, zend_uint op6_len, zval *op7, int self_var TSRMLS_DC);
static void zephir_concat_svsvvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, zval *op5, const char *op6, zend_uint op6_len, zval *op7, const char *op8, zend_uint op8_len, int self_var TSRMLS_DC);
@@ -10022,7 +10034,7 @@ static void zephir_fast_join_str(zval *return_value, char *glue, unsigned int gl
static void zephir_camelize(zval *return_value, const zval *str) {
- int i, len;
+ int i, len, first = 0;
smart_str camelize_str = {0};
char *marker, ch;
@@ -10034,35 +10046,40 @@ static void zephir_camelize(zval *return_value, const zval *str) {
marker = Z_STRVAL_P(str);
len = Z_STRLEN_P(str);
- for (i = 0; i < len - 1; i++) {
- ch = *marker;
- if (i == 0 || ch == '-' || ch == '_') {
+ for (i = 0; i < len; i++) {
+
+ ch = marker[i];
+
+ if (first == 0) {
+
if (ch == '-' || ch == '_') {
- i++;
- marker++;
+ continue;
}
- smart_str_appendc(&camelize_str, toupper(*marker));
- }
- else {
- smart_str_appendc(&camelize_str, tolower(*marker));
+ first = 1;
+ smart_str_appendc(&camelize_str, toupper(ch));
+ continue;
}
- marker++;
- }
+ if (ch == '-' || ch == '_') {
+ if (i != (len - 1)) {
+ i++;
+ ch = marker[i];
+ smart_str_appendc(&camelize_str, toupper(ch));
+ }
+ continue;
+ }
- if (likely(i == len - 1)) {
- smart_str_appendc(&camelize_str, *marker);
+ smart_str_appendc(&camelize_str, tolower(ch));
}
smart_str_0(&camelize_str);
if (camelize_str.c) {
RETURN_STRINGL(camelize_str.c, camelize_str.len, 0);
- } else {
- RETURN_EMPTY_STRING();
}
+ RETURN_EMPTY_STRING();
}
static void zephir_uncamelize(zval *return_value, const zval *str) {
@@ -10078,10 +10095,13 @@ static void zephir_uncamelize(zval *return_value, const zval *str) {
marker = Z_STRVAL_P(str);
for (i = 0; i < Z_STRLEN_P(str); i++) {
+
ch = *marker;
+
if (ch == '\0') {
break;
}
+
if (ch >= 'A' && ch <= 'Z') {
if (i > 0) {
smart_str_appendc(&uncamelize_str, '_');
@@ -10090,6 +10110,7 @@ static void zephir_uncamelize(zval *return_value, const zval *str) {
} else {
smart_str_appendc(&uncamelize_str, (*marker));
}
+
marker++;
}
smart_str_0(&uncamelize_str);
@@ -10257,7 +10278,7 @@ static void zephir_fast_str_replace(zval **return_value_ptr, zval *search, zval
if (Z_TYPE_P(search) == IS_ARRAY) {
do {
- zval *params[] = { search, replace, subject };
+ zval *params[] = { search, replace, subject };
zval_ptr_dtor(return_value_ptr);
return_value_ptr = NULL;
zephir_call_func_aparams(return_value_ptr, "str_replace", sizeof("str_replace")-1, NULL, 0, 3, params TSRMLS_CC);
@@ -14452,6 +14473,107 @@ static void zephir_concat_svsvsvs(zval **result, const char *op1, zend_uint op1_
}
+static void zephir_concat_svsvsvssvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, const char *op8, zend_uint op8_len, zval *op9, const char *op10, zend_uint op10_len, zval *op11, const char *op12, zend_uint op12_len, int self_var TSRMLS_DC){
+
+ zval result_copy, op2_copy, op4_copy, op6_copy, op9_copy, op11_copy;
+ int use_copy = 0, use_copy2 = 0, use_copy4 = 0, use_copy6 = 0, use_copy9 = 0, use_copy11 = 0;
+ uint offset = 0, length;
+
+ if (Z_TYPE_P(op2) != IS_STRING) {
+ zend_make_printable_zval(op2, &op2_copy, &use_copy2);
+ if (use_copy2) {
+ op2 = &op2_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op4) != IS_STRING) {
+ zend_make_printable_zval(op4, &op4_copy, &use_copy4);
+ if (use_copy4) {
+ op4 = &op4_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op6) != IS_STRING) {
+ zend_make_printable_zval(op6, &op6_copy, &use_copy6);
+ if (use_copy6) {
+ op6 = &op6_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op9) != IS_STRING) {
+ zend_make_printable_zval(op9, &op9_copy, &use_copy9);
+ if (use_copy9) {
+ op9 = &op9_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op11) != IS_STRING) {
+ zend_make_printable_zval(op11, &op11_copy, &use_copy11);
+ if (use_copy11) {
+ op11 = &op11_copy;
+ }
+ }
+
+ length = op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len + Z_STRLEN_P(op9) + op10_len + Z_STRLEN_P(op11) + op12_len;
+ if (self_var) {
+
+ if (Z_TYPE_PP(result) != IS_STRING) {
+ zend_make_printable_zval(*result, &result_copy, &use_copy);
+ if (use_copy) {
+ ZEPHIR_CPY_WRT_CTOR(*result, (&result_copy));
+ }
+ }
+
+ offset = Z_STRLEN_PP(result);
+ length += offset;
+ Z_STRVAL_PP(result) = (char *) str_erealloc(Z_STRVAL_PP(result), length + 1);
+
+ } else {
+ Z_STRVAL_PP(result) = (char *) emalloc(length + 1);
+ }
+
+ memcpy(Z_STRVAL_PP(result) + offset, op1, op1_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len, Z_STRVAL_P(op2), Z_STRLEN_P(op2));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2), op3, op3_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len, Z_STRVAL_P(op4), Z_STRLEN_P(op4));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4), op5, op5_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len, Z_STRVAL_P(op6), Z_STRLEN_P(op6));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6), op7, op7_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len, op8, op8_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len, Z_STRVAL_P(op9), Z_STRLEN_P(op9));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len + Z_STRLEN_P(op9), op10, op10_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len + Z_STRLEN_P(op9) + op10_len, Z_STRVAL_P(op11), Z_STRLEN_P(op11));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len + Z_STRLEN_P(op9) + op10_len + Z_STRLEN_P(op11), op12, op12_len);
+ Z_STRVAL_PP(result)[length] = 0;
+ Z_TYPE_PP(result) = IS_STRING;
+ Z_STRLEN_PP(result) = length;
+
+ if (use_copy2) {
+ zval_dtor(op2);
+ }
+
+ if (use_copy4) {
+ zval_dtor(op4);
+ }
+
+ if (use_copy6) {
+ zval_dtor(op6);
+ }
+
+ if (use_copy9) {
+ zval_dtor(op9);
+ }
+
+ if (use_copy11) {
+ zval_dtor(op11);
+ }
+
+ if (use_copy) {
+ zval_dtor(&result_copy);
+ }
+
+}
+
static void zephir_concat_svsvsvsv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, int self_var TSRMLS_DC){
zval result_copy, op2_copy, op4_copy, op6_copy, op8_copy;
@@ -14625,6 +14747,106 @@ static void zephir_concat_svsvsvsvs(zval **result, const char *op1, zend_uint op
}
+static void zephir_concat_svsvsvsvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, const char *op9, zend_uint op9_len, zval *op10, const char *op11, zend_uint op11_len, int self_var TSRMLS_DC){
+
+ zval result_copy, op2_copy, op4_copy, op6_copy, op8_copy, op10_copy;
+ int use_copy = 0, use_copy2 = 0, use_copy4 = 0, use_copy6 = 0, use_copy8 = 0, use_copy10 = 0;
+ uint offset = 0, length;
+
+ if (Z_TYPE_P(op2) != IS_STRING) {
+ zend_make_printable_zval(op2, &op2_copy, &use_copy2);
+ if (use_copy2) {
+ op2 = &op2_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op4) != IS_STRING) {
+ zend_make_printable_zval(op4, &op4_copy, &use_copy4);
+ if (use_copy4) {
+ op4 = &op4_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op6) != IS_STRING) {
+ zend_make_printable_zval(op6, &op6_copy, &use_copy6);
+ if (use_copy6) {
+ op6 = &op6_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op8) != IS_STRING) {
+ zend_make_printable_zval(op8, &op8_copy, &use_copy8);
+ if (use_copy8) {
+ op8 = &op8_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op10) != IS_STRING) {
+ zend_make_printable_zval(op10, &op10_copy, &use_copy10);
+ if (use_copy10) {
+ op10 = &op10_copy;
+ }
+ }
+
+ length = op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + Z_STRLEN_P(op8) + op9_len + Z_STRLEN_P(op10) + op11_len;
+ if (self_var) {
+
+ if (Z_TYPE_PP(result) != IS_STRING) {
+ zend_make_printable_zval(*result, &result_copy, &use_copy);
+ if (use_copy) {
+ ZEPHIR_CPY_WRT_CTOR(*result, (&result_copy));
+ }
+ }
+
+ offset = Z_STRLEN_PP(result);
+ length += offset;
+ Z_STRVAL_PP(result) = (char *) str_erealloc(Z_STRVAL_PP(result), length + 1);
+
+ } else {
+ Z_STRVAL_PP(result) = (char *) emalloc(length + 1);
+ }
+
+ memcpy(Z_STRVAL_PP(result) + offset, op1, op1_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len, Z_STRVAL_P(op2), Z_STRLEN_P(op2));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2), op3, op3_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len, Z_STRVAL_P(op4), Z_STRLEN_P(op4));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4), op5, op5_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len, Z_STRVAL_P(op6), Z_STRLEN_P(op6));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6), op7, op7_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len, Z_STRVAL_P(op8), Z_STRLEN_P(op8));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + Z_STRLEN_P(op8), op9, op9_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + Z_STRLEN_P(op8) + op9_len, Z_STRVAL_P(op10), Z_STRLEN_P(op10));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + Z_STRLEN_P(op8) + op9_len + Z_STRLEN_P(op10), op11, op11_len);
+ Z_STRVAL_PP(result)[length] = 0;
+ Z_TYPE_PP(result) = IS_STRING;
+ Z_STRLEN_PP(result) = length;
+
+ if (use_copy2) {
+ zval_dtor(op2);
+ }
+
+ if (use_copy4) {
+ zval_dtor(op4);
+ }
+
+ if (use_copy6) {
+ zval_dtor(op6);
+ }
+
+ if (use_copy8) {
+ zval_dtor(op8);
+ }
+
+ if (use_copy10) {
+ zval_dtor(op10);
+ }
+
+ if (use_copy) {
+ zval_dtor(&result_copy);
+ }
+
+}
+
static void zephir_concat_svsvv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, zval *op5, int self_var TSRMLS_DC){
zval result_copy, op2_copy, op4_copy, op5_copy;
@@ -17401,12 +17623,12 @@ static PHP_METHOD(phalcon_0__closure, __invoke) {
- zephir_array_fetch_long(&_0, matches, 1, PH_NOISY | PH_READONLY, "phalcon/text.zep", 276 TSRMLS_CC);
+ zephir_array_fetch_long(&_0, matches, 1, PH_NOISY | PH_READONLY, "phalcon/text.zep", 272 TSRMLS_CC);
ZEPHIR_INIT_VAR(words);
zephir_fast_explode_str(words, SL("|"), _0, LONG_MAX TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_2, "array_rand", NULL, 438, words);
+ ZEPHIR_CALL_FUNCTION(&_2, "array_rand", NULL, 442, words);
zephir_check_call_status();
- zephir_array_fetch(&_1, words, _2, PH_NOISY | PH_READONLY, "phalcon/text.zep", 277 TSRMLS_CC);
+ zephir_array_fetch(&_1, words, _2, PH_NOISY | PH_READONLY, "phalcon/text.zep", 273 TSRMLS_CC);
RETURN_CTOR(_1);
}
@@ -17967,7 +18189,7 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) {
if (_0) {
paddingSize = (blockSize - (zephir_safe_mod_long_long(zephir_fast_strlen_ev(text), blockSize TSRMLS_CC)));
if (paddingSize >= 256) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Block size is bigger than 256", "phalcon/crypt.zep", 147);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Block size is bigger than 256", "phalcon/crypt.zep", 142);
return;
}
do {
@@ -18076,7 +18298,7 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) {
RETURN_CTOR(text);
}
if (paddingSize > blockSize) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Invalid padding size", "phalcon/crypt.zep", 191);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Invalid padding size", "phalcon/crypt.zep", 186);
return;
}
ZEPHIR_SINIT_NVAR(_1);
@@ -18352,7 +18574,7 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) {
if (!((zephir_function_exists_ex(SS("mcrypt_get_iv_size") TSRMLS_CC) == SUCCESS))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "mcrypt extension is required", "phalcon/crypt.zep", 307);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "mcrypt extension is required", "phalcon/crypt.zep", 302);
return;
}
if (ZEPHIR_IS_STRING_IDENTICAL(key, "")) {
@@ -18362,7 +18584,7 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) {
ZEPHIR_CPY_WRT(encryptKey, key);
}
if (ZEPHIR_IS_EMPTY(encryptKey)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Encryption key cannot be empty", "phalcon/crypt.zep", 317);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Encryption key cannot be empty", "phalcon/crypt.zep", 312);
return;
}
ZEPHIR_OBS_VAR(cipher);
@@ -18372,7 +18594,7 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) {
ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 131, cipher, mode);
zephir_check_call_status();
if (ZEPHIR_LT_LONG(ivSize, zephir_fast_strlen_ev(encryptKey))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 325);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 320);
return;
}
ZEPHIR_SINIT_VAR(_0);
@@ -18441,7 +18663,7 @@ static PHP_METHOD(Phalcon_Crypt, decrypt) {
if (!((zephir_function_exists_ex(SS("mcrypt_get_iv_size") TSRMLS_CC) == SUCCESS))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "mcrypt extension is required", "phalcon/crypt.zep", 361);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "mcrypt extension is required", "phalcon/crypt.zep", 356);
return;
}
if (Z_TYPE_P(key) == IS_NULL) {
@@ -18451,7 +18673,7 @@ static PHP_METHOD(Phalcon_Crypt, decrypt) {
ZEPHIR_CPY_WRT(decryptKey, key);
}
if (ZEPHIR_IS_EMPTY(decryptKey)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Decryption key cannot be empty", "phalcon/crypt.zep", 371);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Decryption key cannot be empty", "phalcon/crypt.zep", 366);
return;
}
ZEPHIR_OBS_VAR(cipher);
@@ -18463,13 +18685,13 @@ static PHP_METHOD(Phalcon_Crypt, decrypt) {
ZEPHIR_INIT_VAR(keySize);
ZVAL_LONG(keySize, zephir_fast_strlen_ev(decryptKey));
if (ZEPHIR_GT(keySize, ivSize)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 380);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 375);
return;
}
ZEPHIR_INIT_VAR(length);
ZVAL_LONG(length, zephir_fast_strlen_ev(text));
if (ZEPHIR_GT(keySize, length)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of IV is larger than text to decrypt", "phalcon/crypt.zep", 385);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of IV is larger than text to decrypt", "phalcon/crypt.zep", 380);
return;
}
ZEPHIR_INIT_VAR(_0);
@@ -18917,7 +19139,7 @@ static PHP_METHOD(Phalcon_Debug, listenExceptions) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "onUncaughtException", 1);
zephir_array_fast_append(_0, _1);
- ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 147, _0);
+ ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 148, _0);
zephir_check_call_status();
RETURN_THIS();
@@ -18937,7 +19159,7 @@ static PHP_METHOD(Phalcon_Debug, listenLowSeverity) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "onUncaughtLowSeverity", 1);
zephir_array_fast_append(_0, _1);
- ZEPHIR_CALL_FUNCTION(NULL, "set_error_handler", NULL, 148, _0);
+ ZEPHIR_CALL_FUNCTION(NULL, "set_error_handler", NULL, 149, _0);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_2);
zephir_create_array(_2, 2, 0 TSRMLS_CC);
@@ -18945,7 +19167,7 @@ static PHP_METHOD(Phalcon_Debug, listenLowSeverity) {
ZEPHIR_INIT_NVAR(_1);
ZVAL_STRING(_1, "onUncaughtException", 1);
zephir_array_fast_append(_2, _1);
- ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 147, _2);
+ ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 148, _2);
zephir_check_call_status();
RETURN_THIS();
@@ -18980,7 +19202,7 @@ static PHP_METHOD(Phalcon_Debug, debugVar) {
ZEPHIR_INIT_VAR(_0);
zephir_create_array(_0, 3, 0 TSRMLS_CC);
zephir_array_fast_append(_0, varz);
- ZEPHIR_CALL_FUNCTION(&_1, "debug_backtrace", NULL, 149);
+ ZEPHIR_CALL_FUNCTION(&_1, "debug_backtrace", NULL, 150);
zephir_check_call_status();
zephir_array_fast_append(_0, _1);
ZEPHIR_INIT_VAR(_2);
@@ -19020,7 +19242,7 @@ static PHP_METHOD(Phalcon_Debug, _escapeString) {
ZVAL_LONG(&_3, 2);
ZEPHIR_SINIT_VAR(_4);
ZVAL_STRING(&_4, "utf-8", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("htmlentities", NULL, 150, _0, &_3, &_4);
+ ZEPHIR_RETURN_CALL_FUNCTION("htmlentities", NULL, 151, _0, &_3, &_4);
zephir_check_call_status();
RETURN_MM();
}
@@ -19071,7 +19293,7 @@ static PHP_METHOD(Phalcon_Debug, _getArrayDump) {
) {
ZEPHIR_GET_HMKEY(k, _2, _1);
ZEPHIR_GET_HVALUE(v, _3);
- ZEPHIR_CALL_FUNCTION(&_4, "is_scalar", &_5, 151, v);
+ ZEPHIR_CALL_FUNCTION(&_4, "is_scalar", &_5, 152, v);
zephir_check_call_status();
if (zephir_is_true(_4)) {
ZEPHIR_INIT_NVAR(varDump);
@@ -19088,7 +19310,7 @@ static PHP_METHOD(Phalcon_Debug, _getArrayDump) {
if (Z_TYPE_P(v) == IS_ARRAY) {
ZEPHIR_INIT_NVAR(_8);
ZVAL_LONG(_8, (zephir_get_numberval(n) + 1));
- ZEPHIR_CALL_METHOD(&_6, this_ptr, "_getarraydump", &_9, 152, v, _8);
+ ZEPHIR_CALL_METHOD(&_6, this_ptr, "_getarraydump", &_9, 153, v, _8);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_10);
ZEPHIR_CONCAT_SVSVS(_10, "[", k, "] => Array(", _6, ")");
@@ -19122,14 +19344,14 @@ static PHP_METHOD(Phalcon_Debug, _getVarDump) {
zephir_fcall_cache_entry *_2 = NULL;
int ZEPHIR_LAST_CALL_STATUS;
- zval *variable, *className, *dumpedObject = NULL, *dump, *_0 = NULL, *_1 = NULL;
+ zval *variable, *className, *dumpedObject = NULL, *_0 = NULL, *_1 = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 0, &variable);
- ZEPHIR_CALL_FUNCTION(&_0, "is_scalar", NULL, 151, variable);
+ ZEPHIR_CALL_FUNCTION(&_0, "is_scalar", NULL, 152, variable);
zephir_check_call_status();
if (zephir_is_true(_0)) {
if (Z_TYPE_P(variable) == IS_BOOL) {
@@ -19150,20 +19372,20 @@ static PHP_METHOD(Phalcon_Debug, _getVarDump) {
if (Z_TYPE_P(variable) == IS_OBJECT) {
ZEPHIR_INIT_VAR(className);
zephir_get_class(className, variable, 0 TSRMLS_CC);
- ZEPHIR_INIT_VAR(dump);
if ((zephir_method_exists_ex(variable, SS("dump") TSRMLS_CC) == SUCCESS)) {
ZEPHIR_CALL_METHOD(&dumpedObject, variable, "dump", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 0, dumpedObject);
zephir_check_call_status();
- ZEPHIR_CONCAT_SVSVS(dump, "Object(", className, ": ", _1, ")");
+ ZEPHIR_CONCAT_SVSVS(return_value, "Object(", className, ": ", _1, ")");
+ RETURN_MM();
} else {
- ZEPHIR_CONCAT_SVS(dump, "Object(", className, ")");
+ ZEPHIR_CONCAT_SVS(return_value, "Object(", className, ")");
+ RETURN_MM();
}
- RETURN_CCTOR(dump);
}
if (Z_TYPE_P(variable) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 152, variable);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 153, variable);
zephir_check_call_status();
ZEPHIR_CONCAT_SVS(return_value, "Array(", _1, ")");
RETURN_MM();
@@ -19184,11 +19406,11 @@ static PHP_METHOD(Phalcon_Debug, getMajorVersion) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_version_ce, "get", &_1, 153);
+ ZEPHIR_CALL_CE_STATIC(&_0, phalcon_version_ce, "get", &_1, 154);
zephir_check_call_status();
ZEPHIR_INIT_VAR(parts);
zephir_fast_explode_str(parts, SL(" "), _0, LONG_MAX TSRMLS_CC);
- zephir_array_fetch_long(&_2, parts, 0, PH_NOISY | PH_READONLY, "phalcon/debug.zep", 290 TSRMLS_CC);
+ zephir_array_fetch_long(&_2, parts, 0, PH_NOISY | PH_READONLY, "phalcon/debug.zep", 289 TSRMLS_CC);
RETURN_CTOR(_2);
}
@@ -19203,7 +19425,7 @@ static PHP_METHOD(Phalcon_Debug, getVersion) {
ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmajorversion", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_CE_STATIC(&_1, phalcon_version_ce, "get", &_2, 153);
+ ZEPHIR_CALL_CE_STATIC(&_1, phalcon_version_ce, "get", &_2, 154);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "
#", &_0, " | ");
ZEPHIR_CPY_WRT(html, _1);
- if (zephir_array_isset_string(trace, SS("class"))) {
- ZEPHIR_OBS_VAR(className);
- zephir_array_fetch_string(&className, trace, SL("class"), PH_NOISY, "phalcon/debug.zep", 356 TSRMLS_CC);
+ ZEPHIR_OBS_VAR(className);
+ if (zephir_array_isset_string_fetch(&className, trace, SS("class"), 0 TSRMLS_CC)) {
ZEPHIR_INIT_VAR(_2);
ZEPHIR_INIT_VAR(_3);
ZEPHIR_SINIT_VAR(_4);
@@ -19305,13 +19519,17 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
object_init_ex(classReflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC));
ZEPHIR_CALL_METHOD(NULL, classReflection, "__construct", NULL, 62, className);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, classReflection, "isinternal", NULL, 154);
+ ZEPHIR_CALL_METHOD(&_8, classReflection, "isinternal", NULL, 155);
zephir_check_call_status();
if (zephir_is_true(_8)) {
ZEPHIR_INIT_VAR(_9);
zephir_fast_strtolower(_9, className);
+ ZEPHIR_SINIT_NVAR(_5);
+ ZVAL_STRING(&_5, "_", 0);
+ ZEPHIR_SINIT_NVAR(_6);
+ ZVAL_STRING(&_6, "-", 0);
ZEPHIR_INIT_VAR(prepareInternalClass);
- zephir_fast_str_replace(&prepareInternalClass, underscore, minus, _9 TSRMLS_CC);
+ zephir_fast_str_replace(&prepareInternalClass, &_5, &_6, _9 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVSVS(_7, "", className, "");
zephir_concat_self(&html, _7 TSRMLS_CC);
@@ -19321,11 +19539,11 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
zephir_concat_self(&html, _10 TSRMLS_CC);
}
}
- zephir_array_fetch_string(&_11, trace, SL("type"), PH_NOISY | PH_READONLY, "phalcon/debug.zep", 395 TSRMLS_CC);
+ zephir_array_fetch_string(&_11, trace, SL("type"), PH_NOISY | PH_READONLY, "phalcon/debug.zep", 385 TSRMLS_CC);
zephir_concat_self(&html, _11 TSRMLS_CC);
}
ZEPHIR_OBS_VAR(functionName);
- zephir_array_fetch_string(&functionName, trace, SL("function"), PH_NOISY, "phalcon/debug.zep", 401 TSRMLS_CC);
+ zephir_array_fetch_string(&functionName, trace, SL("function"), PH_NOISY, "phalcon/debug.zep", 391 TSRMLS_CC);
if (zephir_array_isset_string(trace, SS("class"))) {
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVS(_7, "", functionName, "");
@@ -19334,13 +19552,17 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
if ((zephir_function_exists(functionName TSRMLS_CC) == SUCCESS)) {
ZEPHIR_INIT_VAR(functionReflection);
object_init_ex(functionReflection, zephir_get_internal_ce(SS("reflectionfunction") TSRMLS_CC));
- ZEPHIR_CALL_METHOD(NULL, functionReflection, "__construct", NULL, 155, functionName);
+ ZEPHIR_CALL_METHOD(NULL, functionReflection, "__construct", NULL, 156, functionName);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, functionReflection, "isinternal", NULL, 156);
+ ZEPHIR_CALL_METHOD(&_8, functionReflection, "isinternal", NULL, 157);
zephir_check_call_status();
if (zephir_is_true(_8)) {
+ ZEPHIR_SINIT_NVAR(_4);
+ ZVAL_STRING(&_4, "_", 0);
+ ZEPHIR_SINIT_NVAR(_5);
+ ZVAL_STRING(&_5, "-", 0);
ZEPHIR_INIT_VAR(preparedFunctionName);
- zephir_fast_str_replace(&preparedFunctionName, underscore, minus, functionName TSRMLS_CC);
+ zephir_fast_str_replace(&preparedFunctionName, &_4, &_5, functionName TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_10);
ZEPHIR_CONCAT_SVSVS(_10, "", functionName, "");
zephir_concat_self(&html, _10 TSRMLS_CC);
@@ -19355,13 +19577,12 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
zephir_concat_self(&html, _7 TSRMLS_CC);
}
}
- if (zephir_array_isset_string(trace, SS("args"))) {
- ZEPHIR_OBS_VAR(traceArgs);
- zephir_array_fetch_string(&traceArgs, trace, SL("args"), PH_NOISY, "phalcon/debug.zep", 435 TSRMLS_CC);
+ ZEPHIR_OBS_VAR(traceArgs);
+ if (zephir_array_isset_string_fetch(&traceArgs, trace, SS("args"), 0 TSRMLS_CC)) {
if (zephir_fast_count_int(traceArgs TSRMLS_CC)) {
ZEPHIR_INIT_VAR(arguments);
array_init(arguments);
- zephir_is_iterable(traceArgs, &_13, &_12, 0, 0, "phalcon/debug.zep", 450);
+ zephir_is_iterable(traceArgs, &_13, &_12, 0, 0, "phalcon/debug.zep", 439);
for (
; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS
; zephir_hash_move_forward_ex(_13, &_12)
@@ -19371,7 +19592,7 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVS(_7, "", _8, "");
- zephir_array_append(&arguments, _7, PH_SEPARATE, "phalcon/debug.zep", 444);
+ zephir_array_append(&arguments, _7, PH_SEPARATE, "phalcon/debug.zep", 433);
}
ZEPHIR_INIT_NVAR(_3);
zephir_fast_join_str(_3, SL(", "), arguments TSRMLS_CC);
@@ -19385,7 +19606,7 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
ZEPHIR_OBS_VAR(filez);
if (zephir_array_isset_string_fetch(&filez, trace, SS("file"), 0 TSRMLS_CC)) {
ZEPHIR_OBS_VAR(_16);
- zephir_array_fetch_string(&_16, trace, SL("line"), PH_NOISY, "phalcon/debug.zep", 461 TSRMLS_CC);
+ zephir_array_fetch_string(&_16, trace, SL("line"), PH_NOISY, "phalcon/debug.zep", 450 TSRMLS_CC);
zephir_get_strval(_17, _16);
ZEPHIR_CPY_WRT(line, _17);
ZEPHIR_INIT_LNVAR(_7);
@@ -19394,7 +19615,7 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
ZEPHIR_OBS_VAR(showFiles);
zephir_read_property_this(&showFiles, this_ptr, SL("_showFiles"), PH_NOISY_CC);
if (zephir_is_true(showFiles)) {
- ZEPHIR_CALL_FUNCTION(&lines, "file", NULL, 157, filez);
+ ZEPHIR_CALL_FUNCTION(&lines, "file", NULL, 158, filez);
zephir_check_call_status();
ZEPHIR_INIT_VAR(numberLines);
ZVAL_LONG(numberLines, zephir_fast_count_int(lines TSRMLS_CC));
@@ -19431,16 +19652,6 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
ZEPHIR_CONCAT_SVSVS(_10, "");
zephir_concat_self(&html, _10 TSRMLS_CC);
}
- ZEPHIR_INIT_VAR(commentPattern);
- ZVAL_STRING(commentPattern, "#\\*\\/#", 1);
- ZEPHIR_INIT_VAR(utf8);
- ZVAL_STRING(utf8, "UTF-8", 1);
- ZEPHIR_INIT_VAR(entCompat);
- ZVAL_LONG(entCompat, 2);
- ZEPHIR_INIT_VAR(tab);
- ZVAL_STRING(tab, "\t", 1);
- ZEPHIR_INIT_VAR(comment);
- ZVAL_STRING(comment, "* /", 1);
i = firstLine;
while (1) {
if (!(ZEPHIR_GE_LONG(lastLine, i))) {
@@ -19449,33 +19660,47 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
ZEPHIR_SINIT_NVAR(linePosition);
ZVAL_LONG(&linePosition, (i - 1));
ZEPHIR_OBS_NVAR(currentLine);
- zephir_array_fetch(¤tLine, lines, &linePosition, PH_NOISY, "phalcon/debug.zep", 549 TSRMLS_CC);
+ zephir_array_fetch(¤tLine, lines, &linePosition, PH_NOISY, "phalcon/debug.zep", 523 TSRMLS_CC);
if (zephir_is_true(showFileFragment)) {
if (i == firstLine) {
ZEPHIR_INIT_NVAR(_19);
ZEPHIR_INIT_NVAR(_3);
ZEPHIR_INIT_NVAR(_9);
zephir_fast_trim(_9, currentLine, NULL , ZEPHIR_TRIM_RIGHT TSRMLS_CC);
- zephir_preg_match(_3, commentPattern, _9, _19, 0, 0 , 0 TSRMLS_CC);
+ ZEPHIR_SINIT_NVAR(_20);
+ ZVAL_STRING(&_20, "#\\*\\/#", 0);
+ zephir_preg_match(_3, &_20, _9, _19, 0, 0 , 0 TSRMLS_CC);
if (zephir_is_true(_3)) {
- ZEPHIR_INIT_NVAR(_20);
- zephir_fast_str_replace(&_20, comment, space, currentLine TSRMLS_CC);
- ZEPHIR_CPY_WRT(currentLine, _20);
+ ZEPHIR_INIT_NVAR(_21);
+ ZEPHIR_SINIT_NVAR(_22);
+ ZVAL_STRING(&_22, "* /", 0);
+ ZEPHIR_SINIT_NVAR(_23);
+ ZVAL_STRING(&_23, " ", 0);
+ zephir_fast_str_replace(&_21, &_22, &_23, currentLine TSRMLS_CC);
+ ZEPHIR_CPY_WRT(currentLine, _21);
}
}
}
- if (ZEPHIR_IS_STRING(currentLine, "\n")) {
+ _24 = ZEPHIR_IS_STRING(currentLine, "\n");
+ if (!(_24)) {
+ _24 = ZEPHIR_IS_STRING(currentLine, "\r\n");
+ }
+ if (_24) {
zephir_concat_self_str(&html, SL(" \n") TSRMLS_CC);
} else {
- if (ZEPHIR_IS_STRING(currentLine, "\r\n")) {
- zephir_concat_self_str(&html, SL(" \n") TSRMLS_CC);
- } else {
- ZEPHIR_INIT_NVAR(_20);
- zephir_fast_str_replace(&_20, tab, twoSpaces, currentLine TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_8, "htmlentities", &_21, 150, _20, entCompat, utf8);
- zephir_check_call_status();
- zephir_concat_self(&html, _8 TSRMLS_CC);
- }
+ ZEPHIR_INIT_NVAR(_21);
+ ZEPHIR_SINIT_NVAR(_20);
+ ZVAL_STRING(&_20, "\t", 0);
+ ZEPHIR_SINIT_NVAR(_22);
+ ZVAL_STRING(&_22, " ", 0);
+ zephir_fast_str_replace(&_21, &_20, &_22, currentLine TSRMLS_CC);
+ ZEPHIR_SINIT_NVAR(_23);
+ ZVAL_LONG(&_23, 2);
+ ZEPHIR_SINIT_NVAR(_25);
+ ZVAL_STRING(&_25, "UTF-8", 0);
+ ZEPHIR_CALL_FUNCTION(&_8, "htmlentities", &_26, 151, _21, &_23, &_25);
+ zephir_check_call_status();
+ zephir_concat_self(&html, _8 TSRMLS_CC);
}
i++;
}
@@ -19497,7 +19722,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtLowSeverity) {
- ZEPHIR_CALL_FUNCTION(&_0, "error_reporting", NULL, 158);
+ ZEPHIR_CALL_FUNCTION(&_0, "error_reporting", NULL, 159);
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_1);
zephir_bitwise_and_function(&_1, _0, severity TSRMLS_CC);
@@ -19506,9 +19731,9 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtLowSeverity) {
object_init_ex(_2, zephir_get_internal_ce(SS("errorexception") TSRMLS_CC));
ZEPHIR_INIT_VAR(_3);
ZVAL_LONG(_3, 0);
- ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 159, message, _3, severity, file, line);
+ ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 160, message, _3, severity, file, line);
zephir_check_call_status();
- zephir_throw_exception_debug(_2, "phalcon/debug.zep", 592 TSRMLS_CC);
+ zephir_throw_exception_debug(_2, "phalcon/debug.zep", 566 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -19531,7 +19756,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
- ZEPHIR_CALL_FUNCTION(&obLevel, "ob_get_level", NULL, 160);
+ ZEPHIR_CALL_FUNCTION(&obLevel, "ob_get_level", NULL, 161);
zephir_check_call_status();
if (ZEPHIR_GT_LONG(obLevel, 0)) {
ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118);
@@ -19591,21 +19816,21 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
ZEPHIR_CALL_METHOD(&_9, exception, "gettrace", NULL, 0);
zephir_check_call_status();
- zephir_is_iterable(_9, &_11, &_10, 0, 0, "phalcon/debug.zep", 686);
+ zephir_is_iterable(_9, &_11, &_10, 0, 0, "phalcon/debug.zep", 660);
for (
; zephir_hash_get_current_data_ex(_11, (void**) &_12, &_10) == SUCCESS
; zephir_hash_move_forward_ex(_11, &_10)
) {
ZEPHIR_GET_HMKEY(n, _11, _10);
ZEPHIR_GET_HVALUE(traceItem, _12);
- ZEPHIR_CALL_METHOD(&_13, this_ptr, "showtraceitem", &_14, 161, n, traceItem);
+ ZEPHIR_CALL_METHOD(&_13, this_ptr, "showtraceitem", &_14, 162, n, traceItem);
zephir_check_call_status();
zephir_concat_self(&html, _13 TSRMLS_CC);
}
zephir_concat_self_str(&html, SL(" ") TSRMLS_CC);
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
zephir_concat_self_str(&html, SL("Key | Value | ") TSRMLS_CC);
- zephir_is_iterable(_REQUEST, &_16, &_15, 0, 0, "phalcon/debug.zep", 700);
+ zephir_is_iterable(_REQUEST, &_16, &_15, 0, 0, "phalcon/debug.zep", 674);
for (
; zephir_hash_get_current_data_ex(_16, (void**) &_17, &_15) == SUCCESS
; zephir_hash_move_forward_ex(_16, &_15)
@@ -19617,7 +19842,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
ZEPHIR_CONCAT_SVSVS(_18, "", keyRequest, " | ", value, " | ");
zephir_concat_self(&html, _18 TSRMLS_CC);
} else {
- ZEPHIR_CALL_FUNCTION(&_13, "print_r", &_19, 162, value, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(&_13, "print_r", &_19, 163, value, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_18);
ZEPHIR_CONCAT_SVSVS(_18, "", keyRequest, " | ", _13, " | ");
@@ -19627,7 +19852,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
zephir_concat_self_str(&html, SL(" ") TSRMLS_CC);
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
zephir_concat_self_str(&html, SL("Key | Value | ") TSRMLS_CC);
- zephir_is_iterable(_SERVER, &_21, &_20, 0, 0, "phalcon/debug.zep", 710);
+ zephir_is_iterable(_SERVER, &_21, &_20, 0, 0, "phalcon/debug.zep", 684);
for (
; zephir_hash_get_current_data_ex(_21, (void**) &_22, &_20) == SUCCESS
; zephir_hash_move_forward_ex(_21, &_20)
@@ -19643,9 +19868,9 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
zephir_concat_self_str(&html, SL(" ") TSRMLS_CC);
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
zephir_concat_self_str(&html, SL("# | Path | ") TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_13, "get_included_files", NULL, 163);
+ ZEPHIR_CALL_FUNCTION(&_13, "get_included_files", NULL, 164);
zephir_check_call_status();
- zephir_is_iterable(_13, &_25, &_24, 0, 0, "phalcon/debug.zep", 720);
+ zephir_is_iterable(_13, &_25, &_24, 0, 0, "phalcon/debug.zep", 694);
for (
; zephir_hash_get_current_data_ex(_25, (void**) &_26, &_24) == SUCCESS
; zephir_hash_move_forward_ex(_25, &_24)
@@ -19658,7 +19883,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
}
zephir_concat_self_str(&html, SL(" ") TSRMLS_CC);
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_13, "memory_get_usage", NULL, 164, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(&_13, "memory_get_usage", NULL, 165, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_27);
ZEPHIR_CONCAT_SVS(_27, "Memory |
---|
Usage | ", _13, " | ");
@@ -19667,14 +19892,14 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
if (Z_TYPE_P(dataVars) == IS_ARRAY) {
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
zephir_concat_self_str(&html, SL("Key | Value | ") TSRMLS_CC);
- zephir_is_iterable(dataVars, &_29, &_28, 0, 0, "phalcon/debug.zep", 738);
+ zephir_is_iterable(dataVars, &_29, &_28, 0, 0, "phalcon/debug.zep", 712);
for (
; zephir_hash_get_current_data_ex(_29, (void**) &_30, &_28) == SUCCESS
; zephir_hash_move_forward_ex(_29, &_28)
) {
ZEPHIR_GET_HMKEY(keyVar, _29, _28);
ZEPHIR_GET_HVALUE(dataVar, _30);
- zephir_array_fetch_long(&_32, dataVar, 0, PH_NOISY | PH_READONLY, "phalcon/debug.zep", 736 TSRMLS_CC);
+ zephir_array_fetch_long(&_32, dataVar, 0, PH_NOISY | PH_READONLY, "phalcon/debug.zep", 710 TSRMLS_CC);
ZEPHIR_CALL_METHOD(&_31, this_ptr, "_getvardump", &_23, 0, _32);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_33);
@@ -19835,7 +20060,7 @@ static PHP_METHOD(Phalcon_Di, setShared) {
static PHP_METHOD(Phalcon_Di, remove) {
- zval *name_param = NULL, *_0;
+ zval *name_param = NULL, *_0, *_1;
zval *name = NULL;
ZEPHIR_MM_GROW();
@@ -19856,6 +20081,8 @@ static PHP_METHOD(Phalcon_Di, remove) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_services"), PH_NOISY_CC);
zephir_array_unset(&_0, name, PH_SEPARATE);
+ _1 = zephir_fetch_nproperty_this(this_ptr, SL("_sharedInstances"), PH_NOISY_CC);
+ zephir_array_unset(&_1, name, PH_SEPARATE);
ZEPHIR_MM_RESTORE();
}
@@ -19963,7 +20190,7 @@ static PHP_METHOD(Phalcon_Di, getRaw) {
ZEPHIR_CONCAT_SVS(_2, "Service '", name, "' wasn't found in the dependency injection container");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/di.zep", 187 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/di.zep", 189 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -20002,7 +20229,7 @@ static PHP_METHOD(Phalcon_Di, getService) {
ZEPHIR_CONCAT_SVS(_2, "Service '", name, "' wasn't found in the dependency injection container");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/di.zep", 201 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/di.zep", 203 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -20060,7 +20287,7 @@ static PHP_METHOD(Phalcon_Di, get) {
ZEPHIR_CONCAT_SVS(_3, "Service '", name, "' wasn't found in the dependency injection container");
ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_2, "phalcon/di.zep", 227 TSRMLS_CC);
+ zephir_throw_exception_debug(_2, "phalcon/di.zep", 229 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -20383,7 +20610,7 @@ static PHP_METHOD(Phalcon_Di, __call) {
ZEPHIR_CONCAT_SVS(_5, "Call to undefined method or service '", method, "'");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _5);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/di.zep", 425 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/di.zep", 427 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -21419,13 +21646,13 @@ static PHP_METHOD(Phalcon_Escaper, detectEncoding) {
; zephir_hash_move_forward_ex(_3, &_2)
) {
ZEPHIR_GET_HVALUE(charset, _4);
- ZEPHIR_CALL_FUNCTION(&_5, "mb_detect_encoding", &_6, 177, str, charset, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(&_5, "mb_detect_encoding", &_6, 178, str, charset, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
if (zephir_is_true(_5)) {
RETURN_CCTOR(charset);
}
}
- ZEPHIR_RETURN_CALL_FUNCTION("mb_detect_encoding", &_6, 177, str);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_detect_encoding", &_6, 178, str);
zephir_check_call_status();
RETURN_MM();
@@ -21447,11 +21674,11 @@ static PHP_METHOD(Phalcon_Escaper, normalizeEncoding) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_escaper_exception_ce, "Extension 'mbstring' is required", "phalcon/escaper.zep", 128);
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "detectencoding", NULL, 178, str);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "detectencoding", NULL, 179, str);
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "UTF-32", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 179, str, &_1, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 180, str, &_1, _0);
zephir_check_call_status();
RETURN_MM();
@@ -21471,7 +21698,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeHtml) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_htmlQuoteType"), PH_NOISY_CC);
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_encoding"), PH_NOISY_CC);
- ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 180, text, _0, _1);
+ ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 181, text, _0, _1);
zephir_check_call_status();
RETURN_MM();
@@ -21492,7 +21719,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeHtmlAttr) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_encoding"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, 3);
- ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 180, attribute, &_1, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 181, attribute, &_1, _0);
zephir_check_call_status();
RETURN_MM();
@@ -21510,7 +21737,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeCss) {
zephir_get_strval(css, css_param);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 181, css);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 182, css);
zephir_check_call_status();
zephir_escape_css(return_value, _0);
RETURN_MM();
@@ -21529,7 +21756,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeJs) {
zephir_get_strval(js, js_param);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 181, js);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 182, js);
zephir_check_call_status();
zephir_escape_js(return_value, _0);
RETURN_MM();
@@ -21548,7 +21775,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeUrl) {
zephir_get_strval(url, url_param);
- ZEPHIR_RETURN_CALL_FUNCTION("rawurlencode", NULL, 182, url);
+ ZEPHIR_RETURN_CALL_FUNCTION("rawurlencode", NULL, 183, url);
zephir_check_call_status();
RETURN_MM();
@@ -21827,16 +22054,16 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) {
if (ZEPHIR_IS_STRING(filter, "email")) {
ZEPHIR_SINIT_VAR(_3);
ZVAL_STRING(&_3, "FILTER_SANITIZE_EMAIL", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 189, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 190, &_3);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 190, value, _4);
+ ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, _4);
zephir_check_call_status();
RETURN_MM();
}
if (ZEPHIR_IS_STRING(filter, "int")) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 519);
- ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 190, value, &_3);
+ ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3);
zephir_check_call_status();
RETURN_MM();
}
@@ -21846,14 +22073,14 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) {
if (ZEPHIR_IS_STRING(filter, "absint")) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, zephir_get_intval(value));
- ZEPHIR_RETURN_CALL_FUNCTION("abs", NULL, 191, &_3);
+ ZEPHIR_RETURN_CALL_FUNCTION("abs", NULL, 192, &_3);
zephir_check_call_status();
RETURN_MM();
}
if (ZEPHIR_IS_STRING(filter, "string")) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 513);
- ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 190, value, &_3);
+ ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3);
zephir_check_call_status();
RETURN_MM();
}
@@ -21863,7 +22090,7 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) {
add_assoc_long_ex(_2, SS("flags"), 4096);
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 520);
- ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 190, value, &_3, _2);
+ ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3, _2);
zephir_check_call_status();
RETURN_MM();
}
@@ -21886,13 +22113,13 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) {
RETURN_MM();
}
if (ZEPHIR_IS_STRING(filter, "striptags")) {
- ZEPHIR_RETURN_CALL_FUNCTION("strip_tags", NULL, 192, value);
+ ZEPHIR_RETURN_CALL_FUNCTION("strip_tags", NULL, 193, value);
zephir_check_call_status();
RETURN_MM();
}
if (ZEPHIR_IS_STRING(filter, "lower")) {
if ((zephir_function_exists_ex(SS("mb_strtolower") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 193, value);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 194, value);
zephir_check_call_status();
RETURN_MM();
}
@@ -21901,7 +22128,7 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) {
}
if (ZEPHIR_IS_STRING(filter, "upper")) {
if ((zephir_function_exists_ex(SS("mb_strtoupper") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 194, value);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 195, value);
zephir_check_call_status();
RETURN_MM();
}
@@ -22682,7 +22909,7 @@ static PHP_METHOD(Phalcon_Loader, register) {
ZEPHIR_INIT_VAR(_2);
ZVAL_STRING(_2, "autoLoad", 1);
zephir_array_fast_append(_1, _2);
- ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_register", NULL, 292, _1);
+ ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_register", NULL, 293, _1);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_registered"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
}
@@ -22706,7 +22933,7 @@ static PHP_METHOD(Phalcon_Loader, unregister) {
ZEPHIR_INIT_VAR(_2);
ZVAL_STRING(_2, "autoLoad", 1);
zephir_array_fast_append(_1, _2);
- ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_unregister", NULL, 293, _1);
+ ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_unregister", NULL, 294, _1);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_registered"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
}
@@ -22814,7 +23041,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) {
zephir_check_temp_parameter(_9);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 294, filePath);
+ ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath);
zephir_check_call_status();
if (zephir_is_true(_11)) {
if (Z_TYPE_P(eventsManager) == IS_OBJECT) {
@@ -22885,7 +23112,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) {
zephir_check_temp_parameter(_9);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 294, filePath);
+ ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath);
zephir_check_call_status();
if (zephir_is_true(_11)) {
if (Z_TYPE_P(eventsManager) == IS_OBJECT) {
@@ -22943,7 +23170,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) {
zephir_check_temp_parameter(_9);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 294, filePath);
+ ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath);
zephir_check_call_status();
if (zephir_is_true(_11)) {
if (Z_TYPE_P(eventsManager) == IS_OBJECT) {
@@ -23196,7 +23423,7 @@ static PHP_METHOD(Phalcon_Registry, next) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_CALL_FUNCTION(NULL, "next", NULL, 397, _0);
+ ZEPHIR_CALL_FUNCTION(NULL, "next", NULL, 399, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -23212,7 +23439,7 @@ static PHP_METHOD(Phalcon_Registry, key) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_RETURN_CALL_FUNCTION("key", NULL, 398, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("key", NULL, 400, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
RETURN_MM();
@@ -23228,7 +23455,7 @@ static PHP_METHOD(Phalcon_Registry, rewind) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_CALL_FUNCTION(NULL, "reset", NULL, 399, _0);
+ ZEPHIR_CALL_FUNCTION(NULL, "reset", NULL, 401, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -23244,7 +23471,7 @@ static PHP_METHOD(Phalcon_Registry, valid) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_CALL_FUNCTION(&_1, "key", NULL, 398, _0);
+ ZEPHIR_CALL_FUNCTION(&_1, "key", NULL, 400, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
RETURN_MM_BOOL(Z_TYPE_P(_1) != IS_NULL);
@@ -23260,7 +23487,7 @@ static PHP_METHOD(Phalcon_Registry, current) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_RETURN_CALL_FUNCTION("current", NULL, 400, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("current", NULL, 402, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
RETURN_MM();
@@ -23289,7 +23516,7 @@ static PHP_METHOD(Phalcon_Registry, __set) {
}
- ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetset", NULL, 401, key, value);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetset", NULL, 403, key, value);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -23317,7 +23544,7 @@ static PHP_METHOD(Phalcon_Registry, __get) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetget", NULL, 402, key);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetget", NULL, 404, key);
zephir_check_call_status();
RETURN_MM();
@@ -23345,7 +23572,7 @@ static PHP_METHOD(Phalcon_Registry, __isset) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetexists", NULL, 403, key);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetexists", NULL, 405, key);
zephir_check_call_status();
RETURN_MM();
@@ -23373,7 +23600,7 @@ static PHP_METHOD(Phalcon_Registry, __unset) {
}
- ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetunset", NULL, 404, key);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetunset", NULL, 406, key);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -23529,7 +23756,7 @@ static PHP_METHOD(Phalcon_Security, getSaltBytes) {
ZEPHIR_INIT_NVAR(safeBytes);
ZEPHIR_INIT_NVAR(_1);
ZVAL_LONG(_1, numberBytes);
- ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", &_3, 405, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", &_3, 407, _1);
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&_4, "base64_encode", &_5, 112, _2);
zephir_check_call_status();
@@ -23621,7 +23848,7 @@ static PHP_METHOD(Phalcon_Security, hash) {
}
ZEPHIR_INIT_VAR(_3);
ZEPHIR_CONCAT_SVSV(_3, "$", variant, "$", saltBytes);
- ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 406, password, _3);
+ ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 408, password, _3);
zephir_check_call_status();
RETURN_MM();
}
@@ -23644,11 +23871,11 @@ static PHP_METHOD(Phalcon_Security, hash) {
ZVAL_STRING(&_5, "%02s", 0);
ZEPHIR_SINIT_VAR(_6);
ZVAL_LONG(&_6, workFactor);
- ZEPHIR_CALL_FUNCTION(&_7, "sprintf", NULL, 186, &_5, &_6);
+ ZEPHIR_CALL_FUNCTION(&_7, "sprintf", NULL, 187, &_5, &_6);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_3);
ZEPHIR_CONCAT_SVSVSV(_3, "$2", variant, "$", _7, "$", saltBytes);
- ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 406, password, _3);
+ ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 408, password, _3);
zephir_check_call_status();
RETURN_MM();
} while(0);
@@ -23688,7 +23915,7 @@ static PHP_METHOD(Phalcon_Security, checkHash) {
RETURN_MM_BOOL(0);
}
}
- ZEPHIR_CALL_FUNCTION(&_1, "crypt", NULL, 406, password, passwordHash);
+ ZEPHIR_CALL_FUNCTION(&_1, "crypt", NULL, 408, password, passwordHash);
zephir_check_call_status();
zephir_get_strval(_2, _1);
ZEPHIR_CPY_WRT(cryptedHash, _2);
@@ -23752,7 +23979,7 @@ static PHP_METHOD(Phalcon_Security, getTokenKey) {
ZEPHIR_INIT_VAR(safeBytes);
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, numberBytes);
- ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", NULL, 405, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", NULL, 407, _1);
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&_3, "base64_encode", NULL, 112, _2);
zephir_check_call_status();
@@ -23794,7 +24021,7 @@ static PHP_METHOD(Phalcon_Security, getToken) {
}
ZEPHIR_INIT_VAR(_0);
ZVAL_LONG(_0, numberBytes);
- ZEPHIR_CALL_FUNCTION(&token, "openssl_random_pseudo_bytes", NULL, 405, _0);
+ ZEPHIR_CALL_FUNCTION(&token, "openssl_random_pseudo_bytes", NULL, 407, _0);
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&_1, "base64_encode", NULL, 112, token);
zephir_check_call_status();
@@ -23967,7 +24194,7 @@ static PHP_METHOD(Phalcon_Security, computeHmac) {
}
- ZEPHIR_CALL_FUNCTION(&hmac, "hash_hmac", NULL, 407, algo, data, key, (raw ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_FUNCTION(&hmac, "hash_hmac", NULL, 409, algo, data, key, (raw ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
if (!(zephir_is_true(hmac))) {
ZEPHIR_INIT_VAR(_0);
@@ -24758,7 +24985,7 @@ static PHP_METHOD(Phalcon_Tag, colorField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "color", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24778,7 +25005,7 @@ static PHP_METHOD(Phalcon_Tag, textField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "text", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24798,7 +25025,7 @@ static PHP_METHOD(Phalcon_Tag, numericField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "number", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24818,7 +25045,7 @@ static PHP_METHOD(Phalcon_Tag, rangeField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "range", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24838,7 +25065,7 @@ static PHP_METHOD(Phalcon_Tag, emailField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "email", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24858,7 +25085,7 @@ static PHP_METHOD(Phalcon_Tag, dateField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "date", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24878,7 +25105,7 @@ static PHP_METHOD(Phalcon_Tag, dateTimeField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "datetime", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24898,7 +25125,7 @@ static PHP_METHOD(Phalcon_Tag, dateTimeLocalField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "datetime-local", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24918,7 +25145,7 @@ static PHP_METHOD(Phalcon_Tag, monthField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "month", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24938,7 +25165,7 @@ static PHP_METHOD(Phalcon_Tag, timeField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "time", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24958,7 +25185,7 @@ static PHP_METHOD(Phalcon_Tag, weekField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "week", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24978,7 +25205,7 @@ static PHP_METHOD(Phalcon_Tag, passwordField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "password", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24998,7 +25225,7 @@ static PHP_METHOD(Phalcon_Tag, hiddenField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "hidden", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25018,7 +25245,7 @@ static PHP_METHOD(Phalcon_Tag, fileField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "file", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25038,7 +25265,7 @@ static PHP_METHOD(Phalcon_Tag, searchField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "search", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25058,7 +25285,7 @@ static PHP_METHOD(Phalcon_Tag, telField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "tel", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25078,7 +25305,7 @@ static PHP_METHOD(Phalcon_Tag, urlField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "url", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25098,7 +25325,7 @@ static PHP_METHOD(Phalcon_Tag, checkField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "checkbox", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 412, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 414, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25118,7 +25345,7 @@ static PHP_METHOD(Phalcon_Tag, radioField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "radio", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 412, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 414, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25140,7 +25367,7 @@ static PHP_METHOD(Phalcon_Tag, imageInput) {
ZVAL_STRING(_1, "image", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_2);
ZVAL_BOOL(_2, 1);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters, _2);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters, _2);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25162,7 +25389,7 @@ static PHP_METHOD(Phalcon_Tag, submitButton) {
ZVAL_STRING(_1, "submit", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_2);
ZVAL_BOOL(_2, 1);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters, _2);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters, _2);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25183,7 +25410,7 @@ static PHP_METHOD(Phalcon_Tag, selectStatic) {
}
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 205, parameters, data);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, parameters, data);
zephir_check_call_status();
RETURN_MM();
@@ -25203,7 +25430,7 @@ static PHP_METHOD(Phalcon_Tag, select) {
}
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 205, parameters, data);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, parameters, data);
zephir_check_call_status();
RETURN_MM();
@@ -25714,13 +25941,13 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_VAR(_3);
ZVAL_STRING(&_3, "en_US.UTF-8", 0);
- ZEPHIR_CALL_FUNCTION(&locale, "setlocale", &_4, 413, &_0, &_3);
+ ZEPHIR_CALL_FUNCTION(&locale, "setlocale", &_4, 415, &_0, &_3);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "UTF-8", 0);
ZEPHIR_SINIT_NVAR(_3);
ZVAL_STRING(&_3, "ASCII//TRANSLIT", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "iconv", NULL, 376, &_0, &_3, text);
+ ZEPHIR_CALL_FUNCTION(&_5, "iconv", NULL, 378, &_0, &_3, text);
zephir_check_call_status();
zephir_get_strval(text, _5);
}
@@ -25783,7 +26010,7 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) {
if (zephir_is_true(_5)) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 0);
- ZEPHIR_CALL_FUNCTION(NULL, "setlocale", &_4, 413, &_3, locale);
+ ZEPHIR_CALL_FUNCTION(NULL, "setlocale", &_4, 415, &_3, locale);
zephir_check_call_status();
}
RETURN_CCTOR(friendly);
@@ -26090,24 +26317,21 @@ static PHP_METHOD(Phalcon_Text, uncamelize) {
static PHP_METHOD(Phalcon_Text, increment) {
- zval *str_param = NULL, *separator = NULL, *parts, *number = NULL, *_0;
- zval *str = NULL;
+ zval *str_param = NULL, *separator_param = NULL, *parts, *number = NULL, *_0;
+ zval *str = NULL, *separator = NULL;
ZEPHIR_MM_GROW();
- zephir_fetch_params(1, 1, 1, &str_param, &separator);
+ zephir_fetch_params(1, 1, 1, &str_param, &separator_param);
zephir_get_strval(str, str_param);
- if (!separator) {
- ZEPHIR_CPY_WRT(separator, ZEPHIR_GLOBAL(global_null));
+ if (!separator_param) {
+ ZEPHIR_INIT_VAR(separator);
+ ZVAL_STRING(separator, "_", 1);
} else {
- ZEPHIR_SEPARATE_PARAM(separator);
+ zephir_get_strval(separator, separator_param);
}
- if (Z_TYPE_P(separator) == IS_NULL) {
- ZEPHIR_INIT_NVAR(separator);
- ZVAL_STRING(separator, "_", 1);
- }
ZEPHIR_INIT_VAR(parts);
zephir_fast_explode(parts, separator, str, LONG_MAX TSRMLS_CC);
ZEPHIR_OBS_VAR(number);
@@ -26118,7 +26342,7 @@ static PHP_METHOD(Phalcon_Text, increment) {
ZEPHIR_INIT_NVAR(number);
ZVAL_LONG(number, 1);
}
- zephir_array_fetch_long(&_0, parts, 0, PH_NOISY | PH_READONLY, "phalcon/text.zep", 88 TSRMLS_CC);
+ zephir_array_fetch_long(&_0, parts, 0, PH_NOISY | PH_READONLY, "phalcon/text.zep", 84 TSRMLS_CC);
ZEPHIR_CONCAT_VVV(return_value, _0, separator, number);
RETURN_MM();
@@ -26154,13 +26378,13 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_STRING(&_0, "a", 0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "z", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "A", 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "Z", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_INIT_VAR(pool);
zephir_fast_array_merge(pool, &(_2), &(_4) TSRMLS_CC);
@@ -26171,13 +26395,13 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 9);
- ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "a", 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "f", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(pool);
zephir_fast_array_merge(pool, &(_2), &(_4) TSRMLS_CC);
@@ -26188,7 +26412,7 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 9);
- ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
break;
}
@@ -26197,7 +26421,7 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 1);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 9);
- ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
break;
}
@@ -26205,21 +26429,21 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 9);
- ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "a", 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "z", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "A", 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "Z", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_5, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&pool, "array_merge", &_6, 417, _2, _4, _5);
+ ZEPHIR_CALL_FUNCTION(&pool, "array_merge", &_6, 419, _2, _4, _5);
zephir_check_call_status();
break;
} while(0);
@@ -26233,7 +26457,7 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, end);
- zephir_array_fetch_long(&_7, pool, zephir_mt_rand(zephir_get_intval(&_0), zephir_get_intval(&_1) TSRMLS_CC), PH_NOISY | PH_READONLY, "phalcon/text.zep", 130 TSRMLS_CC);
+ zephir_array_fetch_long(&_7, pool, zephir_mt_rand(zephir_get_intval(&_0), zephir_get_intval(&_1) TSRMLS_CC), PH_NOISY | PH_READONLY, "phalcon/text.zep", 126 TSRMLS_CC);
zephir_concat_self(&str, _7 TSRMLS_CC);
}
RETURN_CCTOR(str);
@@ -26323,7 +26547,7 @@ static PHP_METHOD(Phalcon_Text, lower) {
if ((zephir_function_exists_ex(SS("mb_strtolower") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 193, str, encoding);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 194, str, encoding);
zephir_check_call_status();
RETURN_MM();
}
@@ -26371,7 +26595,7 @@ static PHP_METHOD(Phalcon_Text, upper) {
if ((zephir_function_exists_ex(SS("mb_strtoupper") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 194, str, encoding);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 195, str, encoding);
zephir_check_call_status();
RETURN_MM();
}
@@ -26416,26 +26640,26 @@ static PHP_METHOD(Phalcon_Text, concat) {
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, 0);
- ZEPHIR_CALL_FUNCTION(&separator, "func_get_arg", &_1, 418, &_0);
+ ZEPHIR_CALL_FUNCTION(&separator, "func_get_arg", &_1, 420, &_0);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, 1);
- ZEPHIR_CALL_FUNCTION(&a, "func_get_arg", &_1, 418, &_0);
+ ZEPHIR_CALL_FUNCTION(&a, "func_get_arg", &_1, 420, &_0);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, 2);
- ZEPHIR_CALL_FUNCTION(&b, "func_get_arg", &_1, 418, &_0);
+ ZEPHIR_CALL_FUNCTION(&b, "func_get_arg", &_1, 420, &_0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_2, "func_num_args", NULL, 419);
+ ZEPHIR_CALL_FUNCTION(&_2, "func_num_args", NULL, 421);
zephir_check_call_status();
if (ZEPHIR_GT_LONG(_2, 3)) {
- ZEPHIR_CALL_FUNCTION(&_3, "func_get_args", NULL, 165);
+ ZEPHIR_CALL_FUNCTION(&_3, "func_get_args", NULL, 166);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, 3);
- ZEPHIR_CALL_FUNCTION(&_4, "array_slice", NULL, 377, _3, &_0);
+ ZEPHIR_CALL_FUNCTION(&_4, "array_slice", NULL, 379, _3, &_0);
zephir_check_call_status();
- zephir_is_iterable(_4, &_6, &_5, 0, 0, "phalcon/text.zep", 246);
+ zephir_is_iterable(_4, &_6, &_5, 0, 0, "phalcon/text.zep", 242);
for (
; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS
; zephir_hash_move_forward_ex(_6, &_5)
@@ -26530,36 +26754,36 @@ static PHP_METHOD(Phalcon_Text, dynamic) {
}
- ZEPHIR_CALL_FUNCTION(&_0, "substr_count", &_1, 420, text, leftDelimiter);
+ ZEPHIR_CALL_FUNCTION(&_0, "substr_count", &_1, 422, text, leftDelimiter);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_2, "substr_count", &_1, 420, text, rightDelimiter);
+ ZEPHIR_CALL_FUNCTION(&_2, "substr_count", &_1, 422, text, rightDelimiter);
zephir_check_call_status();
if (!ZEPHIR_IS_IDENTICAL(_0, _2)) {
ZEPHIR_INIT_VAR(_3);
object_init_ex(_3, spl_ce_RuntimeException);
ZEPHIR_INIT_VAR(_4);
ZEPHIR_CONCAT_SVS(_4, "Syntax error in string \"", text, "\"");
- ZEPHIR_CALL_METHOD(NULL, _3, "__construct", NULL, 421, _4);
+ ZEPHIR_CALL_METHOD(NULL, _3, "__construct", NULL, 423, _4);
zephir_check_call_status();
- zephir_throw_exception_debug(_3, "phalcon/text.zep", 265 TSRMLS_CC);
+ zephir_throw_exception_debug(_3, "phalcon/text.zep", 261 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_CALL_FUNCTION(&ld_s, "preg_quote", &_5, 422, leftDelimiter);
+ ZEPHIR_CALL_FUNCTION(&ld_s, "preg_quote", &_5, 424, leftDelimiter);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&rd_s, "preg_quote", &_5, 422, rightDelimiter);
+ ZEPHIR_CALL_FUNCTION(&rd_s, "preg_quote", &_5, 424, rightDelimiter);
zephir_check_call_status();
ZEPHIR_INIT_VAR(pattern);
ZEPHIR_CONCAT_SVSVVSVS(pattern, "/", ld_s, "([^", ld_s, rd_s, "]+)", rd_s, "/");
ZEPHIR_CPY_WRT(result, text);
while (1) {
- if (!(zephir_memnstr(result, leftDelimiter, "phalcon/text.zep", 273))) {
+ if (!(zephir_memnstr(result, leftDelimiter, "phalcon/text.zep", 269))) {
break;
}
ZEPHIR_INIT_NVAR(_3);
ZEPHIR_INIT_NVAR(_3);
zephir_create_closure_ex(_3, NULL, phalcon_0__closure_ce, SS("__invoke") TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_6, "preg_replace_callback", &_7, 423, pattern, _3, result);
+ ZEPHIR_CALL_FUNCTION(&_6, "preg_replace_callback", &_7, 425, pattern, _3, result);
zephir_check_call_status();
ZEPHIR_CPY_WRT(result, _6);
}
@@ -27223,7 +27447,7 @@ static PHP_METHOD(Phalcon_Version, _getVersion) {
ZVAL_LONG(_0, 0);
zephir_array_fast_append(return_value, _0);
ZEPHIR_INIT_NVAR(_0);
- ZVAL_LONG(_0, 5);
+ ZVAL_LONG(_0, 6);
zephir_array_fast_append(return_value, _0);
ZEPHIR_INIT_NVAR(_0);
ZVAL_LONG(_0, 4);
@@ -27292,7 +27516,7 @@ static PHP_METHOD(Phalcon_Version, get) {
zephir_array_fetch_long(&specialNumber, version, 4, PH_NOISY, "phalcon/version.zep", 128 TSRMLS_CC);
ZEPHIR_INIT_VAR(result);
ZEPHIR_CONCAT_VSVSVS(result, major, ".", medium, ".", minor, " ");
- ZEPHIR_CALL_STATIC(&suffix, "_getspecial", &_0, 437, special);
+ ZEPHIR_CALL_STATIC(&suffix, "_getspecial", &_0, 441, special);
zephir_check_call_status();
if (!ZEPHIR_IS_STRING(suffix, "")) {
ZEPHIR_INIT_VAR(_1);
@@ -27326,11 +27550,11 @@ static PHP_METHOD(Phalcon_Version, getId) {
zephir_array_fetch_long(&specialNumber, version, 4, PH_NOISY, "phalcon/version.zep", 158 TSRMLS_CC);
ZEPHIR_SINIT_VAR(_0);
ZVAL_STRING(&_0, "%02s", 0);
- ZEPHIR_CALL_FUNCTION(&_1, "sprintf", &_2, 186, &_0, medium);
+ ZEPHIR_CALL_FUNCTION(&_1, "sprintf", &_2, 187, &_0, medium);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "%02s", 0);
- ZEPHIR_CALL_FUNCTION(&_3, "sprintf", &_2, 186, &_0, minor);
+ ZEPHIR_CALL_FUNCTION(&_3, "sprintf", &_2, 187, &_0, minor);
zephir_check_call_status();
ZEPHIR_CONCAT_VVVVV(return_value, major, _1, _3, special, specialNumber);
RETURN_MM();
@@ -27359,7 +27583,7 @@ static PHP_METHOD(Phalcon_Version, getPart) {
}
if (part == 3) {
zephir_array_fetch_long(&_1, version, 3, PH_NOISY | PH_READONLY, "phalcon/version.zep", 187 TSRMLS_CC);
- ZEPHIR_CALL_STATIC(&result, "_getspecial", &_0, 437, _1);
+ ZEPHIR_CALL_STATIC(&result, "_getspecial", &_0, 441, _1);
zephir_check_call_status();
break;
}
@@ -36858,7 +37082,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Libmemcached, save) {
int ZEPHIR_LAST_CALL_STATUS;
zend_bool stopBuffer;
- zval *keyName = NULL, *content = NULL, *lifetime = NULL, *stopBuffer_param = NULL, *lastKey = NULL, *frontend, *memcache = NULL, *cachedContent = NULL, *preparedContent = NULL, *tmp, *tt1 = NULL, *success = NULL, *options, *specialKey, *keys = NULL, *isBuffering = NULL, *_0;
+ zval *keyName = NULL, *content = NULL, *lifetime = NULL, *stopBuffer_param = NULL, *lastKey = NULL, *frontend, *memcache = NULL, *cachedContent = NULL, *preparedContent = NULL, *tmp, *tt1 = NULL, *success = NULL, *options, *specialKey, *keys = NULL, *isBuffering = NULL, *_0, *_1, *_2 = NULL, *_3;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 0, 4, &keyName, &content, &lifetime, &stopBuffer_param);
@@ -36931,7 +37155,16 @@ static PHP_METHOD(Phalcon_Cache_Backend_Libmemcached, save) {
zephir_check_call_status();
}
if (!(zephir_is_true(success))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "Failed storing data in memcached", "phalcon/cache/backend/libmemcached.zep", 223);
+ ZEPHIR_INIT_VAR(_1);
+ object_init_ex(_1, phalcon_cache_exception_ce);
+ ZEPHIR_CALL_METHOD(&_2, memcache, "getresultcode", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_INIT_VAR(_3);
+ ZEPHIR_CONCAT_SV(_3, "Failed storing data in memcached, error code: ", _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3);
+ zephir_check_call_status();
+ zephir_throw_exception_debug(_1, "phalcon/cache/backend/libmemcached.zep", 223 TSRMLS_CC);
+ ZEPHIR_MM_RESTORE();
return;
}
ZEPHIR_OBS_VAR(options);
@@ -43122,7 +43355,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, fetchAll) {
if (!(zephir_is_true(row))) {
break;
}
- zephir_array_append(&results, row, PH_SEPARATE, "phalcon/db/adapter.zep", 249);
+ zephir_array_append(&results, row, PH_SEPARATE, "phalcon/db/adapter.zep", 243);
}
}
RETURN_CCTOR(results);
@@ -43192,7 +43425,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, insert) {
ZEPHIR_CONCAT_SVS(_1, "Unable to insert into ", table, " without data");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _1);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/db/adapter.zep", 317 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/db/adapter.zep", 312 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -43202,7 +43435,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, insert) {
array_init(insertValues);
ZEPHIR_INIT_VAR(bindDataTypes);
array_init(bindDataTypes);
- zephir_is_iterable(values, &_3, &_2, 0, 0, "phalcon/db/adapter.zep", 347);
+ zephir_is_iterable(values, &_3, &_2, 0, 0, "phalcon/db/adapter.zep", 342);
for (
; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS
; zephir_hash_move_forward_ex(_3, &_2)
@@ -43211,24 +43444,24 @@ static PHP_METHOD(Phalcon_Db_Adapter, insert) {
ZEPHIR_GET_HVALUE(value, _4);
if (Z_TYPE_P(value) == IS_OBJECT) {
zephir_get_strval(_5, value);
- zephir_array_append(&placeholders, _5, PH_SEPARATE, "phalcon/db/adapter.zep", 330);
+ zephir_array_append(&placeholders, _5, PH_SEPARATE, "phalcon/db/adapter.zep", 325);
} else {
if (Z_TYPE_P(value) == IS_NULL) {
ZEPHIR_INIT_NVAR(_0);
ZVAL_STRING(_0, "null", 1);
- zephir_array_append(&placeholders, _0, PH_SEPARATE, "phalcon/db/adapter.zep", 333);
+ zephir_array_append(&placeholders, _0, PH_SEPARATE, "phalcon/db/adapter.zep", 328);
} else {
ZEPHIR_INIT_NVAR(_0);
ZVAL_STRING(_0, "?", 1);
- zephir_array_append(&placeholders, _0, PH_SEPARATE, "phalcon/db/adapter.zep", 335);
- zephir_array_append(&insertValues, value, PH_SEPARATE, "phalcon/db/adapter.zep", 336);
+ zephir_array_append(&placeholders, _0, PH_SEPARATE, "phalcon/db/adapter.zep", 330);
+ zephir_array_append(&insertValues, value, PH_SEPARATE, "phalcon/db/adapter.zep", 331);
if (Z_TYPE_P(dataTypes) == IS_ARRAY) {
ZEPHIR_OBS_NVAR(bindType);
if (!(zephir_array_isset_fetch(&bindType, dataTypes, position, 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Incomplete number of bind types", "phalcon/db/adapter.zep", 339);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Incomplete number of bind types", "phalcon/db/adapter.zep", 334);
return;
}
- zephir_array_append(&bindDataTypes, bindType, PH_SEPARATE, "phalcon/db/adapter.zep", 341);
+ zephir_array_append(&bindDataTypes, bindType, PH_SEPARATE, "phalcon/db/adapter.zep", 336);
}
}
}
@@ -43246,7 +43479,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, insert) {
if (ZEPHIR_GLOBAL(db).escape_identifiers) {
ZEPHIR_INIT_VAR(escapedFields);
array_init(escapedFields);
- zephir_is_iterable(fields, &_7, &_6, 0, 0, "phalcon/db/adapter.zep", 364);
+ zephir_is_iterable(fields, &_7, &_6, 0, 0, "phalcon/db/adapter.zep", 359);
for (
; zephir_hash_get_current_data_ex(_7, (void**) &_8, &_6) == SUCCESS
; zephir_hash_move_forward_ex(_7, &_6)
@@ -43254,7 +43487,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, insert) {
ZEPHIR_GET_HVALUE(field, _8);
ZEPHIR_CALL_METHOD(&_9, this_ptr, "escapeidentifier", &_10, 0, field);
zephir_check_call_status();
- zephir_array_append(&escapedFields, _9, PH_SEPARATE, "phalcon/db/adapter.zep", 362);
+ zephir_array_append(&escapedFields, _9, PH_SEPARATE, "phalcon/db/adapter.zep", 357);
}
} else {
ZEPHIR_CPY_WRT(escapedFields, fields);
@@ -43303,15 +43536,15 @@ static PHP_METHOD(Phalcon_Db_Adapter, insertAsDict) {
if (_0) {
RETURN_MM_BOOL(0);
}
- zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/db/adapter.zep", 419);
+ zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/db/adapter.zep", 414);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
) {
ZEPHIR_GET_HMKEY(field, _2, _1);
ZEPHIR_GET_HVALUE(value, _3);
- zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/db/adapter.zep", 415);
- zephir_array_append(&values, value, PH_SEPARATE, "phalcon/db/adapter.zep", 416);
+ zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/db/adapter.zep", 410);
+ zephir_array_append(&values, value, PH_SEPARATE, "phalcon/db/adapter.zep", 411);
}
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "insert", NULL, 0, table, values, fields, dataTypes);
zephir_check_call_status();
@@ -43344,7 +43577,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, update) {
array_init(updateValues);
ZEPHIR_INIT_VAR(bindDataTypes);
array_init(bindDataTypes);
- zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/db/adapter.zep", 505);
+ zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/db/adapter.zep", 500);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -43353,7 +43586,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, update) {
ZEPHIR_GET_HVALUE(value, _2);
ZEPHIR_OBS_NVAR(field);
if (!(zephir_array_isset_fetch(&field, fields, position, 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The number of values in the update is not the same as fields", "phalcon/db/adapter.zep", 478);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The number of values in the update is not the same as fields", "phalcon/db/adapter.zep", 473);
return;
}
if (ZEPHIR_GLOBAL(db).escape_identifiers) {
@@ -43365,25 +43598,25 @@ static PHP_METHOD(Phalcon_Db_Adapter, update) {
if (Z_TYPE_P(value) == IS_OBJECT) {
ZEPHIR_INIT_LNVAR(_4);
ZEPHIR_CONCAT_VSV(_4, escapedField, " = ", value);
- zephir_array_append(&placeholders, _4, PH_SEPARATE, "phalcon/db/adapter.zep", 488);
+ zephir_array_append(&placeholders, _4, PH_SEPARATE, "phalcon/db/adapter.zep", 483);
} else {
if (Z_TYPE_P(value) == IS_NULL) {
ZEPHIR_INIT_LNVAR(_4);
ZEPHIR_CONCAT_VS(_4, escapedField, " = null");
- zephir_array_append(&placeholders, _4, PH_SEPARATE, "phalcon/db/adapter.zep", 491);
+ zephir_array_append(&placeholders, _4, PH_SEPARATE, "phalcon/db/adapter.zep", 486);
} else {
- zephir_array_append(&updateValues, value, PH_SEPARATE, "phalcon/db/adapter.zep", 493);
+ zephir_array_append(&updateValues, value, PH_SEPARATE, "phalcon/db/adapter.zep", 488);
if (Z_TYPE_P(dataTypes) == IS_ARRAY) {
ZEPHIR_OBS_NVAR(bindType);
if (!(zephir_array_isset_fetch(&bindType, dataTypes, position, 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Incomplete number of bind types", "phalcon/db/adapter.zep", 496);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Incomplete number of bind types", "phalcon/db/adapter.zep", 491);
return;
}
- zephir_array_append(&bindDataTypes, bindType, PH_SEPARATE, "phalcon/db/adapter.zep", 498);
+ zephir_array_append(&bindDataTypes, bindType, PH_SEPARATE, "phalcon/db/adapter.zep", 493);
}
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_VS(_5, escapedField, " = ?");
- zephir_array_append(&placeholders, _5, PH_SEPARATE, "phalcon/db/adapter.zep", 500);
+ zephir_array_append(&placeholders, _5, PH_SEPARATE, "phalcon/db/adapter.zep", 495);
}
}
}
@@ -43402,7 +43635,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, update) {
zephir_concat_self(&updateSql, whereCondition TSRMLS_CC);
} else {
if (Z_TYPE_P(whereCondition) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Invalid WHERE clause conditions", "phalcon/db/adapter.zep", 528);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Invalid WHERE clause conditions", "phalcon/db/adapter.zep", 523);
return;
}
ZEPHIR_OBS_VAR(conditions);
@@ -43462,15 +43695,15 @@ static PHP_METHOD(Phalcon_Db_Adapter, updateAsDict) {
if (_0) {
RETURN_MM_BOOL(0);
}
- zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/db/adapter.zep", 604);
+ zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/db/adapter.zep", 599);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
) {
ZEPHIR_GET_HMKEY(field, _2, _1);
ZEPHIR_GET_HVALUE(value, _3);
- zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/db/adapter.zep", 600);
- zephir_array_append(&values, value, PH_SEPARATE, "phalcon/db/adapter.zep", 601);
+ zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/db/adapter.zep", 595);
+ zephir_array_append(&values, value, PH_SEPARATE, "phalcon/db/adapter.zep", 596);
}
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "update", NULL, 0, table, fields, values, whereCondition, dataTypes);
zephir_check_call_status();
@@ -43609,7 +43842,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, tableExists) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchone", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_array_fetch_long(&_4, _0, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 681 TSRMLS_CC);
+ zephir_array_fetch_long(&_4, _0, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 676 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_GT_LONG(_4, 0));
}
@@ -43659,7 +43892,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, viewExists) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchone", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_array_fetch_long(&_4, _0, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 693 TSRMLS_CC);
+ zephir_array_fetch_long(&_4, _0, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 688 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_GT_LONG(_4, 0));
}
@@ -43760,11 +43993,11 @@ static PHP_METHOD(Phalcon_Db_Adapter, createTable) {
ZEPHIR_OBS_VAR(columns);
if (!(zephir_array_isset_string_fetch(&columns, definition, SS("columns"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 720);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 715);
return;
}
if (!(zephir_fast_count_int(columns TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 724);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 719);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dialect"), PH_NOISY_CC);
@@ -43858,7 +44091,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, createView) {
if (!(zephir_array_isset_string(definition, SS("sql")))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 749);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 739);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dialect"), PH_NOISY_CC);
@@ -44371,14 +44604,14 @@ static PHP_METHOD(Phalcon_Db_Adapter, listTables) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchall", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 858);
+ zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 848);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
) {
ZEPHIR_GET_HVALUE(table, _6);
- zephir_array_fetch_long(&_7, table, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 856 TSRMLS_CC);
- zephir_array_append(&allTables, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 856);
+ zephir_array_fetch_long(&_7, table, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 846 TSRMLS_CC);
+ zephir_array_append(&allTables, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 846);
}
RETURN_CCTOR(allTables);
@@ -44422,14 +44655,14 @@ static PHP_METHOD(Phalcon_Db_Adapter, listViews) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchall", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 876);
+ zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 866);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
) {
ZEPHIR_GET_HVALUE(table, _6);
- zephir_array_fetch_long(&_7, table, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 874 TSRMLS_CC);
- zephir_array_append(&allTables, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 874);
+ zephir_array_fetch_long(&_7, table, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 864 TSRMLS_CC);
+ zephir_array_append(&allTables, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 864);
}
RETURN_CCTOR(allTables);
@@ -44472,27 +44705,27 @@ static PHP_METHOD(Phalcon_Db_Adapter, describeIndexes) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchall", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 908);
+ zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 898);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
) {
ZEPHIR_GET_HVALUE(index, _6);
- zephir_array_fetch_long(&keyName, index, 2, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 897 TSRMLS_CC);
+ zephir_array_fetch_long(&keyName, index, 2, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 887 TSRMLS_CC);
if (!(zephir_array_isset(indexes, keyName))) {
ZEPHIR_INIT_NVAR(columns);
array_init(columns);
} else {
ZEPHIR_OBS_NVAR(columns);
- zephir_array_fetch(&columns, indexes, keyName, PH_NOISY, "phalcon/db/adapter.zep", 901 TSRMLS_CC);
+ zephir_array_fetch(&columns, indexes, keyName, PH_NOISY, "phalcon/db/adapter.zep", 891 TSRMLS_CC);
}
- zephir_array_fetch_long(&_7, index, 4, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 904 TSRMLS_CC);
- zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 904);
+ zephir_array_fetch_long(&_7, index, 4, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 894 TSRMLS_CC);
+ zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 894);
zephir_array_update_zval(&indexes, keyName, &columns, PH_COPY | PH_SEPARATE);
}
ZEPHIR_INIT_VAR(indexObjects);
array_init(indexObjects);
- zephir_is_iterable(indexes, &_9, &_8, 0, 0, "phalcon/db/adapter.zep", 917);
+ zephir_is_iterable(indexes, &_9, &_8, 0, 0, "phalcon/db/adapter.zep", 907);
for (
; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS
; zephir_hash_move_forward_ex(_9, &_8)
@@ -44560,40 +44793,40 @@ static PHP_METHOD(Phalcon_Db_Adapter, describeReferences) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchall", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 961);
+ zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 951);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
) {
ZEPHIR_GET_HVALUE(reference, _6);
- zephir_array_fetch_long(&constraintName, reference, 2, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 937 TSRMLS_CC);
+ zephir_array_fetch_long(&constraintName, reference, 2, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 927 TSRMLS_CC);
if (!(zephir_array_isset(references, constraintName))) {
ZEPHIR_OBS_NVAR(referencedSchema);
- zephir_array_fetch_long(&referencedSchema, reference, 3, PH_NOISY, "phalcon/db/adapter.zep", 939 TSRMLS_CC);
+ zephir_array_fetch_long(&referencedSchema, reference, 3, PH_NOISY, "phalcon/db/adapter.zep", 929 TSRMLS_CC);
ZEPHIR_OBS_NVAR(referencedTable);
- zephir_array_fetch_long(&referencedTable, reference, 4, PH_NOISY, "phalcon/db/adapter.zep", 940 TSRMLS_CC);
+ zephir_array_fetch_long(&referencedTable, reference, 4, PH_NOISY, "phalcon/db/adapter.zep", 930 TSRMLS_CC);
ZEPHIR_INIT_NVAR(columns);
array_init(columns);
ZEPHIR_INIT_NVAR(referencedColumns);
array_init(referencedColumns);
} else {
- zephir_array_fetch(&_7, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 944 TSRMLS_CC);
+ zephir_array_fetch(&_7, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 934 TSRMLS_CC);
ZEPHIR_OBS_NVAR(referencedSchema);
- zephir_array_fetch_string(&referencedSchema, _7, SL("referencedSchema"), PH_NOISY, "phalcon/db/adapter.zep", 944 TSRMLS_CC);
- zephir_array_fetch(&_8, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 945 TSRMLS_CC);
+ zephir_array_fetch_string(&referencedSchema, _7, SL("referencedSchema"), PH_NOISY, "phalcon/db/adapter.zep", 934 TSRMLS_CC);
+ zephir_array_fetch(&_8, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 935 TSRMLS_CC);
ZEPHIR_OBS_NVAR(referencedTable);
- zephir_array_fetch_string(&referencedTable, _8, SL("referencedTable"), PH_NOISY, "phalcon/db/adapter.zep", 945 TSRMLS_CC);
- zephir_array_fetch(&_9, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 946 TSRMLS_CC);
+ zephir_array_fetch_string(&referencedTable, _8, SL("referencedTable"), PH_NOISY, "phalcon/db/adapter.zep", 935 TSRMLS_CC);
+ zephir_array_fetch(&_9, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 936 TSRMLS_CC);
ZEPHIR_OBS_NVAR(columns);
- zephir_array_fetch_string(&columns, _9, SL("columns"), PH_NOISY, "phalcon/db/adapter.zep", 946 TSRMLS_CC);
- zephir_array_fetch(&_10, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 947 TSRMLS_CC);
+ zephir_array_fetch_string(&columns, _9, SL("columns"), PH_NOISY, "phalcon/db/adapter.zep", 936 TSRMLS_CC);
+ zephir_array_fetch(&_10, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 937 TSRMLS_CC);
ZEPHIR_OBS_NVAR(referencedColumns);
- zephir_array_fetch_string(&referencedColumns, _10, SL("referencedColumns"), PH_NOISY, "phalcon/db/adapter.zep", 947 TSRMLS_CC);
+ zephir_array_fetch_string(&referencedColumns, _10, SL("referencedColumns"), PH_NOISY, "phalcon/db/adapter.zep", 937 TSRMLS_CC);
}
- zephir_array_fetch_long(&_7, reference, 1, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 950 TSRMLS_CC);
- zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 950);
- zephir_array_fetch_long(&_8, reference, 5, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 951 TSRMLS_CC);
- zephir_array_append(&referencedColumns, _8, PH_SEPARATE, "phalcon/db/adapter.zep", 951);
+ zephir_array_fetch_long(&_7, reference, 1, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 940 TSRMLS_CC);
+ zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 940);
+ zephir_array_fetch_long(&_8, reference, 5, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 941 TSRMLS_CC);
+ zephir_array_append(&referencedColumns, _8, PH_SEPARATE, "phalcon/db/adapter.zep", 941);
ZEPHIR_INIT_NVAR(_11);
zephir_create_array(_11, 4, 0 TSRMLS_CC);
zephir_array_update_string(&_11, SL("referencedSchema"), &referencedSchema, PH_COPY | PH_SEPARATE);
@@ -44604,7 +44837,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, describeReferences) {
}
ZEPHIR_INIT_VAR(referenceObjects);
array_init(referenceObjects);
- zephir_is_iterable(references, &_13, &_12, 0, 0, "phalcon/db/adapter.zep", 971);
+ zephir_is_iterable(references, &_13, &_12, 0, 0, "phalcon/db/adapter.zep", 961);
for (
; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS
; zephir_hash_move_forward_ex(_13, &_12)
@@ -44616,16 +44849,16 @@ static PHP_METHOD(Phalcon_Db_Adapter, describeReferences) {
ZEPHIR_INIT_NVAR(_11);
zephir_create_array(_11, 4, 0 TSRMLS_CC);
ZEPHIR_OBS_NVAR(_15);
- zephir_array_fetch_string(&_15, arrayReference, SL("referencedSchema"), PH_NOISY, "phalcon/db/adapter.zep", 964 TSRMLS_CC);
+ zephir_array_fetch_string(&_15, arrayReference, SL("referencedSchema"), PH_NOISY, "phalcon/db/adapter.zep", 954 TSRMLS_CC);
zephir_array_update_string(&_11, SL("referencedSchema"), &_15, PH_COPY | PH_SEPARATE);
ZEPHIR_OBS_NVAR(_15);
- zephir_array_fetch_string(&_15, arrayReference, SL("referencedTable"), PH_NOISY, "phalcon/db/adapter.zep", 965 TSRMLS_CC);
+ zephir_array_fetch_string(&_15, arrayReference, SL("referencedTable"), PH_NOISY, "phalcon/db/adapter.zep", 955 TSRMLS_CC);
zephir_array_update_string(&_11, SL("referencedTable"), &_15, PH_COPY | PH_SEPARATE);
ZEPHIR_OBS_NVAR(_15);
- zephir_array_fetch_string(&_15, arrayReference, SL("columns"), PH_NOISY, "phalcon/db/adapter.zep", 966 TSRMLS_CC);
+ zephir_array_fetch_string(&_15, arrayReference, SL("columns"), PH_NOISY, "phalcon/db/adapter.zep", 956 TSRMLS_CC);
zephir_array_update_string(&_11, SL("columns"), &_15, PH_COPY | PH_SEPARATE);
ZEPHIR_OBS_NVAR(_15);
- zephir_array_fetch_string(&_15, arrayReference, SL("referencedColumns"), PH_NOISY, "phalcon/db/adapter.zep", 968 TSRMLS_CC);
+ zephir_array_fetch_string(&_15, arrayReference, SL("referencedColumns"), PH_NOISY, "phalcon/db/adapter.zep", 958 TSRMLS_CC);
zephir_array_update_string(&_11, SL("referencedColumns"), &_15, PH_COPY | PH_SEPARATE);
ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_16, 16, name, _11);
zephir_check_call_status();
@@ -44671,7 +44904,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, tableOptions) {
ZVAL_LONG(_2, 2);
ZEPHIR_CALL_METHOD(&_1, this_ptr, "fetchall", NULL, 0, sql, _2);
zephir_check_call_status();
- zephir_array_fetch_long(&_3, _1, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 987 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, _1, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 977 TSRMLS_CC);
RETURN_CTOR(_3);
}
array_init(return_value);
@@ -44706,7 +44939,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, createSavepoint) {
ZEPHIR_CALL_METHOD(&_0, dialect, "supportssavepoints", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_0))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter.", "phalcon/db/adapter.zep", 1002);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter.", "phalcon/db/adapter.zep", 992);
return;
}
ZEPHIR_CALL_METHOD(&_1, dialect, "createsavepoint", NULL, 0, name);
@@ -44744,7 +44977,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, releaseSavepoint) {
ZEPHIR_CALL_METHOD(&_0, dialect, "supportssavepoints", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_0))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1018);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1008);
return;
}
ZEPHIR_CALL_METHOD(&_1, dialect, "supportsreleasesavepoints", NULL, 0);
@@ -44787,7 +45020,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, rollbackSavepoint) {
ZEPHIR_CALL_METHOD(&_0, dialect, "supportssavepoints", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_0))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1038);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1028);
return;
}
ZEPHIR_CALL_METHOD(&_1, dialect, "rollbacksavepoint", NULL, 0, name);
@@ -44812,14 +45045,14 @@ static PHP_METHOD(Phalcon_Db_Adapter, setNestedTransactionsWithSavepoints) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_transactionLevel"), PH_NOISY_CC);
if (ZEPHIR_GT_LONG(_0, 0)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Nested transaction with savepoints behavior cannot be changed while a transaction is open", "phalcon/db/adapter.zep", 1051);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Nested transaction with savepoints behavior cannot be changed while a transaction is open", "phalcon/db/adapter.zep", 1041);
return;
}
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_dialect"), PH_NOISY_CC);
ZEPHIR_CALL_METHOD(&_2, _1, "supportssavepoints", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_2))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1055);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1045);
return;
}
zephir_update_property_this(this_ptr, SL("_transactionsWithSavepoints"), nestedTransactionsWithSavepoints ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
@@ -47020,11 +47253,10 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionGroupBy) {
if (unlikely(Z_TYPE_P(filed) != IS_ARRAY)) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Invalid SQL-GROUP-BY expression", "phalcon/db/dialect.zep", 829);
return;
- } else {
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqlexpression", &_4, 0, filed, escapeChar, bindCounts);
- zephir_check_call_status();
- zephir_array_append(&fields, _3, PH_SEPARATE, "phalcon/db/dialect.zep", 831);
}
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqlexpression", &_4, 0, filed, escapeChar, bindCounts);
+ zephir_check_call_status();
+ zephir_array_append(&fields, _3, PH_SEPARATE, "phalcon/db/dialect.zep", 832);
}
ZEPHIR_INIT_VAR(_5);
zephir_fast_join_str(_5, SL(", "), fields TSRMLS_CC);
@@ -47106,11 +47338,10 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionOrderBy) {
if (unlikely(Z_TYPE_P(filed) != IS_ARRAY)) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Invalid SQL-ORDER-BY expression", "phalcon/db/dialect.zep", 870);
return;
- } else {
- zephir_array_fetch_long(&_3, filed, 0, PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 872 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&fieldSql, this_ptr, "getsqlexpression", &_4, 0, _3, escapeChar, bindCounts);
- zephir_check_call_status();
}
+ zephir_array_fetch_long(&_3, filed, 0, PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 873 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&fieldSql, this_ptr, "getsqlexpression", &_4, 0, _3, escapeChar, bindCounts);
+ zephir_check_call_status();
ZEPHIR_OBS_NVAR(type);
_5 = zephir_array_isset_long_fetch(&type, filed, 1, 0 TSRMLS_CC);
if (_5) {
@@ -47659,19 +47890,19 @@ static PHP_METHOD(Phalcon_Db_Profiler, startProfile) {
ZEPHIR_CALL_METHOD(NULL, activeProfile, "__construct", NULL, 0);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlstatement", NULL, 143, sqlStatement);
+ ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlstatement", NULL, 144, sqlStatement);
zephir_check_call_status();
if (Z_TYPE_P(sqlVariables) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlvariables", NULL, 144, sqlVariables);
+ ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlvariables", NULL, 145, sqlVariables);
zephir_check_call_status();
}
if (Z_TYPE_P(sqlBindTypes) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlbindtypes", NULL, 145, sqlBindTypes);
+ ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlbindtypes", NULL, 146, sqlBindTypes);
zephir_check_call_status();
}
ZEPHIR_INIT_VAR(_0);
zephir_microtime(_0, ZEPHIR_GLOBAL(global_true) TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, activeProfile, "setinitialtime", NULL, 146, _0);
+ ZEPHIR_CALL_METHOD(NULL, activeProfile, "setinitialtime", NULL, 147, _0);
zephir_check_call_status();
if ((zephir_method_exists_ex(this_ptr, SS("beforestartprofile") TSRMLS_CC) == SUCCESS)) {
ZEPHIR_CALL_METHOD(NULL, this_ptr, "beforestartprofile", NULL, 0, activeProfile);
@@ -50756,15 +50987,14 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) {
if (zephir_is_true(size)) {
ZEPHIR_CALL_METHOD(&scale, column, "getscale", NULL, 0);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_1);
- ZEPHIR_CONCAT_SV(_1, "(", size);
- zephir_concat_self(&columnSql, _1 TSRMLS_CC);
if (zephir_is_true(scale)) {
+ ZEPHIR_INIT_LNVAR(_1);
+ ZEPHIR_CONCAT_SVSVS(_1, "(", size, ",", scale, ")");
+ zephir_concat_self(&columnSql, _1 TSRMLS_CC);
+ } else {
ZEPHIR_INIT_VAR(_4);
- ZEPHIR_CONCAT_SVS(_4, ",", scale, ")");
+ ZEPHIR_CONCAT_SVS(_4, "(", size, ")");
zephir_concat_self(&columnSql, _4 TSRMLS_CC);
- } else {
- zephir_concat_self_str(&columnSql, SL(")") TSRMLS_CC);
}
}
ZEPHIR_CALL_METHOD(&_0, column, "isunsigned", NULL, 0);
@@ -50846,7 +51076,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) {
break;
}
if (ZEPHIR_IS_EMPTY(columnSql)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Unrecognized MySQL data type", "phalcon/db/dialect/mysql.zep", 192);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Unrecognized MySQL data type", "phalcon/db/dialect/mysql.zep", 191);
return;
}
ZEPHIR_CALL_METHOD(&typeValues, column, "gettypevalues", NULL, 0);
@@ -50855,7 +51085,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) {
if (Z_TYPE_P(typeValues) == IS_ARRAY) {
ZEPHIR_INIT_VAR(valueSql);
ZVAL_STRING(valueSql, "", 1);
- zephir_is_iterable(typeValues, &_6, &_5, 0, 0, "phalcon/db/dialect/mysql.zep", 203);
+ zephir_is_iterable(typeValues, &_6, &_5, 0, 0, "phalcon/db/dialect/mysql.zep", 202);
for (
; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS
; zephir_hash_move_forward_ex(_6, &_5)
@@ -50897,8 +51127,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addColumn) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *afterPosition = NULL, *sql = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *afterPosition = NULL, *sql, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, _3, *_4 = NULL, *_5 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &column);
@@ -50927,50 +51157,41 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addColumn) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` ADD ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` ADD ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumndefinition", NULL, 0, column);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVSV(_3, "`", _1, "` ", _2);
- zephir_concat_self(&sql, _3 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(sql);
+ ZEPHIR_CONCAT_SVSVSV(sql, "ALTER TABLE ", _0, " ADD `", _1, "` ", _2);
ZEPHIR_CALL_METHOD(&defaultValue, column, "getdefault", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(defaultValue))) {
- ZEPHIR_SINIT_VAR(_4);
- ZVAL_STRING(&_4, "\"", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 141, defaultValue, &_4);
+ ZEPHIR_SINIT_VAR(_3);
+ ZVAL_STRING(&_3, "\"", 0);
+ ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 141, defaultValue, &_3);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_6);
- ZEPHIR_CONCAT_SVS(_6, " DEFAULT \"", _5, "\"");
- zephir_concat_self(&sql, _6 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_5);
+ ZEPHIR_CONCAT_SVS(_5, " DEFAULT \"", _4, "\"");
+ zephir_concat_self(&sql, _5 TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_5, column, "isnotnull", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, column, "isnotnull", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_5)) {
+ if (zephir_is_true(_4)) {
zephir_concat_self_str(&sql, SL(" NOT NULL") TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_5, column, "isfirst", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, column, "isfirst", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_5)) {
+ if (zephir_is_true(_4)) {
zephir_concat_self_str(&sql, SL(" FIRST") TSRMLS_CC);
} else {
ZEPHIR_CALL_METHOD(&afterPosition, column, "getafterposition", NULL, 0);
zephir_check_call_status();
if (zephir_is_true(afterPosition)) {
- ZEPHIR_INIT_LNVAR(_6);
- ZEPHIR_CONCAT_SV(_6, " AFTER ", afterPosition);
- zephir_concat_self(&sql, _6 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_5);
+ ZEPHIR_CONCAT_SV(_5, " AFTER ", afterPosition);
+ zephir_concat_self(&sql, _5 TSRMLS_CC);
}
}
RETURN_CCTOR(sql);
@@ -50980,8 +51201,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addColumn) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, modifyColumn) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *currentColumn = NULL, *sql = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *currentColumn = NULL, *sql, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, _3, *_4 = NULL, *_5;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 1, &tableName_param, &schemaName_param, &column, ¤tColumn);
@@ -51013,37 +51234,28 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, modifyColumn) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` MODIFY ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` MODIFY ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumndefinition", NULL, 0, column);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVSV(_3, "`", _1, "` ", _2);
- zephir_concat_self(&sql, _3 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(sql);
+ ZEPHIR_CONCAT_SVSVSV(sql, "ALTER TABLE ", _0, " MODIFY `", _1, "` ", _2);
ZEPHIR_CALL_METHOD(&defaultValue, column, "getdefault", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(defaultValue))) {
- ZEPHIR_SINIT_VAR(_4);
- ZVAL_STRING(&_4, "\"", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 141, defaultValue, &_4);
+ ZEPHIR_SINIT_VAR(_3);
+ ZVAL_STRING(&_3, "\"", 0);
+ ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 141, defaultValue, &_3);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_6);
- ZEPHIR_CONCAT_SVS(_6, " DEFAULT \"", _5, "\"");
- zephir_concat_self(&sql, _6 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_5);
+ ZEPHIR_CONCAT_SVS(_5, " DEFAULT \"", _4, "\"");
+ zephir_concat_self(&sql, _5 TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_5, column, "isnotnull", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, column, "isnotnull", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_5)) {
+ if (zephir_is_true(_4)) {
zephir_concat_self_str(&sql, SL(" NOT NULL") TSRMLS_CC);
}
RETURN_CCTOR(sql);
@@ -51052,8 +51264,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, modifyColumn) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropColumn) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *columnName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *columnName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *columnName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *columnName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &columnName_param);
@@ -51093,28 +51306,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropColumn) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` DROP COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` DROP COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", columnName, "`");
- zephir_concat_self(&sql, _0 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP COLUMN `", columnName, "`");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addIndex) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql = NULL, *indexType = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql, *indexType = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
@@ -51143,24 +51346,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addIndex) {
}
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSV(_0, "ALTER TABLE `", schemaName, "`.`", tableName);
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SV(_0, "ALTER TABLE `", tableName);
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CONCAT_SV(sql, "ALTER TABLE ", _0);
ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(indexType))) {
ZEPHIR_INIT_VAR(_1);
- ZEPHIR_CONCAT_SVS(_1, "` ADD ", indexType, " INDEX ");
+ ZEPHIR_CONCAT_SVS(_1, " ADD ", indexType, " INDEX ");
zephir_concat_self(&sql, _1 TSRMLS_CC);
} else {
- zephir_concat_self_str(&sql, SL("` ADD INDEX ") TSRMLS_CC);
+ zephir_concat_self_str(&sql, SL(" ADD INDEX ") TSRMLS_CC);
}
ZEPHIR_CALL_METHOD(&_2, index, "getname", NULL, 0);
zephir_check_call_status();
@@ -51177,8 +51374,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addIndex) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropIndex) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *indexName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *indexName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *indexName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *indexName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &indexName_param);
@@ -51218,28 +51416,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropIndex) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` DROP INDEX ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` DROP INDEX ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", indexName, "`");
- zephir_concat_self(&sql, _0 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP INDEX `", indexName, "`");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addPrimaryKey) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql = NULL, *_1 = NULL, *_2 = NULL, *_3;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *index, *_0 = NULL, *_1 = NULL, *_2 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
@@ -51268,31 +51456,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addPrimaryKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` ADD PRIMARY KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` ADD PRIMARY KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 43, _2);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVS(_3, "(", _1, ")");
- zephir_concat_self(&sql, _3 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " ADD PRIMARY KEY (", _1, ")");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropPrimaryKey) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 0, &tableName_param, &schemaName_param);
@@ -51321,25 +51500,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropPrimaryKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` DROP PRIMARY KEY");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` DROP PRIMARY KEY");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVS(return_value, "ALTER TABLE ", _0, " DROP PRIMARY KEY");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *reference, *sql = NULL, *referencedSchema = NULL, *onDelete = NULL, *onUpdate = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *reference, *sql, *onDelete = NULL, *onUpdate = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &reference);
@@ -51368,41 +51540,26 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` ADD FOREIGN KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` ADD FOREIGN KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, reference, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_3, reference, "getcolumns", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 43, _3);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_4);
- ZEPHIR_CONCAT_SVSVS(_4, "`", _1, "`(", _2, ") REFERENCES ");
- zephir_concat_self(&sql, _4 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&referencedSchema, reference, "getreferencedschema", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_5, reference, "getreferencedtable", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(referencedSchema)) {
- ZEPHIR_INIT_VAR(_5);
- ZEPHIR_CONCAT_SVS(_5, "`", referencedSchema, "`.");
- zephir_concat_self(&sql, _5 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_6, reference, "getreferencedtable", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_6, reference, "getreferencedschema", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "preparetable", NULL, 0, _5, _6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_8, reference, "getreferencedcolumns", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", NULL, 43, _8);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_5);
- ZEPHIR_CONCAT_SVSVS(_5, "`", _6, "`(", _7, ")");
- zephir_concat_self(&sql, _5 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(sql);
+ ZEPHIR_CONCAT_SVSVSVSVSVS(sql, "ALTER TABLE ", _0, " ADD FOREIGN KEY `", _1, "`(", _2, ") REFERENCES ", _4, "(", _7, ")");
ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onDelete))) {
@@ -51413,9 +51570,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) {
ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onUpdate))) {
- ZEPHIR_INIT_LNVAR(_5);
- ZEPHIR_CONCAT_SV(_5, " ON UPDATE ", onUpdate);
- zephir_concat_self(&sql, _5 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SV(_9, " ON UPDATE ", onUpdate);
+ zephir_concat_self(&sql, _9 TSRMLS_CC);
}
RETURN_CCTOR(sql);
@@ -51423,8 +51580,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropForeignKey) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *referenceName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *referenceName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *referenceName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *referenceName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &referenceName_param);
@@ -51464,30 +51622,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropForeignKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` DROP FOREIGN KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` DROP FOREIGN KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_CONCAT_VSVS(return_value, sql, "`", referenceName, "`");
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP FOREIGN KEY `", referenceName, "`");
RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) {
- zephir_fcall_cache_entry *_6 = NULL, *_9 = NULL, *_14 = NULL;
+ zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_13 = NULL;
+ HashTable *_1, *_11, *_17;
+ HashPosition _0, _10, _16;
int ZEPHIR_LAST_CALL_STATUS;
- HashTable *_2, *_12, *_18;
- HashPosition _1, _11, _17;
zval *definition = NULL;
- zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, **_3, *_4 = NULL, *_5 = NULL, _7 = zval_used_for_init, *_8 = NULL, *_10 = NULL, **_13, *_15 = NULL, *_16 = NULL, **_19, *_20 = NULL, *_21 = NULL, *_22;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, **_2, *_3 = NULL, *_4 = NULL, _6 = zval_used_for_init, *_7 = NULL, *_9 = NULL, **_12, *_14 = NULL, *_15 = NULL, **_18, *_19 = NULL, *_20 = NULL, *_21;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &definition_param);
@@ -51520,19 +51670,11 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) {
ZEPHIR_OBS_VAR(columns);
if (!(zephir_array_isset_string_fetch(&columns, definition, SS("columns"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'columns' is required in the definition array", "phalcon/db/dialect/mysql.zep", 424);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'columns' is required in the definition array", "phalcon/db/dialect/mysql.zep", 354);
return;
}
- ZEPHIR_INIT_VAR(table);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "`", schemaName, "`.`", tableName, "`");
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", tableName, "`");
- ZEPHIR_CPY_WRT(table, _0);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(temporary);
ZVAL_BOOL(temporary, 0);
ZEPHIR_OBS_VAR(options);
@@ -51548,134 +51690,134 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) {
}
ZEPHIR_INIT_VAR(createLines);
array_init(createLines);
- zephir_is_iterable(columns, &_2, &_1, 0, 0, "phalcon/db/dialect/mysql.zep", 487);
+ zephir_is_iterable(columns, &_1, &_0, 0, 0, "phalcon/db/dialect/mysql.zep", 413);
for (
- ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
- ; zephir_hash_move_forward_ex(_2, &_1)
+ ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
+ ; zephir_hash_move_forward_ex(_1, &_0)
) {
- ZEPHIR_GET_HVALUE(column, _3);
- ZEPHIR_CALL_METHOD(&_4, column, "getname", NULL, 0);
+ ZEPHIR_GET_HVALUE(column, _2);
+ ZEPHIR_CALL_METHOD(&_3, column, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumndefinition", &_6, 0, column);
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumndefinition", &_5, 0, column);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(columnLine);
- ZEPHIR_CONCAT_SVSV(columnLine, "`", _4, "` ", _5);
+ ZEPHIR_CONCAT_SVSV(columnLine, "`", _3, "` ", _4);
ZEPHIR_CALL_METHOD(&defaultValue, column, "getdefault", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(defaultValue))) {
- ZEPHIR_SINIT_NVAR(_7);
- ZVAL_STRING(&_7, "\"", 0);
- ZEPHIR_CALL_FUNCTION(&_8, "addcslashes", &_9, 141, defaultValue, &_7);
+ ZEPHIR_SINIT_NVAR(_6);
+ ZVAL_STRING(&_6, "\"", 0);
+ ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 141, defaultValue, &_6);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SVS(_10, " DEFAULT \"", _8, "\"");
- zephir_concat_self(&columnLine, _10 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, " DEFAULT \"", _7, "\"");
+ zephir_concat_self(&columnLine, _9 TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isnotnull", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isnotnull", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
zephir_concat_self_str(&columnLine, SL(" NOT NULL") TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isautoincrement", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isautoincrement", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
zephir_concat_self_str(&columnLine, SL(" AUTO_INCREMENT") TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isprimary", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isprimary", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
zephir_concat_self_str(&columnLine, SL(" PRIMARY KEY") TSRMLS_CC);
}
- zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 481);
+ zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 407);
}
ZEPHIR_OBS_VAR(indexes);
if (zephir_array_isset_string_fetch(&indexes, definition, SS("indexes"), 0 TSRMLS_CC)) {
- zephir_is_iterable(indexes, &_12, &_11, 0, 0, "phalcon/db/dialect/mysql.zep", 509);
+ zephir_is_iterable(indexes, &_11, &_10, 0, 0, "phalcon/db/dialect/mysql.zep", 435);
for (
- ; zephir_hash_get_current_data_ex(_12, (void**) &_13, &_11) == SUCCESS
- ; zephir_hash_move_forward_ex(_12, &_11)
+ ; zephir_hash_get_current_data_ex(_11, (void**) &_12, &_10) == SUCCESS
+ ; zephir_hash_move_forward_ex(_11, &_10)
) {
- ZEPHIR_GET_HVALUE(index, _13);
+ ZEPHIR_GET_HVALUE(index, _12);
ZEPHIR_CALL_METHOD(&indexName, index, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
zephir_check_call_status();
if (ZEPHIR_IS_STRING(indexName, "PRIMARY")) {
- ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_14, 43, _5);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_13, 43, _4);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(indexSql);
- ZEPHIR_CONCAT_SVS(indexSql, "PRIMARY KEY (", _4, ")");
+ ZEPHIR_CONCAT_SVS(indexSql, "PRIMARY KEY (", _3, ")");
} else {
ZEPHIR_INIT_NVAR(indexSql);
if (!(ZEPHIR_IS_EMPTY(indexType))) {
- ZEPHIR_CALL_METHOD(&_15, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_14, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, this_ptr, "getcolumnlist", &_14, 43, _15);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_13, 43, _14);
zephir_check_call_status();
- ZEPHIR_CONCAT_VSVSVS(indexSql, indexType, " KEY `", indexName, "` (", _8, ")");
+ ZEPHIR_CONCAT_VSVSVS(indexSql, indexType, " KEY `", indexName, "` (", _7, ")");
} else {
- ZEPHIR_CALL_METHOD(&_16, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_15, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", &_14, 43, _16);
+ ZEPHIR_CALL_METHOD(&_14, this_ptr, "getcolumnlist", &_13, 43, _15);
zephir_check_call_status();
- ZEPHIR_CONCAT_SVSVS(indexSql, "KEY `", indexName, "` (", _15, ")");
+ ZEPHIR_CONCAT_SVSVS(indexSql, "KEY `", indexName, "` (", _14, ")");
}
}
- zephir_array_append(&createLines, indexSql, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 507);
+ zephir_array_append(&createLines, indexSql, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 433);
}
}
ZEPHIR_OBS_VAR(references);
if (zephir_array_isset_string_fetch(&references, definition, SS("references"), 0 TSRMLS_CC)) {
- zephir_is_iterable(references, &_18, &_17, 0, 0, "phalcon/db/dialect/mysql.zep", 531);
+ zephir_is_iterable(references, &_17, &_16, 0, 0, "phalcon/db/dialect/mysql.zep", 457);
for (
- ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS
- ; zephir_hash_move_forward_ex(_18, &_17)
+ ; zephir_hash_get_current_data_ex(_17, (void**) &_18, &_16) == SUCCESS
+ ; zephir_hash_move_forward_ex(_17, &_16)
) {
- ZEPHIR_GET_HVALUE(reference, _19);
- ZEPHIR_CALL_METHOD(&_4, reference, "getname", NULL, 0);
+ ZEPHIR_GET_HVALUE(reference, _18);
+ ZEPHIR_CALL_METHOD(&_3, reference, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, reference, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, reference, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", &_14, 43, _8);
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_13, 43, _7);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_15, reference, "getreferencedtable", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_14, reference, "getreferencedtable", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_20, reference, "getreferencedcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_19, reference, "getreferencedcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_16, this_ptr, "getcolumnlist", &_14, 43, _20);
+ ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", &_13, 43, _19);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(referenceSql);
- ZEPHIR_CONCAT_SVSVSSVSVS(referenceSql, "CONSTRAINT `", _4, "` FOREIGN KEY (", _5, ")", " REFERENCES `", _15, "`(", _16, ")");
+ ZEPHIR_CONCAT_SVSVSSVSVS(referenceSql, "CONSTRAINT `", _3, "` FOREIGN KEY (", _4, ")", " REFERENCES `", _14, "`(", _15, ")");
ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onDelete))) {
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SV(_10, " ON DELETE ", onDelete);
- zephir_concat_self(&referenceSql, _10 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SV(_9, " ON DELETE ", onDelete);
+ zephir_concat_self(&referenceSql, _9 TSRMLS_CC);
}
ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onUpdate))) {
- ZEPHIR_INIT_LNVAR(_21);
- ZEPHIR_CONCAT_SV(_21, " ON UPDATE ", onUpdate);
- zephir_concat_self(&referenceSql, _21 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_20);
+ ZEPHIR_CONCAT_SV(_20, " ON UPDATE ", onUpdate);
+ zephir_concat_self(&referenceSql, _20 TSRMLS_CC);
}
- zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 529);
+ zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 455);
}
}
- ZEPHIR_INIT_VAR(_22);
- zephir_fast_join_str(_22, SL(",\n\t"), createLines TSRMLS_CC);
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_VS(_10, _22, "\n)");
- zephir_concat_self(&sql, _10 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_21);
+ zephir_fast_join_str(_21, SL(",\n\t"), createLines TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_VS(_9, _21, "\n)");
+ zephir_concat_self(&sql, _9 TSRMLS_CC);
if (zephir_array_isset_string(definition, SS("options"))) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "_gettableoptions", NULL, 0, definition);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_gettableoptions", NULL, 0, definition);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_21);
- ZEPHIR_CONCAT_SV(_21, " ", _4);
- zephir_concat_self(&sql, _21 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_20);
+ ZEPHIR_CONCAT_SV(_20, " ", _3);
+ zephir_concat_self(&sql, _20 TSRMLS_CC);
}
RETURN_CCTOR(sql);
@@ -51683,9 +51825,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropTable) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *sql, *table = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &tableName_param, &schemaName_param, &ifExists_param);
@@ -51719,16 +51862,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropTable) {
}
- ZEPHIR_INIT_VAR(table);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "`", schemaName, "`.`", tableName, "`");
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", tableName, "`");
- ZEPHIR_CPY_WRT(table, _0);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
ZEPHIR_CONCAT_SV(sql, "DROP TABLE IF EXISTS ", table);
@@ -51741,9 +51876,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropTable) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zval *definition = NULL;
- zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *view = NULL, *viewSql;
- zval *viewName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *_0 = NULL;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 1, &viewName_param, &definition_param, &schemaName_param);
@@ -51771,29 +51907,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createView) {
ZEPHIR_OBS_VAR(viewSql);
if (!(zephir_array_isset_string_fetch(&viewSql, definition, SS("sql"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/mysql.zep", 571);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/mysql.zep", 493);
return;
}
- ZEPHIR_INIT_VAR(view);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "`", schemaName, "`.`", viewName, "`");
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", viewName, "`");
- ZEPHIR_CPY_WRT(view, _0);
- }
- ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", view, " AS ", viewSql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", _0, " AS ", viewSql);
RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *sql, *view = NULL;
- zval *viewName = NULL, *schemaName = NULL, *_0;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &viewName_param, &schemaName_param, &ifExists_param);
@@ -51827,13 +51956,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropView) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_VSV(_0, schemaName, ".", viewName);
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_CPY_WRT(view, viewName);
- }
+ ZEPHIR_CALL_METHOD(&view, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
ZEPHIR_CONCAT_SV(sql, "DROP VIEW IF EXISTS ", view);
@@ -51918,7 +52042,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, viewExists) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, describeColumns) {
- zval *table_param = NULL, *schema_param = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *table_param = NULL, *schema_param = NULL, *_0 = NULL;
zval *table = NULL, *schema = NULL;
ZEPHIR_MM_GROW();
@@ -51943,11 +52068,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, describeColumns) {
}
- if (schema && Z_STRLEN_P(schema)) {
- ZEPHIR_CONCAT_SVSVS(return_value, "DESCRIBE `", schema, "`.`", table, "`");
- RETURN_MM();
- }
- ZEPHIR_CONCAT_SVS(return_value, "DESCRIBE `", table, "`");
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, table, schema);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SV(return_value, "DESCRIBE ", _0);
RETURN_MM();
}
@@ -52012,7 +52135,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, listViews) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, describeIndexes) {
- zval *table_param = NULL, *schema_param = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *table_param = NULL, *schema_param = NULL, *_0 = NULL;
zval *table = NULL, *schema = NULL;
ZEPHIR_MM_GROW();
@@ -52037,11 +52161,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, describeIndexes) {
}
- if (schema && Z_STRLEN_P(schema)) {
- ZEPHIR_CONCAT_SVSVS(return_value, "SHOW INDEXES FROM `", schema, "`.`", table, "`");
- RETURN_MM();
- }
- ZEPHIR_CONCAT_SVS(return_value, "SHOW INDEXES FROM `", table, "`");
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, table, schema);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SV(return_value, "SHOW INDEXES FROM ", _0);
RETURN_MM();
}
@@ -52147,7 +52269,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, _getTableOptions) {
if (zephir_is_true(engine)) {
ZEPHIR_INIT_VAR(_0);
ZEPHIR_CONCAT_SV(_0, "ENGINE=", engine);
- zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 727);
+ zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 633);
}
}
ZEPHIR_OBS_VAR(autoIncrement);
@@ -52155,7 +52277,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, _getTableOptions) {
if (zephir_is_true(autoIncrement)) {
ZEPHIR_INIT_LNVAR(_0);
ZEPHIR_CONCAT_SV(_0, "AUTO_INCREMENT=", autoIncrement);
- zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 736);
+ zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 642);
}
}
ZEPHIR_OBS_VAR(tableCollation);
@@ -52163,13 +52285,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, _getTableOptions) {
if (zephir_is_true(tableCollation)) {
ZEPHIR_INIT_VAR(collationParts);
zephir_fast_explode_str(collationParts, SL("_"), tableCollation, LONG_MAX TSRMLS_CC);
- zephir_array_fetch_long(&_1, collationParts, 0, PH_NOISY | PH_READONLY, "phalcon/db/dialect/mysql.zep", 746 TSRMLS_CC);
+ zephir_array_fetch_long(&_1, collationParts, 0, PH_NOISY | PH_READONLY, "phalcon/db/dialect/mysql.zep", 652 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_0);
ZEPHIR_CONCAT_SV(_0, "DEFAULT CHARSET=", _1);
- zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 746);
+ zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 652);
ZEPHIR_INIT_VAR(_2);
ZEPHIR_CONCAT_SV(_2, "COLLATE=", tableCollation);
- zephir_array_append(&tableOptions, _2, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 747);
+ zephir_array_append(&tableOptions, _2, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 653);
}
}
if (zephir_fast_count_int(tableOptions TSRMLS_CC)) {
@@ -52719,9 +52841,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, createTable) {
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropTable) {
int ZEPHIR_LAST_CALL_STATUS;
- zephir_fcall_cache_entry *_2 = NULL;
zend_bool ifExists;
- zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *table = NULL, *_0 = NULL, *_1 = NULL, *_3 = NULL, *_4 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *table = NULL;
zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
@@ -52761,23 +52882,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropTable) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_CALL_CE_STATIC(&_1, phalcon_text_ce, "upper", &_2, 142, schemaName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", NULL, 42, _1);
- zephir_check_call_status();
- ZEPHIR_CALL_CE_STATIC(&_4, phalcon_text_ce, "upper", &_2, 142, tableName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "escape", NULL, 42, _4);
- zephir_check_call_status();
- ZEPHIR_INIT_VAR(table);
- ZEPHIR_CONCAT_VSV(table, _0, ".", _3);
- } else {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_2, 142, tableName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&table, this_ptr, "escape", NULL, 42, _0);
- zephir_check_call_status();
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
if (ifExists) {
ZEPHIR_CONCAT_SV(return_value, "DROP TABLE IF EXISTS ", table);
RETURN_MM();
@@ -52790,9 +52896,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropTable) {
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, createView) {
int ZEPHIR_LAST_CALL_STATUS;
- zephir_fcall_cache_entry *_1 = NULL;
zval *definition = NULL;
- zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *view = NULL, *viewSql, *_0 = NULL, *_2 = NULL, *_3;
+ zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *_0 = NULL;
zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
@@ -52821,25 +52926,12 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, createView) {
ZEPHIR_OBS_VAR(viewSql);
if (!(zephir_array_isset_string_fetch(&viewSql, definition, SS("sql"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/oracle.zep", 234);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/oracle.zep", 230);
return;
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schemaName);
- zephir_check_call_status();
- ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, viewName);
- zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_VSV(_3, _0, ".", _2);
- ZEPHIR_CALL_METHOD(&view, this_ptr, "escape", NULL, 42, _3);
- zephir_check_call_status();
- } else {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, viewName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&view, this_ptr, "escape", NULL, 42, _0);
- zephir_check_call_status();
- }
- ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", view, " AS ", viewSql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", _0, " AS ", viewSql);
RETURN_MM();
}
@@ -52847,9 +52939,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, createView) {
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropView) {
int ZEPHIR_LAST_CALL_STATUS;
- zephir_fcall_cache_entry *_1 = NULL;
zend_bool ifExists;
- zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *view = NULL, *_0 = NULL, *_2 = NULL, *_3;
+ zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *view = NULL;
zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
@@ -52884,21 +52975,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropView) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schemaName);
- zephir_check_call_status();
- ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, viewName);
- zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_VSV(_3, _0, ".", _2);
- ZEPHIR_CALL_METHOD(&view, this_ptr, "escape", NULL, 42, _3);
- zephir_check_call_status();
- } else {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, viewName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&view, this_ptr, "escape", NULL, 42, _0);
- zephir_check_call_status();
- }
+ ZEPHIR_CALL_METHOD(&view, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
if (ifExists) {
ZEPHIR_CONCAT_SV(return_value, "DROP VIEW IF EXISTS ", view);
RETURN_MM();
@@ -53235,6 +53313,57 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, supportsReleaseSavepoints) {
}
+static PHP_METHOD(Phalcon_Db_Dialect_Oracle, prepareTable) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zephir_fcall_cache_entry *_0 = NULL, *_2 = NULL;
+ zval *table_param = NULL, *schema_param = NULL, *alias_param = NULL, *escapeChar_param = NULL, *_1 = NULL, *_3 = NULL;
+ zval *table = NULL, *schema = NULL, *alias = NULL, *escapeChar = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 3, &table_param, &schema_param, &alias_param, &escapeChar_param);
+
+ if (unlikely(Z_TYPE_P(table_param) != IS_STRING && Z_TYPE_P(table_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'table' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(table_param) == IS_STRING)) {
+ zephir_get_strval(table, table_param);
+ } else {
+ ZEPHIR_INIT_VAR(table);
+ ZVAL_EMPTY_STRING(table);
+ }
+ if (!schema_param) {
+ ZEPHIR_INIT_VAR(schema);
+ ZVAL_EMPTY_STRING(schema);
+ } else {
+ zephir_get_strval(schema, schema_param);
+ }
+ if (!alias_param) {
+ ZEPHIR_INIT_VAR(alias);
+ ZVAL_EMPTY_STRING(alias);
+ } else {
+ zephir_get_strval(alias, alias_param);
+ }
+ if (!escapeChar_param) {
+ ZEPHIR_INIT_VAR(escapeChar);
+ ZVAL_EMPTY_STRING(escapeChar);
+ } else {
+ zephir_get_strval(escapeChar, escapeChar_param);
+ }
+
+
+ ZEPHIR_CALL_CE_STATIC(&_1, phalcon_text_ce, "upper", &_2, 142, table);
+ zephir_check_call_status();
+ ZEPHIR_CALL_CE_STATIC(&_3, phalcon_text_ce, "upper", &_2, 142, schema);
+ zephir_check_call_status();
+ ZEPHIR_RETURN_CALL_PARENT(phalcon_db_dialect_oracle_ce, this_ptr, "preparetable", &_0, 143, _1, _3, alias, escapeChar);
+ zephir_check_call_status();
+ RETURN_MM();
+
+}
+
@@ -53432,8 +53561,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, getColumnDefinition) {
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addColumn) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *sql = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *sql, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &column);
@@ -53462,16 +53591,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addColumn) {
}
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\" ADD COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\" ADD COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CONCAT_SVS(sql, "ALTER TABLE ", _0, " ADD COLUMN ");
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumndefinition", NULL, 0, column);
@@ -53503,8 +53626,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, modifyColumn) {
zend_bool _10;
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *currentColumn = NULL, *sql, *sqlAlterTable = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9 = NULL, _11, *_12 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *currentColumn = NULL, *sql, *sqlAlterTable, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9 = NULL, _11, *_12 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 1, &tableName_param, &schemaName_param, &column, ¤tColumn);
@@ -53538,16 +53661,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, modifyColumn) {
ZVAL_STRING(sql, "", 1);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sqlAlterTable);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(sqlAlterTable, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\"");
- ZEPHIR_CPY_WRT(sqlAlterTable, _0);
- }
+ ZEPHIR_CONCAT_SV(sqlAlterTable, "ALTER TABLE ", _0);
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, currentColumn, "getname", NULL, 0);
@@ -53635,8 +53752,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, modifyColumn) {
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropColumn) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *columnName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *columnName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *columnName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *columnName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &columnName_param);
@@ -53676,150 +53794,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropColumn) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\" ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\" ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, " DROP COLUMN \"", columnName, "\"");
- zephir_concat_self(&sql, _0 TSRMLS_CC);
- RETURN_CCTOR(sql);
-
-}
-
-static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addIndex) {
-
- int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql, *indexType = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_4 = NULL, *_5 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_3 = NULL;
-
- ZEPHIR_MM_GROW();
- zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
-
- if (unlikely(Z_TYPE_P(tableName_param) != IS_STRING && Z_TYPE_P(tableName_param) != IS_NULL)) {
- zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'tableName' must be a string") TSRMLS_CC);
- RETURN_MM_NULL();
- }
-
- if (likely(Z_TYPE_P(tableName_param) == IS_STRING)) {
- zephir_get_strval(tableName, tableName_param);
- } else {
- ZEPHIR_INIT_VAR(tableName);
- ZVAL_EMPTY_STRING(tableName);
- }
- if (unlikely(Z_TYPE_P(schemaName_param) != IS_STRING && Z_TYPE_P(schemaName_param) != IS_NULL)) {
- zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'schemaName' must be a string") TSRMLS_CC);
- RETURN_MM_NULL();
- }
-
- if (likely(Z_TYPE_P(schemaName_param) == IS_STRING)) {
- zephir_get_strval(schemaName, schemaName_param);
- } else {
- ZEPHIR_INIT_VAR(schemaName);
- ZVAL_EMPTY_STRING(schemaName);
- }
-
-
- ZEPHIR_CALL_METHOD(&_0, index, "getname", NULL, 0);
- zephir_check_call_status();
- if (ZEPHIR_IS_STRING_IDENTICAL(_0, "PRIMARY")) {
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "addprimarykey", NULL, 0, tableName, schemaName, index);
- zephir_check_call_status();
- RETURN_MM();
- }
- ZEPHIR_INIT_VAR(sql);
- ZVAL_STRING(sql, "CREATE", 1);
- ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
- zephir_check_call_status();
- if (!(ZEPHIR_IS_EMPTY(indexType))) {
- ZEPHIR_INIT_VAR(_1);
- ZEPHIR_CONCAT_SV(_1, " ", indexType);
- zephir_concat_self(&sql, _1 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_2, index, "getname", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_1);
- ZEPHIR_CONCAT_SVS(_1, " INDEX \"", _2, "\" ON");
- zephir_concat_self(&sql, _1 TSRMLS_CC);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVSVS(_3, " \"", schemaName, "\".\"", tableName, "\"");
- zephir_concat_self(&sql, _3 TSRMLS_CC);
- } else {
- ZEPHIR_INIT_LNVAR(_3);
- ZEPHIR_CONCAT_SVS(_3, " \"", tableName, "\"");
- zephir_concat_self(&sql, _3 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 43, _5);
- zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_1);
- ZEPHIR_CONCAT_SVS(_1, " (", _4, ")");
- zephir_concat_self(&sql, _1 TSRMLS_CC);
- RETURN_CCTOR(sql);
-
-}
-
-static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropIndex) {
-
- zval *tableName_param = NULL, *schemaName_param = NULL, *indexName_param = NULL;
- zval *tableName = NULL, *schemaName = NULL, *indexName = NULL;
-
- ZEPHIR_MM_GROW();
- zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &indexName_param);
-
- if (unlikely(Z_TYPE_P(tableName_param) != IS_STRING && Z_TYPE_P(tableName_param) != IS_NULL)) {
- zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'tableName' must be a string") TSRMLS_CC);
- RETURN_MM_NULL();
- }
-
- if (likely(Z_TYPE_P(tableName_param) == IS_STRING)) {
- zephir_get_strval(tableName, tableName_param);
- } else {
- ZEPHIR_INIT_VAR(tableName);
- ZVAL_EMPTY_STRING(tableName);
- }
- if (unlikely(Z_TYPE_P(schemaName_param) != IS_STRING && Z_TYPE_P(schemaName_param) != IS_NULL)) {
- zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'schemaName' must be a string") TSRMLS_CC);
- RETURN_MM_NULL();
- }
-
- if (likely(Z_TYPE_P(schemaName_param) == IS_STRING)) {
- zephir_get_strval(schemaName, schemaName_param);
- } else {
- ZEPHIR_INIT_VAR(schemaName);
- ZVAL_EMPTY_STRING(schemaName);
- }
- if (unlikely(Z_TYPE_P(indexName_param) != IS_STRING && Z_TYPE_P(indexName_param) != IS_NULL)) {
- zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'indexName' must be a string") TSRMLS_CC);
- RETURN_MM_NULL();
- }
-
- if (likely(Z_TYPE_P(indexName_param) == IS_STRING)) {
- zephir_get_strval(indexName, indexName_param);
- } else {
- ZEPHIR_INIT_VAR(indexName);
- ZVAL_EMPTY_STRING(indexName);
- }
-
-
- ZEPHIR_CONCAT_SVS(return_value, "DROP INDEX \"", indexName, "\"");
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP COLUMN \"", columnName, "\"");
RETURN_MM();
}
-static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addPrimaryKey) {
+static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addIndex) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql = NULL, *_1 = NULL, *_2 = NULL, *_3;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql, *indexType = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
@@ -53848,31 +53834,137 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addPrimaryKey) {
}
+ ZEPHIR_CALL_METHOD(&_0, index, "getname", NULL, 0);
+ zephir_check_call_status();
+ if (ZEPHIR_IS_STRING_IDENTICAL(_0, "PRIMARY")) {
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "addprimarykey", NULL, 0, tableName, schemaName, index);
+ zephir_check_call_status();
+ RETURN_MM();
+ }
ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
+ ZVAL_STRING(sql, "CREATE", 1);
+ ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
+ zephir_check_call_status();
+ if (!(ZEPHIR_IS_EMPTY(indexType))) {
+ ZEPHIR_INIT_VAR(_1);
+ ZEPHIR_CONCAT_SV(_1, " ", indexType);
+ zephir_concat_self(&sql, _1 TSRMLS_CC);
+ }
+ ZEPHIR_CALL_METHOD(&_2, index, "getname", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_INIT_LNVAR(_1);
+ ZEPHIR_CONCAT_SVSV(_1, " INDEX \"", _2, "\" ON ", _3);
+ zephir_concat_self(&sql, _1 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 43, _5);
+ zephir_check_call_status();
+ ZEPHIR_INIT_VAR(_6);
+ ZEPHIR_CONCAT_SVS(_6, " (", _4, ")");
+ zephir_concat_self(&sql, _6 TSRMLS_CC);
+ RETURN_CCTOR(sql);
+
+}
+
+static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropIndex) {
+
+ zval *tableName_param = NULL, *schemaName_param = NULL, *indexName_param = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *indexName = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &indexName_param);
+
+ if (unlikely(Z_TYPE_P(tableName_param) != IS_STRING && Z_TYPE_P(tableName_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'tableName' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(tableName_param) == IS_STRING)) {
+ zephir_get_strval(tableName, tableName_param);
} else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
+ ZEPHIR_INIT_VAR(tableName);
+ ZVAL_EMPTY_STRING(tableName);
}
+ if (unlikely(Z_TYPE_P(schemaName_param) != IS_STRING && Z_TYPE_P(schemaName_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'schemaName' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(schemaName_param) == IS_STRING)) {
+ zephir_get_strval(schemaName, schemaName_param);
+ } else {
+ ZEPHIR_INIT_VAR(schemaName);
+ ZVAL_EMPTY_STRING(schemaName);
+ }
+ if (unlikely(Z_TYPE_P(indexName_param) != IS_STRING && Z_TYPE_P(indexName_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'indexName' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(indexName_param) == IS_STRING)) {
+ zephir_get_strval(indexName, indexName_param);
+ } else {
+ ZEPHIR_INIT_VAR(indexName);
+ ZVAL_EMPTY_STRING(indexName);
+ }
+
+
+ ZEPHIR_CONCAT_SVS(return_value, "DROP INDEX \"", indexName, "\"");
+ RETURN_MM();
+
+}
+
+static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addPrimaryKey) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *index, *_0 = NULL, *_1 = NULL, *_2 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
+
+ if (unlikely(Z_TYPE_P(tableName_param) != IS_STRING && Z_TYPE_P(tableName_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'tableName' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(tableName_param) == IS_STRING)) {
+ zephir_get_strval(tableName, tableName_param);
+ } else {
+ ZEPHIR_INIT_VAR(tableName);
+ ZVAL_EMPTY_STRING(tableName);
+ }
+ if (unlikely(Z_TYPE_P(schemaName_param) != IS_STRING && Z_TYPE_P(schemaName_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'schemaName' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(schemaName_param) == IS_STRING)) {
+ zephir_get_strval(schemaName, schemaName_param);
+ } else {
+ ZEPHIR_INIT_VAR(schemaName);
+ ZVAL_EMPTY_STRING(schemaName);
+ }
+
+
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 43, _2);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVS(_3, " ADD CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _1, ")");
- zephir_concat_self(&sql, _3 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " ADD CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _1, ")");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropPrimaryKey) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 0, &tableName_param, &schemaName_param);
@@ -53901,26 +53993,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropPrimaryKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- zephir_concat_self_str(&sql, SL(" DROP CONSTRAINT \"PRIMARY\"") TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVS(return_value, "ALTER TABLE ", _0, " DROP CONSTRAINT \"PRIMARY\"");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *reference, *sql = NULL, *onDelete = NULL, *onUpdate = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7, *_8 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *reference, *sql, *onDelete = NULL, *onUpdate = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &reference);
@@ -53949,16 +54033,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\" ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\" ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, reference, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_3, reference, "getcolumns", NULL, 0);
@@ -53971,22 +54047,21 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", NULL, 43, _6);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_7);
- ZEPHIR_CONCAT_SVSVSSVSVS(_7, "ADD CONSTRAINT \"", _1, "\" FOREIGN KEY (", _2, ")", " REFERENCES \"", _4, "\" (", _5, ")");
- zephir_concat_self(&sql, _7 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(sql);
+ ZEPHIR_CONCAT_SVSVSVSSVSVS(sql, "ALTER TABLE ", _0, " ADD CONSTRAINT \"", _1, "\" FOREIGN KEY (", _2, ")", " REFERENCES \"", _4, "\" (", _5, ")");
ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onDelete))) {
- ZEPHIR_INIT_VAR(_8);
- ZEPHIR_CONCAT_SV(_8, " ON DELETE ", onDelete);
- zephir_concat_self(&sql, _8 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_7);
+ ZEPHIR_CONCAT_SV(_7, " ON DELETE ", onDelete);
+ zephir_concat_self(&sql, _7 TSRMLS_CC);
}
ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onUpdate))) {
- ZEPHIR_INIT_LNVAR(_8);
- ZEPHIR_CONCAT_SV(_8, " ON UPDATE ", onUpdate);
- zephir_concat_self(&sql, _8 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_7);
+ ZEPHIR_CONCAT_SV(_7, " ON UPDATE ", onUpdate);
+ zephir_concat_self(&sql, _7 TSRMLS_CC);
}
RETURN_CCTOR(sql);
@@ -53994,8 +54069,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) {
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropForeignKey) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *referenceName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *referenceName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *referenceName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *referenceName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &referenceName_param);
@@ -54035,32 +54111,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropForeignKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, " DROP CONSTRAINT \"", referenceName, "\"");
- zephir_concat_self(&sql, _0 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP CONSTRAINT \"", referenceName, "\"");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) {
- zephir_fcall_cache_entry *_6 = NULL, *_9 = NULL, *_17 = NULL;
+ zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_16 = NULL;
+ HashTable *_1, *_14, *_23;
+ HashPosition _0, _13, _22;
int ZEPHIR_LAST_CALL_STATUS;
- HashTable *_2, *_15, *_24;
- HashPosition _1, _14, _23;
zval *definition = NULL;
- zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *indexSqlAfterCreate, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, *primaryColumns, **_3, *_4 = NULL, *_5 = NULL, _7 = zval_used_for_init, *_8 = NULL, *_10 = NULL, *_11 = NULL, *_12 = NULL, *_13 = NULL, **_16, *_18 = NULL, *_20 = NULL, *_21 = NULL, *_22 = NULL, **_25, *_26 = NULL, *_27;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL, *_19 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *indexSqlAfterCreate, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, *primaryColumns, **_2, *_3 = NULL, *_4 = NULL, _6 = zval_used_for_init, *_7 = NULL, *_9 = NULL, *_10 = NULL, *_11 = NULL, *_12 = NULL, **_15, *_17 = NULL, *_18 = NULL, *_19 = NULL, *_20 = NULL, *_21 = NULL, **_24, *_25 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &definition_param);
@@ -54093,19 +54159,11 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) {
ZEPHIR_OBS_VAR(columns);
if (!(zephir_array_isset_string_fetch(&columns, definition, SS("columns"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'columns' is required in the definition array", "phalcon/db/dialect/postgresql.zep", 383);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'columns' is required in the definition array", "phalcon/db/dialect/postgresql.zep", 327);
return;
}
- ZEPHIR_INIT_VAR(table);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "\"", tableName, "\"");
- ZEPHIR_CPY_WRT(table, _0);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(temporary);
ZVAL_BOOL(temporary, 0);
ZEPHIR_OBS_VAR(options);
@@ -54123,64 +54181,64 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) {
array_init(createLines);
ZEPHIR_INIT_VAR(primaryColumns);
array_init(primaryColumns);
- zephir_is_iterable(columns, &_2, &_1, 0, 0, "phalcon/db/dialect/postgresql.zep", 443);
+ zephir_is_iterable(columns, &_1, &_0, 0, 0, "phalcon/db/dialect/postgresql.zep", 383);
for (
- ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
- ; zephir_hash_move_forward_ex(_2, &_1)
+ ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
+ ; zephir_hash_move_forward_ex(_1, &_0)
) {
- ZEPHIR_GET_HVALUE(column, _3);
- ZEPHIR_CALL_METHOD(&_4, column, "getname", NULL, 0);
+ ZEPHIR_GET_HVALUE(column, _2);
+ ZEPHIR_CALL_METHOD(&_3, column, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumndefinition", &_6, 0, column);
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumndefinition", &_5, 0, column);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(columnLine);
- ZEPHIR_CONCAT_SVSV(columnLine, "\"", _4, "\" ", _5);
+ ZEPHIR_CONCAT_SVSV(columnLine, "\"", _3, "\" ", _4);
ZEPHIR_CALL_METHOD(&defaultValue, column, "getdefault", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(defaultValue))) {
- ZEPHIR_SINIT_NVAR(_7);
- ZVAL_STRING(&_7, "\"", 0);
- ZEPHIR_CALL_FUNCTION(&_8, "addcslashes", &_9, 141, defaultValue, &_7);
+ ZEPHIR_SINIT_NVAR(_6);
+ ZVAL_STRING(&_6, "\"", 0);
+ ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 141, defaultValue, &_6);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SVS(_10, " DEFAULT \"", _8, "\"");
- zephir_concat_self(&columnLine, _10 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, " DEFAULT \"", _7, "\"");
+ zephir_concat_self(&columnLine, _9 TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isnotnull", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isnotnull", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
zephir_concat_self_str(&columnLine, SL(" NOT NULL") TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isautoincrement", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isautoincrement", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
}
- ZEPHIR_CALL_METHOD(&_11, column, "isprimary", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_10, column, "isprimary", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_11)) {
- ZEPHIR_CALL_METHOD(&_12, column, "getname", NULL, 0);
+ if (zephir_is_true(_10)) {
+ ZEPHIR_CALL_METHOD(&_11, column, "getname", NULL, 0);
zephir_check_call_status();
- zephir_array_append(&primaryColumns, _12, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 438);
+ zephir_array_append(&primaryColumns, _11, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 378);
}
- zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 441);
+ zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 381);
}
if (!(ZEPHIR_IS_EMPTY(primaryColumns))) {
- ZEPHIR_INIT_VAR(_13);
- zephir_fast_join_str(_13, SL(","), primaryColumns TSRMLS_CC);
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SVS(_10, "PRIMARY KEY (", _13, ")");
- zephir_array_append(&createLines, _10, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 444);
+ ZEPHIR_INIT_VAR(_12);
+ zephir_fast_join_str(_12, SL(","), primaryColumns TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, "PRIMARY KEY (", _12, ")");
+ zephir_array_append(&createLines, _9, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 384);
}
ZEPHIR_INIT_VAR(indexSqlAfterCreate);
ZVAL_STRING(indexSqlAfterCreate, "", 1);
ZEPHIR_OBS_VAR(indexes);
if (zephir_array_isset_string_fetch(&indexes, definition, SS("indexes"), 0 TSRMLS_CC)) {
- zephir_is_iterable(indexes, &_15, &_14, 0, 0, "phalcon/db/dialect/postgresql.zep", 484);
+ zephir_is_iterable(indexes, &_14, &_13, 0, 0, "phalcon/db/dialect/postgresql.zep", 418);
for (
- ; zephir_hash_get_current_data_ex(_15, (void**) &_16, &_14) == SUCCESS
- ; zephir_hash_move_forward_ex(_15, &_14)
+ ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS
+ ; zephir_hash_move_forward_ex(_14, &_13)
) {
- ZEPHIR_GET_HVALUE(index, _16);
+ ZEPHIR_GET_HVALUE(index, _15);
ZEPHIR_CALL_METHOD(&indexName, index, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
@@ -54188,126 +54246,112 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) {
ZEPHIR_INIT_NVAR(indexSql);
ZVAL_STRING(indexSql, "", 1);
if (ZEPHIR_IS_STRING(indexName, "PRIMARY")) {
- ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_17, 43, _5);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_16, 43, _4);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(indexSql);
- ZEPHIR_CONCAT_SVS(indexSql, "CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _4, ")");
+ ZEPHIR_CONCAT_SVS(indexSql, "CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _3, ")");
} else {
if (!(ZEPHIR_IS_EMPTY(indexType))) {
- ZEPHIR_CALL_METHOD(&_11, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_10, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, this_ptr, "getcolumnlist", &_17, 43, _11);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_16, 43, _10);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(indexSql);
- ZEPHIR_CONCAT_SVSVSVS(indexSql, "CONSTRAINT \"", indexName, "\" ", indexType, " (", _8, ")");
+ ZEPHIR_CONCAT_SVSVSVS(indexSql, "CONSTRAINT \"", indexName, "\" ", indexType, " (", _7, ")");
} else {
- ZEPHIR_CALL_METHOD(&_12, index, "getname", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_11, index, "getname", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_17, this_ptr, "preparetable", NULL, 143, tableName, schemaName);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_18);
- ZEPHIR_CONCAT_SVS(_18, "CREATE INDEX \"", _12, "\" ON ");
+ ZEPHIR_CONCAT_SVSV(_18, "CREATE INDEX \"", _11, "\" ON ", _17);
zephir_concat_self(&indexSqlAfterCreate, _18 TSRMLS_CC);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", tableName, "\"");
- zephir_concat_self(&indexSqlAfterCreate, _0 TSRMLS_CC);
- } else {
- ZEPHIR_INIT_LNVAR(_19);
- ZEPHIR_CONCAT_SVS(_19, "\"", tableName, "\"");
- zephir_concat_self(&indexSqlAfterCreate, _19 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_21, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_20, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_20, this_ptr, "getcolumnlist", &_17, 43, _21);
+ ZEPHIR_CALL_METHOD(&_19, this_ptr, "getcolumnlist", &_16, 43, _20);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_22);
- ZEPHIR_CONCAT_SVS(_22, " (", _20, ");");
- zephir_concat_self(&indexSqlAfterCreate, _22 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_21);
+ ZEPHIR_CONCAT_SVS(_21, " (", _19, ");");
+ zephir_concat_self(&indexSqlAfterCreate, _21 TSRMLS_CC);
}
}
if (!(ZEPHIR_IS_EMPTY(indexSql))) {
- zephir_array_append(&createLines, indexSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 481);
+ zephir_array_append(&createLines, indexSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 415);
}
}
}
ZEPHIR_OBS_VAR(references);
if (zephir_array_isset_string_fetch(&references, definition, SS("references"), 0 TSRMLS_CC)) {
- zephir_is_iterable(references, &_24, &_23, 0, 0, "phalcon/db/dialect/postgresql.zep", 513);
+ zephir_is_iterable(references, &_23, &_22, 0, 0, "phalcon/db/dialect/postgresql.zep", 443);
for (
- ; zephir_hash_get_current_data_ex(_24, (void**) &_25, &_23) == SUCCESS
- ; zephir_hash_move_forward_ex(_24, &_23)
+ ; zephir_hash_get_current_data_ex(_23, (void**) &_24, &_22) == SUCCESS
+ ; zephir_hash_move_forward_ex(_23, &_22)
) {
- ZEPHIR_GET_HVALUE(reference, _25);
- ZEPHIR_CALL_METHOD(&_4, reference, "getname", NULL, 0);
+ ZEPHIR_GET_HVALUE(reference, _24);
+ ZEPHIR_CALL_METHOD(&_3, reference, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, reference, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, reference, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", &_17, 43, _8);
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_16, 43, _7);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(referenceSql);
- ZEPHIR_CONCAT_SVSVS(referenceSql, "CONSTRAINT \"", _4, "\" FOREIGN KEY (", _5, ") REFERENCES ");
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_CALL_METHOD(&_11, reference, "getreferencedtable", NULL, 0);
- zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SVSVS(_10, "\"", schemaName, "\".\"", _11, "\" ");
- zephir_concat_self(&referenceSql, _10 TSRMLS_CC);
- } else {
- ZEPHIR_CALL_METHOD(&_12, reference, "getreferencedtable", NULL, 0);
- zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_18);
- ZEPHIR_CONCAT_SVS(_18, "\"", _12, "\" ");
- zephir_concat_self(&referenceSql, _18 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_21, reference, "getreferencedcolumns", NULL, 0);
+ ZEPHIR_CONCAT_SVSVS(referenceSql, "CONSTRAINT \"", _3, "\" FOREIGN KEY (", _4, ") REFERENCES ");
+ ZEPHIR_CALL_METHOD(&_11, reference, "getreferencedtable", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_10, this_ptr, "preparetable", NULL, 143, _11, schemaName);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_20, this_ptr, "getcolumnlist", &_17, 43, _21);
+ zephir_concat_self(&referenceSql, _10 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_19, reference, "getreferencedcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_22);
- ZEPHIR_CONCAT_SVS(_22, "(", _20, ")");
- zephir_concat_self(&referenceSql, _22 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_17, this_ptr, "getcolumnlist", &_16, 43, _19);
+ zephir_check_call_status();
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, " (", _17, ")");
+ zephir_concat_self(&referenceSql, _9 TSRMLS_CC);
ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onDelete))) {
- ZEPHIR_INIT_LNVAR(_26);
- ZEPHIR_CONCAT_SV(_26, " ON DELETE ", onDelete);
- zephir_concat_self(&referenceSql, _26 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_18);
+ ZEPHIR_CONCAT_SV(_18, " ON DELETE ", onDelete);
+ zephir_concat_self(&referenceSql, _18 TSRMLS_CC);
}
ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onUpdate))) {
- ZEPHIR_INIT_LNVAR(_26);
- ZEPHIR_CONCAT_SV(_26, " ON UPDATE ", onUpdate);
- zephir_concat_self(&referenceSql, _26 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_21);
+ ZEPHIR_CONCAT_SV(_21, " ON UPDATE ", onUpdate);
+ zephir_concat_self(&referenceSql, _21 TSRMLS_CC);
}
- zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 511);
+ zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 441);
}
}
- ZEPHIR_INIT_NVAR(_13);
- zephir_fast_join_str(_13, SL(",\n\t"), createLines TSRMLS_CC);
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_VS(_10, _13, "\n)");
- zephir_concat_self(&sql, _10 TSRMLS_CC);
+ ZEPHIR_INIT_NVAR(_12);
+ zephir_fast_join_str(_12, SL(",\n\t"), createLines TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_VS(_9, _12, "\n)");
+ zephir_concat_self(&sql, _9 TSRMLS_CC);
if (zephir_array_isset_string(definition, SS("options"))) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "_gettableoptions", NULL, 0, definition);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_gettableoptions", NULL, 0, definition);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_26);
- ZEPHIR_CONCAT_SV(_26, " ", _4);
- zephir_concat_self(&sql, _26 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_25);
+ ZEPHIR_CONCAT_SV(_25, " ", _3);
+ zephir_concat_self(&sql, _25 TSRMLS_CC);
}
- ZEPHIR_INIT_VAR(_27);
- ZEPHIR_CONCAT_SV(_27, ";", indexSqlAfterCreate);
- zephir_concat_self(&sql, _27 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_25);
+ ZEPHIR_CONCAT_SV(_25, ";", indexSqlAfterCreate);
+ zephir_concat_self(&sql, _25 TSRMLS_CC);
RETURN_CCTOR(sql);
}
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropTable) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *table = NULL, *sql;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &tableName_param, &schemaName_param, &ifExists_param);
@@ -54341,21 +54385,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropTable) {
}
- ZEPHIR_INIT_VAR(table);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "\"", tableName, "\"");
- ZEPHIR_CPY_WRT(table, _0);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
- ZEPHIR_CONCAT_SVS(sql, "DROP TABLE IF EXISTS \"", table, "\"");
+ ZEPHIR_CONCAT_SV(sql, "DROP TABLE IF EXISTS ", table);
} else {
- ZEPHIR_CONCAT_SVS(sql, "DROP TABLE \"", table, "\"");
+ ZEPHIR_CONCAT_SV(sql, "DROP TABLE ", table);
}
RETURN_CCTOR(sql);
@@ -54363,9 +54399,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropTable) {
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zval *definition = NULL;
- zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *view = NULL;
- zval *viewName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *_0 = NULL;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 1, &viewName_param, &definition_param, &schemaName_param);
@@ -54393,29 +54430,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createView) {
ZEPHIR_OBS_VAR(viewSql);
if (!(zephir_array_isset_string_fetch(&viewSql, definition, SS("sql"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/postgresql.zep", 554);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/postgresql.zep", 480);
return;
}
- ZEPHIR_INIT_VAR(view);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", viewName, "\"");
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "\"", viewName, "\"");
- ZEPHIR_CPY_WRT(view, _0);
- }
- ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", view, " AS ", viewSql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", _0, " AS ", viewSql);
RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *view = NULL, *sql;
- zval *viewName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &viewName_param, &schemaName_param, &ifExists_param);
@@ -54449,21 +54479,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropView) {
}
- ZEPHIR_INIT_VAR(view);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", viewName, "\"");
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "\"", viewName, "\"");
- ZEPHIR_CPY_WRT(view, _0);
- }
+ ZEPHIR_CALL_METHOD(&view, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
- ZEPHIR_CONCAT_SVS(sql, "DROP VIEW IF EXISTS ", view, "");
+ ZEPHIR_CONCAT_SV(sql, "DROP VIEW IF EXISTS ", view);
} else {
- ZEPHIR_CONCAT_SVS(sql, "DROP VIEW ", view, "");
+ ZEPHIR_CONCAT_SV(sql, "DROP VIEW ", view);
}
RETURN_CCTOR(sql);
@@ -54904,8 +54926,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, getColumnDefinition) {
static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addColumn) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *sql = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *sql, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &column);
@@ -54934,16 +54956,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addColumn) {
}
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\" ADD COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\" ADD COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CONCAT_SVS(sql, "ALTER TABLE ", _0, " ADD COLUMN ");
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumndefinition", NULL, 0, column);
@@ -55011,7 +55027,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, modifyColumn) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Altering a DB column is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 169);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Altering a DB column is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 165);
return;
}
@@ -55059,7 +55075,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropColumn) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Dropping DB column is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 177);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Dropping DB column is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 173);
return;
}
@@ -55213,7 +55229,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addPrimaryKey) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Adding a primary key after table has been created is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 221);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Adding a primary key after table has been created is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 217);
return;
}
@@ -55250,7 +55266,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropPrimaryKey) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Removing a primary key after table has been created is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 229);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Removing a primary key after table has been created is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 225);
return;
}
@@ -55287,7 +55303,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addForeignKey) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Adding a foreign key constraint to an existing table is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 237);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Adding a foreign key constraint to an existing table is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 233);
return;
}
@@ -55335,7 +55351,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropForeignKey) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Dropping a foreign key constraint is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 245);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Dropping a foreign key constraint is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 241);
return;
}
@@ -55375,16 +55391,17 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, createTable) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Not implemented yet", "phalcon/db/dialect/sqlite.zep", 253);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Not implemented yet", "phalcon/db/dialect/sqlite.zep", 249);
return;
}
static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropTable) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *sql, *table = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &tableName_param, &schemaName_param, &ifExists_param);
@@ -55418,18 +55435,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropTable) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_VSV(_0, schemaName, "\".\"", tableName);
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_CPY_WRT(table, tableName);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
- ZEPHIR_CONCAT_SVS(sql, "DROP TABLE IF EXISTS \"", table, "\"");
+ ZEPHIR_CONCAT_SV(sql, "DROP TABLE IF EXISTS ", table);
} else {
- ZEPHIR_CONCAT_SVS(sql, "DROP TABLE \"", table, "\"");
+ ZEPHIR_CONCAT_SV(sql, "DROP TABLE ", table);
}
RETURN_CCTOR(sql);
@@ -55437,9 +55449,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropTable) {
static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, createView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zval *definition = NULL;
- zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *view = NULL, *viewSql;
- zval *viewName = NULL, *schemaName = NULL, *_0;
+ zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *_0 = NULL;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 1, &viewName_param, &definition_param, &schemaName_param);
@@ -55467,26 +55480,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, createView) {
ZEPHIR_OBS_VAR(viewSql);
if (!(zephir_array_isset_string_fetch(&viewSql, definition, SS("sql"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/sqlite.zep", 286);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/sqlite.zep", 278);
return;
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_VSV(_0, schemaName, "\".\"", viewName);
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_CPY_WRT(view, viewName);
- }
- ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW \"", view, "\" AS ", viewSql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", _0, " AS ", viewSql);
RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *view = NULL;
- zval *viewName = NULL, *schemaName = NULL, *_0;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &viewName_param, &schemaName_param, &ifExists_param);
@@ -55520,18 +55529,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropView) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_VSV(_0, schemaName, "\".\"", viewName);
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_CPY_WRT(view, viewName);
- }
+ ZEPHIR_CALL_METHOD(&view, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
if (ifExists) {
- ZEPHIR_CONCAT_SVS(return_value, "DROP VIEW IF EXISTS \"", view, "\"");
+ ZEPHIR_CONCAT_SV(return_value, "DROP VIEW IF EXISTS ", view);
RETURN_MM();
}
- ZEPHIR_CONCAT_SVS(return_value, "DROP VIEW \"", view, "\"");
+ ZEPHIR_CONCAT_SV(return_value, "DROP VIEW ", view);
RETURN_MM();
}
@@ -56421,7 +56425,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, all) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "variables", 1);
zephir_array_fast_append(_0, _1);
- ZEPHIR_CALL_FUNCTION(&_2, "func_get_args", NULL, 165);
+ ZEPHIR_CALL_FUNCTION(&_2, "func_get_args", NULL, 166);
zephir_check_call_status();
ZEPHIR_CALL_USER_FUNC_ARRAY(return_value, _0, _2);
zephir_check_call_status();
@@ -56621,7 +56625,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, (tab + 1));
- ZEPHIR_CALL_METHOD(&_18, this_ptr, "output", &_19, 166, value, _3, &_5);
+ ZEPHIR_CALL_METHOD(&_18, this_ptr, "output", &_19, 167, value, _3, &_5);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_20);
@@ -56653,7 +56657,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
zephir_concat_self(&output, _2 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_13, "get_parent_class", &_21, 167, variable);
+ ZEPHIR_CALL_FUNCTION(&_13, "get_parent_class", &_21, 168, variable);
zephir_check_call_status();
if (zephir_is_true(_13)) {
ZEPHIR_INIT_NVAR(_12);
@@ -56664,7 +56668,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_check_temp_parameter(_3);
zephir_check_call_status();
zephir_array_update_string(&_12, SL(":style"), &_18, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_FUNCTION(&_18, "get_parent_class", &_21, 167, variable);
+ ZEPHIR_CALL_FUNCTION(&_18, "get_parent_class", &_21, 168, variable);
zephir_check_call_status();
zephir_array_update_string(&_12, SL(":parent"), &_18, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
@@ -56710,7 +56714,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, (tab + 1));
- ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 166, value, _3, &_5);
+ ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 167, value, _3, &_5);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_20);
@@ -56720,7 +56724,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
} else {
do {
Z_SET_ISREF_P(variable);
- ZEPHIR_CALL_FUNCTION(&attr, "each", &_28, 168, variable);
+ ZEPHIR_CALL_FUNCTION(&attr, "each", &_28, 169, variable);
Z_UNSET_ISREF_P(variable);
zephir_check_call_status();
if (!(zephir_is_true(attr))) {
@@ -56766,7 +56770,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_check_call_status();
zephir_array_update_string(&_12, SL(":style"), &_26, PH_COPY | PH_SEPARATE);
Z_SET_ISREF_P(key);
- ZEPHIR_CALL_FUNCTION(&_26, "end", &_32, 169, key);
+ ZEPHIR_CALL_FUNCTION(&_26, "end", &_32, 170, key);
Z_UNSET_ISREF_P(key);
zephir_check_call_status();
zephir_array_update_string(&_12, SL(":key"), &_26, PH_COPY | PH_SEPARATE);
@@ -56782,7 +56786,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, (tab + 1));
- ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 166, value, _3, &_5);
+ ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 167, value, _3, &_5);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_20);
@@ -56790,7 +56794,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_concat_self(&output, _20 TSRMLS_CC);
} while (zephir_is_true(attr));
}
- ZEPHIR_CALL_FUNCTION(&attr, "get_class_methods", NULL, 170, variable);
+ ZEPHIR_CALL_FUNCTION(&attr, "get_class_methods", NULL, 171, variable);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, tab);
@@ -56907,11 +56911,12 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Integer (:var)", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
- ZEPHIR_CALL_FUNCTION(&_2, "is_float", NULL, 171, variable);
+ ZEPHIR_CALL_FUNCTION(&_2, "is_float", NULL, 172, variable);
zephir_check_call_status();
if (zephir_is_true(_2)) {
ZEPHIR_INIT_NVAR(_1);
@@ -56925,8 +56930,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Float (:var)", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _13);
RETURN_MM();
}
if (zephir_is_numeric(variable)) {
@@ -56942,8 +56948,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Numeric string (:length) \":var\"", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
if (Z_TYPE_P(variable) == IS_STRING) {
@@ -56960,15 +56967,16 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
ZVAL_LONG(&_5, 4);
ZEPHIR_SINIT_VAR(_40);
ZVAL_STRING(&_40, "utf-8", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "htmlentities", NULL, 150, variable, &_5, &_40);
+ ZEPHIR_CALL_FUNCTION(&_2, "htmlentities", NULL, 151, variable, &_5, &_40);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_13, "nl2br", NULL, 172, _2);
+ ZEPHIR_CALL_FUNCTION(&_26, "nl2br", NULL, 173, _2);
zephir_check_call_status();
- zephir_array_update_string(&_1, SL(":var"), &_13, PH_COPY | PH_SEPARATE);
+ zephir_array_update_string(&_1, SL(":var"), &_26, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "String (:length) \":var\"", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _26);
RETURN_MM();
}
if (Z_TYPE_P(variable) == IS_BOOL) {
@@ -56991,8 +56999,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &_14, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Boolean (:var)", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
if (Z_TYPE_P(variable) == IS_NULL) {
@@ -57006,8 +57015,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":style"), &_2, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "NULL", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
ZEPHIR_INIT_NVAR(_1);
@@ -57021,8 +57031,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "(:var)", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
@@ -57076,7 +57087,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, variables) {
ZEPHIR_INIT_VAR(output);
ZVAL_STRING(output, "", 1);
- ZEPHIR_CALL_FUNCTION(&_0, "func_get_args", NULL, 165);
+ ZEPHIR_CALL_FUNCTION(&_0, "func_get_args", NULL, 166);
zephir_check_call_status();
zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/debug/dump.zep", 290);
for (
@@ -57835,7 +57846,7 @@ static PHP_METHOD(Phalcon_Di_Service, resolve) {
ZEPHIR_CALL_METHOD(NULL, builder, "__construct", NULL, 0);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&instance, builder, "build", NULL, 174, dependencyInjector, definition, parameters);
+ ZEPHIR_CALL_METHOD(&instance, builder, "build", NULL, 175, dependencyInjector, definition, parameters);
zephir_check_call_status();
} else {
found = 0;
@@ -58031,7 +58042,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_cli_ce, this_ptr, "__construct", &_0, 173);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_cli_ce, this_ptr, "__construct", &_0, 174);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_1);
zephir_create_array(_1, 10, 0 TSRMLS_CC);
@@ -58333,7 +58344,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, _buildParameters) {
) {
ZEPHIR_GET_HMKEY(position, _1, _0);
ZEPHIR_GET_HVALUE(argument, _2);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_buildparameter", &_4, 175, dependencyInjector, position, argument);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_buildparameter", &_4, 176, dependencyInjector, position, argument);
zephir_check_call_status();
zephir_array_append(&buildArguments, _3, PH_SEPARATE, "phalcon/di/service/builder.zep", 117);
}
@@ -58378,7 +58389,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) {
} else {
ZEPHIR_OBS_VAR(arguments);
if (zephir_array_isset_string_fetch(&arguments, definition, SS("arguments"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 176, dependencyInjector, arguments);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 177, dependencyInjector, arguments);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(instance);
ZEPHIR_LAST_CALL_STATUS = zephir_create_instance_params(instance, className, _0 TSRMLS_CC);
@@ -58448,7 +58459,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) {
}
if (zephir_fast_count_int(arguments TSRMLS_CC)) {
ZEPHIR_INIT_NVAR(_5);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 176, dependencyInjector, arguments);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 177, dependencyInjector, arguments);
zephir_check_call_status();
ZEPHIR_CALL_USER_FUNC_ARRAY(_5, methodCall, _0);
zephir_check_call_status();
@@ -58512,7 +58523,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) {
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameter", &_12, 175, dependencyInjector, propertyPosition, propertyValue);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameter", &_12, 176, dependencyInjector, propertyPosition, propertyValue);
zephir_check_call_status();
zephir_update_property_zval_zval(instance, propertyName, _0 TSRMLS_CC);
}
@@ -58816,7 +58827,7 @@ static PHP_METHOD(Phalcon_Events_Manager, attach) {
}
ZEPHIR_INIT_VAR(_2);
ZVAL_LONG(_2, 1);
- ZEPHIR_CALL_METHOD(NULL, priorityQueue, "setextractflags", NULL, 183, _2);
+ ZEPHIR_CALL_METHOD(NULL, priorityQueue, "setextractflags", NULL, 184, _2);
zephir_check_call_status();
zephir_update_property_array(this_ptr, SL("_events"), eventType, priorityQueue TSRMLS_CC);
} else {
@@ -58826,7 +58837,7 @@ static PHP_METHOD(Phalcon_Events_Manager, attach) {
if (Z_TYPE_P(priorityQueue) == IS_OBJECT) {
ZEPHIR_INIT_NVAR(_2);
ZVAL_LONG(_2, priority);
- ZEPHIR_CALL_METHOD(NULL, priorityQueue, "insert", NULL, 184, handler, _2);
+ ZEPHIR_CALL_METHOD(NULL, priorityQueue, "insert", NULL, 185, handler, _2);
zephir_check_call_status();
} else {
zephir_array_append(&priorityQueue, handler, PH_SEPARATE, "phalcon/events/manager.zep", 82);
@@ -58875,7 +58886,7 @@ static PHP_METHOD(Phalcon_Events_Manager, detach) {
}
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, 1);
- ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "setextractflags", NULL, 183, _1);
+ ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "setextractflags", NULL, 184, _1);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_1);
ZVAL_LONG(_1, 3);
@@ -58897,13 +58908,13 @@ static PHP_METHOD(Phalcon_Events_Manager, detach) {
if (!ZEPHIR_IS_IDENTICAL(_5, handler)) {
zephir_array_fetch_string(&_6, data, SL("data"), PH_NOISY | PH_READONLY, "phalcon/events/manager.zep", 117 TSRMLS_CC);
zephir_array_fetch_string(&_7, data, SL("priority"), PH_NOISY | PH_READONLY, "phalcon/events/manager.zep", 117 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "insert", &_8, 184, _6, _7);
+ ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "insert", &_8, 185, _6, _7);
zephir_check_call_status();
}
}
zephir_update_property_array(this_ptr, SL("_events"), eventType, newPriorityQueue TSRMLS_CC);
} else {
- ZEPHIR_CALL_FUNCTION(&key, "array_search", NULL, 185, handler, priorityQueue, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(&key, "array_search", NULL, 186, handler, priorityQueue, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
if (!ZEPHIR_IS_FALSE_IDENTICAL(key)) {
zephir_array_unset(&priorityQueue, key, PH_SEPARATE);
@@ -59059,7 +59070,7 @@ static PHP_METHOD(Phalcon_Events_Manager, fireQueue) {
zephir_get_class(_1, queue, 0 TSRMLS_CC);
ZEPHIR_SINIT_VAR(_2);
ZVAL_STRING(&_2, "Unexpected value type: expected object of type SplPriorityQueue, %s given", 0);
- ZEPHIR_CALL_FUNCTION(&_3, "sprintf", NULL, 186, &_2, _1);
+ ZEPHIR_CALL_FUNCTION(&_3, "sprintf", NULL, 187, &_2, _1);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3);
zephir_check_call_status();
@@ -59272,9 +59283,9 @@ static PHP_METHOD(Phalcon_Events_Manager, fire) {
if (_3) {
ZEPHIR_INIT_NVAR(event);
object_init_ex(event, phalcon_events_event_ce);
- ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 187, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 188, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 188, fireEvents, event);
+ ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 189, fireEvents, event);
zephir_check_call_status();
}
}
@@ -59288,10 +59299,10 @@ static PHP_METHOD(Phalcon_Events_Manager, fire) {
if (Z_TYPE_P(event) == IS_NULL) {
ZEPHIR_INIT_NVAR(event);
object_init_ex(event, phalcon_events_event_ce);
- ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 187, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 188, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 188, fireEvents, event);
+ ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 189, fireEvents, event);
zephir_check_call_status();
}
}
@@ -59504,7 +59515,7 @@ static PHP_METHOD(Phalcon_Flash_Direct, output) {
}
}
if (remove) {
- ZEPHIR_CALL_PARENT(NULL, phalcon_flash_direct_ce, this_ptr, "clear", &_3, 195);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_flash_direct_ce, this_ptr, "clear", &_3, 196);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -59777,7 +59788,7 @@ static PHP_METHOD(Phalcon_Flash_Session, output) {
zephir_check_call_status();
}
}
- ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_4, 195);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_4, 196);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -59795,7 +59806,7 @@ static PHP_METHOD(Phalcon_Flash_Session, clear) {
ZVAL_BOOL(_0, 1);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "_getsessionmessages", NULL, 0, _0);
zephir_check_call_status();
- ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_1, 195);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_1, 196);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -60921,7 +60932,7 @@ static PHP_METHOD(Phalcon_Forms_Form, isValid) {
} else {
ZEPHIR_INIT_NVAR(validation);
object_init_ex(validation, phalcon_validation_ce);
- ZEPHIR_CALL_METHOD(NULL, validation, "__construct", &_11, 209, preparedValidators);
+ ZEPHIR_CALL_METHOD(NULL, validation, "__construct", &_11, 210, preparedValidators);
zephir_check_call_status();
}
ZEPHIR_CALL_METHOD(&filters, element, "getfilters", NULL, 0);
@@ -60929,10 +60940,10 @@ static PHP_METHOD(Phalcon_Forms_Form, isValid) {
if (Z_TYPE_P(filters) == IS_ARRAY) {
ZEPHIR_CALL_METHOD(&_2, element, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, validation, "setfilters", &_12, 210, _2, filters);
+ ZEPHIR_CALL_METHOD(NULL, validation, "setfilters", &_12, 211, _2, filters);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&elementMessages, validation, "validate", &_13, 211, data, entity);
+ ZEPHIR_CALL_METHOD(&elementMessages, validation, "validate", &_13, 212, data, entity);
zephir_check_call_status();
if (zephir_fast_count_int(elementMessages TSRMLS_CC)) {
ZEPHIR_CALL_METHOD(&_14, element, "getname", NULL, 0);
@@ -60995,7 +61006,7 @@ static PHP_METHOD(Phalcon_Forms_Form, getMessages) {
; zephir_hash_move_forward_ex(_2, &_1)
) {
ZEPHIR_GET_HVALUE(elementMessages, _3);
- ZEPHIR_CALL_METHOD(NULL, group, "appendmessages", &_4, 212, elementMessages);
+ ZEPHIR_CALL_METHOD(NULL, group, "appendmessages", &_4, 213, elementMessages);
zephir_check_call_status();
}
}
@@ -61465,7 +61476,7 @@ static PHP_METHOD(Phalcon_Forms_Form, rewind) {
ZVAL_LONG(_0, 0);
zephir_update_property_this(this_ptr, SL("_position"), _0 TSRMLS_CC);
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_elements"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_1, "array_values", NULL, 213, _0);
+ ZEPHIR_CALL_FUNCTION(&_1, "array_values", NULL, 214, _0);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_elementsIndexed"), _1 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -61557,7 +61568,7 @@ static PHP_METHOD(Phalcon_Forms_Manager, create) {
}
ZEPHIR_INIT_VAR(form);
object_init_ex(form, phalcon_forms_form_ce);
- ZEPHIR_CALL_METHOD(NULL, form, "__construct", NULL, 214, entity);
+ ZEPHIR_CALL_METHOD(NULL, form, "__construct", NULL, 215, entity);
zephir_check_call_status();
zephir_update_property_array(this_ptr, SL("_forms"), name, form TSRMLS_CC);
RETURN_CCTOR(form);
@@ -61666,7 +61677,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Check, render) {
ZVAL_BOOL(_2, 1);
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes, _2);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "checkfield", &_0, 196, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "checkfield", &_0, 197, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61711,7 +61722,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Date, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "datefield", &_0, 197, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "datefield", &_0, 198, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61756,7 +61767,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Email, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "emailfield", &_0, 198, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "emailfield", &_0, 199, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61801,7 +61812,7 @@ static PHP_METHOD(Phalcon_Forms_Element_File, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "filefield", &_0, 199, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "filefield", &_0, 200, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61846,7 +61857,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Hidden, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "hiddenfield", &_0, 200, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "hiddenfield", &_0, 201, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61891,7 +61902,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Numeric, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "numericfield", &_0, 201, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "numericfield", &_0, 202, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61936,7 +61947,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Password, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "passwordfield", &_0, 202, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "passwordfield", &_0, 203, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61983,7 +61994,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Radio, render) {
ZVAL_BOOL(_2, 1);
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes, _2);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "radiofield", &_0, 203, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "radiofield", &_0, 204, _1);
zephir_check_call_status();
RETURN_MM();
@@ -62034,7 +62045,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Select, __construct) {
zephir_update_property_this(this_ptr, SL("_optionsValues"), options TSRMLS_CC);
- ZEPHIR_CALL_PARENT(NULL, phalcon_forms_element_select_ce, this_ptr, "__construct", &_0, 204, name, attributes);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_forms_element_select_ce, this_ptr, "__construct", &_0, 205, name, attributes);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -62090,7 +62101,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Select, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
_2 = zephir_fetch_nproperty_this(this_ptr, SL("_optionsValues"), PH_NOISY_CC);
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 205, _1, _2);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, _1, _2);
zephir_check_call_status();
RETURN_MM();
@@ -62135,7 +62146,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Submit, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "submitbutton", &_0, 206, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "submitbutton", &_0, 207, _1);
zephir_check_call_status();
RETURN_MM();
@@ -62180,7 +62191,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Text, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textfield", &_0, 207, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textfield", &_0, 208, _1);
zephir_check_call_status();
RETURN_MM();
@@ -62225,7 +62236,7 @@ static PHP_METHOD(Phalcon_Forms_Element_TextArea, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textarea", &_0, 208, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textarea", &_0, 209, _1);
zephir_check_call_status();
RETURN_MM();
@@ -62532,7 +62543,7 @@ static PHP_METHOD(Phalcon_Http_Cookie, send) {
} else {
ZEPHIR_CPY_WRT(encryptValue, value);
}
- ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 215, name, encryptValue, expire, path, domain, secure, httpOnly);
+ ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 216, name, encryptValue, expire, path, domain, secure, httpOnly);
zephir_check_call_status();
RETURN_THIS();
@@ -62620,7 +62631,7 @@ static PHP_METHOD(Phalcon_Http_Cookie, delete) {
zephir_time(_2);
ZEPHIR_SINIT_VAR(_4);
ZVAL_LONG(&_4, (zephir_get_numberval(_2) - 691200));
- ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 215, name, ZEPHIR_GLOBAL(global_null), &_4, path, domain, secure, httpOnly);
+ ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 216, name, ZEPHIR_GLOBAL(global_null), &_4, path, domain, secure, httpOnly);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -62977,7 +62988,7 @@ static PHP_METHOD(Phalcon_Http_Request, get) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 216, _REQUEST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _REQUEST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -63028,7 +63039,7 @@ static PHP_METHOD(Phalcon_Http_Request, getPost) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 216, _POST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _POST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -63038,7 +63049,7 @@ static PHP_METHOD(Phalcon_Http_Request, getPut) {
int ZEPHIR_LAST_CALL_STATUS;
zend_bool notAllowEmpty, noRecursive;
- zval *name_param = NULL, *filters = NULL, *defaultValue = NULL, *notAllowEmpty_param = NULL, *noRecursive_param = NULL, *put = NULL, *_0, _1;
+ zval *name_param = NULL, *filters = NULL, *defaultValue = NULL, *notAllowEmpty_param = NULL, *noRecursive_param = NULL, *put = NULL, *_0 = NULL;
zval *name = NULL;
ZEPHIR_MM_GROW();
@@ -63083,17 +63094,15 @@ static PHP_METHOD(Phalcon_Http_Request, getPut) {
if (Z_TYPE_P(put) != IS_ARRAY) {
ZEPHIR_INIT_NVAR(put);
array_init(put);
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_SINIT_VAR(_1);
- ZVAL_STRING(&_1, "php://input", 0);
- zephir_file_get_contents(_0, &_1 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getrawbody", NULL, 0);
+ zephir_check_call_status();
Z_SET_ISREF_P(put);
- ZEPHIR_CALL_FUNCTION(NULL, "parse_str", NULL, 217, _0, put);
+ ZEPHIR_CALL_FUNCTION(NULL, "parse_str", NULL, 218, _0, put);
Z_UNSET_ISREF_P(put);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_putCache"), put TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 216, put, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, put, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -63144,7 +63153,7 @@ static PHP_METHOD(Phalcon_Http_Request, getQuery) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 216, _GET, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _GET, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -63581,7 +63590,7 @@ static PHP_METHOD(Phalcon_Http_Request, getServerAddress) {
}
ZEPHIR_SINIT_VAR(_0);
ZVAL_STRING(&_0, "localhost", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("gethostbyname", NULL, 218, &_0);
+ ZEPHIR_RETURN_CALL_FUNCTION("gethostbyname", NULL, 219, &_0);
zephir_check_call_status();
RETURN_MM();
@@ -63772,7 +63781,7 @@ static PHP_METHOD(Phalcon_Http_Request, isMethod) {
}
- ZEPHIR_CALL_METHOD(&httpMethod, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&httpMethod, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
if (Z_TYPE_P(methods) == IS_STRING) {
_0 = strict;
@@ -63844,7 +63853,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPost) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "POST"));
@@ -63857,7 +63866,7 @@ static PHP_METHOD(Phalcon_Http_Request, isGet) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "GET"));
@@ -63870,7 +63879,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPut) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "PUT"));
@@ -63883,7 +63892,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPatch) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "PATCH"));
@@ -63896,7 +63905,7 @@ static PHP_METHOD(Phalcon_Http_Request, isHead) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "HEAD"));
@@ -63909,7 +63918,7 @@ static PHP_METHOD(Phalcon_Http_Request, isDelete) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "DELETE"));
@@ -63922,7 +63931,7 @@ static PHP_METHOD(Phalcon_Http_Request, isOptions) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "OPTIONS"));
@@ -63970,7 +63979,7 @@ static PHP_METHOD(Phalcon_Http_Request, hasFiles) {
}
}
if (Z_TYPE_P(error) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 220, error, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 221, error, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
numberFiles += zephir_get_numberval(_4);
}
@@ -64014,7 +64023,7 @@ static PHP_METHOD(Phalcon_Http_Request, hasFileHelper) {
}
}
if (Z_TYPE_P(value) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 220, value, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 221, value, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
numberFiles += zephir_get_numberval(_4);
}
@@ -64063,7 +64072,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) {
zephir_array_fetch_string(&_6, input, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC);
zephir_array_fetch_string(&_7, input, SL("size"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC);
zephir_array_fetch_string(&_8, input, SL("error"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&smoothInput, this_ptr, "smoothfiles", &_9, 221, _4, _5, _6, _7, _8, prefix);
+ ZEPHIR_CALL_METHOD(&smoothInput, this_ptr, "smoothfiles", &_9, 222, _4, _5, _6, _7, _8, prefix);
zephir_check_call_status();
zephir_is_iterable(smoothInput, &_11, &_10, 0, 0, "phalcon/http/request.zep", 714);
for (
@@ -64097,7 +64106,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) {
ZEPHIR_INIT_NVAR(_16);
object_init_ex(_16, phalcon_http_request_file_ce);
zephir_array_fetch_string(&_17, file, SL("key"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 711 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 222, dataFile, _17);
+ ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 223, dataFile, _17);
zephir_check_call_status();
zephir_array_append(&files, _16, PH_SEPARATE, "phalcon/http/request.zep", 711);
}
@@ -64111,7 +64120,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) {
if (_13) {
ZEPHIR_INIT_NVAR(_16);
object_init_ex(_16, phalcon_http_request_file_ce);
- ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 222, input, prefix);
+ ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 223, input, prefix);
zephir_check_call_status();
zephir_array_append(&files, _16, PH_SEPARATE, "phalcon/http/request.zep", 716);
}
@@ -64184,7 +64193,7 @@ static PHP_METHOD(Phalcon_Http_Request, smoothFiles) {
zephir_array_fetch(&_7, tmp_names, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC);
zephir_array_fetch(&_8, sizes, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC);
zephir_array_fetch(&_9, errors, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&parentFiles, this_ptr, "smoothfiles", &_10, 221, _5, _6, _7, _8, _9, p);
+ ZEPHIR_CALL_METHOD(&parentFiles, this_ptr, "smoothfiles", &_10, 222, _5, _6, _7, _8, _9, p);
zephir_check_call_status();
zephir_is_iterable(parentFiles, &_12, &_11, 0, 0, "phalcon/http/request.zep", 755);
for (
@@ -64238,7 +64247,7 @@ static PHP_METHOD(Phalcon_Http_Request, getHeaders) {
ZVAL_STRING(&_8, " ", 0);
zephir_fast_str_replace(&_4, &_7, &_8, _6 TSRMLS_CC);
zephir_fast_strtolower(_3, _4);
- ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 223, _3);
+ ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 224, _3);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_10);
ZEPHIR_SINIT_NVAR(_11);
@@ -64257,7 +64266,7 @@ static PHP_METHOD(Phalcon_Http_Request, getHeaders) {
ZVAL_STRING(&_7, " ", 0);
zephir_fast_str_replace(&_4, &_5, &_7, name TSRMLS_CC);
zephir_fast_strtolower(_3, _4);
- ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 223, _3);
+ ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 224, _3);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_6);
ZEPHIR_SINIT_NVAR(_8);
@@ -64332,7 +64341,7 @@ static PHP_METHOD(Phalcon_Http_Request, _getQualityHeader) {
ZVAL_LONG(&_2, -1);
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 1);
- ZEPHIR_CALL_FUNCTION(&_4, "preg_split", &_5, 224, &_1, _0, &_2, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "preg_split", &_5, 225, &_1, _0, &_2, &_3);
zephir_check_call_status();
zephir_is_iterable(_4, &_7, &_6, 0, 0, "phalcon/http/request.zep", 827);
for (
@@ -64350,7 +64359,7 @@ static PHP_METHOD(Phalcon_Http_Request, _getQualityHeader) {
ZVAL_LONG(&_2, -1);
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 1);
- ZEPHIR_CALL_FUNCTION(&_10, "preg_split", &_5, 224, &_1, _9, &_2, &_3);
+ ZEPHIR_CALL_FUNCTION(&_10, "preg_split", &_5, 225, &_1, _9, &_2, &_3);
zephir_check_call_status();
zephir_is_iterable(_10, &_12, &_11, 0, 0, "phalcon/http/request.zep", 824);
for (
@@ -64481,7 +64490,7 @@ static PHP_METHOD(Phalcon_Http_Request, getAcceptableContent) {
ZVAL_STRING(_0, "HTTP_ACCEPT", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "accept", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 225, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1);
zephir_check_temp_parameter(_0);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
@@ -64500,7 +64509,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestAccept) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "accept", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 226, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -64518,7 +64527,7 @@ static PHP_METHOD(Phalcon_Http_Request, getClientCharsets) {
ZVAL_STRING(_0, "HTTP_ACCEPT_CHARSET", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "charset", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 225, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1);
zephir_check_temp_parameter(_0);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
@@ -64537,7 +64546,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestCharset) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "charset", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 226, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -64555,7 +64564,7 @@ static PHP_METHOD(Phalcon_Http_Request, getLanguages) {
ZVAL_STRING(_0, "HTTP_ACCEPT_LANGUAGE", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "language", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 225, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1);
zephir_check_temp_parameter(_0);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
@@ -64574,7 +64583,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestLanguage) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "language", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 226, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -64894,7 +64903,7 @@ static PHP_METHOD(Phalcon_Http_Response, setStatusCode) {
if (_4) {
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "HTTP/", 0);
- ZEPHIR_CALL_FUNCTION(&_6, "strstr", &_7, 233, key, &_5);
+ ZEPHIR_CALL_FUNCTION(&_6, "strstr", &_7, 234, key, &_5);
zephir_check_call_status();
_4 = zephir_is_true(_6);
}
@@ -65165,6 +65174,48 @@ static PHP_METHOD(Phalcon_Http_Response, setExpires) {
}
+static PHP_METHOD(Phalcon_Http_Response, setCache) {
+
+ zval *_1, *_3;
+ zval *minutes_param = NULL, *date, _0, _2, *_4;
+ int minutes, ZEPHIR_LAST_CALL_STATUS;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 0, &minutes_param);
+
+ if (unlikely(Z_TYPE_P(minutes_param) != IS_LONG)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'minutes' must be a long/integer") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ minutes = Z_LVAL_P(minutes_param);
+
+
+ ZEPHIR_INIT_VAR(date);
+ object_init_ex(date, php_date_get_date_ce());
+ ZEPHIR_CALL_METHOD(NULL, date, "__construct", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_SINIT_VAR(_0);
+ ZVAL_LONG(&_0, minutes);
+ ZEPHIR_INIT_VAR(_1);
+ ZEPHIR_CONCAT_SVS(_1, "+", &_0, " minutes");
+ ZEPHIR_CALL_METHOD(NULL, date, "modify", NULL, 0, _1);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "setexpires", NULL, 0, date);
+ zephir_check_call_status();
+ ZEPHIR_SINIT_VAR(_2);
+ ZVAL_LONG(&_2, ((minutes * 60)));
+ ZEPHIR_INIT_VAR(_3);
+ ZEPHIR_CONCAT_SV(_3, "max-age=", &_2);
+ ZEPHIR_INIT_VAR(_4);
+ ZVAL_STRING(_4, "Cache-Control", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "setheader", NULL, 0, _4, _3);
+ zephir_check_temp_parameter(_4);
+ zephir_check_call_status();
+ RETURN_THIS();
+
+}
+
static PHP_METHOD(Phalcon_Http_Response, setNotModified) {
int ZEPHIR_LAST_CALL_STATUS;
@@ -65279,7 +65330,7 @@ static PHP_METHOD(Phalcon_Http_Response, redirect) {
if (_0) {
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "://", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "strstr", NULL, 233, location, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strstr", NULL, 234, location, &_1);
zephir_check_call_status();
_0 = zephir_is_true(_2);
}
@@ -65336,7 +65387,7 @@ static PHP_METHOD(Phalcon_Http_Response, redirect) {
statusCode = 302;
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_statusCodes"), PH_NOISY_CC);
ZEPHIR_OBS_VAR(message);
- zephir_array_fetch_long(&message, _5, 302, PH_NOISY, "phalcon/http/response.zep", 461 TSRMLS_CC);
+ zephir_array_fetch_long(&message, _5, 302, PH_NOISY, "phalcon/http/response.zep", 481 TSRMLS_CC);
} else {
ZEPHIR_OBS_NVAR(message);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_statusCodes"), PH_NOISY_CC);
@@ -65472,7 +65523,7 @@ static PHP_METHOD(Phalcon_Http_Response, send) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_sent"), PH_NOISY_CC);
if (zephir_is_true(_0)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_response_exception_ce, "Response was already sent", "phalcon/http/response.zep", 568);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_response_exception_ce, "Response was already sent", "phalcon/http/response.zep", 588);
return;
}
ZEPHIR_OBS_VAR(headers);
@@ -65499,7 +65550,7 @@ static PHP_METHOD(Phalcon_Http_Response, send) {
_1 = (zephir_fast_strlen_ev(file)) ? 1 : 0;
}
if (_1) {
- ZEPHIR_CALL_FUNCTION(NULL, "readfile", NULL, 234, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "readfile", NULL, 235, file);
zephir_check_call_status();
}
}
@@ -65739,7 +65790,7 @@ static PHP_METHOD(Phalcon_Http_Request_File, __construct) {
zephir_update_property_this(this_ptr, SL("_name"), name TSRMLS_CC);
ZEPHIR_SINIT_VAR(_0);
ZVAL_STRING(&_0, "PATHINFO_EXTENSION", 0);
- ZEPHIR_CALL_FUNCTION(&_1, "defined", NULL, 227, &_0);
+ ZEPHIR_CALL_FUNCTION(&_1, "defined", NULL, 228, &_0);
zephir_check_call_status();
if (zephir_is_true(_1)) {
ZEPHIR_SINIT_NVAR(_0);
@@ -65805,15 +65856,15 @@ static PHP_METHOD(Phalcon_Http_Request_File, getRealType) {
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, 16);
- ZEPHIR_CALL_FUNCTION(&finfo, "finfo_open", NULL, 228, &_0);
+ ZEPHIR_CALL_FUNCTION(&finfo, "finfo_open", NULL, 229, &_0);
zephir_check_call_status();
if (Z_TYPE_P(finfo) != IS_RESOURCE) {
RETURN_MM_STRING("", 1);
}
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_tmp"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 229, finfo, _1);
+ ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 230, finfo, _1);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 230, finfo);
+ ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 231, finfo);
zephir_check_call_status();
RETURN_CCTOR(mime);
@@ -65831,7 +65882,7 @@ static PHP_METHOD(Phalcon_Http_Request_File, isUploadedFile) {
zephir_check_call_status();
_0 = Z_TYPE_P(tmp) == IS_STRING;
if (_0) {
- ZEPHIR_CALL_FUNCTION(&_1, "is_uploaded_file", NULL, 231, tmp);
+ ZEPHIR_CALL_FUNCTION(&_1, "is_uploaded_file", NULL, 232, tmp);
zephir_check_call_status();
_0 = zephir_is_true(_1);
}
@@ -65862,7 +65913,7 @@ static PHP_METHOD(Phalcon_Http_Request_File, moveTo) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_tmp"), PH_NOISY_CC);
- ZEPHIR_RETURN_CALL_FUNCTION("move_uploaded_file", NULL, 232, _0, destination);
+ ZEPHIR_RETURN_CALL_FUNCTION("move_uploaded_file", NULL, 233, _0, destination);
zephir_check_call_status();
RETURN_MM();
@@ -66042,30 +66093,30 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, set) {
object_init_ex(cookie, phalcon_http_cookie_ce);
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, expire);
- ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 235, name, value, _1, path, secure, domain, httpOnly);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 236, name, value, _1, path, secure, domain, httpOnly);
zephir_check_call_status();
_2 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 236, _2);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 237, _2);
zephir_check_call_status();
if (zephir_is_true(encryption)) {
- ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 237, encryption);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 238, encryption);
zephir_check_call_status();
}
zephir_update_property_array(this_ptr, SL("_cookies"), name, cookie TSRMLS_CC);
} else {
- ZEPHIR_CALL_METHOD(NULL, cookie, "setvalue", NULL, 238, value);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setvalue", NULL, 239, value);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_1);
ZVAL_LONG(_1, expire);
- ZEPHIR_CALL_METHOD(NULL, cookie, "setexpiration", NULL, 239, _1);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setexpiration", NULL, 240, _1);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, cookie, "setpath", NULL, 240, path);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setpath", NULL, 241, path);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, cookie, "setsecure", NULL, 241, secure);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setsecure", NULL, 242, secure);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, cookie, "setdomain", NULL, 242, domain);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setdomain", NULL, 243, domain);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, cookie, "sethttponly", NULL, 243, httpOnly);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "sethttponly", NULL, 244, httpOnly);
zephir_check_call_status();
}
_2 = zephir_fetch_nproperty_this(this_ptr, SL("_registered"), PH_NOISY_CC);
@@ -66117,17 +66168,17 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, get) {
}
ZEPHIR_INIT_NVAR(cookie);
object_init_ex(cookie, phalcon_http_cookie_ce);
- ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 235, name);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 236, name);
zephir_check_call_status();
ZEPHIR_OBS_VAR(dependencyInjector);
zephir_read_property_this(&dependencyInjector, this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
if (Z_TYPE_P(dependencyInjector) == IS_OBJECT) {
- ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 236, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 237, dependencyInjector);
zephir_check_call_status();
ZEPHIR_OBS_VAR(encryption);
zephir_read_property_this(&encryption, this_ptr, SL("_useEncryption"), PH_NOISY_CC);
if (zephir_is_true(encryption)) {
- ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 237, encryption);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 238, encryption);
zephir_check_call_status();
}
}
@@ -66411,10 +66462,10 @@ static PHP_METHOD(Phalcon_Http_Response_Headers, send) {
if (!(ZEPHIR_IS_EMPTY(value))) {
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_VSV(_5, header, ": ", value);
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 244, _5, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 245, _5, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
} else {
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 244, header, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 245, header, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
}
}
@@ -66475,7 +66526,7 @@ static PHP_METHOD(Phalcon_Http_Response_Headers, __set_state) {
) {
ZEPHIR_GET_HMKEY(key, _1, _0);
ZEPHIR_GET_HVALUE(value, _2);
- ZEPHIR_CALL_METHOD(NULL, headers, "set", &_3, 245, key, value);
+ ZEPHIR_CALL_METHOD(NULL, headers, "set", &_3, 246, key, value);
zephir_check_call_status();
}
}
@@ -67529,13 +67580,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, check) {
ZVAL_NULL(version);
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "GD_VERSION", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "defined", NULL, 227, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "defined", NULL, 228, &_1);
zephir_check_call_status();
if (zephir_is_true(_2)) {
ZEPHIR_INIT_NVAR(version);
ZEPHIR_GET_CONSTANT(version, "GD_VERSION");
} else {
- ZEPHIR_CALL_FUNCTION(&info, "gd_info", NULL, 246);
+ ZEPHIR_CALL_FUNCTION(&info, "gd_info", NULL, 247);
zephir_check_call_status();
ZEPHIR_INIT_VAR(matches);
ZVAL_NULL(matches);
@@ -67553,7 +67604,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, check) {
ZVAL_STRING(&_5, "2.0.1", 0);
ZEPHIR_SINIT_VAR(_6);
ZVAL_STRING(&_6, ">=", 0);
- ZEPHIR_CALL_FUNCTION(&_7, "version_compare", NULL, 247, version, &_5, &_6);
+ ZEPHIR_CALL_FUNCTION(&_7, "version_compare", NULL, 248, version, &_5, &_6);
zephir_check_call_status();
if (!(zephir_is_true(_7))) {
ZEPHIR_INIT_NVAR(_3);
@@ -67619,7 +67670,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) {
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_realpath"), _3 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&imageinfo, "getimagesize", NULL, 248, _4);
+ ZEPHIR_CALL_FUNCTION(&imageinfo, "getimagesize", NULL, 249, _4);
zephir_check_call_status();
if (zephir_is_true(imageinfo)) {
zephir_array_fetch_long(&_5, imageinfo, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter/gd.zep", 77 TSRMLS_CC);
@@ -67635,35 +67686,35 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) {
do {
if (ZEPHIR_IS_LONG(_9, 1)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromgif", NULL, 249, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromgif", NULL, 250, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(_9, 2)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromjpeg", NULL, 250, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromjpeg", NULL, 251, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(_9, 3)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefrompng", NULL, 251, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefrompng", NULL, 252, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(_9, 15)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromwbmp", NULL, 252, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromwbmp", NULL, 253, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(_9, 16)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromxbm", NULL, 253, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromxbm", NULL, 254, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
@@ -67688,7 +67739,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) {
} while(0);
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 254, _10, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 255, _10, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
} else {
_16 = !width;
@@ -67711,14 +67762,14 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) {
ZVAL_LONG(&_17, width);
ZEPHIR_SINIT_VAR(_18);
ZVAL_LONG(&_18, height);
- ZEPHIR_CALL_FUNCTION(&_3, "imagecreatetruecolor", NULL, 255, &_17, &_18);
+ ZEPHIR_CALL_FUNCTION(&_3, "imagecreatetruecolor", NULL, 256, &_17, &_18);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _3 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 256, _4, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, _4, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 254, _9, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 255, _9, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
zephir_update_property_this(this_ptr, SL("_realpath"), _10 TSRMLS_CC);
@@ -67757,7 +67808,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) {
ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION");
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "5.5.0", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 247, _0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1);
zephir_check_call_status();
if (ZEPHIR_LT_LONG(_2, 0)) {
ZEPHIR_OBS_VAR(pre_width);
@@ -67805,11 +67856,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) {
ZVAL_LONG(&_14, 0);
ZEPHIR_SINIT_VAR(_15);
ZVAL_LONG(&_15, 0);
- ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresized", NULL, 257, image, _9, &_12, &_13, &_14, &_15, pre_width, pre_height, _10, _11);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresized", NULL, 258, image, _9, &_12, &_13, &_14, &_15, pre_width, pre_height, _10, _11);
zephir_check_call_status();
if (zephir_is_true(_16)) {
_17 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 258, _17);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _17);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
}
@@ -67833,17 +67884,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) {
ZVAL_LONG(&_15, width);
ZEPHIR_SINIT_VAR(_21);
ZVAL_LONG(&_21, height);
- ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresampled", NULL, 259, image, _9, &_6, &_12, &_13, &_14, &_15, &_21, pre_width, pre_height);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresampled", NULL, 260, image, _9, &_6, &_12, &_13, &_14, &_15, &_21, pre_width, pre_height);
zephir_check_call_status();
if (zephir_is_true(_16)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 258, _10);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_22, "imagesx", &_23, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_22, "imagesx", &_23, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _22 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_24, "imagesy", &_25, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_24, "imagesy", &_25, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _24 TSRMLS_CC);
}
@@ -67853,16 +67904,16 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) {
ZVAL_LONG(&_6, width);
ZEPHIR_SINIT_NVAR(_12);
ZVAL_LONG(&_12, height);
- ZEPHIR_CALL_FUNCTION(&image, "imagescale", NULL, 262, _3, &_6, &_12);
+ ZEPHIR_CALL_FUNCTION(&image, "imagescale", NULL, 263, _3, &_6, &_12);
zephir_check_call_status();
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 258, _5);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _5);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_23, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_23, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _16 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_22, "imagesy", &_25, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_22, "imagesy", &_25, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _22 TSRMLS_CC);
}
@@ -67889,7 +67940,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) {
ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION");
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "5.5.0", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 247, _0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1);
zephir_check_call_status();
if (ZEPHIR_LT_LONG(_2, 0)) {
ZEPHIR_INIT_VAR(_3);
@@ -67915,17 +67966,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) {
ZVAL_LONG(&_11, width);
ZEPHIR_SINIT_VAR(_12);
ZVAL_LONG(&_12, height);
- ZEPHIR_CALL_FUNCTION(&_13, "imagecopyresampled", NULL, 259, image, _5, &_1, &_6, &_7, &_8, &_9, &_10, &_11, &_12);
+ ZEPHIR_CALL_FUNCTION(&_13, "imagecopyresampled", NULL, 260, image, _5, &_1, &_6, &_7, &_8, &_9, &_10, &_11, &_12);
zephir_check_call_status();
if (zephir_is_true(_13)) {
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 258, _14);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 259, _14);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_17, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_17, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _16 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_18, "imagesy", &_19, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_18, "imagesy", &_19, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _18 TSRMLS_CC);
}
@@ -67945,16 +67996,16 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) {
ZVAL_LONG(_3, height);
zephir_array_update_string(&rect, SL("height"), &_3, PH_COPY | PH_SEPARATE);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&image, "imagecrop", NULL, 263, _5, rect);
+ ZEPHIR_CALL_FUNCTION(&image, "imagecrop", NULL, 264, _5, rect);
zephir_check_call_status();
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 258, _14);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 259, _14);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_13, "imagesx", &_17, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_13, "imagesx", &_17, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _13 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_16, "imagesy", &_19, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagesy", &_19, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _16 TSRMLS_CC);
}
@@ -67982,20 +68033,20 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _rotate) {
ZVAL_LONG(&_3, 0);
ZEPHIR_SINIT_VAR(_4);
ZVAL_LONG(&_4, 127);
- ZEPHIR_CALL_FUNCTION(&transparent, "imagecolorallocatealpha", NULL, 264, _0, &_1, &_2, &_3, &_4);
+ ZEPHIR_CALL_FUNCTION(&transparent, "imagecolorallocatealpha", NULL, 265, _0, &_1, &_2, &_3, &_4);
zephir_check_call_status();
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, (360 - degrees));
ZEPHIR_SINIT_NVAR(_2);
ZVAL_LONG(&_2, 1);
- ZEPHIR_CALL_FUNCTION(&image, "imagerotate", NULL, 265, _5, &_1, transparent, &_2);
+ ZEPHIR_CALL_FUNCTION(&image, "imagerotate", NULL, 266, _5, &_1, transparent, &_2);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 254, image, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, image, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&width, "imagesx", NULL, 260, image);
+ ZEPHIR_CALL_FUNCTION(&width, "imagesx", NULL, 261, image);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&height, "imagesy", NULL, 261, image);
+ ZEPHIR_CALL_FUNCTION(&height, "imagesy", NULL, 262, image);
zephir_check_call_status();
_6 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
@@ -68008,11 +68059,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _rotate) {
ZVAL_LONG(&_4, 0);
ZEPHIR_SINIT_VAR(_7);
ZVAL_LONG(&_7, 100);
- ZEPHIR_CALL_FUNCTION(&_8, "imagecopymerge", NULL, 266, _6, image, &_1, &_2, &_3, &_4, width, height, &_7);
+ ZEPHIR_CALL_FUNCTION(&_8, "imagecopymerge", NULL, 267, _6, image, &_1, &_2, &_3, &_4, width, height, &_7);
zephir_check_call_status();
if (zephir_is_true(_8)) {
_9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, _9);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _9);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_width"), width TSRMLS_CC);
@@ -68038,7 +68089,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) {
ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION");
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "5.5.0", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 247, _0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1);
zephir_check_call_status();
if (ZEPHIR_LT_LONG(_2, 0)) {
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
@@ -68066,7 +68117,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) {
ZVAL_LONG(&_11, 0);
ZEPHIR_SINIT_NVAR(_12);
ZVAL_LONG(&_12, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, image, _6, &_1, &_9, &_10, &_11, &_12, _8);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, image, _6, &_1, &_9, &_10, &_11, &_12, _8);
zephir_check_call_status();
}
} else {
@@ -68090,18 +68141,18 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) {
ZVAL_LONG(&_11, ((zephir_get_numberval(_7) - x) - 1));
ZEPHIR_SINIT_NVAR(_12);
ZVAL_LONG(&_12, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, image, _6, &_1, &_9, &_10, &_11, _8, &_12);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, image, _6, &_1, &_9, &_10, &_11, _8, &_12);
zephir_check_call_status();
}
}
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, _5);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _5);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_14, "imagesx", NULL, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_14, "imagesx", NULL, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _14 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_15, "imagesy", NULL, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_15, "imagesy", NULL, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _15 TSRMLS_CC);
} else {
@@ -68109,13 +68160,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) {
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 268, _3, &_1);
+ ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 269, _3, &_1);
zephir_check_call_status();
} else {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 2);
- ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 268, _4, &_1);
+ ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 269, _4, &_1);
zephir_check_call_status();
}
}
@@ -68138,7 +68189,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _sharpen) {
ZEPHIR_INIT_VAR(_0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, (-18 + ((amount * 0.08))));
- ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 192, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 2);
@@ -68187,15 +68238,15 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _sharpen) {
ZVAL_LONG(&_6, (amount - 8));
ZEPHIR_SINIT_VAR(_7);
ZVAL_LONG(&_7, 0);
- ZEPHIR_CALL_FUNCTION(&_8, "imageconvolution", NULL, 269, _5, matrix, &_6, &_7);
+ ZEPHIR_CALL_FUNCTION(&_8, "imageconvolution", NULL, 270, _5, matrix, &_6, &_7);
zephir_check_call_status();
if (zephir_is_true(_8)) {
_9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "imagesx", NULL, 260, _9);
+ ZEPHIR_CALL_FUNCTION(&_10, "imagesx", NULL, 261, _9);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _10 TSRMLS_CC);
_11 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_12, "imagesy", NULL, 261, _11);
+ ZEPHIR_CALL_FUNCTION(&_12, "imagesy", NULL, 262, _11);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _12 TSRMLS_CC);
}
@@ -68221,7 +68272,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZEPHIR_INIT_VAR(_0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_DOUBLE(&_1, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127)));
- ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 192, &_1);
zephir_check_call_status();
zephir_round(_0, _2, NULL, NULL TSRMLS_CC);
opacity = zephir_get_intval(_0);
@@ -68247,7 +68298,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZVAL_LONG(&_11, 0);
ZEPHIR_SINIT_VAR(_12);
ZVAL_LONG(&_12, 0);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, reflection, _7, &_1, &_10, &_11, &_12, _8, _9);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, reflection, _7, &_1, &_10, &_11, &_12, _8, _9);
zephir_check_call_status();
offset = 0;
while (1) {
@@ -68288,7 +68339,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZVAL_LONG(&_21, src_y);
ZEPHIR_SINIT_NVAR(_22);
ZVAL_LONG(&_22, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, line, _18, &_11, &_12, &_20, &_21, _19, &_22);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, line, _18, &_11, &_12, &_20, &_21, _19, &_22);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_11);
ZVAL_LONG(&_11, 4);
@@ -68300,7 +68351,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZVAL_LONG(&_21, 0);
ZEPHIR_SINIT_NVAR(_22);
ZVAL_LONG(&_22, dst_opacity);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_23, 270, line, &_11, &_12, &_20, &_21, &_22);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_23, 271, line, &_11, &_12, &_20, &_21, &_22);
zephir_check_call_status();
_24 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_11);
@@ -68313,18 +68364,18 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZVAL_LONG(&_21, 0);
ZEPHIR_SINIT_NVAR(_22);
ZVAL_LONG(&_22, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, reflection, line, &_11, &_12, &_20, &_21, _24, &_22);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, reflection, line, &_11, &_12, &_20, &_21, _24, &_22);
zephir_check_call_status();
offset++;
}
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, _14);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _14);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), reflection TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_25, "imagesx", NULL, 260, reflection);
+ ZEPHIR_CALL_FUNCTION(&_25, "imagesx", NULL, 261, reflection);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _25 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_26, "imagesy", NULL, 261, reflection);
+ ZEPHIR_CALL_FUNCTION(&_26, "imagesy", NULL, 262, reflection);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _26 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -68346,21 +68397,21 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) {
ZEPHIR_CALL_METHOD(&_0, watermark, "render", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&overlay, "imagecreatefromstring", NULL, 271, _0);
+ ZEPHIR_CALL_FUNCTION(&overlay, "imagecreatefromstring", NULL, 272, _0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 254, overlay, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, overlay, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 260, overlay);
+ ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 261, overlay);
zephir_check_call_status();
width = zephir_get_intval(_1);
- ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 261, overlay);
+ ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 262, overlay);
zephir_check_call_status();
height = zephir_get_intval(_2);
if (opacity < 100) {
ZEPHIR_INIT_VAR(_3);
ZEPHIR_SINIT_VAR(_4);
ZVAL_DOUBLE(&_4, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127)));
- ZEPHIR_CALL_FUNCTION(&_5, "abs", NULL, 191, &_4);
+ ZEPHIR_CALL_FUNCTION(&_5, "abs", NULL, 192, &_4);
zephir_check_call_status();
zephir_round(_3, _5, NULL, NULL TSRMLS_CC);
opacity = zephir_get_intval(_3);
@@ -68372,11 +68423,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) {
ZVAL_LONG(&_7, 127);
ZEPHIR_SINIT_VAR(_8);
ZVAL_LONG(&_8, opacity);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 264, overlay, &_4, &_6, &_7, &_8);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 265, overlay, &_4, &_6, &_7, &_8);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_4);
ZVAL_LONG(&_4, 3);
- ZEPHIR_CALL_FUNCTION(NULL, "imagelayereffect", NULL, 272, overlay, &_4);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagelayereffect", NULL, 273, overlay, &_4);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_4);
ZVAL_LONG(&_4, 0);
@@ -68386,11 +68437,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) {
ZVAL_LONG(&_7, width);
ZEPHIR_SINIT_NVAR(_8);
ZVAL_LONG(&_8, height);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", NULL, 273, overlay, &_4, &_6, &_7, &_8, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", NULL, 274, overlay, &_4, &_6, &_7, &_8, color);
zephir_check_call_status();
}
_9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 256, _9, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, _9, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_4);
@@ -68405,10 +68456,10 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) {
ZVAL_LONG(&_11, width);
ZEPHIR_SINIT_VAR(_12);
ZVAL_LONG(&_12, height);
- ZEPHIR_CALL_FUNCTION(&_5, "imagecopy", NULL, 267, _10, overlay, &_4, &_6, &_7, &_8, &_11, &_12);
+ ZEPHIR_CALL_FUNCTION(&_5, "imagecopy", NULL, 268, _10, overlay, &_4, &_6, &_7, &_8, &_11, &_12);
zephir_check_call_status();
if (zephir_is_true(_5)) {
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, overlay);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, overlay);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -68440,7 +68491,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZEPHIR_INIT_VAR(_0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_DOUBLE(&_1, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127)));
- ZEPHIR_CALL_FUNCTION(&_2, "abs", &_3, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "abs", &_3, 192, &_1);
zephir_check_call_status();
zephir_round(_0, _2, NULL, NULL TSRMLS_CC);
opacity = zephir_get_intval(_0);
@@ -68449,7 +68500,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_1, size);
ZEPHIR_SINIT_VAR(_4);
ZVAL_LONG(&_4, 0);
- ZEPHIR_CALL_FUNCTION(&space, "imagettfbbox", NULL, 274, &_1, &_4, fontfile, text);
+ ZEPHIR_CALL_FUNCTION(&space, "imagettfbbox", NULL, 275, &_1, &_4, fontfile, text);
zephir_check_call_status();
if (zephir_array_isset_long(space, 0)) {
ZEPHIR_OBS_VAR(_5);
@@ -68483,12 +68534,12 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, (s4 - s0));
- ZEPHIR_CALL_FUNCTION(&_12, "abs", &_3, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_12, "abs", &_3, 192, &_1);
zephir_check_call_status();
width = (zephir_get_numberval(_12) + 10);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, (s5 - s1));
- ZEPHIR_CALL_FUNCTION(&_13, "abs", &_3, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_13, "abs", &_3, 192, &_1);
zephir_check_call_status();
height = (zephir_get_numberval(_13) + 10);
if (offsetX < 0) {
@@ -68508,7 +68559,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_15, b);
ZEPHIR_SINIT_VAR(_16);
ZVAL_LONG(&_16, opacity);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 264, _14, &_1, &_4, &_15, &_16);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 265, _14, &_1, &_4, &_15, &_16);
zephir_check_call_status();
angle = 0;
_18 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
@@ -68520,17 +68571,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_15, offsetX);
ZEPHIR_SINIT_NVAR(_16);
ZVAL_LONG(&_16, offsetY);
- ZEPHIR_CALL_FUNCTION(NULL, "imagettftext", NULL, 275, _18, &_1, &_4, &_15, &_16, color, fontfile, text);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagettftext", NULL, 276, _18, &_1, &_4, &_15, &_16, color, fontfile, text);
zephir_check_call_status();
} else {
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, size);
- ZEPHIR_CALL_FUNCTION(&_12, "imagefontwidth", NULL, 276, &_1);
+ ZEPHIR_CALL_FUNCTION(&_12, "imagefontwidth", NULL, 277, &_1);
zephir_check_call_status();
width = (zephir_get_intval(_12) * zephir_fast_strlen_ev(text));
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, size);
- ZEPHIR_CALL_FUNCTION(&_13, "imagefontheight", NULL, 277, &_1);
+ ZEPHIR_CALL_FUNCTION(&_13, "imagefontheight", NULL, 278, &_1);
zephir_check_call_status();
height = zephir_get_intval(_13);
if (offsetX < 0) {
@@ -68550,7 +68601,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_15, b);
ZEPHIR_SINIT_NVAR(_16);
ZVAL_LONG(&_16, opacity);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 264, _14, &_1, &_4, &_15, &_16);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 265, _14, &_1, &_4, &_15, &_16);
zephir_check_call_status();
_19 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
@@ -68559,7 +68610,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_4, offsetX);
ZEPHIR_SINIT_NVAR(_15);
ZVAL_LONG(&_15, offsetY);
- ZEPHIR_CALL_FUNCTION(NULL, "imagestring", NULL, 278, _19, &_1, &_4, &_15, text, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagestring", NULL, 279, _19, &_1, &_4, &_15, text, color);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -68580,22 +68631,22 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZEPHIR_CALL_METHOD(&_0, mask, "render", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&maskImage, "imagecreatefromstring", NULL, 271, _0);
+ ZEPHIR_CALL_FUNCTION(&maskImage, "imagecreatefromstring", NULL, 272, _0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 260, maskImage);
+ ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 261, maskImage);
zephir_check_call_status();
mask_width = zephir_get_intval(_1);
- ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 261, maskImage);
+ ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 262, maskImage);
zephir_check_call_status();
mask_height = zephir_get_intval(_2);
alpha = 127;
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 254, maskImage, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 255, maskImage, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC);
ZEPHIR_CALL_METHOD(&newimage, this_ptr, "_create", NULL, 0, _4, _5);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 254, newimage, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 255, newimage, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_6);
ZVAL_LONG(&_6, 0);
@@ -68605,13 +68656,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZVAL_LONG(&_8, 0);
ZEPHIR_SINIT_VAR(_9);
ZVAL_LONG(&_9, alpha);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 264, newimage, &_6, &_7, &_8, &_9);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 265, newimage, &_6, &_7, &_8, &_9);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_6);
ZVAL_LONG(&_6, 0);
ZEPHIR_SINIT_NVAR(_7);
ZVAL_LONG(&_7, 0);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefill", NULL, 279, newimage, &_6, &_7, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefill", NULL, 280, newimage, &_6, &_7, color);
zephir_check_call_status();
_11 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
_12 = !ZEPHIR_IS_LONG(_11, mask_width);
@@ -68622,7 +68673,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
if (_12) {
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
_15 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&tempImage, "imagecreatetruecolor", NULL, 255, _14, _15);
+ ZEPHIR_CALL_FUNCTION(&tempImage, "imagecreatetruecolor", NULL, 256, _14, _15);
zephir_check_call_status();
_16 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
_17 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC);
@@ -68638,9 +68689,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZVAL_LONG(&_18, mask_width);
ZEPHIR_SINIT_VAR(_19);
ZVAL_LONG(&_19, mask_height);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopyresampled", NULL, 259, tempImage, maskImage, &_6, &_7, &_8, &_9, _16, _17, &_18, &_19);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopyresampled", NULL, 260, tempImage, maskImage, &_6, &_7, &_8, &_9, _16, _17, &_18, &_19);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 258, maskImage);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, maskImage);
zephir_check_call_status();
ZEPHIR_CPY_WRT(maskImage, tempImage);
}
@@ -68660,9 +68711,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZVAL_LONG(&_6, x);
ZEPHIR_SINIT_NVAR(_7);
ZVAL_LONG(&_7, y);
- ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 280, maskImage, &_6, &_7);
+ ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 281, maskImage, &_6, &_7);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 281, maskImage, index);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 282, maskImage, index);
zephir_check_call_status();
if (zephir_array_isset_string(color, SS("red"))) {
zephir_array_fetch_string(&_23, color, SL("red"), PH_NOISY | PH_READONLY, "phalcon/image/adapter/gd.zep", 431 TSRMLS_CC);
@@ -68675,10 +68726,10 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZVAL_LONG(&_7, x);
ZEPHIR_SINIT_NVAR(_8);
ZVAL_LONG(&_8, y);
- ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 280, _16, &_7, &_8);
+ ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 281, _16, &_7, &_8);
zephir_check_call_status();
_17 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 281, _17, index);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 282, _17, index);
zephir_check_call_status();
ZEPHIR_OBS_NVAR(r);
zephir_array_fetch_string(&r, color, SL("red"), PH_NOISY, "phalcon/image/adapter/gd.zep", 436 TSRMLS_CC);
@@ -68688,22 +68739,22 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
zephir_array_fetch_string(&b, color, SL("blue"), PH_NOISY, "phalcon/image/adapter/gd.zep", 436 TSRMLS_CC);
ZEPHIR_SINIT_NVAR(_7);
ZVAL_LONG(&_7, alpha);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 264, newimage, r, g, b, &_7);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 265, newimage, r, g, b, &_7);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_7);
ZVAL_LONG(&_7, x);
ZEPHIR_SINIT_NVAR(_8);
ZVAL_LONG(&_8, y);
- ZEPHIR_CALL_FUNCTION(NULL, "imagesetpixel", &_24, 282, newimage, &_7, &_8, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesetpixel", &_24, 283, newimage, &_7, &_8, color);
zephir_check_call_status();
y++;
}
x++;
}
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 258, _14);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, _14);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 258, maskImage);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, maskImage);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), newimage TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -68737,9 +68788,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _background) {
ZVAL_LONG(&_4, b);
ZEPHIR_SINIT_VAR(_5);
ZVAL_LONG(&_5, opacity);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 264, background, &_2, &_3, &_4, &_5);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 265, background, &_2, &_3, &_4, &_5);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 256, background, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, background, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_6 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
@@ -68752,11 +68803,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _background) {
ZVAL_LONG(&_4, 0);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, 0);
- ZEPHIR_CALL_FUNCTION(&_9, "imagecopy", NULL, 267, background, _6, &_2, &_3, &_4, &_5, _7, _8);
+ ZEPHIR_CALL_FUNCTION(&_9, "imagecopy", NULL, 268, background, _6, &_2, &_3, &_4, &_5, _7, _8);
zephir_check_call_status();
if (zephir_is_true(_9)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, _10);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), background TSRMLS_CC);
}
@@ -68784,7 +68835,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _blur) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 7);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_2, 270, _0, &_1);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_2, 271, _0, &_1);
zephir_check_call_status();
i++;
}
@@ -68823,7 +68874,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) {
ZVAL_LONG(&_3, x1);
ZEPHIR_SINIT_NVAR(_4);
ZVAL_LONG(&_4, y1);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorat", &_5, 280, _2, &_3, &_4);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorat", &_5, 281, _2, &_3, &_4);
zephir_check_call_status();
x2 = (x + amount);
y2 = (y + amount);
@@ -68836,7 +68887,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) {
ZVAL_LONG(&_7, x2);
ZEPHIR_SINIT_NVAR(_8);
ZVAL_LONG(&_8, y2);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", &_9, 273, _6, &_3, &_4, &_7, &_8, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", &_9, 274, _6, &_3, &_4, &_7, &_8, color);
zephir_check_call_status();
y += amount;
}
@@ -68869,30 +68920,30 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _save) {
zephir_fast_strtolower(ext, _1);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "gif", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_2, 0)) {
ZEPHIR_INIT_ZVAL_NREF(_4);
ZVAL_LONG(_4, 1);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_5, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_5, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _5 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 285, _7, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 286, _7, file);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "jpg", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
_8 = ZEPHIR_IS_LONG(_5, 0);
if (!(_8)) {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "jpeg", 0);
- ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
_8 = ZEPHIR_IS_LONG(_9, 0);
}
@@ -68901,64 +68952,64 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _save) {
ZVAL_LONG(_4, 2);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, quality);
- ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 286, _7, file, &_0);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 287, _7, file, &_0);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "png", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_5, 0)) {
ZEPHIR_INIT_ZVAL_NREF(_4);
ZVAL_LONG(_4, 3);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 287, _7, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 288, _7, file);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "wbmp", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_5, 0)) {
ZEPHIR_INIT_ZVAL_NREF(_4);
ZVAL_LONG(_4, 15);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 288, _7, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 289, _7, file);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "xbm", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_5, 0)) {
ZEPHIR_INIT_ZVAL_NREF(_4);
ZVAL_LONG(_4, 16);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 289, _7, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 290, _7, file);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
@@ -68996,25 +69047,25 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) {
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "gif", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_2, 0)) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 285, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 286, _4);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "jpg", 0);
- ZEPHIR_CALL_FUNCTION(&_6, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_6, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
_7 = ZEPHIR_IS_LONG(_6, 0);
if (!(_7)) {
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "jpeg", 0);
- ZEPHIR_CALL_FUNCTION(&_8, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_8, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
_7 = ZEPHIR_IS_LONG(_8, 0);
}
@@ -69022,45 +69073,45 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, quality);
- ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 286, _4, ZEPHIR_GLOBAL(global_null), &_1);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 287, _4, ZEPHIR_GLOBAL(global_null), &_1);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "png", 0);
- ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_9, 0)) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 287, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 288, _4);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "wbmp", 0);
- ZEPHIR_CALL_FUNCTION(&_10, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_10, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_10, 0)) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 288, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 289, _4);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "xbm", 0);
- ZEPHIR_CALL_FUNCTION(&_11, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_11, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_11, 0)) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 289, _4, ZEPHIR_GLOBAL(global_null));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 290, _4, ZEPHIR_GLOBAL(global_null));
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
@@ -69092,11 +69143,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _create) {
ZVAL_LONG(&_0, width);
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, height);
- ZEPHIR_CALL_FUNCTION(&image, "imagecreatetruecolor", NULL, 255, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&image, "imagecreatetruecolor", NULL, 256, &_0, &_1);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 256, image, ZEPHIR_GLOBAL(global_false));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, image, ZEPHIR_GLOBAL(global_false));
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 254, image, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, image, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
RETURN_CCTOR(image);
@@ -69112,7 +69163,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __destruct) {
ZEPHIR_OBS_VAR(image);
zephir_read_property_this(&image, this_ptr, SL("_image"), PH_NOISY_CC);
if (Z_TYPE_P(image) == IS_RESOURCE) {
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, image);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, image);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -69165,12 +69216,12 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, check) {
}
ZEPHIR_SINIT_VAR(_2);
ZVAL_STRING(&_2, "Imagick::IMAGICK_EXTNUM", 0);
- ZEPHIR_CALL_FUNCTION(&_3, "defined", NULL, 227, &_2);
+ ZEPHIR_CALL_FUNCTION(&_3, "defined", NULL, 228, &_2);
zephir_check_call_status();
if (zephir_is_true(_3)) {
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "Imagick::IMAGICK_EXTNUM", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 189, &_2);
+ ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 190, &_2);
zephir_check_call_status();
zephir_update_static_property_ce(phalcon_image_adapter_imagick_ce, SL("_version"), &_4 TSRMLS_CC);
}
@@ -69255,7 +69306,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, __construct) {
_12 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_13);
ZVAL_STRING(&_13, "Imagick::ALPHACHANNEL_SET", 0);
- ZEPHIR_CALL_FUNCTION(&_14, "constant", NULL, 189, &_13);
+ ZEPHIR_CALL_FUNCTION(&_14, "constant", NULL, 190, &_13);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, _12, "setimagealphachannel", NULL, 0, _14);
zephir_check_call_status();
@@ -69727,7 +69778,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
while (1) {
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::COMPOSITE_DSTOUT", 0);
- ZEPHIR_CALL_FUNCTION(&_12, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_12, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_3);
ZVAL_LONG(_3, 0);
@@ -69741,11 +69792,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
}
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::EVALUATE_MULTIPLY", 0);
- ZEPHIR_CALL_FUNCTION(&_17, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_17, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::CHANNEL_ALPHA", 0);
- ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_3);
ZVAL_LONG(_3, opacity);
@@ -69788,7 +69839,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::ALPHACHANNEL_SET", 0);
- ZEPHIR_CALL_FUNCTION(&_9, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_9, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, image, "setimagealphachannel", &_25, 0, _9);
zephir_check_call_status();
@@ -69805,7 +69856,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
_30 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::COMPOSITE_SRC", 0);
- ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_3);
ZVAL_LONG(_3, 0);
@@ -69835,7 +69886,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
while (1) {
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::COMPOSITE_OVER", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_2, "constant", &_15, 190, &_14);
zephir_check_call_status();
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC);
ZEPHIR_INIT_NVAR(_3);
@@ -69917,7 +69968,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _watermark) {
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_4);
ZVAL_STRING(&_4, "Imagick::COMPOSITE_OVER", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "constant", &_6, 189, &_4);
+ ZEPHIR_CALL_FUNCTION(&_5, "constant", &_6, 190, &_4);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_1);
ZVAL_LONG(_1, offsetX);
@@ -69980,7 +70031,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _text) {
ZVAL_LONG(&_2, g);
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, b);
- ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 186, &_0, &_1, &_2, &_3);
+ ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 187, &_0, &_1, &_2, &_3);
zephir_check_call_status();
ZEPHIR_INIT_VAR(pixel);
object_init_ex(pixel, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC));
@@ -70009,23 +70060,23 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _text) {
if (offsetX < 0) {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, offsetX);
- ZEPHIR_CALL_FUNCTION(&_5, "abs", &_6, 191, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "abs", &_6, 192, &_0);
zephir_check_call_status();
offsetX = zephir_get_numberval(_5);
if (offsetY < 0) {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, offsetY);
- ZEPHIR_CALL_FUNCTION(&_7, "abs", &_6, 191, &_0);
+ ZEPHIR_CALL_FUNCTION(&_7, "abs", &_6, 192, &_0);
zephir_check_call_status();
offsetY = zephir_get_numberval(_7);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0);
- ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 190, &_0);
zephir_check_call_status();
} else {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHEAST", 0);
- ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 190, &_0);
zephir_check_call_status();
}
}
@@ -70094,7 +70145,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _mask) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Imagick::COMPOSITE_DSTIN", 0);
- ZEPHIR_CALL_FUNCTION(&_6, "constant", &_7, 189, &_5);
+ ZEPHIR_CALL_FUNCTION(&_6, "constant", &_7, 190, &_5);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_2);
ZVAL_LONG(_2, 0);
@@ -70144,7 +70195,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) {
ZVAL_LONG(&_2, g);
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, b);
- ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 186, &_0, &_1, &_2, &_3);
+ ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 187, &_0, &_1, &_2, &_3);
zephir_check_call_status();
ZEPHIR_INIT_VAR(pixel1);
object_init_ex(pixel1, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC));
@@ -70183,7 +70234,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) {
if (!(zephir_is_true(_9))) {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::ALPHACHANNEL_SET", 0);
- ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 190, &_0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, background, "setimagealphachannel", &_13, 0, _11);
zephir_check_call_status();
@@ -70192,11 +70243,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) {
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::EVALUATE_MULTIPLY", 0);
- ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 190, &_0);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::CHANNEL_ALPHA", 0);
- ZEPHIR_CALL_FUNCTION(&_15, "constant", &_12, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_15, "constant", &_12, 190, &_0);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_4);
ZVAL_LONG(_4, opacity);
@@ -70210,7 +70261,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) {
_20 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::COMPOSITE_DISSOLVE", 0);
- ZEPHIR_CALL_FUNCTION(&_21, "constant", &_12, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_21, "constant", &_12, 190, &_0);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_4);
ZVAL_LONG(_4, 0);
@@ -70364,7 +70415,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) {
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "w", 0);
- ZEPHIR_CALL_FUNCTION(&fp, "fopen", NULL, 291, file, &_0);
+ ZEPHIR_CALL_FUNCTION(&fp, "fopen", NULL, 292, file, &_0);
zephir_check_call_status();
_11 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_CALL_METHOD(NULL, _11, "writeimagesfile", NULL, 0, fp);
@@ -70388,7 +70439,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::COMPRESSION_JPEG", 0);
- ZEPHIR_CALL_FUNCTION(&_15, "constant", NULL, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_15, "constant", NULL, 190, &_0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, _10, "setimagecompression", NULL, 0, _15);
zephir_check_call_status();
@@ -70460,7 +70511,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _render) {
if (_7) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_STRING(&_3, "Imagick::COMPRESSION_JPEG", 0);
- ZEPHIR_CALL_FUNCTION(&_9, "constant", NULL, 189, &_3);
+ ZEPHIR_CALL_FUNCTION(&_9, "constant", NULL, 190, &_3);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, image, "setimagecompression", NULL, 0, _9);
zephir_check_call_status();
@@ -71859,7 +71910,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, __construct) {
ZEPHIR_INIT_NVAR(mode);
ZVAL_STRING(mode, "ab", 1);
}
- ZEPHIR_CALL_FUNCTION(&handler, "fopen", NULL, 291, name, mode);
+ ZEPHIR_CALL_FUNCTION(&handler, "fopen", NULL, 292, name, mode);
zephir_check_call_status();
if (Z_TYPE_P(handler) != IS_RESOURCE) {
ZEPHIR_INIT_VAR(_0);
@@ -71891,7 +71942,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, getFormatter) {
if (Z_TYPE_P(_0) != IS_OBJECT) {
ZEPHIR_INIT_VAR(_1);
object_init_ex(_1, phalcon_logger_formatter_line_ce);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 295);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 296);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_formatter"), _1 TSRMLS_CC);
}
@@ -71903,7 +71954,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, logInternal) {
zval *context = NULL;
int type, time, ZEPHIR_LAST_CALL_STATUS;
- zval *message_param = NULL, *type_param = NULL, *time_param = NULL, *context_param = NULL, *fileHandler, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3, *_4;
+ zval *message_param = NULL, *type_param = NULL, *time_param = NULL, *context_param = NULL, *fileHandler, *_0 = NULL, *_1 = NULL, *_2, *_3;
zval *message = NULL;
ZEPHIR_MM_GROW();
@@ -71929,11 +71980,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, logInternal) {
ZVAL_LONG(_3, time);
ZEPHIR_CALL_METHOD(&_1, _0, "format", NULL, 0, message, _2, _3, context);
zephir_check_call_status();
- ZEPHIR_INIT_NVAR(_2);
- ZEPHIR_GET_CONSTANT(_2, "PHP_EOL");
- ZEPHIR_INIT_VAR(_4);
- ZEPHIR_CONCAT_VV(_4, _1, _2);
- zephir_fwrite(NULL, fileHandler, _4 TSRMLS_CC);
+ zephir_fwrite(NULL, fileHandler, _1 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
}
@@ -71975,7 +72022,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, __wakeup) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_logger_exception_ce, "Logger must be opened in append or write mode", "phalcon/logger/adapter/file.zep", 152);
return;
}
- ZEPHIR_CALL_FUNCTION(&_1, "fopen", NULL, 291, path, mode);
+ ZEPHIR_CALL_FUNCTION(&_1, "fopen", NULL, 292, path, mode);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_fileHandler"), _1 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -72060,15 +72107,15 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) {
if (!ZEPHIR_IS_TRUE_IDENTICAL(_1)) {
ZEPHIR_SINIT_VAR(_2);
ZVAL_STRING(&_2, "X-Wf-Protocol-1: http://meta.wildfirehq.org/Protocol/JsonStream/0.2", 0);
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 244, &_2);
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "X-Wf-1-Plugin-1: http://meta.firephp.org/Wildfire/Plugin/FirePHP/Library-FirePHPCore/0.3", 0);
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 244, &_2);
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "X-Wf-Structure-1: http://meta.firephp.org/Wildfire/Structure/FirePHP/FirebugConsole/0.1", 0);
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 244, &_2);
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2);
zephir_check_call_status();
zephir_update_static_property_ce(phalcon_logger_adapter_firephp_ce, SL("_initialized"), &(ZEPHIR_GLOBAL(global_true)) TSRMLS_CC);
}
@@ -72098,7 +72145,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) {
if (zephir_array_isset_long(chunk, (zephir_get_numberval(key) + 1))) {
zephir_concat_self_str(&content, SL("|\\") TSRMLS_CC);
}
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 244, content);
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, content);
zephir_check_call_status();
_10 = zephir_fetch_static_property_ce(phalcon_logger_adapter_firephp_ce, SL("_index") TSRMLS_CC);
ZEPHIR_INIT_ZVAL_NREF(_11);
@@ -72176,7 +72223,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Stream, __construct) {
ZEPHIR_INIT_NVAR(mode);
ZVAL_STRING(mode, "ab", 1);
}
- ZEPHIR_CALL_FUNCTION(&stream, "fopen", NULL, 291, name, mode);
+ ZEPHIR_CALL_FUNCTION(&stream, "fopen", NULL, 292, name, mode);
zephir_check_call_status();
if (!(zephir_is_true(stream))) {
ZEPHIR_INIT_VAR(_0);
@@ -72206,7 +72253,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Stream, getFormatter) {
if (Z_TYPE_P(_0) != IS_OBJECT) {
ZEPHIR_INIT_VAR(_1);
object_init_ex(_1, phalcon_logger_formatter_line_ce);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 295);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 296);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_formatter"), _1 TSRMLS_CC);
}
@@ -72308,7 +72355,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, __construct) {
ZEPHIR_INIT_NVAR(facility);
ZVAL_LONG(facility, 8);
}
- ZEPHIR_CALL_FUNCTION(NULL, "openlog", NULL, 296, name, option, facility);
+ ZEPHIR_CALL_FUNCTION(NULL, "openlog", NULL, 297, name, option, facility);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_opened"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
}
@@ -72368,7 +72415,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, logInternal) {
}
zephir_array_fetch_long(&_3, appliedFormat, 0, PH_NOISY | PH_READONLY, "phalcon/logger/adapter/syslog.zep", 102 TSRMLS_CC);
zephir_array_fetch_long(&_4, appliedFormat, 1, PH_NOISY | PH_READONLY, "phalcon/logger/adapter/syslog.zep", 102 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "syslog", NULL, 297, _3, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "syslog", NULL, 298, _3, _4);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -72383,7 +72430,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, close) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_opened"), PH_NOISY_CC);
if (zephir_is_true(_0)) {
- ZEPHIR_CALL_FUNCTION(NULL, "closelog", NULL, 298);
+ ZEPHIR_CALL_FUNCTION(NULL, "closelog", NULL, 299);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -72540,15 +72587,15 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Firephp, format) {
ZVAL_STRING(&_3, "5.3.6", 0);
ZEPHIR_SINIT_VAR(_4);
ZVAL_STRING(&_4, "<", 0);
- ZEPHIR_CALL_FUNCTION(&_0, "version_compare", NULL, 247, _1, &_3, &_4);
+ ZEPHIR_CALL_FUNCTION(&_0, "version_compare", NULL, 248, _1, &_3, &_4);
zephir_check_call_status();
if (!(zephir_is_true(_0))) {
param = (2) ? 1 : 0;
}
- ZEPHIR_CALL_FUNCTION(&backtrace, "debug_backtrace", NULL, 149, (param ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_FUNCTION(&backtrace, "debug_backtrace", NULL, 150, (param ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
Z_SET_ISREF_P(backtrace);
- ZEPHIR_CALL_FUNCTION(&lastTrace, "end", NULL, 169, backtrace);
+ ZEPHIR_CALL_FUNCTION(&lastTrace, "end", NULL, 170, backtrace);
Z_UNSET_ISREF_P(backtrace);
zephir_check_call_status();
if (zephir_array_isset_string(lastTrace, SS("file"))) {
@@ -72642,9 +72689,9 @@ ZEPHIR_INIT_CLASS(Phalcon_Logger_Formatter_Json) {
static PHP_METHOD(Phalcon_Logger_Formatter_Json, format) {
- zval *_1;
+ zval *_2;
int type, timestamp, ZEPHIR_LAST_CALL_STATUS;
- zval *message_param = NULL, *type_param = NULL, *timestamp_param = NULL, *context = NULL, *_0 = NULL, *_2 = NULL;
+ zval *message_param = NULL, *type_param = NULL, *timestamp_param = NULL, *context = NULL, *_0 = NULL, *_1, *_3 = NULL;
zval *message = NULL;
ZEPHIR_MM_GROW();
@@ -72664,17 +72711,21 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Json, format) {
zephir_get_strval(message, _0);
}
ZEPHIR_INIT_VAR(_1);
- zephir_create_array(_1, 3, 0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_2);
- ZVAL_LONG(_2, type);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "gettypestring", NULL, 0, _2);
+ zephir_create_array(_2, 3, 0 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_3);
+ ZVAL_LONG(_3, type);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "gettypestring", NULL, 0, _3);
zephir_check_call_status();
- zephir_array_update_string(&_1, SL("type"), &_0, PH_COPY | PH_SEPARATE);
- zephir_array_update_string(&_1, SL("message"), &message, PH_COPY | PH_SEPARATE);
- ZEPHIR_INIT_NVAR(_2);
- ZVAL_LONG(_2, timestamp);
- zephir_array_update_string(&_1, SL("timestamp"), &_2, PH_COPY | PH_SEPARATE);
- zephir_json_encode(return_value, &(return_value), _1, 0 TSRMLS_CC);
+ zephir_array_update_string(&_2, SL("type"), &_0, PH_COPY | PH_SEPARATE);
+ zephir_array_update_string(&_2, SL("message"), &message, PH_COPY | PH_SEPARATE);
+ ZEPHIR_INIT_NVAR(_3);
+ ZVAL_LONG(_3, timestamp);
+ zephir_array_update_string(&_2, SL("timestamp"), &_3, PH_COPY | PH_SEPARATE);
+ zephir_json_encode(_1, &(_1), _2, 0 TSRMLS_CC);
+ ZEPHIR_INIT_NVAR(_3);
+ ZEPHIR_GET_CONSTANT(_3, "PHP_EOL");
+ ZEPHIR_CONCAT_VV(return_value, _1, _3);
RETURN_MM();
}
@@ -72770,7 +72821,7 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, __construct) {
static PHP_METHOD(Phalcon_Logger_Formatter_Line, format) {
int type, timestamp, ZEPHIR_LAST_CALL_STATUS;
- zval *message_param = NULL, *type_param = NULL, *timestamp_param = NULL, *context = NULL, *format = NULL, *_0 = NULL, *_1, _2 = zval_used_for_init, *_3 = NULL, *_4;
+ zval *message_param = NULL, *type_param = NULL, *timestamp_param = NULL, *context = NULL, *format = NULL, *_0 = NULL, *_1, _2 = zval_used_for_init, *_3 = NULL, *_4 = NULL, *_5;
zval *message = NULL;
ZEPHIR_MM_GROW();
@@ -72791,7 +72842,7 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, format) {
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_dateFormat"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_2);
ZVAL_LONG(&_2, timestamp);
- ZEPHIR_CALL_FUNCTION(&_3, "date", NULL, 299, _1, &_2);
+ ZEPHIR_CALL_FUNCTION(&_3, "date", NULL, 300, _1, &_2);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "%date%", 0);
@@ -72813,7 +72864,11 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, format) {
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "%message%", 0);
zephir_fast_str_replace(&_0, &_2, message, format TSRMLS_CC);
- ZEPHIR_CPY_WRT(format, _0);
+ ZEPHIR_INIT_NVAR(_4);
+ ZEPHIR_GET_CONSTANT(_4, "PHP_EOL");
+ ZEPHIR_INIT_VAR(_5);
+ ZEPHIR_CONCAT_VV(_5, _0, _4);
+ ZEPHIR_CPY_WRT(format, _5);
if (Z_TYPE_P(context) == IS_ARRAY) {
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "interpolate", NULL, 0, format, context);
zephir_check_call_status();
@@ -73841,7 +73896,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, _getResultset) {
}
ZEPHIR_INIT_VAR(collections);
array_init(collections);
- ZEPHIR_CALL_FUNCTION(&_0, "iterator_to_array", NULL, 300, documentsCursor);
+ ZEPHIR_CALL_FUNCTION(&_0, "iterator_to_array", NULL, 301, documentsCursor);
zephir_check_call_status();
zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/collection.zep", 440);
for (
@@ -74304,7 +74359,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, save) {
zephir_update_property_this(this_ptr, SL("_errorMessages"), _1 TSRMLS_CC);
ZEPHIR_OBS_VAR(disableEvents);
zephir_read_static_property_ce(&disableEvents, phalcon_mvc_collection_ce, SL("_disableEvents") TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_2, this_ptr, "_presave", NULL, 301, dependencyInjector, disableEvents, exists);
+ ZEPHIR_CALL_METHOD(&_2, this_ptr, "_presave", NULL, 302, dependencyInjector, disableEvents, exists);
zephir_check_call_status();
if (ZEPHIR_IS_FALSE_IDENTICAL(_2)) {
RETURN_MM_BOOL(0);
@@ -74333,7 +74388,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, save) {
} else {
success = 0;
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_postsave", NULL, 302, disableEvents, (success ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), exists);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_postsave", NULL, 303, disableEvents, (success ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), exists);
zephir_check_call_status();
RETURN_MM();
@@ -75662,7 +75717,7 @@ static PHP_METHOD(Phalcon_Mvc_Micro, mount) {
if (zephir_is_true(_0)) {
ZEPHIR_INIT_VAR(lazyHandler);
object_init_ex(lazyHandler, phalcon_mvc_micro_lazyloader_ce);
- ZEPHIR_CALL_METHOD(NULL, lazyHandler, "__construct", NULL, 303, mainHandler);
+ ZEPHIR_CALL_METHOD(NULL, lazyHandler, "__construct", NULL, 304, mainHandler);
zephir_check_call_status();
} else {
ZEPHIR_CPY_WRT(lazyHandler, mainHandler);
@@ -75811,11 +75866,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, setService) {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
ZEPHIR_INIT_NVAR(dependencyInjector);
object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce);
- ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 173);
+ ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "set", NULL, 304, serviceName, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "set", NULL, 305, serviceName, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -75848,11 +75903,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, hasService) {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
ZEPHIR_INIT_NVAR(dependencyInjector);
object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce);
- ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 173);
+ ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "has", NULL, 305, serviceName);
+ ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "has", NULL, 306, serviceName);
zephir_check_call_status();
RETURN_MM();
@@ -75885,11 +75940,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, getService) {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
ZEPHIR_INIT_NVAR(dependencyInjector);
object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce);
- ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 173);
+ ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "get", NULL, 306, serviceName);
+ ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "get", NULL, 307, serviceName);
zephir_check_call_status();
RETURN_MM();
@@ -75910,11 +75965,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, getSharedService) {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
ZEPHIR_INIT_NVAR(dependencyInjector);
object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce);
- ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 173);
+ ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "getshared", NULL, 307, serviceName);
+ ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "getshared", NULL, 308, serviceName);
zephir_check_call_status();
RETURN_MM();
@@ -77404,12 +77459,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, query) {
ZEPHIR_CALL_METHOD(NULL, criteria, "__construct", NULL, 0);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(NULL, criteria, "setdi", NULL, 308, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "setdi", NULL, 309, dependencyInjector);
zephir_check_call_status();
}
ZEPHIR_INIT_NVAR(_2);
zephir_get_called_class(_2 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 309, _2);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 310, _2);
zephir_check_call_status();
RETURN_CCTOR(criteria);
@@ -78964,9 +79019,9 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) {
break;
}
if (ZEPHIR_IS_LONG(bindType, 3) || ZEPHIR_IS_LONG(bindType, 7)) {
- ZEPHIR_CALL_FUNCTION(&_1, "floatval", &_8, 310, snapshotValue);
+ ZEPHIR_CALL_FUNCTION(&_1, "floatval", &_8, 311, snapshotValue);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_9, "floatval", &_8, 310, value);
+ ZEPHIR_CALL_FUNCTION(&_9, "floatval", &_8, 311, value);
zephir_check_call_status();
changed = !ZEPHIR_IS_IDENTICAL(_1, _9);
break;
@@ -79403,7 +79458,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, save) {
ZEPHIR_INIT_NVAR(_4);
object_init_ex(_4, phalcon_mvc_model_validationfailed_ce);
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_errorMessages"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 311, this_ptr, _3);
+ ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 312, this_ptr, _3);
zephir_check_call_status();
zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 2877 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -80191,7 +80246,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) {
int ZEPHIR_LAST_CALL_STATUS;
HashTable *_1;
HashPosition _0;
- zval *data_param = NULL, *columnMap = NULL, *key = NULL, *value = NULL, *snapshot, *attribute = NULL, **_2, *_3 = NULL, *_4 = NULL, *_6 = NULL;
+ zval *data_param = NULL, *columnMap = NULL, *key = NULL, *value = NULL, *snapshot, *attribute = NULL, **_2, *_3 = NULL, *_4 = NULL;
zval *data = NULL;
ZEPHIR_MM_GROW();
@@ -80207,7 +80262,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) {
if (Z_TYPE_P(columnMap) == IS_ARRAY) {
ZEPHIR_INIT_VAR(snapshot);
array_init(snapshot);
- zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3606);
+ zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3605);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -80250,12 +80305,8 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) {
continue;
}
}
- ZEPHIR_OBS_NVAR(_6);
- zephir_array_fetch_long(&_6, attribute, 0, PH_NOISY, "phalcon/mvc/model.zep", 3600 TSRMLS_CC);
- zephir_array_update_zval(&snapshot, _6, &value, PH_COPY | PH_SEPARATE);
- } else {
- zephir_array_update_zval(&snapshot, attribute, &value, PH_COPY | PH_SEPARATE);
}
+ zephir_array_update_zval(&snapshot, attribute, &value, PH_COPY | PH_SEPARATE);
}
zephir_update_property_this(this_ptr, SL("_snapshot"), snapshot TSRMLS_CC);
RETURN_MM_NULL();
@@ -80300,12 +80351,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_OBS_VAR(snapshot);
zephir_read_property_this(&snapshot, this_ptr, SL("_snapshot"), PH_NOISY_CC);
if (Z_TYPE_P(snapshot) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3645);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3644);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC);
if (!ZEPHIR_IS_LONG(_0, 0)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3652);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3651);
return;
}
ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0);
@@ -80327,7 +80378,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not part of the model");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3684 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3683 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80339,7 +80390,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not part of the model");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3688 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3687 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80352,7 +80403,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not defined on the model");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3696 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3695 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80364,14 +80415,14 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_CONCAT_SVS(_3, "The field '", fieldName, "' was not found in the snapshot");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3703 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3702 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
RETURN_MM_BOOL(!ZEPHIR_IS_EQUAL(value, originalValue));
}
ZEPHIR_INIT_NVAR(_1);
- zephir_is_iterable(allAttributes, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 3739);
+ zephir_is_iterable(allAttributes, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 3738);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
@@ -80406,12 +80457,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) {
ZEPHIR_OBS_VAR(snapshot);
zephir_read_property_this(&snapshot, this_ptr, SL("_snapshot"), PH_NOISY_CC);
if (Z_TYPE_P(snapshot) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3752);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3751);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC);
if (!ZEPHIR_IS_LONG(_0, 0)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3759);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3758);
return;
}
ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0);
@@ -80427,7 +80478,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) {
ZEPHIR_INIT_VAR(changed);
array_init(changed);
ZEPHIR_INIT_VAR(_1);
- zephir_is_iterable(allAttributes, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3813);
+ zephir_is_iterable(allAttributes, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3812);
for (
; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS
; zephir_hash_move_forward_ex(_3, &_2)
@@ -80435,17 +80486,17 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) {
ZEPHIR_GET_HMKEY(name, _3, _2);
ZEPHIR_GET_HVALUE(_1, _4);
if (!(zephir_array_isset(snapshot, name))) {
- zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3792);
+ zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3791);
continue;
}
ZEPHIR_OBS_NVAR(value);
if (!(zephir_fetch_property_zval(&value, this_ptr, name, PH_SILENT_CC))) {
- zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3800);
+ zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3799);
continue;
}
- zephir_array_fetch(&_5, snapshot, name, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 3807 TSRMLS_CC);
+ zephir_array_fetch(&_5, snapshot, name, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 3806 TSRMLS_CC);
if (!ZEPHIR_IS_EQUAL(value, _5)) {
- zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3808);
+ zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3807);
continue;
}
}
@@ -80502,7 +80553,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getRelated) {
ZEPHIR_CONCAT_SVSVS(_3, "There is no defined relations for the model '", className, "' using alias '", alias, "'");
ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_2, "phalcon/mvc/model.zep", 3855 TSRMLS_CC);
+ zephir_throw_exception_debug(_2, "phalcon/mvc/model.zep", 3854 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80640,7 +80691,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __call) {
ZEPHIR_CONCAT_SVSVS(_2, "The method '", method, "' doesn't exist on model '", modelName, "'");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3947 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3946 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -80702,7 +80753,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) {
ZEPHIR_CONCAT_SVSVS(_2, "The static method '", method, "' doesn't exist on model '", modelName, "'");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3998 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3997 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80714,7 +80765,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) {
ZEPHIR_CONCAT_SVS(_3, "The static method '", method, "' requires one argument");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4002 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4001 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80751,7 +80802,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) {
ZEPHIR_CONCAT_SVS(_2, "Cannot resolve attribute '", extraMethod, "' in the model");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4036 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4035 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80810,7 +80861,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __set) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(related);
array_init(related);
- zephir_is_iterable(value, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4100);
+ zephir_is_iterable(value, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4099);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -80819,7 +80870,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __set) {
ZEPHIR_GET_HVALUE(item, _3);
if (Z_TYPE_P(item) == IS_OBJECT) {
if (zephir_instance_of_ev(item, phalcon_mvc_modelinterface_ce TSRMLS_CC)) {
- zephir_array_append(&related, item, PH_SEPARATE, "phalcon/mvc/model.zep", 4087);
+ zephir_array_append(&related, item, PH_SEPARATE, "phalcon/mvc/model.zep", 4086);
}
} else {
ZEPHIR_INIT_NVAR(lowerKey);
@@ -81006,7 +81057,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, unserialize) {
ZEPHIR_CALL_CE_STATIC(&dependencyInjector, phalcon_di_ce, "getdefault", &_0, 1);
zephir_check_call_status();
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 4224);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 4223);
return;
}
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
@@ -81017,13 +81068,13 @@ static PHP_METHOD(Phalcon_Mvc_Model, unserialize) {
zephir_check_call_status();
ZEPHIR_CPY_WRT(manager, _1);
if (Z_TYPE_P(manager) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 4237);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 4236);
return;
}
zephir_update_property_this(this_ptr, SL("_modelsManager"), manager TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, manager, "initialize", NULL, 0, this_ptr);
zephir_check_call_status();
- zephir_is_iterable(attributes, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 4256);
+ zephir_is_iterable(attributes, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 4255);
for (
; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS
; zephir_hash_move_forward_ex(_4, &_3)
@@ -81073,7 +81124,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, toArray) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_0, metaData, "getattributes", NULL, 0, this_ptr);
zephir_check_call_status();
- zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4320);
+ zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4319);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -81089,7 +81140,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, toArray) {
ZEPHIR_CONCAT_SVS(_5, "Column '", attribute, "' doesn't make part of the column map");
ZEPHIR_CALL_METHOD(NULL, _4, "__construct", &_6, 9, _5);
zephir_check_call_status();
- zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 4298 TSRMLS_CC);
+ zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 4297 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
} else {
@@ -82839,9 +82890,11 @@ static PHP_METHOD(Phalcon_Mvc_Url, getBasePath) {
static PHP_METHOD(Phalcon_Mvc_Url, get) {
+ unsigned char _10, _12;
int ZEPHIR_LAST_CALL_STATUS;
- zend_bool _0, _1;
- zval *uri = NULL, *args = NULL, *local = NULL, *baseUri = NULL, *router = NULL, *dependencyInjector = NULL, *routeName, *route = NULL, *queryString = NULL, *_2, *_3 = NULL, _4 = zval_used_for_init, *_5, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9;
+ zend_bool _0, _1, _11;
+ zval *strUri = NULL, *_9 = NULL;
+ zval *uri = NULL, *args = NULL, *local = NULL, *baseUri = NULL, *router = NULL, *dependencyInjector = NULL, *routeName, *route = NULL, *queryString = NULL, *_2, *_3 = NULL, _4 = zval_used_for_init, *_5, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_13;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 0, 4, &uri, &args, &local, &baseUri);
@@ -82869,9 +82922,9 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
if (Z_TYPE_P(local) == IS_NULL) {
_0 = Z_TYPE_P(uri) == IS_STRING;
if (_0) {
- _1 = zephir_memnstr_str(uri, SL("//"), "phalcon/mvc/url.zep", 178);
+ _1 = zephir_memnstr_str(uri, SL("//"), "phalcon/mvc/url.zep", 181);
if (!(_1)) {
- _1 = zephir_memnstr_str(uri, SL(":"), "phalcon/mvc/url.zep", 178);
+ _1 = zephir_memnstr_str(uri, SL(":"), "phalcon/mvc/url.zep", 181);
}
_0 = _1;
}
@@ -82899,7 +82952,7 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
if (Z_TYPE_P(uri) == IS_ARRAY) {
ZEPHIR_OBS_VAR(routeName);
if (!(zephir_array_isset_string_fetch(&routeName, uri, SS("for"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_url_exception_ce, "It's necessary to define the route name with the parameter 'for'", "phalcon/mvc/url.zep", 196);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_url_exception_ce, "It's necessary to define the route name with the parameter 'for'", "phalcon/mvc/url.zep", 199);
return;
}
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_router"), PH_NOISY_CC);
@@ -82908,7 +82961,7 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
ZEPHIR_CPY_WRT(dependencyInjector, _5);
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_url_exception_ce, "A dependency injector container is required to obtain the 'router' service", "phalcon/mvc/url.zep", 208);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_url_exception_ce, "A dependency injector container is required to obtain the 'router' service", "phalcon/mvc/url.zep", 211);
return;
}
ZEPHIR_INIT_NVAR(_3);
@@ -82929,7 +82982,7 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
ZEPHIR_CONCAT_SVS(_7, "Cannot obtain a route using the name '", routeName, "'");
ZEPHIR_CALL_METHOD(NULL, _3, "__construct", NULL, 9, _7);
zephir_check_call_status();
- zephir_throw_exception_debug(_3, "phalcon/mvc/url.zep", 220 TSRMLS_CC);
+ zephir_throw_exception_debug(_3, "phalcon/mvc/url.zep", 223 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -82942,12 +82995,35 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
ZEPHIR_CPY_WRT(uri, _3);
}
if (zephir_is_true(local)) {
- ZEPHIR_INIT_LNVAR(_7);
- ZEPHIR_CONCAT_VV(_7, baseUri, uri);
- ZEPHIR_CPY_WRT(uri, _7);
+ zephir_get_strval(_9, uri);
+ ZEPHIR_CPY_WRT(strUri, _9);
+ _0 = ZEPHIR_IS_STRING(baseUri, "/");
+ if (_0) {
+ _0 = zephir_fast_strlen_ev(strUri) > 2;
+ }
+ _1 = _0;
+ if (_1) {
+ _10 = ZEPHIR_STRING_OFFSET(strUri, 0);
+ _1 = _10 == '/';
+ }
+ _11 = _1;
+ if (_11) {
+ _12 = ZEPHIR_STRING_OFFSET(strUri, 1);
+ _11 = _12 != '/';
+ }
+ ZEPHIR_INIT_NVAR(uri);
+ if (_11) {
+ ZEPHIR_SINIT_NVAR(_4);
+ ZVAL_LONG(&_4, 1);
+ ZEPHIR_INIT_NVAR(_3);
+ zephir_substr(_3, strUri, 1 , 0, ZEPHIR_SUBSTR_NO_LENGTH);
+ ZEPHIR_CONCAT_VV(uri, baseUri, _3);
+ } else {
+ ZEPHIR_CONCAT_VV(uri, baseUri, strUri);
+ }
}
if (zephir_is_true(args)) {
- ZEPHIR_CALL_FUNCTION(&queryString, "http_build_query", NULL, 367, args);
+ ZEPHIR_CALL_FUNCTION(&queryString, "http_build_query", NULL, 369, args);
zephir_check_call_status();
_0 = Z_TYPE_P(queryString) == IS_STRING;
if (_0) {
@@ -82963,9 +83039,9 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
ZEPHIR_CONCAT_SV(_7, "&", queryString);
zephir_concat_self(&uri, _7 TSRMLS_CC);
} else {
- ZEPHIR_INIT_VAR(_9);
- ZEPHIR_CONCAT_SV(_9, "?", queryString);
- zephir_concat_self(&uri, _9 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_13);
+ ZEPHIR_CONCAT_SV(_13, "?", queryString);
+ zephir_concat_self(&uri, _13 TSRMLS_CC);
}
}
}
@@ -83598,19 +83674,19 @@ static PHP_METHOD(Phalcon_Mvc_View, _loadTemplateEngines) {
if (Z_TYPE_P(registeredEngines) != IS_ARRAY) {
ZEPHIR_INIT_VAR(_1);
object_init_ex(_1, phalcon_mvc_view_engine_php_ce);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 368, this_ptr, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 370, this_ptr, dependencyInjector);
zephir_check_call_status();
zephir_array_update_string(&engines, SL(".phtml"), &_1, PH_COPY | PH_SEPARATE);
} else {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "A dependency injector container is required to obtain the application services", "phalcon/mvc/view.zep", 524);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "A dependency injector container is required to obtain the application services", "phalcon/mvc/view.zep", 526);
return;
}
ZEPHIR_INIT_VAR(arguments);
zephir_create_array(arguments, 2, 0 TSRMLS_CC);
zephir_array_fast_append(arguments, this_ptr);
zephir_array_fast_append(arguments, dependencyInjector);
- zephir_is_iterable(registeredEngines, &_3, &_2, 0, 0, "phalcon/mvc/view.zep", 553);
+ zephir_is_iterable(registeredEngines, &_3, &_2, 0, 0, "phalcon/mvc/view.zep", 555);
for (
; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS
; zephir_hash_move_forward_ex(_3, &_2)
@@ -83634,7 +83710,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _loadTemplateEngines) {
ZEPHIR_CONCAT_SV(_6, "Invalid template engine registration for extension: ", extension);
ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6);
zephir_check_call_status();
- zephir_throw_exception_debug(_5, "phalcon/mvc/view.zep", 547 TSRMLS_CC);
+ zephir_throw_exception_debug(_5, "phalcon/mvc/view.zep", 549 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -83728,7 +83804,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _engineRender) {
zephir_read_property_this(&viewParams, this_ptr, SL("_viewParams"), PH_NOISY_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_eventsManager"), PH_NOISY_CC);
ZEPHIR_CPY_WRT(eventsManager, _4);
- zephir_is_iterable(engines, &_6, &_5, 0, 0, "phalcon/mvc/view.zep", 671);
+ zephir_is_iterable(engines, &_6, &_5, 0, 0, "phalcon/mvc/view.zep", 673);
for (
; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS
; zephir_hash_move_forward_ex(_6, &_5)
@@ -83778,7 +83854,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _engineRender) {
ZEPHIR_CONCAT_SVS(_11, "View '", viewsDirPath, "' was not found in the views directory");
ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _11);
zephir_check_call_status();
- zephir_throw_exception_debug(_8, "phalcon/mvc/view.zep", 682 TSRMLS_CC);
+ zephir_throw_exception_debug(_8, "phalcon/mvc/view.zep", 684 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -83843,7 +83919,7 @@ static PHP_METHOD(Phalcon_Mvc_View, exists) {
}
exists = 0;
ZEPHIR_INIT_NVAR(_0);
- zephir_is_iterable(engines, &_2, &_1, 0, 0, "phalcon/mvc/view.zep", 730);
+ zephir_is_iterable(engines, &_2, &_1, 0, 0, "phalcon/mvc/view.zep", 732);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -83937,7 +84013,7 @@ static PHP_METHOD(Phalcon_Mvc_View, render) {
ZEPHIR_CPY_WRT(renderView, _3);
} else {
ZEPHIR_OBS_NVAR(renderView);
- zephir_array_fetch_long(&renderView, pickView, 0, PH_NOISY, "phalcon/mvc/view.zep", 803 TSRMLS_CC);
+ zephir_array_fetch_long(&renderView, pickView, 0, PH_NOISY, "phalcon/mvc/view.zep", 805 TSRMLS_CC);
ZEPHIR_OBS_VAR(pickViewAction);
if (zephir_array_isset_long_fetch(&pickViewAction, pickView, 1, 0 TSRMLS_CC)) {
ZEPHIR_CPY_WRT(layoutName, pickViewAction);
@@ -83995,7 +84071,7 @@ static PHP_METHOD(Phalcon_Mvc_View, render) {
zephir_read_property_this(&templatesBefore, this_ptr, SL("_templatesBefore"), PH_NOISY_CC);
if (Z_TYPE_P(templatesBefore) == IS_ARRAY) {
silence = 0;
- zephir_is_iterable(templatesBefore, &_11, &_10, 0, 0, "phalcon/mvc/view.zep", 879);
+ zephir_is_iterable(templatesBefore, &_11, &_10, 0, 0, "phalcon/mvc/view.zep", 881);
for (
; zephir_hash_get_current_data_ex(_11, (void**) &_12, &_10) == SUCCESS
; zephir_hash_move_forward_ex(_11, &_10)
@@ -84030,7 +84106,7 @@ static PHP_METHOD(Phalcon_Mvc_View, render) {
zephir_read_property_this(&templatesAfter, this_ptr, SL("_templatesAfter"), PH_NOISY_CC);
if (Z_TYPE_P(templatesAfter) == IS_ARRAY) {
silence = 0;
- zephir_is_iterable(templatesAfter, &_15, &_14, 0, 0, "phalcon/mvc/view.zep", 910);
+ zephir_is_iterable(templatesAfter, &_15, &_14, 0, 0, "phalcon/mvc/view.zep", 912);
for (
; zephir_hash_get_current_data_ex(_15, (void**) &_16, &_14) == SUCCESS
; zephir_hash_move_forward_ex(_15, &_14)
@@ -84102,17 +84178,17 @@ static PHP_METHOD(Phalcon_Mvc_View, pick) {
} else {
ZEPHIR_INIT_VAR(layout);
ZVAL_NULL(layout);
- if (zephir_memnstr_str(renderView, SL("/"), "phalcon/mvc/view.zep", 983)) {
+ if (zephir_memnstr_str(renderView, SL("/"), "phalcon/mvc/view.zep", 985)) {
ZEPHIR_INIT_VAR(parts);
zephir_fast_explode_str(parts, SL("/"), renderView, LONG_MAX TSRMLS_CC);
ZEPHIR_OBS_NVAR(layout);
- zephir_array_fetch_long(&layout, parts, 0, PH_NOISY, "phalcon/mvc/view.zep", 984 TSRMLS_CC);
+ zephir_array_fetch_long(&layout, parts, 0, PH_NOISY, "phalcon/mvc/view.zep", 986 TSRMLS_CC);
}
ZEPHIR_INIT_NVAR(pickView);
zephir_create_array(pickView, 1, 0 TSRMLS_CC);
zephir_array_fast_append(pickView, renderView);
if (Z_TYPE_P(layout) != IS_NULL) {
- zephir_array_append(&pickView, layout, PH_SEPARATE, "phalcon/mvc/view.zep", 989);
+ zephir_array_append(&pickView, layout, PH_SEPARATE, "phalcon/mvc/view.zep", 991);
}
}
zephir_update_property_this(this_ptr, SL("_pickView"), pickView TSRMLS_CC);
@@ -84149,7 +84225,7 @@ static PHP_METHOD(Phalcon_Mvc_View, getPartial) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, this_ptr, "partial", NULL, 0, partialPath, params);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", NULL, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", NULL, 291);
zephir_check_call_status();
RETURN_MM();
@@ -84304,7 +84380,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _createCache) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
ZEPHIR_CPY_WRT(dependencyInjector, _0);
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "A dependency injector container is required to obtain the view cache services", "phalcon/mvc/view.zep", 1163);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "A dependency injector container is required to obtain the view cache services", "phalcon/mvc/view.zep", 1165);
return;
}
ZEPHIR_INIT_VAR(cacheService);
@@ -84316,7 +84392,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _createCache) {
if (zephir_array_isset_string_fetch(&cacheOptions, viewOptions, SS("cache"), 0 TSRMLS_CC)) {
if (zephir_array_isset_string(cacheOptions, SS("service"))) {
ZEPHIR_OBS_NVAR(cacheService);
- zephir_array_fetch_string(&cacheService, cacheOptions, SL("service"), PH_NOISY, "phalcon/mvc/view.zep", 1172 TSRMLS_CC);
+ zephir_array_fetch_string(&cacheService, cacheOptions, SL("service"), PH_NOISY, "phalcon/mvc/view.zep", 1174 TSRMLS_CC);
}
}
}
@@ -84324,7 +84400,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _createCache) {
zephir_check_call_status();
ZEPHIR_CPY_WRT(viewCache, _1);
if (Z_TYPE_P(viewCache) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "The injected caching service is invalid", "phalcon/mvc/view.zep", 1182);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "The injected caching service is invalid", "phalcon/mvc/view.zep", 1184);
return;
}
RETURN_CCTOR(viewCache);
@@ -84392,7 +84468,7 @@ static PHP_METHOD(Phalcon_Mvc_View, cache) {
ZEPHIR_INIT_NVAR(cacheOptions);
array_init(cacheOptions);
}
- zephir_is_iterable(options, &_1, &_0, 0, 0, "phalcon/mvc/view.zep", 1250);
+ zephir_is_iterable(options, &_1, &_0, 0, 0, "phalcon/mvc/view.zep", 1252);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -85730,7 +85806,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection_Behavior_Timestampable, notify) {
ZVAL_NULL(timestamp);
ZEPHIR_OBS_VAR(format);
if (zephir_array_isset_string_fetch(&format, options, SS("format"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 299, format);
+ ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 300, format);
zephir_check_call_status();
} else {
ZEPHIR_OBS_VAR(generator);
@@ -87271,7 +87347,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, inWhere) {
array_init(bindParams);
ZEPHIR_INIT_VAR(bindKeys);
array_init(bindKeys);
- zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 450);
+ zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 451);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -87281,7 +87357,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, inWhere) {
ZEPHIR_CONCAT_SV(key, "AP", hiddenParam);
ZEPHIR_INIT_NVAR(queryKey);
ZEPHIR_CONCAT_SVS(queryKey, ":", key, ":");
- zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 441);
+ zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 442);
zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE);
ZEPHIR_SEPARATE(hiddenParam);
zephir_increment(hiddenParam);
@@ -87330,7 +87406,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, notInWhere) {
array_init(bindParams);
ZEPHIR_INIT_VAR(bindKeys);
array_init(bindKeys);
- zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 487);
+ zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 488);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -87340,7 +87416,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, notInWhere) {
ZEPHIR_CONCAT_SV(key, "AP", hiddenParam);
ZEPHIR_INIT_LNVAR(_3);
ZEPHIR_CONCAT_SVS(_3, ":", key, ":");
- zephir_array_append(&bindKeys, _3, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 477);
+ zephir_array_append(&bindKeys, _3, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 478);
zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE);
ZEPHIR_SEPARATE(hiddenParam);
zephir_increment(hiddenParam);
@@ -87669,14 +87745,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, getParams) {
static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) {
- zend_bool _6;
+ zend_bool _6, _7;
HashTable *_4;
HashPosition _3;
zend_class_entry *_2;
int ZEPHIR_LAST_CALL_STATUS;
zval *data = NULL;
zval *modelName = NULL;
- zval *dependencyInjector, *modelName_param = NULL, *data_param = NULL, *conditions, *field = NULL, *value = NULL, *type = NULL, *metaData = NULL, *model, *dataTypes = NULL, *bind, *criteria, *_0 = NULL, *_1 = NULL, **_5, *_7 = NULL, *_8 = NULL;
+ zval *dependencyInjector, *modelName_param = NULL, *data_param = NULL, *attribute = NULL, *conditions, *field = NULL, *value = NULL, *type = NULL, *metaData = NULL, *model, *dataTypes = NULL, *bind, *criteria, *columnMap = NULL, *_0 = NULL, *_1 = NULL, **_5, *_8 = NULL, *_9 = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &dependencyInjector, &modelName_param, &data_param);
@@ -87714,35 +87790,47 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) {
}
ZEPHIR_CALL_METHOD(&dataTypes, metaData, "getdatatypes", NULL, 0, model);
zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&columnMap, metaData, "getreversecolumnmap", NULL, 0, model);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(bind);
array_init(bind);
- zephir_is_iterable(data, &_4, &_3, 0, 0, "phalcon/mvc/model/criteria.zep", 720);
+ zephir_is_iterable(data, &_4, &_3, 0, 0, "phalcon/mvc/model/criteria.zep", 732);
for (
; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS
; zephir_hash_move_forward_ex(_4, &_3)
) {
ZEPHIR_GET_HMKEY(field, _4, _3);
ZEPHIR_GET_HVALUE(value, _5);
+ _6 = Z_TYPE_P(columnMap) == IS_ARRAY;
+ if (_6) {
+ _6 = (zephir_fast_count_int(columnMap TSRMLS_CC)) ? 1 : 0;
+ }
+ if (_6) {
+ ZEPHIR_OBS_NVAR(attribute);
+ zephir_array_fetch(&attribute, columnMap, field, PH_NOISY, "phalcon/mvc/model/criteria.zep", 709 TSRMLS_CC);
+ } else {
+ ZEPHIR_CPY_WRT(attribute, field);
+ }
ZEPHIR_OBS_NVAR(type);
- if (zephir_array_isset_fetch(&type, dataTypes, field, 0 TSRMLS_CC)) {
- _6 = Z_TYPE_P(value) != IS_NULL;
- if (_6) {
- _6 = !ZEPHIR_IS_STRING_IDENTICAL(value, "");
+ if (zephir_array_isset_fetch(&type, dataTypes, attribute, 0 TSRMLS_CC)) {
+ _7 = Z_TYPE_P(value) != IS_NULL;
+ if (_7) {
+ _7 = !ZEPHIR_IS_STRING_IDENTICAL(value, "");
}
- if (_6) {
+ if (_7) {
if (ZEPHIR_IS_LONG(type, 2)) {
- ZEPHIR_INIT_LNVAR(_7);
- ZEPHIR_CONCAT_VSVS(_7, field, " LIKE :", field, ":");
- zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 710);
ZEPHIR_INIT_LNVAR(_8);
- ZEPHIR_CONCAT_SVS(_8, "%", value, "%");
- zephir_array_update_zval(&bind, field, &_8, PH_COPY | PH_SEPARATE);
- } else {
- ZEPHIR_INIT_LNVAR(_7);
- ZEPHIR_CONCAT_VSVS(_7, field, " = :", field, ":");
- zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 715);
- zephir_array_update_zval(&bind, field, &value, PH_COPY | PH_SEPARATE);
+ ZEPHIR_CONCAT_SVSVS(_8, "[", field, "] LIKE :", field, ":");
+ zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 721);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, "%", value, "%");
+ zephir_array_update_zval(&bind, field, &_9, PH_COPY | PH_SEPARATE);
+ continue;
}
+ ZEPHIR_INIT_LNVAR(_8);
+ ZEPHIR_CONCAT_SVSVS(_8, "[", field, "] = :", field, ":");
+ zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 728);
+ zephir_array_update_zval(&bind, field, &value, PH_COPY | PH_SEPARATE);
}
}
}
@@ -87756,12 +87844,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) {
if (zephir_fast_count_int(conditions TSRMLS_CC)) {
ZEPHIR_INIT_NVAR(_0);
zephir_fast_join_str(_0, SL(" AND "), conditions TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, criteria, "where", NULL, 312, _0);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "where", NULL, 313, _0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, criteria, "bind", NULL, 313, bind);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "bind", NULL, 314, bind);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 309, modelName);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 310, modelName);
zephir_check_call_status();
RETURN_CCTOR(criteria);
@@ -87778,7 +87866,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, execute) {
ZEPHIR_CALL_METHOD(&model, this_ptr, "getmodelname", NULL, 0);
zephir_check_call_status();
if (Z_TYPE_P(model) != IS_STRING) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Model name must be string", "phalcon/mvc/model/criteria.zep", 744);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Model name must be string", "phalcon/mvc/model/criteria.zep", 756);
return;
}
ZEPHIR_CALL_METHOD(&_0, this_ptr, "getparams", NULL, 0);
@@ -88783,7 +88871,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasOne) {
object_init_ex(relation, phalcon_mvc_model_relation_ce);
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, 1);
- ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 314, _1, referencedModel, fields, referencedFields, options);
+ ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _1, referencedModel, fields, referencedFields, options);
zephir_check_call_status();
ZEPHIR_OBS_VAR(alias);
if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) {
@@ -88860,7 +88948,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addBelongsTo) {
object_init_ex(relation, phalcon_mvc_model_relation_ce);
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, 0);
- ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 314, _1, referencedModel, fields, referencedFields, options);
+ ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _1, referencedModel, fields, referencedFields, options);
zephir_check_call_status();
ZEPHIR_OBS_VAR(alias);
if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) {
@@ -88938,7 +89026,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasMany) {
object_init_ex(relation, phalcon_mvc_model_relation_ce);
ZEPHIR_INIT_VAR(_0);
ZVAL_LONG(_0, 2);
- ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 314, _0, referencedModel, fields, referencedFields, options);
+ ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _0, referencedModel, fields, referencedFields, options);
zephir_check_call_status();
ZEPHIR_OBS_VAR(alias);
if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) {
@@ -89035,9 +89123,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasManyToMany) {
object_init_ex(relation, phalcon_mvc_model_relation_ce);
ZEPHIR_INIT_VAR(_0);
ZVAL_LONG(_0, 4);
- ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 314, _0, referencedModel, fields, referencedFields, options);
+ ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _0, referencedModel, fields, referencedFields, options);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, relation, "setintermediaterelation", NULL, 315, intermediateFields, intermediateModel, intermediateReferencedFields);
+ ZEPHIR_CALL_METHOD(NULL, relation, "setintermediaterelation", NULL, 316, intermediateFields, intermediateModel, intermediateReferencedFields);
zephir_check_call_status();
ZEPHIR_OBS_VAR(alias);
if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) {
@@ -89498,7 +89586,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1245);
return;
}
- ZEPHIR_CALL_METHOD(&_2, this_ptr, "_mergefindparameters", &_3, 316, extraParameters, parameters);
+ ZEPHIR_CALL_METHOD(&_2, this_ptr, "_mergefindparameters", &_3, 317, extraParameters, parameters);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&builder, this_ptr, "createbuilder", NULL, 0, _2);
zephir_check_call_status();
@@ -89563,10 +89651,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) {
ZEPHIR_CALL_METHOD(&_2, record, "getdi", NULL, 0);
zephir_check_call_status();
zephir_array_update_string(&findParams, SL("di"), &_2, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&findArguments, this_ptr, "_mergefindparameters", &_3, 316, findParams, parameters);
+ ZEPHIR_CALL_METHOD(&findArguments, this_ptr, "_mergefindparameters", &_3, 317, findParams, parameters);
zephir_check_call_status();
if (Z_TYPE_P(extraParameters) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&findParams, this_ptr, "_mergefindparameters", &_3, 316, findArguments, extraParameters);
+ ZEPHIR_CALL_METHOD(&findParams, this_ptr, "_mergefindparameters", &_3, 317, findArguments, extraParameters);
zephir_check_call_status();
} else {
ZEPHIR_CPY_WRT(findParams, findArguments);
@@ -91989,7 +92077,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCallArgument) {
add_assoc_stringl_ex(return_value, SS("type"), SL("all"), 1);
RETURN_MM();
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getexpression", NULL, 321, argument);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getexpression", NULL, 323, argument);
zephir_check_call_status();
RETURN_MM();
@@ -92025,11 +92113,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) {
zephir_create_array(_4, 3, 0 TSRMLS_CC);
add_assoc_stringl_ex(_4, SS("type"), SL("when"), 1);
zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 344 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 321, _6);
+ ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6);
zephir_check_call_status();
zephir_array_update_string(&_4, SL("expr"), &_5, PH_COPY | PH_SEPARATE);
zephir_array_fetch_string(&_8, whenExpr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 345 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 321, _8);
+ ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _8);
zephir_check_call_status();
zephir_array_update_string(&_4, SL("then"), &_5, PH_COPY | PH_SEPARATE);
zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 346);
@@ -92038,7 +92126,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) {
zephir_create_array(_4, 2, 0 TSRMLS_CC);
add_assoc_stringl_ex(_4, SS("type"), SL("else"), 1);
zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 350 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 321, _6);
+ ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6);
zephir_check_call_status();
zephir_array_update_string(&_4, SL("expr"), &_5, PH_COPY | PH_SEPARATE);
zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 351);
@@ -92047,7 +92135,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) {
zephir_create_array(return_value, 3, 0 TSRMLS_CC);
add_assoc_stringl_ex(return_value, SS("type"), SL("case"), 1);
zephir_array_fetch_string(&_6, expr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 357 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 321, _6);
+ ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6);
zephir_check_call_status();
zephir_array_update_string(&return_value, SL("expr"), &_5, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&return_value, SL("when-clauses"), &whenClauses, PH_COPY | PH_SEPARATE);
@@ -92087,13 +92175,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) {
; zephir_hash_move_forward_ex(_1, &_0)
) {
ZEPHIR_GET_HVALUE(argument, _2);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 322, argument);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 324, argument);
zephir_check_call_status();
zephir_array_append(&functionArgs, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 381);
}
} else {
zephir_create_array(functionArgs, 1, 0 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 322, arguments);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 324, arguments);
zephir_check_call_status();
zephir_array_fast_append(functionArgs, _3);
}
@@ -92156,12 +92244,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
if (!ZEPHIR_IS_LONG(exprType, 409)) {
ZEPHIR_OBS_VAR(exprLeft);
if (zephir_array_isset_string_fetch(&exprLeft, expr, SS("left"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&left, this_ptr, "_getexpression", &_0, 321, exprLeft, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&left, this_ptr, "_getexpression", &_0, 323, exprLeft, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
}
ZEPHIR_OBS_VAR(exprRight);
if (zephir_array_isset_string_fetch(&exprRight, expr, SS("right"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&right, this_ptr, "_getexpression", &_0, 321, exprRight, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&right, this_ptr, "_getexpression", &_0, 323, exprRight, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
}
}
@@ -92239,7 +92327,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
break;
}
if (ZEPHIR_IS_LONG(exprType, 355)) {
- ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getqualified", &_1, 323, expr);
+ ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getqualified", &_1, 325, expr);
zephir_check_call_status();
break;
}
@@ -92684,12 +92772,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
break;
}
if (ZEPHIR_IS_LONG(exprType, 350)) {
- ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getfunctioncall", NULL, 324, expr);
+ ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getfunctioncall", NULL, 326, expr);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(exprType, 409)) {
- ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getcaseexpression", NULL, 325, expr);
+ ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getcaseexpression", NULL, 327, expr);
zephir_check_call_status();
break;
}
@@ -92699,7 +92787,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
add_assoc_stringl_ex(exprReturn, SS("type"), SL("select"), 1);
ZEPHIR_INIT_NVAR(_3);
ZVAL_BOOL(_3, 1);
- ZEPHIR_CALL_METHOD(&_12, this_ptr, "_prepareselect", NULL, 326, expr, _3);
+ ZEPHIR_CALL_METHOD(&_12, this_ptr, "_prepareselect", NULL, 328, expr, _3);
zephir_check_call_status();
zephir_array_update_string(&exprReturn, SL("value"), &_12, PH_COPY | PH_SEPARATE);
break;
@@ -92718,7 +92806,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
RETURN_CCTOR(exprReturn);
}
if (zephir_array_isset_string(expr, SS("domain"))) {
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualified", &_1, 323, expr);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualified", &_1, 325, expr);
zephir_check_call_status();
RETURN_MM();
}
@@ -92731,7 +92819,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
; zephir_hash_move_forward_ex(_14, &_13)
) {
ZEPHIR_GET_HVALUE(exprListItem, _15);
- ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_0, 321, exprListItem);
+ ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_0, 323, exprListItem);
zephir_check_call_status();
zephir_array_append(&listItems, _12, PH_SEPARATE, "phalcon/mvc/model/query.zep", 735);
}
@@ -92833,7 +92921,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSelectColumn) {
add_assoc_stringl_ex(sqlColumn, SS("type"), SL("scalar"), 1);
ZEPHIR_OBS_VAR(columnData);
zephir_array_fetch_string(&columnData, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 838 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&sqlExprColumn, this_ptr, "_getexpression", NULL, 321, columnData);
+ ZEPHIR_CALL_METHOD(&sqlExprColumn, this_ptr, "_getexpression", NULL, 323, columnData);
zephir_check_call_status();
ZEPHIR_OBS_VAR(balias);
if (zephir_array_isset_string_fetch(&balias, sqlExprColumn, SS("balias"), 0 TSRMLS_CC)) {
@@ -93026,7 +93114,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) {
add_assoc_long_ex(_2, SS("type"), 355);
zephir_array_update_string(&_2, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_2, SL("name"), &fields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 323, _2);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _2);
zephir_check_call_status();
zephir_array_update_string(&_0, SL("left"), &_1, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_VAR(_4);
@@ -93034,7 +93122,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) {
add_assoc_stringl_ex(_4, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_4, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 323, _4);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _4);
zephir_check_call_status();
zephir_array_update_string(&_0, SL("right"), &_1, PH_COPY | PH_SEPARATE);
zephir_array_fast_append(sqlJoinConditions, _0);
@@ -93070,7 +93158,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) {
add_assoc_long_ex(_2, SS("type"), 355);
zephir_array_update_string(&_2, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_2, SL("name"), &field, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 323, _2);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _2);
zephir_check_call_status();
zephir_array_update_string(&_0, SL("left"), &_1, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_NVAR(_4);
@@ -93078,7 +93166,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) {
add_assoc_stringl_ex(_4, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_4, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("name"), &referencedField, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 323, _4);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _4);
zephir_check_call_status();
zephir_array_update_string(&_0, SL("right"), &_1, PH_COPY | PH_SEPARATE);
zephir_array_append(&sqlJoinPartialConditions, _0, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1041);
@@ -93161,7 +93249,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_long_ex(_8, SS("type"), 355);
zephir_array_update_string(&_8, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_8, SL("name"), &field, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _8);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _8);
zephir_check_call_status();
zephir_array_update_string(&sqlEqualsJoinCondition, SL("left"), &_7, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_NVAR(_10);
@@ -93169,7 +93257,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_stringl_ex(_10, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_10, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_10, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _10);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _10);
zephir_check_call_status();
zephir_array_update_string(&sqlEqualsJoinCondition, SL("right"), &_7, PH_COPY | PH_SEPARATE);
}
@@ -93191,7 +93279,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_long_ex(_12, SS("type"), 355);
zephir_array_update_string(&_12, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_12, SL("name"), &fields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _12);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _12);
zephir_check_call_status();
zephir_array_update_string(&_11, SL("left"), &_7, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_VAR(_13);
@@ -93199,7 +93287,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_stringl_ex(_13, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_13, SL("domain"), &intermediateModelName, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_13, SL("name"), &intermediateFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _13);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _13);
zephir_check_call_status();
zephir_array_update_string(&_11, SL("right"), &_7, PH_COPY | PH_SEPARATE);
zephir_array_fast_append(_10, _11);
@@ -93220,7 +93308,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_long_ex(_14, SS("type"), 355);
zephir_array_update_string(&_14, SL("domain"), &intermediateModelName, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_14, SL("name"), &intermediateReferencedFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _14);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _14);
zephir_check_call_status();
zephir_array_update_string(&_11, SL("left"), &_7, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_VAR(_15);
@@ -93228,7 +93316,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_stringl_ex(_15, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_15, SL("domain"), &referencedModelName, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_15, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _15);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _15);
zephir_check_call_status();
zephir_array_update_string(&_11, SL("right"), &_7, PH_COPY | PH_SEPARATE);
zephir_array_fast_append(_10, _11);
@@ -93295,7 +93383,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) {
; zephir_hash_move_forward_ex(_1, &_0)
) {
ZEPHIR_GET_HVALUE(joinItem, _2);
- ZEPHIR_CALL_METHOD(&joinData, this_ptr, "_getjoin", &_3, 327, manager, joinItem);
+ ZEPHIR_CALL_METHOD(&joinData, this_ptr, "_getjoin", &_3, 329, manager, joinItem);
zephir_check_call_status();
ZEPHIR_OBS_NVAR(source);
zephir_array_fetch_string(&source, joinData, SL("source"), PH_NOISY, "phalcon/mvc/model/query.zep", 1273 TSRMLS_CC);
@@ -93309,7 +93397,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) {
zephir_create_array(completeSource, 2, 0 TSRMLS_CC);
zephir_array_fast_append(completeSource, source);
zephir_array_fast_append(completeSource, schema);
- ZEPHIR_CALL_METHOD(&joinType, this_ptr, "_getjointype", &_4, 328, joinItem);
+ ZEPHIR_CALL_METHOD(&joinType, this_ptr, "_getjointype", &_4, 330, joinItem);
zephir_check_call_status();
ZEPHIR_OBS_NVAR(aliasExpr);
if (zephir_array_isset_string_fetch(&aliasExpr, joinItem, SS("alias"), 0 TSRMLS_CC)) {
@@ -93377,7 +93465,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) {
ZEPHIR_GET_HVALUE(joinItem, _11);
ZEPHIR_OBS_NVAR(joinExpr);
if (zephir_array_isset_string_fetch(&joinExpr, joinItem, SS("conditions"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_13, 321, joinExpr);
+ ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_13, 323, joinExpr);
zephir_check_call_status();
zephir_array_update_zval(&joinPreCondition, joinAliasName, &_12, PH_COPY | PH_SEPARATE);
}
@@ -93435,10 +93523,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) {
ZEPHIR_CALL_METHOD(&_12, relation, "isthrough", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_12))) {
- ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getsinglejoin", &_23, 329, joinType, joinSource, modelAlias, joinAlias, relation);
+ ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getsinglejoin", &_23, 331, joinType, joinSource, modelAlias, joinAlias, relation);
zephir_check_call_status();
} else {
- ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getmultijoin", &_24, 330, joinType, joinSource, modelAlias, joinAlias, relation);
+ ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getmultijoin", &_24, 332, joinType, joinSource, modelAlias, joinAlias, relation);
zephir_check_call_status();
}
if (zephir_array_isset_long(sqlJoin, 0)) {
@@ -93509,7 +93597,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getOrderClause) {
) {
ZEPHIR_GET_HVALUE(orderItem, _2);
zephir_array_fetch_string(&_3, orderItem, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1560 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&orderPartExpr, this_ptr, "_getexpression", &_4, 321, _3);
+ ZEPHIR_CALL_METHOD(&orderPartExpr, this_ptr, "_getexpression", &_4, 323, _3);
zephir_check_call_status();
if (zephir_array_isset_string_fetch(&orderSort, orderItem, SS("sort"), 1 TSRMLS_CC)) {
ZEPHIR_INIT_NVAR(orderPartSort);
@@ -93562,13 +93650,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getGroupClause) {
; zephir_hash_move_forward_ex(_1, &_0)
) {
ZEPHIR_GET_HVALUE(groupItem, _2);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 321, groupItem);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 323, groupItem);
zephir_check_call_status();
zephir_array_append(&groupParts, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1594);
}
} else {
zephir_create_array(groupParts, 1, 0 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 321, group);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 323, group);
zephir_check_call_status();
zephir_array_fast_append(groupParts, _3);
}
@@ -93594,13 +93682,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getLimitClause) {
ZEPHIR_OBS_VAR(number);
if (zephir_array_isset_string_fetch(&number, limitClause, SS("number"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 321, number);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 323, number);
zephir_check_call_status();
zephir_array_update_string(&limit, SL("number"), &_0, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(offset);
if (zephir_array_isset_string_fetch(&offset, limitClause, SS("offset"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 321, offset);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 323, offset);
zephir_check_call_status();
zephir_array_update_string(&limit, SL("offset"), &_0, PH_COPY | PH_SEPARATE);
}
@@ -93804,7 +93892,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) {
ZEPHIR_OBS_VAR(joins);
if (zephir_array_isset_string_fetch(&joins, select, SS("joins"), 0 TSRMLS_CC)) {
if (zephir_fast_count_int(joins TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", NULL, 331, select);
+ ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", NULL, 333, select);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(sqlJoins);
@@ -93830,7 +93918,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) {
; zephir_hash_move_forward_ex(_23, &_22)
) {
ZEPHIR_GET_HVALUE(column, _24);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getselectcolumn", &_25, 332, column);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getselectcolumn", &_25, 334, column);
zephir_check_call_status();
zephir_is_iterable(_3, &_27, &_26, 0, 0, "phalcon/mvc/model/query.zep", 1856);
for (
@@ -93879,31 +93967,31 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) {
}
ZEPHIR_OBS_VAR(where);
if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_31, 321, where);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_31, 323, where);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("where"), &_3, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(groupBy);
if (zephir_array_isset_string_fetch(&groupBy, ast, SS("groupBy"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getgroupclause", NULL, 333, groupBy);
+ ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getgroupclause", NULL, 335, groupBy);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("group"), &_32, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(having);
if (zephir_array_isset_string_fetch(&having, ast, SS("having"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getexpression", &_31, 321, having);
+ ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getexpression", &_31, 323, having);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("having"), &_32, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(order);
if (zephir_array_isset_string_fetch(&order, ast, SS("orderBy"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getorderclause", NULL, 334, order);
+ ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getorderclause", NULL, 336, order);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("order"), &_32, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(limit);
if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getlimitclause", NULL, 335, limit);
+ ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getlimitclause", NULL, 337, limit);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("limit"), &_32, PH_COPY | PH_SEPARATE);
}
@@ -93987,7 +94075,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) {
ZEPHIR_OBS_NVAR(_8);
zephir_array_fetch_string(&_8, exprValue, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 1960 TSRMLS_CC);
zephir_array_update_string(&_7, SL("type"), &_8, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_9, 321, exprValue, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_9, 323, exprValue, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_array_update_string(&_7, SL("value"), &_0, PH_COPY | PH_SEPARATE);
zephir_array_append(&exprValues, _7, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1962);
@@ -94162,7 +94250,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) {
) {
ZEPHIR_GET_HVALUE(updateValue, _11);
zephir_array_fetch_string(&_4, updateValue, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2110 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_12, 321, _4, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_12, 323, _4, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_array_append(&sqlFields, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2110);
ZEPHIR_OBS_NVAR(exprColumn);
@@ -94172,7 +94260,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) {
ZEPHIR_OBS_NVAR(_14);
zephir_array_fetch_string(&_14, exprColumn, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 2113 TSRMLS_CC);
zephir_array_update_string(&_13, SL("type"), &_14, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 321, exprColumn, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 323, exprColumn, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_array_update_string(&_13, SL("value"), &_15, PH_COPY | PH_SEPARATE);
zephir_array_append(&sqlValues, _13, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2115);
@@ -94187,13 +94275,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) {
if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) {
ZEPHIR_SINIT_VAR(_16);
ZVAL_BOOL(&_16, 1);
- ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 321, where, &_16);
+ ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 323, where, &_16);
zephir_check_call_status();
zephir_array_update_string(&sqlUpdate, SL("where"), &_15, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(limit);
if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getlimitclause", NULL, 335, limit);
+ ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getlimitclause", NULL, 337, limit);
zephir_check_call_status();
zephir_array_update_string(&sqlUpdate, SL("limit"), &_15, PH_COPY | PH_SEPARATE);
}
@@ -94312,13 +94400,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) {
if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) {
ZEPHIR_SINIT_VAR(_9);
ZVAL_BOOL(&_9, 1);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", NULL, 321, where, &_9);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", NULL, 323, where, &_9);
zephir_check_call_status();
zephir_array_update_string(&sqlDelete, SL("where"), &_3, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(limit);
if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_10, this_ptr, "_getlimitclause", NULL, 335, limit);
+ ZEPHIR_CALL_METHOD(&_10, this_ptr, "_getlimitclause", NULL, 337, limit);
zephir_check_call_status();
zephir_array_update_string(&sqlDelete, SL("limit"), &_10, PH_COPY | PH_SEPARATE);
}
@@ -94366,22 +94454,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, parse) {
zephir_update_property_this(this_ptr, SL("_type"), type TSRMLS_CC);
do {
if (ZEPHIR_IS_LONG(type, 309)) {
- ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareselect", NULL, 326);
+ ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareselect", NULL, 328);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 306)) {
- ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareinsert", NULL, 336);
+ ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareinsert", NULL, 338);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 300)) {
- ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareupdate", NULL, 337);
+ ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareupdate", NULL, 339);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 303)) {
- ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_preparedelete", NULL, 338);
+ ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_preparedelete", NULL, 340);
zephir_check_call_status();
break;
}
@@ -94768,12 +94856,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) {
isKeepingSnapshots = zephir_get_boolval(_40);
}
object_init_ex(return_value, phalcon_mvc_model_resultset_simple_ce);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 339, simpleColumnMap, resultObject, resultData, cache, (isKeepingSnapshots ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 341, simpleColumnMap, resultObject, resultData, cache, (isKeepingSnapshots ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
}
object_init_ex(return_value, phalcon_mvc_model_resultset_complex_ce);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 340, columns1, resultData, cache);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 342, columns1, resultData, cache);
zephir_check_call_status();
RETURN_MM();
@@ -94933,7 +95021,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_CALL_METHOD(&_15, insertModel, "create", NULL, 0, insertValues);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 341, _15, insertModel);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 343, _15, insertModel);
zephir_check_call_status();
RETURN_MM();
@@ -95064,13 +95152,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) {
zephir_array_update_zval(&updateValues, fieldName, &updateValue, PH_COPY | PH_SEPARATE);
}
- ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 342, model, intermediate, selectBindParams, selectBindTypes);
+ ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 344, model, intermediate, selectBindParams, selectBindTypes);
zephir_check_call_status();
if (!(zephir_fast_count_int(records TSRMLS_CC))) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_11);
ZVAL_BOOL(_11, 1);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 341, _11);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11);
zephir_check_call_status();
RETURN_MM();
}
@@ -95103,7 +95191,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_11);
ZVAL_BOOL(_11, 0);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 341, _11, record);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11, record);
zephir_check_call_status();
RETURN_MM();
}
@@ -95114,7 +95202,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_11);
ZVAL_BOOL(_11, 1);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 341, _11);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11);
zephir_check_call_status();
RETURN_MM();
@@ -95147,13 +95235,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) {
ZEPHIR_CALL_METHOD(&model, _1, "load", NULL, 0, modelName);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 342, model, intermediate, bindParams, bindTypes);
+ ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 344, model, intermediate, bindParams, bindTypes);
zephir_check_call_status();
if (!(zephir_fast_count_int(records TSRMLS_CC))) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_VAR(_2);
ZVAL_BOOL(_2, 1);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 341, _2);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2);
zephir_check_call_status();
RETURN_MM();
}
@@ -95186,7 +95274,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_2);
ZVAL_BOOL(_2, 0);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 341, _2, record);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2, record);
zephir_check_call_status();
RETURN_MM();
}
@@ -95197,7 +95285,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_2);
ZVAL_BOOL(_2, 1);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 341, _2);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2);
zephir_check_call_status();
RETURN_MM();
@@ -95245,18 +95333,18 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getRelatedRecords) {
}
ZEPHIR_INIT_VAR(query);
object_init_ex(query, phalcon_mvc_model_query_ce);
- ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 343);
+ ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 345);
zephir_check_call_status();
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, query, "setdi", NULL, 344, _5);
+ ZEPHIR_CALL_METHOD(NULL, query, "setdi", NULL, 346, _5);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_2);
ZVAL_LONG(_2, 309);
- ZEPHIR_CALL_METHOD(NULL, query, "settype", NULL, 345, _2);
+ ZEPHIR_CALL_METHOD(NULL, query, "settype", NULL, 347, _2);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, query, "setintermediate", NULL, 346, selectIr);
+ ZEPHIR_CALL_METHOD(NULL, query, "setintermediate", NULL, 348, selectIr);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_METHOD(query, "execute", NULL, 347, bindParams, bindTypes);
+ ZEPHIR_RETURN_CALL_METHOD(query, "execute", NULL, 349, bindParams, bindTypes);
zephir_check_call_status();
RETURN_MM();
@@ -95377,22 +95465,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) {
zephir_read_property_this(&type, this_ptr, SL("_type"), PH_NOISY_CC);
do {
if (ZEPHIR_IS_LONG(type, 309)) {
- ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeselect", NULL, 348, intermediate, mergedParams, mergedTypes);
+ ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeselect", NULL, 350, intermediate, mergedParams, mergedTypes);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 306)) {
- ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeinsert", NULL, 349, intermediate, mergedParams, mergedTypes);
+ ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeinsert", NULL, 351, intermediate, mergedParams, mergedTypes);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 300)) {
- ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeupdate", NULL, 350, intermediate, mergedParams, mergedTypes);
+ ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeupdate", NULL, 352, intermediate, mergedParams, mergedTypes);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 303)) {
- ZEPHIR_CALL_METHOD(&result, this_ptr, "_executedelete", NULL, 351, intermediate, mergedParams, mergedTypes);
+ ZEPHIR_CALL_METHOD(&result, this_ptr, "_executedelete", NULL, 353, intermediate, mergedParams, mergedTypes);
zephir_check_call_status();
break;
}
@@ -95447,7 +95535,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, getSingleResult) {
zephir_check_call_status();
RETURN_MM();
}
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "execute", NULL, 347, bindParams, bindTypes);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "execute", NULL, 349, bindParams, bindTypes);
zephir_check_call_status();
ZEPHIR_RETURN_CALL_METHOD(_1, "getfirst", NULL, 0);
zephir_check_call_status();
@@ -95619,7 +95707,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, getSql) {
_2 = zephir_fetch_nproperty_this(this_ptr, SL("_bindTypes"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_3);
ZVAL_BOOL(&_3, 1);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_executeselect", NULL, 348, intermediate, _1, _2, &_3);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_executeselect", NULL, 350, intermediate, _1, _2, &_3);
zephir_check_call_status();
RETURN_MM();
}
@@ -96572,6 +96660,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, delete) {
static PHP_METHOD(Phalcon_Mvc_Model_Resultset, filter) {
+ zend_bool _1;
int ZEPHIR_LAST_CALL_STATUS;
zend_object_iterator *_0;
zval *filter, *records, *record = NULL, *parameters, *processedRecord = NULL;
@@ -96597,12 +96686,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, filter) {
ZEPHIR_INIT_NVAR(processedRecord);
ZEPHIR_CALL_USER_FUNC_ARRAY(processedRecord, filter, parameters);
zephir_check_call_status();
- if (Z_TYPE_P(processedRecord) != IS_OBJECT) {
- if (Z_TYPE_P(processedRecord) != IS_ARRAY) {
- continue;
- }
+ _1 = Z_TYPE_P(processedRecord) != IS_OBJECT;
+ if (_1) {
+ _1 = Z_TYPE_P(processedRecord) != IS_ARRAY;
+ }
+ if (_1) {
+ continue;
}
- zephir_array_append(&records, processedRecord, PH_SEPARATE, "phalcon/mvc/model/resultset.zep", 558);
+ zephir_array_append(&records, processedRecord, PH_SEPARATE, "phalcon/mvc/model/resultset.zep", 556);
}
_0->funcs->dtor(_0 TSRMLS_CC);
RETURN_CCTOR(records);
@@ -96977,7 +97068,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction, rollback) {
ZEPHIR_INIT_NVAR(_0);
object_init_ex(_0, phalcon_mvc_model_transaction_failed_ce);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_rollbackRecord"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 358, rollbackMessage, _5);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 360, rollbackMessage, _5);
zephir_check_call_status();
zephir_throw_exception_debug(_0, "phalcon/mvc/model/transaction.zep", 160 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -96996,7 +97087,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction, getConnection) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_rollbackOnAbort"), PH_NOISY_CC);
if (zephir_is_true(_0)) {
- ZEPHIR_CALL_FUNCTION(&_1, "connection_aborted", NULL, 359);
+ ZEPHIR_CALL_FUNCTION(&_1, "connection_aborted", NULL, 361);
zephir_check_call_status();
if (zephir_is_true(_1)) {
ZEPHIR_INIT_VAR(_2);
@@ -97566,7 +97657,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Behavior_Timestampable, notify) {
ZVAL_NULL(timestamp);
ZEPHIR_OBS_VAR(format);
if (zephir_array_isset_string_fetch(&format, options, SS("format"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 299, format);
+ ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 300, format);
zephir_check_call_status();
} else {
ZEPHIR_OBS_VAR(generator);
@@ -97922,9 +98013,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Libmemcached, __construct) {
ZEPHIR_OBS_VAR(_3);
zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC);
zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 317, _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 318, _1, options);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 319, _1, options);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_4);
@@ -98023,7 +98114,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Libmemcached, reset) {
zephir_check_call_status();
}
}
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_libmemcached_ce, this_ptr, "reset", &_5, 319);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_libmemcached_ce, this_ptr, "reset", &_5, 320);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -98108,9 +98199,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memcache, __construct) {
ZEPHIR_OBS_VAR(_3);
zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC);
zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 317, _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 320, _1, options);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 321, _1, options);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_4);
@@ -98209,7 +98300,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memcache, reset) {
zephir_check_call_status();
}
}
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_memcache_ce, this_ptr, "reset", &_5, 319);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_memcache_ce, this_ptr, "reset", &_5, 320);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -98310,6 +98401,192 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memory, write) {
+#ifdef HAVE_CONFIG_H
+#endif
+
+#include
+
+#include
+#include
+#include
+
+
+
+ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_MetaData_Redis) {
+
+ ZEPHIR_REGISTER_CLASS_EX(Phalcon\\Mvc\\Model\\MetaData, Redis, phalcon, mvc_model_metadata_redis, phalcon_mvc_model_metadata_ce, phalcon_mvc_model_metadata_redis_method_entry, 0);
+
+ zend_declare_property_long(phalcon_mvc_model_metadata_redis_ce, SL("_ttl"), 172800, ZEND_ACC_PROTECTED TSRMLS_CC);
+
+ zend_declare_property_null(phalcon_mvc_model_metadata_redis_ce, SL("_redis"), ZEND_ACC_PROTECTED TSRMLS_CC);
+
+ zend_class_implements(phalcon_mvc_model_metadata_redis_ce TSRMLS_CC, 1, phalcon_mvc_model_metadatainterface_ce);
+ return SUCCESS;
+
+}
+
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, __construct) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *_2;
+ zval *options = NULL, *ttl, *_0 = NULL, *_1, *_3, *_4;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 0, 1, &options);
+
+ if (!options) {
+ ZEPHIR_CPY_WRT(options, ZEPHIR_GLOBAL(global_null));
+ } else {
+ ZEPHIR_SEPARATE_PARAM(options);
+ }
+
+
+ if (Z_TYPE_P(options) != IS_ARRAY) {
+ ZEPHIR_INIT_NVAR(options);
+ array_init(options);
+ }
+ if (!(zephir_array_isset_string(options, SS("host")))) {
+ ZEPHIR_INIT_VAR(_0);
+ ZVAL_STRING(_0, "127.0.0.1", 1);
+ zephir_array_update_string(&options, SL("host"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("port")))) {
+ ZEPHIR_INIT_NVAR(_0);
+ ZVAL_LONG(_0, 6379);
+ zephir_array_update_string(&options, SL("port"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("persistent")))) {
+ ZEPHIR_INIT_NVAR(_0);
+ ZVAL_LONG(_0, 0);
+ zephir_array_update_string(&options, SL("persistent"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("statsKey")))) {
+ ZEPHIR_INIT_NVAR(_0);
+ ZVAL_STRING(_0, "_PHCM_MM", 1);
+ zephir_array_update_string(&options, SL("statsKey"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (zephir_array_isset_string_fetch(&ttl, options, SS("lifetime"), 1 TSRMLS_CC)) {
+ zephir_update_property_this(this_ptr, SL("_ttl"), ttl TSRMLS_CC);
+ }
+ ZEPHIR_INIT_NVAR(_0);
+ object_init_ex(_0, phalcon_cache_backend_redis_ce);
+ ZEPHIR_INIT_VAR(_1);
+ object_init_ex(_1, phalcon_cache_frontend_data_ce);
+ ZEPHIR_INIT_VAR(_2);
+ zephir_create_array(_2, 1, 0 TSRMLS_CC);
+ ZEPHIR_OBS_VAR(_3);
+ zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC);
+ zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 322, _1, options);
+ zephir_check_call_status();
+ zephir_update_property_this(this_ptr, SL("_redis"), _0 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_4);
+ array_init(_4);
+ zephir_update_property_this(this_ptr, SL("_metaData"), _4 TSRMLS_CC);
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, read) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *key_param = NULL, *data = NULL, *_0;
+ zval *key = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 0, &key_param);
+
+ if (unlikely(Z_TYPE_P(key_param) != IS_STRING && Z_TYPE_P(key_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'key' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(key_param) == IS_STRING)) {
+ zephir_get_strval(key, key_param);
+ } else {
+ ZEPHIR_INIT_VAR(key);
+ ZVAL_EMPTY_STRING(key);
+ }
+
+
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ ZEPHIR_CALL_METHOD(&data, _0, "get", NULL, 0, key);
+ zephir_check_call_status();
+ if (Z_TYPE_P(data) == IS_ARRAY) {
+ RETURN_CCTOR(data);
+ }
+ RETURN_MM_NULL();
+
+}
+
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, write) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *key_param = NULL, *data, *_0;
+ zval *key = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 2, 0, &key_param, &data);
+
+ if (unlikely(Z_TYPE_P(key_param) != IS_STRING && Z_TYPE_P(key_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'key' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(key_param) == IS_STRING)) {
+ zephir_get_strval(key, key_param);
+ } else {
+ ZEPHIR_INIT_VAR(key);
+ ZVAL_EMPTY_STRING(key);
+ }
+
+
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ ZEPHIR_CALL_METHOD(NULL, _0, "save", NULL, 0, key, data);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, reset) {
+
+ zephir_fcall_cache_entry *_5 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ HashTable *_2;
+ HashPosition _1;
+ zval *meta, *key = NULL, *realKey = NULL, *_0 = NULL, **_3, *_4;
+
+ ZEPHIR_MM_GROW();
+
+ ZEPHIR_OBS_VAR(meta);
+ zephir_read_property_this(&meta, this_ptr, SL("_metaData"), PH_NOISY_CC);
+ if (Z_TYPE_P(meta) == IS_ARRAY) {
+ ZEPHIR_INIT_VAR(_0);
+ zephir_is_iterable(meta, &_2, &_1, 0, 0, "phalcon/mvc/model/metadata/redis.zep", 131);
+ for (
+ ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
+ ; zephir_hash_move_forward_ex(_2, &_1)
+ ) {
+ ZEPHIR_GET_HMKEY(key, _2, _1);
+ ZEPHIR_GET_HVALUE(_0, _3);
+ ZEPHIR_INIT_NVAR(realKey);
+ ZEPHIR_CONCAT_SV(realKey, "meta-", key);
+ _4 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ ZEPHIR_CALL_METHOD(NULL, _4, "delete", NULL, 0, realKey);
+ zephir_check_call_status();
+ }
+ }
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_redis_ce, this_ptr, "reset", &_5, 320);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+
+
+
#ifdef HAVE_CONFIG_H
#endif
@@ -100603,7 +100880,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) {
}
}
}
- if (zephir_is_numeric(limit)) {
+ if (zephir_is_numeric(number)) {
ZEPHIR_OBS_VAR(hiddenParam);
zephir_read_property_this(&hiddenParam, this_ptr, SL("_hiddenParamNumber"), PH_NOISY_CC);
ZEPHIR_INIT_LNVAR(_4);
@@ -100664,21 +100941,21 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getQuery) {
ZEPHIR_INIT_VAR(query);
object_init_ex(query, phalcon_mvc_model_query_ce);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getphql", NULL, 352);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getphql", NULL, 354);
zephir_check_call_status();
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 343, _0, _1);
+ ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 345, _0, _1);
zephir_check_call_status();
ZEPHIR_OBS_VAR(bindParams);
zephir_read_property_this(&bindParams, this_ptr, SL("_bindParams"), PH_NOISY_CC);
if (Z_TYPE_P(bindParams) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, query, "setbindparams", NULL, 353, bindParams);
+ ZEPHIR_CALL_METHOD(NULL, query, "setbindparams", NULL, 355, bindParams);
zephir_check_call_status();
}
ZEPHIR_OBS_VAR(bindTypes);
zephir_read_property_this(&bindTypes, this_ptr, SL("_bindTypes"), PH_NOISY_CC);
if (Z_TYPE_P(bindTypes) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, query, "setbindtypes", NULL, 354, bindTypes);
+ ZEPHIR_CALL_METHOD(NULL, query, "setbindtypes", NULL, 356, bindTypes);
zephir_check_call_status();
}
RETURN_CCTOR(query);
@@ -110560,7 +110837,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, __construct) {
zephir_update_property_this(this_ptr, SL("_columnTypes"), columnTypes TSRMLS_CC);
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_complex_ce, this_ptr, "__construct", &_0, 355, result, cache);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_complex_ce, this_ptr, "__construct", &_0, 357, result, cache);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -110877,7 +111154,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, __construct) {
zephir_update_property_this(this_ptr, SL("_model"), model TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_columnMap"), columnMap TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_keepSnapshots"), keepSnapshots TSRMLS_CC);
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_simple_ce, this_ptr, "__construct", &_0, 355, result, cache);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_simple_ce, this_ptr, "__construct", &_0, 357, result, cache);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -110932,12 +111209,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, current) {
_6 = zephir_fetch_nproperty_this(this_ptr, SL("_keepSnapshots"), PH_NOISY_CC);
ZEPHIR_INIT_NVAR(_3);
ZVAL_LONG(_3, 0);
- ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmap", &_5, 356, _2, row, columnMap, _3, _6);
+ ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmap", &_5, 358, _2, row, columnMap, _3, _6);
zephir_check_call_status();
}
break;
}
- ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_7, 357, row, columnMap, hydrateMode);
+ ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_7, 359, row, columnMap, hydrateMode);
zephir_check_call_status();
break;
} while(0);
@@ -110953,7 +111230,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, toArray) {
HashTable *_2, *_5;
HashPosition _1, _4;
int ZEPHIR_LAST_CALL_STATUS;
- zval *renameColumns_param = NULL, *result, *records = NULL, *record = NULL, *renamed = NULL, *renamedKey = NULL, *key = NULL, *value = NULL, *renamedRecords, *columnMap, *_0, **_3, **_6, *_7 = NULL, *_8 = NULL, *_10 = NULL;
+ zval *renameColumns_param = NULL, *result, *records = NULL, *record = NULL, *renamed = NULL, *renamedKey = NULL, *key = NULL, *value = NULL, *renamedRecords, *columnMap, *_0, **_3, **_6, *_7 = NULL, *_8 = NULL;
zend_bool renameColumns;
ZEPHIR_MM_GROW();
@@ -110990,7 +111267,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, toArray) {
ZEPHIR_INIT_VAR(renamedRecords);
array_init(renamedRecords);
if (Z_TYPE_P(records) == IS_ARRAY) {
- zephir_is_iterable(records, &_2, &_1, 0, 0, "phalcon/mvc/model/resultset/simple.zep", 220);
+ zephir_is_iterable(records, &_2, &_1, 0, 0, "phalcon/mvc/model/resultset/simple.zep", 218);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -110998,7 +111275,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, toArray) {
ZEPHIR_GET_HVALUE(record, _3);
ZEPHIR_INIT_NVAR(renamed);
array_init(renamed);
- zephir_is_iterable(record, &_5, &_4, 0, 0, "phalcon/mvc/model/resultset/simple.zep", 218);
+ zephir_is_iterable(record, &_5, &_4, 0, 0, "phalcon/mvc/model/resultset/simple.zep", 216);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
@@ -111030,14 +111307,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, toArray) {
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_OBS_NVAR(_10);
- zephir_array_fetch_long(&_10, renamedKey, 0, PH_NOISY, "phalcon/mvc/model/resultset/simple.zep", 209 TSRMLS_CC);
- zephir_array_update_zval(&renamed, _10, &value, PH_COPY | PH_SEPARATE);
- } else {
- zephir_array_update_zval(&renamed, renamedKey, &value, PH_COPY | PH_SEPARATE);
}
+ zephir_array_update_zval(&renamed, renamedKey, &value, PH_COPY | PH_SEPARATE);
}
- zephir_array_append(&renamedRecords, renamed, PH_SEPARATE, "phalcon/mvc/model/resultset/simple.zep", 218);
+ zephir_array_append(&renamedRecords, renamed, PH_SEPARATE, "phalcon/mvc/model/resultset/simple.zep", 216);
}
}
RETURN_CCTOR(renamedRecords);
@@ -111104,22 +111377,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, unserialize) {
ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 72, data);
zephir_check_call_status();
if (Z_TYPE_P(resultset) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/simple.zep", 254);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/simple.zep", 252);
return;
}
- zephir_array_fetch_string(&_0, resultset, SL("model"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 257 TSRMLS_CC);
+ zephir_array_fetch_string(&_0, resultset, SL("model"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 255 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_model"), _0 TSRMLS_CC);
- zephir_array_fetch_string(&_1, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 258 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 256 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_rows"), _1 TSRMLS_CC);
- zephir_array_fetch_string(&_2, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 259 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 257 TSRMLS_CC);
ZEPHIR_INIT_ZVAL_NREF(_3);
ZVAL_LONG(_3, zephir_fast_count_int(_2 TSRMLS_CC));
zephir_update_property_this(this_ptr, SL("_count"), _3 TSRMLS_CC);
- zephir_array_fetch_string(&_4, resultset, SL("cache"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 260 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, resultset, SL("cache"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 258 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_cache"), _4 TSRMLS_CC);
- zephir_array_fetch_string(&_5, resultset, SL("columnMap"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 261 TSRMLS_CC);
+ zephir_array_fetch_string(&_5, resultset, SL("columnMap"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 259 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_columnMap"), _5 TSRMLS_CC);
- zephir_array_fetch_string(&_6, resultset, SL("hydrateMode"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 262 TSRMLS_CC);
+ zephir_array_fetch_string(&_6, resultset, SL("hydrateMode"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 260 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_hydrateMode"), _6 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -111408,7 +111681,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction_Manager, get) {
ZEPHIR_INIT_VAR(_3);
ZVAL_STRING(_3, "rollbackPendent", 1);
zephir_array_fast_append(_2, _3);
- ZEPHIR_CALL_FUNCTION(NULL, "register_shutdown_function", NULL, 360, _2);
+ ZEPHIR_CALL_FUNCTION(NULL, "register_shutdown_function", NULL, 362, _2);
zephir_check_call_status();
}
zephir_update_property_this(this_ptr, SL("_initialized"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
@@ -111467,9 +111740,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction_Manager, getOrCreateTransaction)
ZEPHIR_INIT_VAR(transaction);
object_init_ex(transaction, phalcon_mvc_model_transaction_ce);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_service"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, transaction, "__construct", NULL, 361, dependencyInjector, (autoBegin ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), _5);
+ ZEPHIR_CALL_METHOD(NULL, transaction, "__construct", NULL, 363, dependencyInjector, (autoBegin ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), _5);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, transaction, "settransactionmanager", NULL, 362, this_ptr);
+ ZEPHIR_CALL_METHOD(NULL, transaction, "settransactionmanager", NULL, 364, this_ptr);
zephir_check_call_status();
zephir_update_property_array_append(this_ptr, SL("_transactions"), transaction TSRMLS_CC);
RETURN_ON_FAILURE(zephir_property_incr(this_ptr, SL("_number") TSRMLS_CC));
@@ -111757,7 +112030,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Email, validate) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 274);
- ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 190, value, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_0);
@@ -112030,7 +112303,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Inclusionin, validate) {
zephir_check_temp_parameter(_0);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_5, "in_array", NULL, 363, value, domain, strict);
+ ZEPHIR_CALL_FUNCTION(&_5, "in_array", NULL, 365, value, domain, strict);
zephir_check_call_status();
if (!(zephir_is_true(_5))) {
ZEPHIR_INIT_NVAR(_0);
@@ -112176,7 +112449,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Ip, validate) {
zephir_array_update_string(&options, SL("flags"), &_6, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, 275);
- ZEPHIR_CALL_FUNCTION(&_7, "filter_var", NULL, 190, value, &_5, options);
+ ZEPHIR_CALL_FUNCTION(&_7, "filter_var", NULL, 191, value, &_5, options);
zephir_check_call_status();
if (!(zephir_is_true(_7))) {
ZEPHIR_INIT_NVAR(_0);
@@ -112646,7 +112919,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_StringLength, validate) {
RETURN_MM_BOOL(1);
}
if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 364, value);
+ ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, value);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(length);
@@ -112805,7 +113078,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
zephir_check_temp_parameter(_0);
zephir_check_call_status();
if (Z_TYPE_P(field) == IS_ARRAY) {
- zephir_is_iterable(field, &_2, &_1, 0, 0, "phalcon/mvc/model/validator/uniqueness.zep", 119);
+ zephir_is_iterable(field, &_2, &_1, 0, 0, "phalcon/mvc/model/validator/uniqueness.zep", 120);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -112820,7 +113093,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_4, "Column '", composeField, "' isn't part of the column map");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _4);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 96 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 97 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -112835,7 +113108,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_4, "Column '", columnField, "' isn't part of the table columns");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _4);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 106 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 107 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -112843,11 +113116,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZVAL_LONG(&_6, number);
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVSV(_7, "[", composeField, "] = ?", &_6);
- zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 112);
+ zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 113);
ZEPHIR_CALL_METHOD(&_8, record, "readattribute", &_9, 0, composeField);
zephir_check_call_status();
- zephir_array_append(&bindParams, _8, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 113);
- zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 114);
+ zephir_array_append(&bindParams, _8, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 114);
+ zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 115);
number++;
}
} else {
@@ -112860,7 +113133,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_7, "Column '", field, "' isn't part of the column map");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _7);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 126 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 127 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -112875,17 +113148,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_7, "Column '", columnField, "' isn't part of the table columns");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _7);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 136 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 137 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVS(_7, "[", field, "] = ?0");
- zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 142);
+ zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 143);
ZEPHIR_CALL_METHOD(&_8, record, "readattribute", NULL, 0, field);
zephir_check_call_status();
- zephir_array_append(&bindParams, _8, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 143);
- zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 144);
+ zephir_array_append(&bindParams, _8, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 144);
+ zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 145);
number++;
}
ZEPHIR_CALL_METHOD(&_10, record, "getoperationmade", NULL, 0);
@@ -112900,7 +113173,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
}
ZEPHIR_CALL_METHOD(&_8, metaData, "getprimarykeyattributes", NULL, 0, record);
zephir_check_call_status();
- zephir_is_iterable(_8, &_12, &_11, 0, 0, "phalcon/mvc/model/validator/uniqueness.zep", 189);
+ zephir_is_iterable(_8, &_12, &_11, 0, 0, "phalcon/mvc/model/validator/uniqueness.zep", 190);
for (
; zephir_hash_get_current_data_ex(_12, (void**) &_13, &_11) == SUCCESS
; zephir_hash_move_forward_ex(_12, &_11)
@@ -112914,7 +113187,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_7, "Column '", primaryField, "' isn't part of the table columns");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _7);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 166 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 167 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -112927,7 +113200,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_14, "Column '", primaryField, "' isn't part of the column map");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _14);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 174 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 175 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -112938,11 +113211,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZVAL_LONG(&_6, number);
ZEPHIR_INIT_LNVAR(_4);
ZEPHIR_CONCAT_SVSV(_4, "[", attributeField, "] <> ?", &_6);
- zephir_array_append(&conditions, _4, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 183);
+ zephir_array_append(&conditions, _4, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 184);
ZEPHIR_CALL_METHOD(&_15, record, "readattribute", &_16, 0, primaryField);
zephir_check_call_status();
- zephir_array_append(&bindParams, _15, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 184);
- zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 185);
+ zephir_array_append(&bindParams, _15, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 185);
+ zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 186);
number++;
}
}
@@ -113079,7 +113352,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Url, validate) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 273);
- ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 190, value, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_0);
@@ -113414,7 +113687,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Annotations, handle) {
}
zephir_update_property_this(this_ptr, SL("_processed"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
}
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_router_annotations_ce, this_ptr, "handle", &_18, 365, realUri);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_router_annotations_ce, this_ptr, "handle", &_18, 367, realUri);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -113809,6 +114082,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Router_Group) {
static PHP_METHOD(Phalcon_Mvc_Router_Group, __construct) {
int ZEPHIR_LAST_CALL_STATUS;
+ zend_bool _0;
zval *paths = NULL;
ZEPHIR_MM_GROW();
@@ -113819,12 +114093,12 @@ static PHP_METHOD(Phalcon_Mvc_Router_Group, __construct) {
}
- if (Z_TYPE_P(paths) == IS_ARRAY) {
+ _0 = Z_TYPE_P(paths) == IS_ARRAY;
+ if (!(_0)) {
+ _0 = Z_TYPE_P(paths) == IS_STRING;
+ }
+ if (_0) {
zephir_update_property_this(this_ptr, SL("_paths"), paths TSRMLS_CC);
- } else {
- if (Z_TYPE_P(paths) == IS_STRING) {
- zephir_update_property_this(this_ptr, SL("_paths"), paths TSRMLS_CC);
- }
}
if ((zephir_method_exists_ex(this_ptr, SS("initialize") TSRMLS_CC) == SUCCESS)) {
ZEPHIR_CALL_METHOD(NULL, this_ptr, "initialize", NULL, 0, paths);
@@ -114267,7 +114541,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Group, _addRoute) {
ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 74, _2, mergedPaths, httpMethods);
zephir_check_call_status();
zephir_update_property_array_append(this_ptr, SL("_routes"), route TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, route, "setgroup", NULL, 366, this_ptr);
+ ZEPHIR_CALL_METHOD(NULL, route, "setgroup", NULL, 368, this_ptr);
zephir_check_call_status();
RETURN_CCTOR(route);
@@ -114523,7 +114797,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, extractNamedParams) {
int tmp, cursor, cursorVar, marker, bracketCount = 0, parenthesesCount = 0, foundPattern = 0, intermediate = 0, numberMatches = 0;
char ch;
zval *pattern_param = NULL, *matches, _1 = zval_used_for_init, _2 = zval_used_for_init, *_3 = NULL, _18 = zval_used_for_init, _19 = zval_used_for_init, *_20 = NULL, _22 = zval_used_for_init, *_23 = NULL;
- zval *pattern = NULL, *route, *item = NULL, *variable = NULL, *regexp = NULL, *_4 = NULL, *_21 = NULL, *_24 = NULL;
+ zval *pattern = NULL, *route, *item = NULL, *variable = NULL, *regexp = NULL, *_4 = NULL, *_21 = NULL, *_24 = NULL, *_26 = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 0, &pattern_param);
@@ -114683,9 +114957,9 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, extractNamedParams) {
}
}
if (foundPattern != 2) {
- zephir_concat_self_str(&route, "(", sizeof("(")-1 TSRMLS_CC);
- zephir_concat_self(&route, regexp TSRMLS_CC);
- zephir_concat_self_str(&route, ")", sizeof(")")-1 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_26);
+ ZEPHIR_CONCAT_SVS(_26, "(", regexp, ")");
+ zephir_concat_self(&route, _26 TSRMLS_CC);
} else {
zephir_concat_self(&route, regexp TSRMLS_CC);
}
@@ -114699,9 +114973,9 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, extractNamedParams) {
zephir_array_update_zval(&matches, item, &_23, PH_COPY | PH_SEPARATE);
}
} else {
- zephir_concat_self_str(&route, "{", sizeof("{")-1 TSRMLS_CC);
- zephir_concat_self(&route, item TSRMLS_CC);
- zephir_concat_self_str(&route, "}", sizeof("}")-1 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_26);
+ ZEPHIR_CONCAT_SVS(_26, "{", item, "}");
+ zephir_concat_self(&route, _26 TSRMLS_CC);
}
continue;
}
@@ -114762,13 +115036,13 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, reConfigure) {
ZEPHIR_CALL_SELF(&routePaths, "getroutepaths", NULL, 0, paths);
zephir_check_call_status();
if (!(zephir_start_with_str(pattern, SL("#")))) {
- if (zephir_memnstr_str(pattern, SL("{"), "phalcon/mvc/router/route.zep", 299)) {
+ if (zephir_memnstr_str(pattern, SL("{"), "phalcon/mvc/router/route.zep", 295)) {
ZEPHIR_CALL_METHOD(&extracted, this_ptr, "extractnamedparams", NULL, 0, pattern);
zephir_check_call_status();
ZEPHIR_OBS_VAR(pcrePattern);
- zephir_array_fetch_long(&pcrePattern, extracted, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 304 TSRMLS_CC);
+ zephir_array_fetch_long(&pcrePattern, extracted, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 300 TSRMLS_CC);
ZEPHIR_INIT_VAR(_0);
- zephir_array_fetch_long(&_1, extracted, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/router/route.zep", 305 TSRMLS_CC);
+ zephir_array_fetch_long(&_1, extracted, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/router/route.zep", 301 TSRMLS_CC);
zephir_fast_array_merge(_0, &(routePaths), &(_1) TSRMLS_CC);
ZEPHIR_CPY_WRT(routePaths, _0);
} else {
@@ -114813,23 +115087,23 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, getRoutePaths) {
_0 = zephir_fast_count_int(parts TSRMLS_CC);
if (_0 == 3) {
ZEPHIR_OBS_NVAR(moduleName);
- zephir_array_fetch_long(&moduleName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 357 TSRMLS_CC);
+ zephir_array_fetch_long(&moduleName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 353 TSRMLS_CC);
ZEPHIR_OBS_NVAR(controllerName);
- zephir_array_fetch_long(&controllerName, parts, 1, PH_NOISY, "phalcon/mvc/router/route.zep", 358 TSRMLS_CC);
+ zephir_array_fetch_long(&controllerName, parts, 1, PH_NOISY, "phalcon/mvc/router/route.zep", 354 TSRMLS_CC);
ZEPHIR_OBS_NVAR(actionName);
- zephir_array_fetch_long(&actionName, parts, 2, PH_NOISY, "phalcon/mvc/router/route.zep", 359 TSRMLS_CC);
+ zephir_array_fetch_long(&actionName, parts, 2, PH_NOISY, "phalcon/mvc/router/route.zep", 355 TSRMLS_CC);
break;
}
if (_0 == 2) {
ZEPHIR_OBS_NVAR(controllerName);
- zephir_array_fetch_long(&controllerName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 363 TSRMLS_CC);
+ zephir_array_fetch_long(&controllerName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 359 TSRMLS_CC);
ZEPHIR_OBS_NVAR(actionName);
- zephir_array_fetch_long(&actionName, parts, 1, PH_NOISY, "phalcon/mvc/router/route.zep", 364 TSRMLS_CC);
+ zephir_array_fetch_long(&actionName, parts, 1, PH_NOISY, "phalcon/mvc/router/route.zep", 360 TSRMLS_CC);
break;
}
if (_0 == 1) {
ZEPHIR_OBS_NVAR(controllerName);
- zephir_array_fetch_long(&controllerName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 368 TSRMLS_CC);
+ zephir_array_fetch_long(&controllerName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 364 TSRMLS_CC);
break;
}
} while(0);
@@ -114840,7 +115114,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, getRoutePaths) {
zephir_array_update_string(&routePaths, SL("module"), &moduleName, PH_COPY | PH_SEPARATE);
}
if (Z_TYPE_P(controllerName) != IS_NULL) {
- if (zephir_memnstr_str(controllerName, SL("\\"), "phalcon/mvc/router/route.zep", 383)) {
+ if (zephir_memnstr_str(controllerName, SL("\\"), "phalcon/mvc/router/route.zep", 379)) {
ZEPHIR_INIT_VAR(realClassName);
zephir_get_class_ns(realClassName, controllerName, 0 TSRMLS_CC);
ZEPHIR_INIT_VAR(namespaceName);
@@ -114866,7 +115140,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, getRoutePaths) {
array_init(routePaths);
}
if (Z_TYPE_P(routePaths) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_router_exception_ce, "The route contains invalid paths", "phalcon/mvc/router/route.zep", 415);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_router_exception_ce, "The route contains invalid paths", "phalcon/mvc/router/route.zep", 411);
return;
}
RETURN_CCTOR(routePaths);
@@ -114955,7 +115229,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, getReversedPaths) {
ZEPHIR_INIT_VAR(reversed);
array_init(reversed);
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_paths"), PH_NOISY_CC);
- zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/router/route.zep", 506);
+ zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/router/route.zep", 502);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -115776,7 +116050,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, _loadTemplateEngines) {
if (Z_TYPE_P(registeredEngines) != IS_ARRAY) {
ZEPHIR_INIT_VAR(_0);
object_init_ex(_0, phalcon_mvc_view_engine_php_ce);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 368, this_ptr, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 370, this_ptr, dependencyInjector);
zephir_check_call_status();
zephir_array_update_string(&engines, SL(".phtml"), &_0, PH_COPY | PH_SEPARATE);
} else {
@@ -116029,7 +116303,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, render) {
} else {
ZEPHIR_CPY_WRT(mergedParams, viewParams);
}
- ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 387, path, mergedParams);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 389, path, mergedParams);
zephir_check_call_status();
if (Z_TYPE_P(cache) == IS_OBJECT) {
ZEPHIR_CALL_METHOD(&_0, cache, "isstarted", NULL, 0);
@@ -116097,7 +116371,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, partial) {
} else {
ZEPHIR_CPY_WRT(mergedParams, params);
}
- ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 387, partialPath, mergedParams);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 389, partialPath, mergedParams);
zephir_check_call_status();
if (Z_TYPE_P(params) == IS_ARRAY) {
zephir_update_property_this(this_ptr, SL("_viewParams"), viewParams TSRMLS_CC);
@@ -116481,7 +116755,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Php, render) {
if (mustClean == 1) {
- ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 369);
+ ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 371);
zephir_check_call_status();
}
if (Z_TYPE_P(params) == IS_ARRAY) {
@@ -116576,18 +116850,18 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, getCompiler) {
ZEPHIR_INIT_NVAR(compiler);
object_init_ex(compiler, phalcon_mvc_view_engine_volt_compiler_ce);
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_view"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, compiler, "__construct", NULL, 370, _0);
+ ZEPHIR_CALL_METHOD(NULL, compiler, "__construct", NULL, 372, _0);
zephir_check_call_status();
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
ZEPHIR_CPY_WRT(dependencyInjector, _1);
if (Z_TYPE_P(dependencyInjector) == IS_OBJECT) {
- ZEPHIR_CALL_METHOD(NULL, compiler, "setdi", NULL, 371, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, compiler, "setdi", NULL, 373, dependencyInjector);
zephir_check_call_status();
}
ZEPHIR_OBS_VAR(options);
zephir_read_property_this(&options, this_ptr, SL("_options"), PH_NOISY_CC);
if (Z_TYPE_P(options) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, compiler, "setoptions", NULL, 372, options);
+ ZEPHIR_CALL_METHOD(NULL, compiler, "setoptions", NULL, 374, options);
zephir_check_call_status();
}
zephir_update_property_this(this_ptr, SL("_compiler"), compiler TSRMLS_CC);
@@ -116627,7 +116901,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, render) {
if (mustClean) {
- ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 369);
+ ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 371);
zephir_check_call_status();
}
ZEPHIR_CALL_METHOD(&compiler, this_ptr, "getcompiler", NULL, 0);
@@ -116667,6 +116941,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, render) {
static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, length) {
int ZEPHIR_LAST_CALL_STATUS;
+ zend_bool _0;
zval *item, *length = NULL;
ZEPHIR_MM_GROW();
@@ -116676,21 +116951,20 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, length) {
ZEPHIR_INIT_VAR(length);
ZVAL_LONG(length, 0);
- if (Z_TYPE_P(item) == IS_OBJECT) {
+ _0 = Z_TYPE_P(item) == IS_OBJECT;
+ if (!(_0)) {
+ _0 = Z_TYPE_P(item) == IS_ARRAY;
+ }
+ if (_0) {
ZEPHIR_INIT_NVAR(length);
ZVAL_LONG(length, zephir_fast_count_int(item TSRMLS_CC));
} else {
- if (Z_TYPE_P(item) == IS_ARRAY) {
- ZEPHIR_INIT_NVAR(length);
- ZVAL_LONG(length, zephir_fast_count_int(item TSRMLS_CC));
+ if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) {
+ ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, item);
+ zephir_check_call_status();
} else {
- if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 364, item);
- zephir_check_call_status();
- } else {
- ZEPHIR_INIT_NVAR(length);
- ZVAL_LONG(length, zephir_fast_strlen_ev(item));
- }
+ ZEPHIR_INIT_NVAR(length);
+ ZVAL_LONG(length, zephir_fast_strlen_ev(item));
}
}
RETURN_CCTOR(length);
@@ -116712,7 +116986,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, isIncluded) {
}
if (Z_TYPE_P(haystack) == IS_STRING) {
if ((zephir_function_exists_ex(SS("mb_strpos") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_CALL_FUNCTION(&_0, "mb_strpos", NULL, 373, haystack, needle);
+ ZEPHIR_CALL_FUNCTION(&_0, "mb_strpos", NULL, 375, haystack, needle);
zephir_check_call_status();
RETURN_MM_BOOL(!ZEPHIR_IS_FALSE_IDENTICAL(_0));
}
@@ -116720,7 +116994,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, isIncluded) {
zephir_fast_strpos(_1, haystack, needle, 0 );
RETURN_MM_BOOL(!ZEPHIR_IS_FALSE_IDENTICAL(_1));
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Invalid haystack", "phalcon/mvc/view/engine/volt.zep", 170);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Invalid haystack", "phalcon/mvc/view/engine/volt.zep", 166);
return;
}
@@ -116765,7 +117039,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, convertEncoding) {
_0 = ZEPHIR_IS_STRING(to, "utf8");
}
if (_0) {
- ZEPHIR_RETURN_CALL_FUNCTION("utf8_encode", NULL, 374, text);
+ ZEPHIR_RETURN_CALL_FUNCTION("utf8_encode", NULL, 376, text);
zephir_check_call_status();
RETURN_MM();
}
@@ -116774,21 +117048,21 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, convertEncoding) {
_1 = ZEPHIR_IS_STRING(from, "utf8");
}
if (_1) {
- ZEPHIR_RETURN_CALL_FUNCTION("utf8_decode", NULL, 375, text);
+ ZEPHIR_RETURN_CALL_FUNCTION("utf8_decode", NULL, 377, text);
zephir_check_call_status();
RETURN_MM();
}
if ((zephir_function_exists_ex(SS("mb_convert_encoding") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 179, text, from, to);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 180, text, from, to);
zephir_check_call_status();
RETURN_MM();
}
if ((zephir_function_exists_ex(SS("iconv") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("iconv", NULL, 376, from, to, text);
+ ZEPHIR_RETURN_CALL_FUNCTION("iconv", NULL, 378, from, to, text);
zephir_check_call_status();
RETURN_MM();
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Any of 'mbstring' or 'iconv' is required to perform the charset conversion", "phalcon/mvc/view/engine/volt.zep", 209);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Any of 'mbstring' or 'iconv' is required to perform the charset conversion", "phalcon/mvc/view/engine/volt.zep", 205);
return;
}
@@ -116838,7 +117112,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) {
if (_1) {
ZEPHIR_CALL_METHOD(&_2, value, "current", &_3, 0);
zephir_check_call_status();
- zephir_array_append(&slice, _2, PH_SEPARATE, "phalcon/mvc/view/engine/volt.zep", 235);
+ zephir_array_append(&slice, _2, PH_SEPARATE, "phalcon/mvc/view/engine/volt.zep", 231);
}
ZEPHIR_CALL_METHOD(NULL, value, "next", &_4, 0);
zephir_check_call_status();
@@ -116855,7 +117129,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) {
if (Z_TYPE_P(value) == IS_ARRAY) {
ZEPHIR_SINIT_VAR(_5);
ZVAL_LONG(&_5, start);
- ZEPHIR_RETURN_CALL_FUNCTION("array_slice", NULL, 377, value, &_5, length);
+ ZEPHIR_RETURN_CALL_FUNCTION("array_slice", NULL, 379, value, &_5, length);
zephir_check_call_status();
RETURN_MM();
}
@@ -116863,13 +117137,13 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) {
if (Z_TYPE_P(length) != IS_NULL) {
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, start);
- ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 378, value, &_5, length);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 380, value, &_5, length);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, start);
- ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 378, value, &_5);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 380, value, &_5);
zephir_check_call_status();
RETURN_MM();
}
@@ -116899,7 +117173,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, sort) {
Z_SET_ISREF_P(value);
- ZEPHIR_CALL_FUNCTION(NULL, "asort", NULL, 379, value);
+ ZEPHIR_CALL_FUNCTION(NULL, "asort", NULL, 381, value);
Z_UNSET_ISREF_P(value);
zephir_check_call_status();
RETURN_CTOR(value);
@@ -116939,11 +117213,11 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, callMacro) {
ZEPHIR_CONCAT_SVS(_2, "Macro '", name, "' does not exist");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt.zep", 297 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt.zep", 293 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_RETURN_CALL_FUNCTION("call_user_func", NULL, 380, macro, arguments);
+ ZEPHIR_RETURN_CALL_FUNCTION("call_user_func", NULL, 382, macro, arguments);
zephir_check_call_status();
RETURN_MM();
@@ -117406,7 +117680,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) {
}
}
} else {
- ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_4, 381, left);
+ ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_4, 383, left);
zephir_check_call_status();
ZEPHIR_OBS_VAR(leftType);
zephir_array_fetch_string(&leftType, left, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 339 TSRMLS_CC);
@@ -117428,7 +117702,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) {
zephir_array_fetch_string(&_7, right, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 352 TSRMLS_CC);
zephir_concat_self(&exprCode, _7 TSRMLS_CC);
} else {
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_4, 381, right);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_4, 383, right);
zephir_check_call_status();
zephir_concat_self(&exprCode, _1 TSRMLS_CC);
}
@@ -117457,7 +117731,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
ZVAL_NULL(funcArguments);
ZEPHIR_OBS_NVAR(funcArguments);
if (zephir_array_isset_string_fetch(&funcArguments, expr, SS("arguments"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", &_0, 381, funcArguments);
+ ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", &_0, 383, funcArguments);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(arguments);
@@ -117480,7 +117754,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
zephir_array_fast_append(_1, funcArguments);
ZEPHIR_INIT_VAR(_2);
ZVAL_STRING(_2, "compileFunction", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 382, _2, _1);
+ ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 384, _2, _1);
zephir_check_temp_parameter(_2);
zephir_check_call_status();
if (Z_TYPE_P(code) == IS_STRING) {
@@ -117547,7 +117821,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
ZEPHIR_OBS_VAR(exprLevel);
zephir_read_property_this(&exprLevel, this_ptr, SL("_exprLevel"), PH_NOISY_CC);
if (Z_TYPE_P(block) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlistorextends", NULL, 383, block);
+ ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlistorextends", NULL, 385, block);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(exprLevel, 1)) {
ZEPHIR_CPY_WRT(escapedCode, code);
@@ -117583,7 +117857,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
zephir_read_property_this(&arrayHelpers, this_ptr, SL("_arrayHelpers"), PH_NOISY_CC);
if (Z_TYPE_P(arrayHelpers) != IS_ARRAY) {
ZEPHIR_INIT_NVAR(arrayHelpers);
- zephir_create_array(arrayHelpers, 17, 0 TSRMLS_CC);
+ zephir_create_array(arrayHelpers, 18, 0 TSRMLS_CC);
zephir_array_update_string(&arrayHelpers, SL("link_to"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("image"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("form"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
@@ -117599,6 +117873,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
zephir_array_update_string(&arrayHelpers, SL("text_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("email_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("date_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
+ zephir_array_update_string(&arrayHelpers, SL("tel_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("numeric_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("image_input"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_update_property_this(this_ptr, SL("_arrayHelpers"), arrayHelpers TSRMLS_CC);
@@ -117641,17 +117916,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
}
ZEPHIR_INIT_NVAR(_2);
object_init_ex(_2, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_3, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 572 TSRMLS_CC);
- zephir_array_fetch_string(&_4, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 572 TSRMLS_CC);
+ zephir_array_fetch_string(&_3, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVSVSV(_5, "Undefined function '", name, "' in ", _3, " on line ", _4);
ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _5);
zephir_check_call_status();
- zephir_throw_exception_debug(_2, "phalcon/mvc/view/engine/volt/compiler.zep", 572 TSRMLS_CC);
+ zephir_throw_exception_debug(_2, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_CALL_METHOD(&_8, this_ptr, "expression", &_0, 381, nameExpr);
+ ZEPHIR_CALL_METHOD(&_8, this_ptr, "expression", &_0, 383, nameExpr);
zephir_check_call_status();
ZEPHIR_CONCAT_VSVS(return_value, _8, "(", arguments, ")");
RETURN_MM();
@@ -117675,10 +117950,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveTest) {
ZEPHIR_OBS_VAR(type);
- zephir_array_fetch_string(&type, test, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 585 TSRMLS_CC);
+ zephir_array_fetch_string(&type, test, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 586 TSRMLS_CC);
if (ZEPHIR_IS_LONG(type, 265)) {
ZEPHIR_OBS_VAR(name);
- zephir_array_fetch_string(&name, test, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 592 TSRMLS_CC);
+ zephir_array_fetch_string(&name, test, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 593 TSRMLS_CC);
if (ZEPHIR_IS_STRING(name, "empty")) {
ZEPHIR_CONCAT_SVS(return_value, "empty(", left, ")");
RETURN_MM();
@@ -117706,33 +117981,33 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveTest) {
}
if (ZEPHIR_IS_LONG(type, 350)) {
ZEPHIR_OBS_VAR(testName);
- zephir_array_fetch_string(&testName, test, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 643 TSRMLS_CC);
+ zephir_array_fetch_string(&testName, test, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 644 TSRMLS_CC);
ZEPHIR_OBS_NVAR(name);
if (zephir_array_isset_string_fetch(&name, testName, SS("value"), 0 TSRMLS_CC)) {
if (ZEPHIR_IS_STRING(name, "divisibleby")) {
- zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 647 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 381, _1);
+ zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 648 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "(((", left, ") % (", _0, ")) == 0)");
RETURN_MM();
}
if (ZEPHIR_IS_STRING(name, "sameas")) {
- zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 654 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 381, _1);
+ zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 655 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "(", left, ") === (", _0, ")");
RETURN_MM();
}
if (ZEPHIR_IS_STRING(name, "type")) {
- zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 661 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 381, _1);
+ zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 662 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "gettype(", left, ") === (", _0, ")");
RETURN_MM();
}
}
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 381, test);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, test);
zephir_check_call_status();
ZEPHIR_CONCAT_VSV(return_value, left, " == ", _0);
RETURN_MM();
@@ -117758,28 +118033,28 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
ZEPHIR_INIT_VAR(code);
ZVAL_NULL(code);
ZEPHIR_OBS_VAR(type);
- zephir_array_fetch_string(&type, filter, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 680 TSRMLS_CC);
+ zephir_array_fetch_string(&type, filter, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 681 TSRMLS_CC);
if (ZEPHIR_IS_LONG(type, 265)) {
ZEPHIR_OBS_VAR(name);
- zephir_array_fetch_string(&name, filter, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 686 TSRMLS_CC);
+ zephir_array_fetch_string(&name, filter, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 687 TSRMLS_CC);
} else {
if (!ZEPHIR_IS_LONG(type, 350)) {
ZEPHIR_INIT_VAR(_0);
object_init_ex(_0, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 694 TSRMLS_CC);
- zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 694 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC);
ZEPHIR_INIT_VAR(_3);
ZEPHIR_CONCAT_SVSV(_3, "Unknown filter type in ", _1, " on line ", _2);
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 694 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
ZEPHIR_OBS_VAR(functionName);
- zephir_array_fetch_string(&functionName, filter, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 697 TSRMLS_CC);
+ zephir_array_fetch_string(&functionName, filter, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 698 TSRMLS_CC);
ZEPHIR_OBS_NVAR(name);
- zephir_array_fetch_string(&name, functionName, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 698 TSRMLS_CC);
+ zephir_array_fetch_string(&name, functionName, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 699 TSRMLS_CC);
}
ZEPHIR_INIT_VAR(funcArguments);
ZVAL_NULL(funcArguments);
@@ -117789,9 +118064,9 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
if (zephir_array_isset_string_fetch(&funcArguments, filter, SS("arguments"), 0 TSRMLS_CC)) {
if (!ZEPHIR_IS_STRING(name, "default")) {
ZEPHIR_OBS_VAR(file);
- zephir_array_fetch_string(&file, filter, SL("file"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 713 TSRMLS_CC);
+ zephir_array_fetch_string(&file, filter, SL("file"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 714 TSRMLS_CC);
ZEPHIR_OBS_VAR(line);
- zephir_array_fetch_string(&line, filter, SL("line"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 713 TSRMLS_CC);
+ zephir_array_fetch_string(&line, filter, SL("line"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 714 TSRMLS_CC);
ZEPHIR_INIT_VAR(_4);
zephir_create_array(_4, 3, 0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_5);
@@ -117804,11 +118079,11 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
zephir_array_update_string(&_4, SL("file"), &file, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("line"), &line, PH_COPY | PH_SEPARATE);
Z_SET_ISREF_P(funcArguments);
- ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 384, funcArguments, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 386, funcArguments, _4);
Z_UNSET_ISREF_P(funcArguments);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", NULL, 381, funcArguments);
+ ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", NULL, 383, funcArguments);
zephir_check_call_status();
} else {
ZEPHIR_CPY_WRT(arguments, left);
@@ -117823,7 +118098,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
zephir_array_fast_append(_4, funcArguments);
ZEPHIR_INIT_NVAR(_0);
ZVAL_STRING(_0, "compileFilter", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 382, _0, _4);
+ ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 384, _0, _4);
zephir_check_temp_parameter(_0);
zephir_check_call_status();
if (Z_TYPE_P(code) == IS_STRING) {
@@ -117852,13 +118127,13 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
}
ZEPHIR_INIT_NVAR(_0);
object_init_ex(_0, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 776 TSRMLS_CC);
- zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 776 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_3);
ZEPHIR_CONCAT_SVSVSV(_3, "Invalid definition for user filter '", name, "' in ", _1, " on line ", _2);
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 776 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -117981,13 +118256,13 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
}
ZEPHIR_INIT_NVAR(_0);
object_init_ex(_0, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 965 TSRMLS_CC);
- zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 965 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_3);
ZEPHIR_CONCAT_SVSVSV(_3, "Unknown filter \"", name, "\" in ", _1, " on line ", _2);
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 965 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -118021,7 +118296,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
zephir_array_fast_append(_0, expr);
ZEPHIR_INIT_NVAR(_1);
ZVAL_STRING(_1, "resolveExpression", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "fireextensionevent", &_2, 382, _1, _0);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "fireextensionevent", &_2, 384, _1, _0);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
if (Z_TYPE_P(exprCode) == IS_STRING) {
@@ -118032,22 +118307,22 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
if (!(zephir_array_isset_string_fetch(&type, expr, SS("type"), 0 TSRMLS_CC))) {
ZEPHIR_INIT_NVAR(items);
array_init(items);
- zephir_is_iterable(expr, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1006);
+ zephir_is_iterable(expr, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1007);
for (
; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS
; zephir_hash_move_forward_ex(_4, &_3)
) {
ZEPHIR_GET_HVALUE(singleExpr, _5);
- zephir_array_fetch_string(&_6, singleExpr, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 999 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&singleExprCode, this_ptr, "expression", &_7, 381, _6);
+ zephir_array_fetch_string(&_6, singleExpr, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1000 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&singleExprCode, this_ptr, "expression", &_7, 383, _6);
zephir_check_call_status();
ZEPHIR_OBS_NVAR(name);
if (zephir_array_isset_string_fetch(&name, singleExpr, SS("name"), 0 TSRMLS_CC)) {
ZEPHIR_INIT_LNVAR(_8);
ZEPHIR_CONCAT_SVSV(_8, "'", name, "' => ", singleExprCode);
- zephir_array_append(&items, _8, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1001);
+ zephir_array_append(&items, _8, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1002);
} else {
- zephir_array_append(&items, singleExprCode, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1003);
+ zephir_array_append(&items, singleExprCode, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1004);
}
}
ZEPHIR_INIT_NVAR(exprCode);
@@ -118061,24 +118336,24 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
}
ZEPHIR_OBS_NVAR(left);
if (zephir_array_isset_string_fetch(&left, expr, SS("left"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_7, 381, left);
+ ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_7, 383, left);
zephir_check_call_status();
}
if (ZEPHIR_IS_LONG(type, 311)) {
- zephir_array_fetch_string(&_6, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1029 TSRMLS_CC);
+ zephir_array_fetch_string(&_6, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1030 TSRMLS_CC);
ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvetest", &_10, 0, _6, leftCode);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 124)) {
- zephir_array_fetch_string(&_11, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1037 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvefilter", &_12, 385, _11, leftCode);
+ zephir_array_fetch_string(&_11, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1038 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvefilter", &_12, 387, _11, leftCode);
zephir_check_call_status();
break;
}
ZEPHIR_OBS_NVAR(right);
if (zephir_array_isset_string_fetch(&right, expr, SS("right"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&rightCode, this_ptr, "expression", &_7, 381, right);
+ ZEPHIR_CALL_METHOD(&rightCode, this_ptr, "expression", &_7, 383, right);
zephir_check_call_status();
}
ZEPHIR_INIT_NVAR(exprCode);
@@ -118150,17 +118425,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
}
if (ZEPHIR_IS_LONG(type, 258)) {
ZEPHIR_OBS_NVAR(exprCode);
- zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1104 TSRMLS_CC);
+ zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1105 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(type, 259)) {
ZEPHIR_OBS_NVAR(exprCode);
- zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1108 TSRMLS_CC);
+ zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1109 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(type, 260)) {
ZEPHIR_INIT_NVAR(_1);
- zephir_array_fetch_string(&_6, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1112 TSRMLS_CC);
+ zephir_array_fetch_string(&_6, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1113 TSRMLS_CC);
ZEPHIR_SINIT_NVAR(_13);
ZVAL_STRING(&_13, "'", 0);
ZEPHIR_SINIT_NVAR(_14);
@@ -118186,7 +118461,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
break;
}
if (ZEPHIR_IS_LONG(type, 265)) {
- zephir_array_fetch_string(&_11, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1128 TSRMLS_CC);
+ zephir_array_fetch_string(&_11, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1129 TSRMLS_CC);
ZEPHIR_INIT_NVAR(exprCode);
ZEPHIR_CONCAT_SV(exprCode, "$", _11);
break;
@@ -118254,7 +118529,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
if (ZEPHIR_IS_LONG(type, 365)) {
ZEPHIR_OBS_NVAR(start);
if (zephir_array_isset_string_fetch(&start, expr, SS("start"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&startCode, this_ptr, "expression", &_7, 381, start);
+ ZEPHIR_CALL_METHOD(&startCode, this_ptr, "expression", &_7, 383, start);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(startCode);
@@ -118262,7 +118537,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
}
ZEPHIR_OBS_NVAR(end);
if (zephir_array_isset_string_fetch(&end, expr, SS("end"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&endCode, this_ptr, "expression", &_7, 381, end);
+ ZEPHIR_CALL_METHOD(&endCode, this_ptr, "expression", &_7, 383, end);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(endCode);
@@ -118353,8 +118628,8 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
break;
}
if (ZEPHIR_IS_LONG(type, 366)) {
- zephir_array_fetch_string(&_6, expr, SL("ternary"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1267 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_16, this_ptr, "expression", &_7, 381, _6);
+ zephir_array_fetch_string(&_6, expr, SL("ternary"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1268 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_16, this_ptr, "expression", &_7, 383, _6);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(exprCode);
ZEPHIR_CONCAT_SVSVSVS(exprCode, "(", _16, " ? ", leftCode, " : ", rightCode, ")");
@@ -118372,18 +118647,18 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
}
if (ZEPHIR_IS_LONG(type, 364)) {
ZEPHIR_OBS_NVAR(exprCode);
- zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1279 TSRMLS_CC);
+ zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1280 TSRMLS_CC);
break;
}
ZEPHIR_INIT_NVAR(_1);
object_init_ex(_1, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_11, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1283 TSRMLS_CC);
- zephir_array_fetch_string(&_17, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1283 TSRMLS_CC);
+ zephir_array_fetch_string(&_11, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC);
+ zephir_array_fetch_string(&_17, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_8);
ZEPHIR_CONCAT_SVSVSV(_8, "Unknown expression ", type, " in ", _11, " on line ", _17);
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_18, 9, _8);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1283 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
} while(0);
@@ -118414,7 +118689,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, _statementListOrExtends
}
isStatementList = 1;
if (!(zephir_array_isset_string(statements, SS("type")))) {
- zephir_is_iterable(statements, &_1, &_0, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1323);
+ zephir_is_iterable(statements, &_1, &_0, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1324);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -118427,7 +118702,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, _statementListOrExtends
}
}
if (isStatementList == 1) {
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_statementlist", NULL, 386, statements);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_statementlist", NULL, 388, statements);
zephir_check_call_status();
RETURN_MM();
}
@@ -118459,7 +118734,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
if (!(zephir_array_isset_string(statement, SS("expr")))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1351);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1352);
return;
}
ZEPHIR_INIT_VAR(compilation);
@@ -118474,15 +118749,15 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
ZEPHIR_INIT_VAR(prefixLevel);
ZEPHIR_CONCAT_VV(prefixLevel, prefix, level);
ZEPHIR_OBS_VAR(expr);
- zephir_array_fetch_string(&expr, statement, SL("expr"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1369 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 381, expr);
+ zephir_array_fetch_string(&expr, statement, SL("expr"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1370 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 383, expr);
zephir_check_call_status();
ZEPHIR_OBS_VAR(blockStatements);
- zephir_array_fetch_string(&blockStatements, statement, SL("block_statements"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1375 TSRMLS_CC);
+ zephir_array_fetch_string(&blockStatements, statement, SL("block_statements"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1376 TSRMLS_CC);
ZEPHIR_INIT_NVAR(forElse);
ZVAL_BOOL(forElse, 0);
if (Z_TYPE_P(blockStatements) == IS_ARRAY) {
- zephir_is_iterable(blockStatements, &_2, &_1, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1401);
+ zephir_is_iterable(blockStatements, &_2, &_1, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1402);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -118505,7 +118780,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
}
}
}
- ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlist", NULL, 386, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlist", NULL, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
ZEPHIR_OBS_VAR(loopContext);
zephir_read_property_this(&loopContext, this_ptr, SL("_loopPointers"), PH_NOISY_CC);
@@ -118540,7 +118815,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
ZEPHIR_CPY_WRT(iterator, exprCode);
}
ZEPHIR_OBS_VAR(variable);
- zephir_array_fetch_string(&variable, statement, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1430 TSRMLS_CC);
+ zephir_array_fetch_string(&variable, statement, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1431 TSRMLS_CC);
ZEPHIR_OBS_VAR(key);
if (zephir_array_isset_string_fetch(&key, statement, SS("key"), 0 TSRMLS_CC)) {
ZEPHIR_INIT_LNVAR(_5);
@@ -118553,7 +118828,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
}
ZEPHIR_OBS_VAR(ifExpr);
if (zephir_array_isset_string_fetch(&ifExpr, statement, SS("if_expr"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_12, this_ptr, "expression", &_0, 381, ifExpr);
+ ZEPHIR_CALL_METHOD(&_12, this_ptr, "expression", &_0, 383, ifExpr);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVS(_5, "if (", _12, ") { ?>");
@@ -118648,19 +118923,19 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileIf) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1521);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1522);
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 381, expr);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr);
zephir_check_call_status();
- zephir_array_fetch_string(&_2, statement, SL("true_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1527 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_statementlist", &_3, 386, _2, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ zephir_array_fetch_string(&_2, statement, SL("true_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1528 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_statementlist", &_3, 388, _2, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
ZEPHIR_INIT_VAR(compilation);
ZEPHIR_CONCAT_SVSV(compilation, "", _1);
ZEPHIR_OBS_VAR(blockStatements);
if (zephir_array_isset_string_fetch(&blockStatements, statement, SS("false_statements"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "_statementlist", &_3, 386, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "_statementlist", &_3, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZEPHIR_CONCAT_SV(_5, "", _4);
@@ -118686,10 +118961,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileElseIf) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1556);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1557);
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 381, expr);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr);
zephir_check_call_status();
ZEPHIR_CONCAT_SVS(return_value, "");
RETURN_MM();
@@ -118718,12 +118993,12 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1576);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1577);
return;
}
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 381, expr);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 383, expr);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_0, 381, expr);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_0, 383, expr);
zephir_check_call_status();
ZEPHIR_INIT_VAR(compilation);
ZEPHIR_CONCAT_SVS(compilation, "di->get('viewCache'); ");
@@ -118732,14 +119007,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) {
ZEPHIR_INIT_VAR(_2);
ZEPHIR_CONCAT_SVS(_2, "$_cacheKey[", exprCode, "]");
zephir_concat_self(&compilation, _2 TSRMLS_CC);
- zephir_array_fetch_string(&_3, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1586 TSRMLS_CC);
+ zephir_array_fetch_string(&_3, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1587 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_3, 265)) {
- zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1587 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1588 TSRMLS_CC);
ZEPHIR_INIT_VAR(_5);
ZEPHIR_CONCAT_SVSVSVS(_5, " = $_cache[", exprCode, "]->start(", exprCode, ", $", _4, "); ");
zephir_concat_self(&compilation, _5 TSRMLS_CC);
} else {
- zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1589 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1590 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVSVSVS(_5, " = $_cache[", exprCode, "]->start(", exprCode, ", ", _4, "); ");
zephir_concat_self(&compilation, _5 TSRMLS_CC);
@@ -118752,20 +119027,20 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) {
ZEPHIR_INIT_LNVAR(_2);
ZEPHIR_CONCAT_SVS(_2, "if ($_cacheKey[", exprCode, "] === null) { ?>");
zephir_concat_self(&compilation, _2 TSRMLS_CC);
- zephir_array_fetch_string(&_3, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1599 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_6, this_ptr, "_statementlist", NULL, 386, _3, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ zephir_array_fetch_string(&_3, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1600 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_6, this_ptr, "_statementlist", NULL, 388, _3, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_concat_self(&compilation, _6 TSRMLS_CC);
ZEPHIR_OBS_NVAR(lifetime);
if (zephir_array_isset_string_fetch(&lifetime, statement, SS("lifetime"), 0 TSRMLS_CC)) {
- zephir_array_fetch_string(&_4, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1605 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1606 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_4, 265)) {
- zephir_array_fetch_string(&_7, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1606 TSRMLS_CC);
+ zephir_array_fetch_string(&_7, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1607 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVSVSVS(_5, "save(", exprCode, ", null, $", _7, "); ");
zephir_concat_self(&compilation, _5 TSRMLS_CC);
} else {
- zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1608 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1609 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVSVSVS(_5, "save(", exprCode, ", null, ", _4, "); ");
zephir_concat_self(&compilation, _5 TSRMLS_CC);
@@ -118800,24 +119075,24 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileSet) {
ZEPHIR_OBS_VAR(assignments);
if (!(zephir_array_isset_string_fetch(&assignments, statement, SS("assignments"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1629);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1630);
return;
}
ZEPHIR_INIT_VAR(compilation);
ZVAL_STRING(compilation, "");
RETURN_MM();
@@ -118895,10 +119170,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileReturn) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1710);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1711);
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 381, expr);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr);
zephir_check_call_status();
ZEPHIR_CONCAT_SVS(return_value, "");
RETURN_MM();
@@ -118922,14 +119197,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileAutoEscape) {
ZEPHIR_OBS_VAR(autoescape);
if (!(zephir_array_isset_string_fetch(&autoescape, statement, SS("enable"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1730);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1731);
return;
}
ZEPHIR_OBS_VAR(oldAutoescape);
zephir_read_property_this(&oldAutoescape, this_ptr, SL("_autoescape"), PH_NOISY_CC);
zephir_update_property_this(this_ptr, SL("_autoescape"), autoescape TSRMLS_CC);
- zephir_array_fetch_string(&_0, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1739 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&compilation, this_ptr, "_statementlist", NULL, 386, _0, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ zephir_array_fetch_string(&_0, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1740 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&compilation, this_ptr, "_statementlist", NULL, 388, _0, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_autoescape"), oldAutoescape TSRMLS_CC);
RETURN_CCTOR(compilation);
@@ -118951,17 +119226,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileEcho) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1760);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1761);
return;
}
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", NULL, 381, expr);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", NULL, 383, expr);
zephir_check_call_status();
- zephir_array_fetch_string(&_0, expr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1768 TSRMLS_CC);
+ zephir_array_fetch_string(&_0, expr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1769 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_0, 350)) {
- zephir_array_fetch_string(&name, expr, SL("name"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1770 TSRMLS_CC);
- zephir_array_fetch_string(&_1, name, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1772 TSRMLS_CC);
+ zephir_array_fetch_string(&name, expr, SL("name"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1771 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, name, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1773 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_1, 265)) {
- zephir_array_fetch_string(&_2, name, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1777 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, name, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1778 TSRMLS_CC);
if (ZEPHIR_IS_STRING(_2, "super")) {
RETURN_CCTOR(exprCode);
}
@@ -118993,14 +119268,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileInclude) {
ZEPHIR_OBS_VAR(pathExpr);
if (!(zephir_array_isset_string_fetch(&pathExpr, statement, SS("path"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1805);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1806);
return;
}
- zephir_array_fetch_string(&_0, pathExpr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1812 TSRMLS_CC);
+ zephir_array_fetch_string(&_0, pathExpr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1813 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_0, 260)) {
if (!(zephir_array_isset_string(statement, SS("params")))) {
ZEPHIR_OBS_VAR(path);
- zephir_array_fetch_string(&path, pathExpr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1822 TSRMLS_CC);
+ zephir_array_fetch_string(&path, pathExpr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1823 TSRMLS_CC);
ZEPHIR_OBS_VAR(view);
zephir_read_property_this(&view, this_ptr, SL("_view"), PH_NOISY_CC);
if (Z_TYPE_P(view) == IS_OBJECT) {
@@ -119028,14 +119303,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileInclude) {
RETURN_CCTOR(compilation);
}
}
- ZEPHIR_CALL_METHOD(&path, this_ptr, "expression", &_3, 381, pathExpr);
+ ZEPHIR_CALL_METHOD(&path, this_ptr, "expression", &_3, 383, pathExpr);
zephir_check_call_status();
ZEPHIR_OBS_VAR(params);
if (!(zephir_array_isset_string_fetch(¶ms, statement, SS("params"), 0 TSRMLS_CC))) {
ZEPHIR_CONCAT_SVS(return_value, "partial(", path, "); ?>");
RETURN_MM();
}
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_3, 381, params);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_3, 383, params);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "partial(", path, ", ", _1, "); ?>");
RETURN_MM();
@@ -119062,7 +119337,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
ZEPHIR_OBS_VAR(name);
if (!(zephir_array_isset_string_fetch(&name, statement, SS("name"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1877);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1878);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_macros"), PH_NOISY_CC);
@@ -119073,7 +119348,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
ZEPHIR_CONCAT_SVS(_2, "Macro '", name, "' is already defined");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1884 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1885 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -119091,7 +119366,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
ZEPHIR_INIT_LNVAR(_2);
ZEPHIR_CONCAT_VS(_2, macroName, " = function($__p = null) { ");
zephir_concat_self(&code, _2 TSRMLS_CC);
- zephir_is_iterable(parameters, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1922);
+ zephir_is_iterable(parameters, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1923);
for (
; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS
; zephir_hash_move_forward_ex(_4, &_3)
@@ -119099,7 +119374,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
ZEPHIR_GET_HMKEY(position, _4, _3);
ZEPHIR_GET_HVALUE(parameter, _5);
ZEPHIR_OBS_NVAR(variableName);
- zephir_array_fetch_string(&variableName, parameter, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1906 TSRMLS_CC);
+ zephir_array_fetch_string(&variableName, parameter, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1907 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_6);
ZEPHIR_CONCAT_SVS(_6, "if (isset($__p[", position, "])) { ");
zephir_concat_self(&code, _6 TSRMLS_CC);
@@ -119116,7 +119391,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
zephir_concat_self_str(&code, SL(" } else { ") TSRMLS_CC);
ZEPHIR_OBS_NVAR(defaultValue);
if (zephir_array_isset_string_fetch(&defaultValue, parameter, SS("default"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_10, this_ptr, "expression", &_11, 381, defaultValue);
+ ZEPHIR_CALL_METHOD(&_10, this_ptr, "expression", &_11, 383, defaultValue);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_12);
ZEPHIR_CONCAT_SVSVS(_12, "$", variableName, " = ", _10, ";");
@@ -119132,7 +119407,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
}
ZEPHIR_OBS_VAR(blockStatements);
if (zephir_array_isset_string_fetch(&blockStatements, statement, SS("block_statements"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_10, this_ptr, "_statementlist", NULL, 386, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_10, this_ptr, "_statementlist", NULL, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_2);
ZEPHIR_CONCAT_VS(_2, _10, " 1) {
ZEPHIR_OBS_VAR(numberOfBytes);
- zephir_array_fetch_long(&numberOfBytes, response, 1, PH_NOISY, "phalcon/queue/beanstalk.zep", 288 TSRMLS_CC);
+ zephir_array_fetch_long(&numberOfBytes, response, 1, PH_NOISY, "phalcon/queue/beanstalk.zep", 293 TSRMLS_CC);
ZEPHIR_CALL_METHOD(&response, this_ptr, "read", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&data, "yaml_parse", NULL, 0, response);
@@ -130444,13 +130723,13 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, read) {
}
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, (length + 2));
- ZEPHIR_CALL_FUNCTION(&data, "fread", NULL, 393, connection, &_0);
+ ZEPHIR_CALL_FUNCTION(&data, "fread", NULL, 395, connection, &_0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_1, "stream_get_meta_data", NULL, 394, connection);
+ ZEPHIR_CALL_FUNCTION(&_1, "stream_get_meta_data", NULL, 396, connection);
zephir_check_call_status();
- zephir_array_fetch_string(&_2, _1, SL("timed_out"), PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 332 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, _1, SL("timed_out"), PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 337 TSRMLS_CC);
if (zephir_is_true(_2)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_exception_ce, "Connection timed out", "phalcon/queue/beanstalk.zep", 333);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_exception_ce, "Connection timed out", "phalcon/queue/beanstalk.zep", 338);
return;
}
ZEPHIR_SINIT_NVAR(_0);
@@ -130462,7 +130741,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, read) {
ZVAL_LONG(&_0, 16384);
ZEPHIR_SINIT_VAR(_3);
ZVAL_STRING(&_3, "\r\n", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("stream_get_line", NULL, 395, connection, &_0, &_3);
+ ZEPHIR_RETURN_CALL_FUNCTION("stream_get_line", NULL, 397, connection, &_0, &_3);
zephir_check_call_status();
RETURN_MM();
@@ -130494,7 +130773,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, write) {
ZEPHIR_CPY_WRT(packet, _0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, zephir_fast_strlen_ev(packet));
- ZEPHIR_RETURN_CALL_FUNCTION("fwrite", NULL, 396, connection, packet, &_1);
+ ZEPHIR_RETURN_CALL_FUNCTION("fwrite", NULL, 398, connection, packet, &_1);
zephir_check_call_status();
RETURN_MM();
@@ -130560,15 +130839,19 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, getBody) {
static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, __construct) {
- zval *queue, *id, *body;
+ zval *id = NULL;
+ zval *queue, *id_param = NULL, *body;
- zephir_fetch_params(0, 3, 0, &queue, &id, &body);
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 3, 0, &queue, &id_param, &body);
+ zephir_get_strval(id, id_param);
zephir_update_property_this(this_ptr, SL("_queue"), queue TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_id"), id TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_body"), body TSRMLS_CC);
+ ZEPHIR_MM_RESTORE();
}
@@ -130588,7 +130871,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, delete) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 59 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 57 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_3, "DELETED"));
}
@@ -130626,7 +130909,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, release) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_4, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_5, _4, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 73 TSRMLS_CC);
+ zephir_array_fetch_long(&_5, _4, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 71 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_5, "RELEASED"));
}
@@ -130657,7 +130940,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, bury) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_3, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_4, _3, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 87 TSRMLS_CC);
+ zephir_array_fetch_long(&_4, _3, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 85 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_4, "BURIED"));
}
@@ -130678,7 +130961,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, touch) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 104 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 102 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_3, "TOUCHED"));
}
@@ -130699,7 +130982,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, kick) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 116 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 114 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_3, "KICKED"));
}
@@ -130720,11 +131003,11 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, stats) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&response, queue, "readyaml", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_2, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 130 TSRMLS_CC);
+ zephir_array_fetch_long(&_2, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 128 TSRMLS_CC);
if (ZEPHIR_IS_STRING(_2, "NOT_FOUND")) {
RETURN_MM_BOOL(0);
}
- zephir_array_fetch_long(&_3, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 134 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 132 TSRMLS_CC);
RETURN_CTOR(_3);
}
@@ -130749,7 +131032,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, __wakeup) {
zephir_check_temp_parameter(_2);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/queue/beanstalk/job.zep", 143 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/queue/beanstalk/job.zep", 141 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -131635,7 +131918,7 @@ static PHP_METHOD(Phalcon_Session_Bag, getIterator) {
}
object_init_ex(return_value, zephir_get_internal_ce(SS("arrayiterator") TSRMLS_CC));
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 410, _1);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 412, _1);
zephir_check_call_status();
RETURN_MM();
@@ -131923,7 +132206,7 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) {
ZEPHIR_OBS_VAR(_3);
zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC);
zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 317, _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_4);
zephir_create_array(_4, 4, 0 TSRMLS_CC);
@@ -131931,7 +132214,7 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) {
zephir_array_update_string(&_4, SL("client"), &client, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("prefix"), &prefix, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("statsKey"), &statsKey, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 318, _1, _4);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 319, _1, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_libmemcached"), _0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_5);
@@ -131970,9 +132253,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) {
ZEPHIR_INIT_NVAR(_6);
ZVAL_STRING(_6, "gc", 1);
zephir_array_fast_append(_11, _6);
- ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 408, _5, _7, _8, _9, _10, _11);
+ ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _5, _7, _8, _9, _10, _11);
zephir_check_call_status();
- ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_libmemcached_ce, this_ptr, "__construct", &_12, 409, options);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_libmemcached_ce, this_ptr, "__construct", &_12, 411, options);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -132148,9 +132431,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Memcache, __construct) {
ZEPHIR_OBS_VAR(_3);
zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC);
zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 317, _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 320, _1, options);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 321, _1, options);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_4);
@@ -132189,9 +132472,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Memcache, __construct) {
ZEPHIR_INIT_NVAR(_5);
ZVAL_STRING(_5, "gc", 1);
zephir_array_fast_append(_10, _5);
- ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 408, _4, _6, _7, _8, _9, _10);
+ ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _4, _6, _7, _8, _9, _10);
zephir_check_call_status();
- ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_memcache_ce, this_ptr, "__construct", &_11, 409, options);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_memcache_ce, this_ptr, "__construct", &_11, 411, options);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -132283,6 +132566,223 @@ static PHP_METHOD(Phalcon_Session_Adapter_Memcache, gc) {
+#ifdef HAVE_CONFIG_H
+#endif
+
+#include
+
+#include
+#include
+#include
+
+
+
+ZEPHIR_INIT_CLASS(Phalcon_Session_Adapter_Redis) {
+
+ ZEPHIR_REGISTER_CLASS_EX(Phalcon\\Session\\Adapter, Redis, phalcon, session_adapter_redis, phalcon_session_adapter_ce, phalcon_session_adapter_redis_method_entry, 0);
+
+ zend_declare_property_null(phalcon_session_adapter_redis_ce, SL("_redis"), ZEND_ACC_PROTECTED TSRMLS_CC);
+
+ zend_declare_property_long(phalcon_session_adapter_redis_ce, SL("_lifetime"), 8600, ZEND_ACC_PROTECTED TSRMLS_CC);
+
+ zend_class_implements(phalcon_session_adapter_redis_ce TSRMLS_CC, 1, phalcon_session_adapterinterface_ce);
+ return SUCCESS;
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, getRedis) {
+
+
+ RETURN_MEMBER(this_ptr, "_redis");
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, getLifetime) {
+
+
+ RETURN_MEMBER(this_ptr, "_lifetime");
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, __construct) {
+
+ zephir_fcall_cache_entry *_11 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *options_param = NULL, *lifetime, *_0 = NULL, *_1, *_3, *_5 = NULL;
+ zval *options = NULL, *_2, *_4, *_6, *_7, *_8, *_9, *_10;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 0, 1, &options_param);
+
+ if (!options_param) {
+ ZEPHIR_INIT_VAR(options);
+ array_init(options);
+ } else {
+ zephir_get_arrval(options, options_param);
+ }
+
+
+ if (!(zephir_array_isset_string(options, SS("host")))) {
+ ZEPHIR_INIT_VAR(_0);
+ ZVAL_STRING(_0, "127.0.0.1", 1);
+ zephir_array_update_string(&options, SL("host"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("port")))) {
+ ZEPHIR_INIT_NVAR(_0);
+ ZVAL_LONG(_0, 6379);
+ zephir_array_update_string(&options, SL("port"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("persistent")))) {
+ zephir_array_update_string(&options, SL("persistent"), &ZEPHIR_GLOBAL(global_false), PH_COPY | PH_SEPARATE);
+ }
+ ZEPHIR_OBS_VAR(lifetime);
+ if (zephir_array_isset_string_fetch(&lifetime, options, SS("lifetime"), 0 TSRMLS_CC)) {
+ zephir_update_property_this(this_ptr, SL("_lifetime"), lifetime TSRMLS_CC);
+ }
+ ZEPHIR_INIT_NVAR(_0);
+ object_init_ex(_0, phalcon_cache_backend_redis_ce);
+ ZEPHIR_INIT_VAR(_1);
+ object_init_ex(_1, phalcon_cache_frontend_data_ce);
+ ZEPHIR_INIT_VAR(_2);
+ zephir_create_array(_2, 1, 0 TSRMLS_CC);
+ ZEPHIR_OBS_VAR(_3);
+ zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC);
+ zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 322, _1, options);
+ zephir_check_call_status();
+ zephir_update_property_this(this_ptr, SL("_redis"), _0 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_4);
+ zephir_create_array(_4, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_4, this_ptr);
+ ZEPHIR_INIT_VAR(_5);
+ ZVAL_STRING(_5, "open", 1);
+ zephir_array_fast_append(_4, _5);
+ ZEPHIR_INIT_VAR(_6);
+ zephir_create_array(_6, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_6, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "close", 1);
+ zephir_array_fast_append(_6, _5);
+ ZEPHIR_INIT_VAR(_7);
+ zephir_create_array(_7, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_7, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "read", 1);
+ zephir_array_fast_append(_7, _5);
+ ZEPHIR_INIT_VAR(_8);
+ zephir_create_array(_8, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_8, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "write", 1);
+ zephir_array_fast_append(_8, _5);
+ ZEPHIR_INIT_VAR(_9);
+ zephir_create_array(_9, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_9, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "destroy", 1);
+ zephir_array_fast_append(_9, _5);
+ ZEPHIR_INIT_VAR(_10);
+ zephir_create_array(_10, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_10, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "gc", 1);
+ zephir_array_fast_append(_10, _5);
+ ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _4, _6, _7, _8, _9, _10);
+ zephir_check_call_status();
+ ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_redis_ce, this_ptr, "__construct", &_11, 411, options);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, open) {
+
+
+ RETURN_BOOL(1);
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, close) {
+
+
+ RETURN_BOOL(1);
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, read) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *sessionId, *_0, *_1;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 0, &sessionId);
+
+
+
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ _1 = zephir_fetch_nproperty_this(this_ptr, SL("_lifetime"), PH_NOISY_CC);
+ ZEPHIR_RETURN_CALL_METHOD(_0, "get", NULL, 0, sessionId, _1);
+ zephir_check_call_status();
+ RETURN_MM();
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, write) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *sessionId, *data, *_0, *_1;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 2, 0, &sessionId, &data);
+
+
+
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ _1 = zephir_fetch_nproperty_this(this_ptr, SL("_lifetime"), PH_NOISY_CC);
+ ZEPHIR_CALL_METHOD(NULL, _0, "save", NULL, 0, sessionId, data, _1);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, destroy) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *sessionId = NULL, *_0;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 0, 1, &sessionId);
+
+ if (!sessionId) {
+ ZEPHIR_CPY_WRT(sessionId, ZEPHIR_GLOBAL(global_null));
+ } else {
+ ZEPHIR_SEPARATE_PARAM(sessionId);
+ }
+
+
+ if (Z_TYPE_P(sessionId) == IS_NULL) {
+ ZEPHIR_CALL_METHOD(&sessionId, this_ptr, "getid", NULL, 0);
+ zephir_check_call_status();
+ }
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ ZEPHIR_RETURN_CALL_METHOD(_0, "delete", NULL, 0, sessionId);
+ zephir_check_call_status();
+ RETURN_MM();
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, gc) {
+
+
+ RETURN_BOOL(1);
+
+}
+
+
+
+
#ifdef HAVE_CONFIG_H
#endif
@@ -132432,7 +132932,7 @@ static PHP_METHOD(Phalcon_Tag_Select, selectField) {
ZEPHIR_GET_CONSTANT(_6, "PHP_EOL");
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SV(_7, "", _6);
- ZEPHIR_CALL_SELF(&_8, "_optionsfromresultset", &_9, 414, options, using, value, _7);
+ ZEPHIR_CALL_SELF(&_8, "_optionsfromresultset", &_9, 416, options, using, value, _7);
zephir_check_call_status();
zephir_concat_self(&code, _8 TSRMLS_CC);
} else {
@@ -132441,7 +132941,7 @@ static PHP_METHOD(Phalcon_Tag_Select, selectField) {
ZEPHIR_GET_CONSTANT(_6, "PHP_EOL");
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SV(_7, "", _6);
- ZEPHIR_CALL_SELF(&_8, "_optionsfromarray", &_10, 415, options, value, _7);
+ ZEPHIR_CALL_SELF(&_8, "_optionsfromarray", &_10, 417, options, value, _7);
zephir_check_call_status();
zephir_concat_self(&code, _8 TSRMLS_CC);
} else {
@@ -132579,12 +133079,12 @@ static PHP_METHOD(Phalcon_Tag_Select, _optionsFromArray) {
) {
ZEPHIR_GET_HMKEY(optionValue, _1, _0);
ZEPHIR_GET_HVALUE(optionText, _2);
- ZEPHIR_CALL_FUNCTION(&escaped, "htmlspecialchars", &_3, 180, optionValue);
+ ZEPHIR_CALL_FUNCTION(&escaped, "htmlspecialchars", &_3, 181, optionValue);
zephir_check_call_status();
if (Z_TYPE_P(optionText) == IS_ARRAY) {
ZEPHIR_INIT_NVAR(_4);
ZEPHIR_GET_CONSTANT(_4, "PHP_EOL");
- ZEPHIR_CALL_SELF(&_5, "_optionsfromarray", &_6, 415, optionText, value, closeOption);
+ ZEPHIR_CALL_SELF(&_5, "_optionsfromarray", &_6, 417, optionText, value, closeOption);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_7);
ZEPHIR_GET_CONSTANT(_7, "PHP_EOL");
@@ -132641,10 +133141,53 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter) {
ZEPHIR_REGISTER_CLASS(Phalcon\\Translate, Adapter, phalcon, translate_adapter, phalcon_translate_adapter_method_entry, ZEND_ACC_EXPLICIT_ABSTRACT_CLASS);
+ zend_declare_property_null(phalcon_translate_adapter_ce, SL("_interpolator"), ZEND_ACC_PROTECTED TSRMLS_CC);
+
return SUCCESS;
}
+static PHP_METHOD(Phalcon_Translate_Adapter, __construct) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *options_param = NULL, *interpolator = NULL;
+ zval *options = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 0, &options_param);
+
+ options = options_param;
+
+
+
+ ZEPHIR_OBS_VAR(interpolator);
+ if (!(zephir_array_isset_string_fetch(&interpolator, options, SS("interpolator"), 0 TSRMLS_CC))) {
+ ZEPHIR_INIT_NVAR(interpolator);
+ object_init_ex(interpolator, phalcon_translate_interpolator_associativearray_ce);
+ if (zephir_has_constructor(interpolator TSRMLS_CC)) {
+ ZEPHIR_CALL_METHOD(NULL, interpolator, "__construct", NULL, 0);
+ zephir_check_call_status();
+ }
+ }
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "setinterpolator", NULL, 0, interpolator);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Translate_Adapter, setInterpolator) {
+
+ zval *interpolator;
+
+ zephir_fetch_params(0, 1, 0, &interpolator);
+
+
+
+ zephir_update_property_this(this_ptr, SL("_interpolator"), interpolator TSRMLS_CC);
+ RETURN_THISW();
+
+}
+
static PHP_METHOD(Phalcon_Translate_Adapter, t) {
int ZEPHIR_LAST_CALL_STATUS;
@@ -132715,7 +133258,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter, offsetSet) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_translate_exception_ce, "Translate is an immutable ArrayAccess object", "phalcon/translate/adapter.zep", 64);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_translate_exception_ce, "Translate is an immutable ArrayAccess object", "phalcon/translate/adapter.zep", 86);
return;
}
@@ -132756,7 +133299,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter, offsetUnset) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_translate_exception_ce, "Translate is an immutable ArrayAccess object", "phalcon/translate/adapter.zep", 82);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_translate_exception_ce, "Translate is an immutable ArrayAccess object", "phalcon/translate/adapter.zep", 104);
return;
}
@@ -132793,9 +133336,8 @@ static PHP_METHOD(Phalcon_Translate_Adapter, offsetGet) {
static PHP_METHOD(Phalcon_Translate_Adapter, replacePlaceholders) {
- HashTable *_1;
- HashPosition _0;
- zval *translation_param = NULL, *placeholders = NULL, *key = NULL, *value = NULL, **_2, *_3 = NULL, *_4 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *translation_param = NULL, *placeholders = NULL, *_0;
zval *translation = NULL;
ZEPHIR_MM_GROW();
@@ -132817,24 +133359,10 @@ static PHP_METHOD(Phalcon_Translate_Adapter, replacePlaceholders) {
}
- if (Z_TYPE_P(placeholders) == IS_ARRAY) {
- if (zephir_fast_count_int(placeholders TSRMLS_CC)) {
- zephir_is_iterable(placeholders, &_1, &_0, 0, 0, "phalcon/translate/adapter.zep", 108);
- for (
- ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
- ; zephir_hash_move_forward_ex(_1, &_0)
- ) {
- ZEPHIR_GET_HMKEY(key, _1, _0);
- ZEPHIR_GET_HVALUE(value, _2);
- ZEPHIR_INIT_NVAR(_3);
- ZEPHIR_INIT_LNVAR(_4);
- ZEPHIR_CONCAT_SVS(_4, "%", key, "%");
- zephir_fast_str_replace(&_3, _4, value, translation TSRMLS_CC);
- zephir_get_strval(translation, _3);
- }
- }
- }
- RETURN_CTOR(translation);
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_interpolator"), PH_NOISY_CC);
+ ZEPHIR_RETURN_CALL_METHOD(_0, "replaceplaceholders", NULL, 0, translation, placeholders);
+ zephir_check_call_status();
+ RETURN_MM();
}
@@ -132889,6 +133417,28 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Exception) {
+#ifdef HAVE_CONFIG_H
+#endif
+
+#include
+
+#include
+
+
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_InterpolatorInterface) {
+
+ ZEPHIR_REGISTER_INTERFACE(Phalcon\\Translate, InterpolatorInterface, phalcon, translate_interpolatorinterface, phalcon_translate_interpolatorinterface_method_entry);
+
+ return SUCCESS;
+
+}
+
+ZEPHIR_DOC_METHOD(Phalcon_Translate_InterpolatorInterface, replacePlaceholders);
+
+
+
+
#ifdef HAVE_CONFIG_H
#endif
@@ -132916,11 +133466,10 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter_Csv) {
static PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct) {
- zend_bool _12;
- zephir_fcall_cache_entry *_9 = NULL;
int ZEPHIR_LAST_CALL_STATUS;
- zval *options_param = NULL, *data = NULL, *file = NULL, *_0, *_2, _3 = zval_used_for_init, *_4 = NULL, *_5, *_6, *_7, *_8, *_10, _11 = zval_used_for_init, *_13, *_14 = NULL;
- zval *options = NULL, *_1;
+ zephir_fcall_cache_entry *_0 = NULL;
+ zval *options_param = NULL, *_1, *_2, *_3, *_4;
+ zval *options = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 0, &options_param);
@@ -132929,64 +133478,80 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct) {
+ ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_csv_ce, this_ptr, "__construct", &_0, 426, options);
+ zephir_check_call_status();
if (!(zephir_array_isset_string(options, SS("content")))) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter 'content' is required", "phalcon/translate/adapter/csv.zep", 43);
return;
}
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_INIT_VAR(_1);
- zephir_create_array(_1, 3, 0 TSRMLS_CC);
- add_assoc_stringl_ex(_1, SS("delimiter"), SL(";"), 1);
- add_assoc_long_ex(_1, SS("length"), 0);
- add_assoc_stringl_ex(_1, SS("enclosure"), SL("\""), 1);
- zephir_fast_array_merge(_0, &(_1), &(options) TSRMLS_CC);
- ZEPHIR_CPY_WRT(options, _0);
- zephir_array_fetch_string(&_2, options, SL("content"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 52 TSRMLS_CC);
- ZEPHIR_SINIT_VAR(_3);
- ZVAL_STRING(&_3, "rb", 0);
- ZEPHIR_CALL_FUNCTION(&file, "fopen", NULL, 291, _2, &_3);
+ zephir_array_fetch_string(&_1, options, SL("content"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 46 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_2);
+ ZVAL_LONG(_2, 0);
+ ZEPHIR_INIT_VAR(_3);
+ ZVAL_STRING(_3, ";", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_INIT_VAR(_4);
+ ZVAL_STRING(_4, "\"", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "_load", NULL, 427, _1, _2, _3, _4);
+ zephir_check_temp_parameter(_3);
+ zephir_check_temp_parameter(_4);
zephir_check_call_status();
- if (Z_TYPE_P(file) != IS_RESOURCE) {
- ZEPHIR_INIT_VAR(_4);
- object_init_ex(_4, phalcon_translate_exception_ce);
- zephir_array_fetch_string(&_5, options, SL("content"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 55 TSRMLS_CC);
- ZEPHIR_INIT_VAR(_6);
- ZEPHIR_CONCAT_SVS(_6, "Error opening translation file '", _5, "'");
- ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 9, _6);
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Translate_Adapter_Csv, _load) {
+
+ zend_bool _6;
+ zephir_fcall_cache_entry *_3 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *file, *length, *delimiter, *enclosure, *data = NULL, *fileHandler = NULL, _0 = zval_used_for_init, *_1 = NULL, *_2, *_4, _5 = zval_used_for_init, *_7, *_8 = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 4, 0, &file, &length, &delimiter, &enclosure);
+
+
+
+ ZEPHIR_SINIT_VAR(_0);
+ ZVAL_STRING(&_0, "rb", 0);
+ ZEPHIR_CALL_FUNCTION(&fileHandler, "fopen", NULL, 292, file, &_0);
+ zephir_check_call_status();
+ if (Z_TYPE_P(fileHandler) != IS_RESOURCE) {
+ ZEPHIR_INIT_VAR(_1);
+ object_init_ex(_1, phalcon_translate_exception_ce);
+ ZEPHIR_INIT_VAR(_2);
+ ZEPHIR_CONCAT_SVS(_2, "Error opening translation file '", file, "'");
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_4, "phalcon/translate/adapter/csv.zep", 55 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/translate/adapter/csv.zep", 64 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
while (1) {
- zephir_array_fetch_string(&_5, options, SL("length"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 60 TSRMLS_CC);
- zephir_array_fetch_string(&_7, options, SL("delimiter"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 60 TSRMLS_CC);
- zephir_array_fetch_string(&_8, options, SL("enclosure"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 60 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&data, "fgetcsv", &_9, 424, file, _5, _7, _8);
+ ZEPHIR_CALL_FUNCTION(&data, "fgetcsv", &_3, 428, fileHandler, length, delimiter, enclosure);
zephir_check_call_status();
if (ZEPHIR_IS_FALSE_IDENTICAL(data)) {
break;
}
- zephir_array_fetch_long(&_10, data, 0, PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 65 TSRMLS_CC);
- ZEPHIR_SINIT_NVAR(_3);
- ZVAL_LONG(&_3, 0);
- ZEPHIR_SINIT_NVAR(_11);
- ZVAL_LONG(&_11, 1);
- ZEPHIR_INIT_NVAR(_4);
- zephir_substr(_4, _10, 0 , 1 , 0);
- _12 = ZEPHIR_IS_STRING_IDENTICAL(_4, "#");
- if (!(_12)) {
- _12 = !(zephir_array_isset_long(data, 1));
+ zephir_array_fetch_long(&_4, data, 0, PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 74 TSRMLS_CC);
+ ZEPHIR_SINIT_NVAR(_0);
+ ZVAL_LONG(&_0, 0);
+ ZEPHIR_SINIT_NVAR(_5);
+ ZVAL_LONG(&_5, 1);
+ ZEPHIR_INIT_NVAR(_1);
+ zephir_substr(_1, _4, 0 , 1 , 0);
+ _6 = ZEPHIR_IS_STRING_IDENTICAL(_1, "#");
+ if (!(_6)) {
+ _6 = !(zephir_array_isset_long(data, 1));
}
- if (_12) {
+ if (_6) {
continue;
}
- zephir_array_fetch_long(&_13, data, 1, PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 69 TSRMLS_CC);
- ZEPHIR_OBS_NVAR(_14);
- zephir_array_fetch_long(&_14, data, 0, PH_NOISY, "phalcon/translate/adapter/csv.zep", 69 TSRMLS_CC);
- zephir_update_property_array(this_ptr, SL("_translate"), _14, _13 TSRMLS_CC);
+ zephir_array_fetch_long(&_7, data, 1, PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 78 TSRMLS_CC);
+ ZEPHIR_OBS_NVAR(_8);
+ zephir_array_fetch_long(&_8, data, 0, PH_NOISY, "phalcon/translate/adapter/csv.zep", 78 TSRMLS_CC);
+ zephir_update_property_array(this_ptr, SL("_translate"), _8, _7 TSRMLS_CC);
}
- zephir_fclose(file TSRMLS_CC);
+ zephir_fclose(fileHandler TSRMLS_CC);
ZEPHIR_MM_RESTORE();
}
@@ -133109,6 +133674,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter_Gettext) {
static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, __construct) {
int ZEPHIR_LAST_CALL_STATUS;
+ zephir_fcall_cache_entry *_0 = NULL;
zval *options_param = NULL;
zval *options = NULL;
@@ -133119,6 +133685,8 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, __construct) {
+ ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_gettext_ce, this_ptr, "__construct", &_0, 426, options);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, this_ptr, "prepareoptions", NULL, 0, options);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -133150,22 +133718,22 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, query) {
}
- ZEPHIR_CALL_FUNCTION(&_0, "func_num_args", NULL, 419);
+ ZEPHIR_CALL_FUNCTION(&_0, "func_num_args", NULL, 421);
zephir_check_call_status();
if (ZEPHIR_GT_LONG(_0, 2)) {
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, 2);
- ZEPHIR_CALL_FUNCTION(&domain, "func_get_arg", NULL, 418, &_1);
+ ZEPHIR_CALL_FUNCTION(&domain, "func_get_arg", NULL, 420, &_1);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(domain);
ZVAL_NULL(domain);
}
if (!(zephir_is_true(domain))) {
- ZEPHIR_CALL_FUNCTION(&translation, "gettext", NULL, 425, index);
+ ZEPHIR_CALL_FUNCTION(&translation, "gettext", NULL, 429, index);
zephir_check_call_status();
} else {
- ZEPHIR_CALL_FUNCTION(&translation, "dgettext", NULL, 426, domain, index);
+ ZEPHIR_CALL_FUNCTION(&translation, "dgettext", NULL, 430, domain, index);
zephir_check_call_status();
}
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "replaceplaceholders", NULL, 0, translation, placeholders);
@@ -133263,12 +133831,12 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, nquery) {
if (!(domain && Z_STRLEN_P(domain))) {
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, count);
- ZEPHIR_CALL_FUNCTION(&translation, "ngettext", NULL, 427, msgid1, msgid2, &_0);
+ ZEPHIR_CALL_FUNCTION(&translation, "ngettext", NULL, 431, msgid1, msgid2, &_0);
zephir_check_call_status();
} else {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, count);
- ZEPHIR_CALL_FUNCTION(&translation, "dngettext", NULL, 428, domain, msgid1, msgid2, &_0);
+ ZEPHIR_CALL_FUNCTION(&translation, "dngettext", NULL, 432, domain, msgid1, msgid2, &_0);
zephir_check_call_status();
}
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "replaceplaceholders", NULL, 0, translation, placeholders);
@@ -133299,7 +133867,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setDomain) {
}
- ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 429, domain);
+ ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 433, domain);
zephir_check_call_status();
RETURN_MM();
@@ -133314,7 +133882,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, resetDomain) {
ZEPHIR_CALL_METHOD(&_0, this_ptr, "getdefaultdomain", NULL, 0);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 429, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 433, _0);
zephir_check_call_status();
RETURN_MM();
@@ -133369,21 +133937,21 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setDirectory) {
zephir_update_property_this(this_ptr, SL("_directory"), directory TSRMLS_CC);
if (Z_TYPE_P(directory) == IS_ARRAY) {
if (zephir_fast_count_int(directory TSRMLS_CC)) {
- zephir_is_iterable(directory, &_1, &_0, 0, 0, "phalcon/translate/adapter/gettext.zep", 180);
+ zephir_is_iterable(directory, &_1, &_0, 0, 0, "phalcon/translate/adapter/gettext.zep", 181);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
) {
ZEPHIR_GET_HMKEY(key, _1, _0);
ZEPHIR_GET_HVALUE(value, _2);
- ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 430, key, value);
+ ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 434, key, value);
zephir_check_call_status();
}
}
} else {
ZEPHIR_CALL_METHOD(&_4, this_ptr, "getdefaultdomain", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 430, _4, directory);
+ ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 434, _4, directory);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -133426,7 +133994,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setLocale) {
ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CALL_FUNCTION(&_1, "func_get_args", NULL, 165);
+ ZEPHIR_CALL_FUNCTION(&_1, "func_get_args", NULL, 166);
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_2);
ZVAL_STRING(&_2, "setlocale", 0);
@@ -133439,12 +134007,12 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setLocale) {
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_locale"), PH_NOISY_CC);
ZEPHIR_INIT_VAR(_4);
ZEPHIR_CONCAT_SV(_4, "LC_ALL=", _3);
- ZEPHIR_CALL_FUNCTION(NULL, "putenv", NULL, 431, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "putenv", NULL, 435, _4);
zephir_check_call_status();
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_locale"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_6);
ZVAL_LONG(&_6, 0);
- ZEPHIR_CALL_FUNCTION(NULL, "setlocale", NULL, 413, &_6, _5);
+ ZEPHIR_CALL_FUNCTION(NULL, "setlocale", NULL, 415, &_6, _5);
zephir_check_call_status();
RETURN_MM_MEMBER(this_ptr, "_locale");
@@ -133478,11 +134046,11 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, prepareOptions) {
if (!(zephir_array_isset_string(options, SS("locale")))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter \"locale\" is required", "phalcon/translate/adapter/gettext.zep", 230);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter \"locale\" is required", "phalcon/translate/adapter/gettext.zep", 231);
return;
}
if (!(zephir_array_isset_string(options, SS("directory")))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter \"directory\" is required", "phalcon/translate/adapter/gettext.zep", 234);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter \"directory\" is required", "phalcon/translate/adapter/gettext.zep", 235);
return;
}
ZEPHIR_INIT_VAR(_0);
@@ -133490,17 +134058,17 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, prepareOptions) {
zephir_check_call_status();
zephir_fast_array_merge(_0, &(_1), &(options) TSRMLS_CC);
ZEPHIR_CPY_WRT(options, _0);
- zephir_array_fetch_string(&_2, options, SL("category"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 239 TSRMLS_CC);
- zephir_array_fetch_string(&_3, options, SL("locale"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 239 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, options, SL("category"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 240 TSRMLS_CC);
+ zephir_array_fetch_string(&_3, options, SL("locale"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 240 TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "setlocale", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_array_fetch_string(&_4, options, SL("defaultDomain"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 240 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, options, SL("defaultDomain"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 241 TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "setdefaultdomain", NULL, 0, _4);
zephir_check_call_status();
- zephir_array_fetch_string(&_5, options, SL("directory"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 241 TSRMLS_CC);
+ zephir_array_fetch_string(&_5, options, SL("directory"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 242 TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "setdirectory", NULL, 0, _5);
zephir_check_call_status();
- zephir_array_fetch_string(&_6, options, SL("defaultDomain"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 242 TSRMLS_CC);
+ zephir_array_fetch_string(&_6, options, SL("defaultDomain"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 243 TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "setdomain", NULL, 0, _6);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -133545,6 +134113,8 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter_NativeArray) {
static PHP_METHOD(Phalcon_Translate_Adapter_NativeArray, __construct) {
+ int ZEPHIR_LAST_CALL_STATUS;
+ zephir_fcall_cache_entry *_0 = NULL;
zval *options_param = NULL, *data;
zval *options = NULL;
@@ -133555,13 +134125,15 @@ static PHP_METHOD(Phalcon_Translate_Adapter_NativeArray, __construct) {
+ ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_nativearray_ce, this_ptr, "__construct", &_0, 426, options);
+ zephir_check_call_status();
ZEPHIR_OBS_VAR(data);
if (!(zephir_array_isset_string_fetch(&data, options, SS("content"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Translation content was not provided", "phalcon/translate/adapter/nativearray.zep", 44);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Translation content was not provided", "phalcon/translate/adapter/nativearray.zep", 46);
return;
}
if (Z_TYPE_P(data) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Translation data must be an array", "phalcon/translate/adapter/nativearray.zep", 48);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Translation data must be an array", "phalcon/translate/adapter/nativearray.zep", 50);
return;
}
zephir_update_property_this(this_ptr, SL("_translate"), data TSRMLS_CC);
@@ -133634,6 +134206,147 @@ static PHP_METHOD(Phalcon_Translate_Adapter_NativeArray, exists) {
+#ifdef HAVE_CONFIG_H
+#endif
+
+#include
+
+#include
+#include
+#include
+
+
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_Interpolator_AssociativeArray) {
+
+ ZEPHIR_REGISTER_CLASS(Phalcon\\Translate\\Interpolator, AssociativeArray, phalcon, translate_interpolator_associativearray, phalcon_translate_interpolator_associativearray_method_entry, 0);
+
+ zend_class_implements(phalcon_translate_interpolator_associativearray_ce TSRMLS_CC, 1, phalcon_translate_interpolatorinterface_ce);
+ return SUCCESS;
+
+}
+
+static PHP_METHOD(Phalcon_Translate_Interpolator_AssociativeArray, replacePlaceholders) {
+
+ HashTable *_2;
+ HashPosition _1;
+ zend_bool _0;
+ zval *translation_param = NULL, *placeholders = NULL, *key = NULL, *value = NULL, **_3, *_4 = NULL, *_5 = NULL;
+ zval *translation = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 1, &translation_param, &placeholders);
+
+ if (unlikely(Z_TYPE_P(translation_param) != IS_STRING && Z_TYPE_P(translation_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'translation' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(translation_param) == IS_STRING)) {
+ zephir_get_strval(translation, translation_param);
+ } else {
+ ZEPHIR_INIT_VAR(translation);
+ ZVAL_EMPTY_STRING(translation);
+ }
+ if (!placeholders) {
+ placeholders = ZEPHIR_GLOBAL(global_null);
+ }
+
+
+ _0 = Z_TYPE_P(placeholders) == IS_ARRAY;
+ if (_0) {
+ _0 = (zephir_fast_count_int(placeholders TSRMLS_CC)) ? 1 : 0;
+ }
+ if (_0) {
+ zephir_is_iterable(placeholders, &_2, &_1, 0, 0, "phalcon/translate/interpolator/associativearray.zep", 38);
+ for (
+ ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
+ ; zephir_hash_move_forward_ex(_2, &_1)
+ ) {
+ ZEPHIR_GET_HMKEY(key, _2, _1);
+ ZEPHIR_GET_HVALUE(value, _3);
+ ZEPHIR_INIT_NVAR(_4);
+ ZEPHIR_INIT_LNVAR(_5);
+ ZEPHIR_CONCAT_SVS(_5, "%", key, "%");
+ zephir_fast_str_replace(&_4, _5, value, translation TSRMLS_CC);
+ zephir_get_strval(translation, _4);
+ }
+ }
+ RETURN_CTOR(translation);
+
+}
+
+
+
+
+#ifdef HAVE_CONFIG_H
+#endif
+
+#include
+
+#include
+#include
+#include
+
+
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_Interpolator_IndexedArray) {
+
+ ZEPHIR_REGISTER_CLASS(Phalcon\\Translate\\Interpolator, IndexedArray, phalcon, translate_interpolator_indexedarray, phalcon_translate_interpolator_indexedarray_method_entry, 0);
+
+ zend_class_implements(phalcon_translate_interpolator_indexedarray_ce TSRMLS_CC, 1, phalcon_translate_interpolatorinterface_ce);
+ return SUCCESS;
+
+}
+
+static PHP_METHOD(Phalcon_Translate_Interpolator_IndexedArray, replacePlaceholders) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zend_bool _0;
+ zval *translation_param = NULL, *placeholders = NULL, _1;
+ zval *translation = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 1, &translation_param, &placeholders);
+
+ if (unlikely(Z_TYPE_P(translation_param) != IS_STRING && Z_TYPE_P(translation_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'translation' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(translation_param) == IS_STRING)) {
+ zephir_get_strval(translation, translation_param);
+ } else {
+ ZEPHIR_INIT_VAR(translation);
+ ZVAL_EMPTY_STRING(translation);
+ }
+ if (!placeholders) {
+ placeholders = ZEPHIR_GLOBAL(global_null);
+ }
+
+
+ _0 = Z_TYPE_P(placeholders) == IS_ARRAY;
+ if (_0) {
+ _0 = (zephir_fast_count_int(placeholders TSRMLS_CC)) ? 1 : 0;
+ }
+ if (_0) {
+ Z_SET_ISREF_P(placeholders);
+ ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 386, placeholders, translation);
+ Z_UNSET_ISREF_P(placeholders);
+ zephir_check_call_status();
+ ZEPHIR_SINIT_VAR(_1);
+ ZVAL_STRING(&_1, "sprintf", 0);
+ ZEPHIR_CALL_USER_FUNC_ARRAY(return_value, &_1, placeholders);
+ zephir_check_call_status();
+ RETURN_MM();
+ }
+ RETURN_CTOR(translation);
+
+}
+
+
+
+
#ifdef HAVE_CONFIG_H
#endif
@@ -133839,7 +134552,7 @@ static PHP_METHOD(Phalcon_Validation_Message, __set_state) {
zephir_array_fetch_string(&_0, message, SL("_message"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC);
zephir_array_fetch_string(&_1, message, SL("_field"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC);
zephir_array_fetch_string(&_2, message, SL("_type"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 432, _0, _1, _2);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 436, _0, _1, _2);
zephir_check_call_status();
RETURN_MM();
@@ -133925,7 +134638,7 @@ static PHP_METHOD(Phalcon_Validation_Validator, __construct) {
_0 = Z_TYPE_P(options) != IS_NULL;
}
if (_0) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_validation_exception_ce, "Options must be an array", "phalcon/validation/validator.zep", 39);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_validation_exception_ce, "Options must be an array", "phalcon/validation/validator.zep", 40);
return;
} else {
zephir_update_property_this(this_ptr, SL("_options"), options TSRMLS_CC);
@@ -134453,7 +135166,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alnum, validate) {
if (_2) {
RETURN_MM_BOOL(1);
}
- ZEPHIR_CALL_FUNCTION(&_3, "ctype_alnum", NULL, 433, value);
+ ZEPHIR_CALL_FUNCTION(&_3, "ctype_alnum", NULL, 437, value);
zephir_check_call_status();
if (!(zephir_is_true(_3))) {
ZEPHIR_INIT_NVAR(_1);
@@ -134486,7 +135199,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alnum, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZVAL_STRING(_5, "Alnum", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _4, field, _5);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5);
zephir_check_temp_parameter(_5);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -134556,7 +135269,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alpha, validate) {
if (_2) {
RETURN_MM_BOOL(1);
}
- ZEPHIR_CALL_FUNCTION(&_3, "ctype_alpha", NULL, 434, value);
+ ZEPHIR_CALL_FUNCTION(&_3, "ctype_alpha", NULL, 438, value);
zephir_check_call_status();
if (!(zephir_is_true(_3))) {
ZEPHIR_INIT_NVAR(_1);
@@ -134589,7 +135302,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alpha, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZVAL_STRING(_5, "Alpha", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _4, field, _5);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5);
zephir_check_temp_parameter(_5);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -134706,7 +135419,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Between, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZVAL_STRING(_5, "Between", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 432, _4, field, _5);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _4, field, _5);
zephir_check_temp_parameter(_5);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -134770,7 +135483,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, validate) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&valueWith, validation, "getvalue", NULL, 0, fieldWith);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "compare", NULL, 435, value, valueWith);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "compare", NULL, 439, value, valueWith);
zephir_check_call_status();
if (!(zephir_is_true(_1))) {
ZEPHIR_INIT_NVAR(_0);
@@ -134813,7 +135526,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_3);
ZVAL_STRING(_3, "Confirmation", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 432, _2, field, _3);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _2, field, _3);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -134852,12 +135565,12 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, compare) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_STRING(&_3, "utf-8", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "mb_strtolower", &_5, 193, a, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "mb_strtolower", &_5, 194, a, &_3);
zephir_check_call_status();
zephir_get_strval(a, _4);
ZEPHIR_SINIT_NVAR(_3);
ZVAL_STRING(&_3, "utf-8", 0);
- ZEPHIR_CALL_FUNCTION(&_6, "mb_strtolower", &_5, 193, b, &_3);
+ ZEPHIR_CALL_FUNCTION(&_6, "mb_strtolower", &_5, 194, b, &_3);
zephir_check_call_status();
zephir_get_strval(b, _6);
}
@@ -134924,7 +135637,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Digit, validate) {
if (_2) {
RETURN_MM_BOOL(1);
}
- ZEPHIR_CALL_FUNCTION(&_3, "ctype_digit", NULL, 436, value);
+ ZEPHIR_CALL_FUNCTION(&_3, "ctype_digit", NULL, 440, value);
zephir_check_call_status();
if (!(zephir_is_true(_3))) {
ZEPHIR_INIT_NVAR(_1);
@@ -134957,7 +135670,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Digit, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZVAL_STRING(_5, "Digit", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _4, field, _5);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5);
zephir_check_temp_parameter(_5);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -135029,7 +135742,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Email, validate) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 274);
- ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 190, value, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_1);
@@ -135062,7 +135775,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Email, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_6);
ZVAL_STRING(_6, "Email", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _5, field, _6);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6);
zephir_check_temp_parameter(_6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -135138,7 +135851,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_ExclusionIn, validate) {
zephir_check_temp_parameter(_1);
zephir_check_call_status();
if (Z_TYPE_P(domain) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'domain' must be an array", "phalcon/validation/validator/exclusionin.zep", 59);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'domain' must be an array", "phalcon/validation/validator/exclusionin.zep", 62);
return;
}
if (zephir_fast_in_array(value, domain TSRMLS_CC)) {
@@ -135175,7 +135888,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_ExclusionIn, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_4);
ZVAL_STRING(_4, "ExclusionIn", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _3, field, _4);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _3, field, _4);
zephir_check_temp_parameter(_4);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -135246,7 +135959,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
ZEPHIR_CALL_METHOD(&label, validation, "getlabel", NULL, 0, field);
zephir_check_call_status();
}
- zephir_array_fetch_string(&_1, _SERVER, SL("REQUEST_METHOD"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 61 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, _SERVER, SL("REQUEST_METHOD"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 62 TSRMLS_CC);
_2 = ZEPHIR_IS_STRING(_1, "POST");
if (_2) {
_2 = ZEPHIR_IS_EMPTY(_POST);
@@ -135257,14 +135970,14 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
}
_4 = _3;
if (_4) {
- zephir_array_fetch_string(&_5, _SERVER, SL("CONTENT_LENGTH"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 61 TSRMLS_CC);
+ zephir_array_fetch_string(&_5, _SERVER, SL("CONTENT_LENGTH"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 62 TSRMLS_CC);
_4 = ZEPHIR_GT_LONG(_5, 0);
}
_6 = _4;
if (!(_6)) {
_7 = zephir_array_isset_string(value, SS("error"));
if (_7) {
- zephir_array_fetch_string(&_8, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 61 TSRMLS_CC);
+ zephir_array_fetch_string(&_8, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 62 TSRMLS_CC);
_7 = ZEPHIR_IS_LONG_IDENTICAL(_8, 1);
}
_6 = _7;
@@ -135291,7 +136004,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_11);
ZVAL_STRING(_11, "FileIniSize", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_12, 432, _9, field, _11);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_12, 436, _9, field, _11);
zephir_check_temp_parameter(_11);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -135309,7 +136022,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
if (!(_14)) {
_15 = zephir_array_isset_string(value, SS("error"));
if (_15) {
- zephir_array_fetch_string(&_16, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 73 TSRMLS_CC);
+ zephir_array_fetch_string(&_16, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 75 TSRMLS_CC);
_15 = ZEPHIR_IS_LONG_IDENTICAL(_16, 4);
}
_14 = _15;
@@ -135325,13 +136038,13 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
}
_18 = _17;
if (!(_18)) {
- zephir_array_fetch_string(&_19, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 77 TSRMLS_CC);
+ zephir_array_fetch_string(&_19, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 79 TSRMLS_CC);
_18 = !ZEPHIR_IS_LONG_IDENTICAL(_19, 0);
}
_20 = _18;
if (!(_20)) {
- zephir_array_fetch_string(&_21, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 77 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_9, "is_uploaded_file", NULL, 231, _21);
+ zephir_array_fetch_string(&_21, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 79 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&_9, "is_uploaded_file", NULL, 232, _21);
zephir_check_call_status();
_20 = !zephir_is_true(_9);
}
@@ -135357,7 +136070,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_23);
ZVAL_STRING(_23, "FileEmpty", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 432, _22, field, _23);
+ ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _22, field, _23);
zephir_check_temp_parameter(_23);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11);
@@ -135394,7 +136107,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_23);
ZVAL_STRING(_23, "FileValid", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 432, _9, field, _23);
+ ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _9, field, _23);
zephir_check_temp_parameter(_23);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11);
@@ -135437,22 +136150,22 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_preg_match(_11, _27, maxSize, matches, 0, 0 , 0 TSRMLS_CC);
if (zephir_array_isset_long(matches, 2)) {
ZEPHIR_OBS_NVAR(unit);
- zephir_array_fetch_long(&unit, matches, 2, PH_NOISY, "phalcon/validation/validator/file.zep", 110 TSRMLS_CC);
+ zephir_array_fetch_long(&unit, matches, 2, PH_NOISY, "phalcon/validation/validator/file.zep", 115 TSRMLS_CC);
}
- zephir_array_fetch_long(&_28, matches, 1, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 113 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 310, _28);
+ zephir_array_fetch_long(&_28, matches, 1, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 118 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 311, _28);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_30);
- zephir_array_fetch(&_31, byteUnits, unit, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 113 TSRMLS_CC);
+ zephir_array_fetch(&_31, byteUnits, unit, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 118 TSRMLS_CC);
ZEPHIR_SINIT_VAR(_32);
ZVAL_LONG(&_32, 2);
zephir_pow_function(_30, &_32, _31);
ZEPHIR_INIT_VAR(bytes);
mul_function(bytes, _22, _30 TSRMLS_CC);
- zephir_array_fetch_string(&_33, value, SL("size"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 115 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 310, _33);
+ zephir_array_fetch_string(&_33, value, SL("size"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 120 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 311, _33);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_34, "floatval", &_29, 310, bytes);
+ ZEPHIR_CALL_FUNCTION(&_34, "floatval", &_29, 311, bytes);
zephir_check_call_status();
if (ZEPHIR_GT(_22, _34)) {
ZEPHIR_INIT_NVAR(_30);
@@ -135477,7 +136190,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_36);
ZVAL_STRING(_36, "FileSize", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _30, "__construct", &_12, 432, _35, field, _36);
+ ZEPHIR_CALL_METHOD(NULL, _30, "__construct", &_12, 436, _35, field, _36);
zephir_check_temp_parameter(_36);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _30);
@@ -135497,22 +136210,22 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_temp_parameter(_11);
zephir_check_call_status();
if (Z_TYPE_P(types) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'allowedTypes' must be an array", "phalcon/validation/validator/file.zep", 132);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'allowedTypes' must be an array", "phalcon/validation/validator/file.zep", 138);
return;
}
if ((zephir_function_exists_ex(SS("finfo_open") TSRMLS_CC) == SUCCESS)) {
ZEPHIR_SINIT_NVAR(_32);
ZVAL_LONG(&_32, 16);
- ZEPHIR_CALL_FUNCTION(&tmp, "finfo_open", NULL, 228, &_32);
+ ZEPHIR_CALL_FUNCTION(&tmp, "finfo_open", NULL, 229, &_32);
zephir_check_call_status();
- zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 137 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 229, tmp, _28);
+ zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 143 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 230, tmp, _28);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 230, tmp);
+ ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 231, tmp);
zephir_check_call_status();
} else {
ZEPHIR_OBS_NVAR(mime);
- zephir_array_fetch_string(&mime, value, SL("type"), PH_NOISY, "phalcon/validation/validator/file.zep", 141 TSRMLS_CC);
+ zephir_array_fetch_string(&mime, value, SL("type"), PH_NOISY, "phalcon/validation/validator/file.zep", 147 TSRMLS_CC);
}
if (!(zephir_fast_in_array(mime, types TSRMLS_CC))) {
ZEPHIR_INIT_NVAR(_11);
@@ -135539,7 +136252,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_23);
ZVAL_STRING(_23, "FileType", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 432, _22, field, _23);
+ ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _22, field, _23);
zephir_check_temp_parameter(_23);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11);
@@ -135562,13 +136275,13 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
_37 = zephir_is_true(_22);
}
if (_37) {
- zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 158 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&tmp, "getimagesize", NULL, 248, _28);
+ zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 164 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&tmp, "getimagesize", NULL, 249, _28);
zephir_check_call_status();
ZEPHIR_OBS_VAR(width);
- zephir_array_fetch_long(&width, tmp, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 159 TSRMLS_CC);
+ zephir_array_fetch_long(&width, tmp, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 165 TSRMLS_CC);
ZEPHIR_OBS_VAR(height);
- zephir_array_fetch_long(&height, tmp, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 160 TSRMLS_CC);
+ zephir_array_fetch_long(&height, tmp, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 166 TSRMLS_CC);
ZEPHIR_INIT_NVAR(_11);
ZVAL_STRING(_11, "minResolution", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_CALL_METHOD(&_34, this_ptr, "issetoption", NULL, 0, _11);
@@ -135583,9 +136296,9 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
ZEPHIR_INIT_VAR(minResolution);
zephir_fast_explode_str(minResolution, SL("x"), _35, LONG_MAX TSRMLS_CC);
ZEPHIR_OBS_VAR(minWidth);
- zephir_array_fetch_long(&minWidth, minResolution, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 164 TSRMLS_CC);
+ zephir_array_fetch_long(&minWidth, minResolution, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 170 TSRMLS_CC);
ZEPHIR_OBS_VAR(minHeight);
- zephir_array_fetch_long(&minHeight, minResolution, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 165 TSRMLS_CC);
+ zephir_array_fetch_long(&minHeight, minResolution, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 171 TSRMLS_CC);
} else {
ZEPHIR_INIT_NVAR(minWidth);
ZVAL_LONG(minWidth, 1);
@@ -135624,7 +136337,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_23);
ZVAL_STRING(_23, "FileMinResolution", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 432, _35, field, _23);
+ ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _35, field, _23);
zephir_check_temp_parameter(_23);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11);
@@ -135645,9 +136358,9 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
ZEPHIR_INIT_VAR(maxResolution);
zephir_fast_explode_str(maxResolution, SL("x"), _39, LONG_MAX TSRMLS_CC);
ZEPHIR_OBS_VAR(maxWidth);
- zephir_array_fetch_long(&maxWidth, maxResolution, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 186 TSRMLS_CC);
+ zephir_array_fetch_long(&maxWidth, maxResolution, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 192 TSRMLS_CC);
ZEPHIR_OBS_VAR(maxHeight);
- zephir_array_fetch_long(&maxHeight, maxResolution, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 187 TSRMLS_CC);
+ zephir_array_fetch_long(&maxHeight, maxResolution, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 193 TSRMLS_CC);
_40 = ZEPHIR_GT(width, maxWidth);
if (!(_40)) {
_40 = ZEPHIR_GT(height, maxHeight);
@@ -135680,7 +136393,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_26);
ZVAL_STRING(_26, "FileMaxResolution", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _23, "__construct", &_12, 432, _41, field, _26);
+ ZEPHIR_CALL_METHOD(NULL, _23, "__construct", &_12, 436, _41, field, _26);
zephir_check_temp_parameter(_26);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _23);
@@ -135718,8 +136431,9 @@ ZEPHIR_INIT_CLASS(Phalcon_Validation_Validator_Identical) {
static PHP_METHOD(Phalcon_Validation_Validator_Identical, validate) {
int ZEPHIR_LAST_CALL_STATUS;
+ zend_bool valid;
zval *field = NULL;
- zval *validation, *field_param = NULL, *message = NULL, *label = NULL, *replacePairs, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4;
+ zval *validation, *field_param = NULL, *message = NULL, *label = NULL, *replacePairs, *value = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 0, &validation, &field_param);
@@ -135737,48 +136451,70 @@ static PHP_METHOD(Phalcon_Validation_Validator_Identical, validate) {
}
- ZEPHIR_CALL_METHOD(&_0, validation, "getvalue", NULL, 0, field);
+ ZEPHIR_CALL_METHOD(&value, validation, "getvalue", NULL, 0, field);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_2);
- ZVAL_STRING(_2, "accepted", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "getoption", NULL, 0, _2);
- zephir_check_temp_parameter(_2);
+ ZEPHIR_INIT_VAR(_1);
+ ZVAL_STRING(_1, "accepted", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "hasoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
zephir_check_call_status();
- if (!ZEPHIR_IS_EQUAL(_0, _1)) {
- ZEPHIR_INIT_NVAR(_2);
- ZVAL_STRING(_2, "label", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&label, this_ptr, "getoption", NULL, 0, _2);
- zephir_check_temp_parameter(_2);
+ if (zephir_is_true(_0)) {
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "accepted", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&_2, this_ptr, "getoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
+ zephir_check_call_status();
+ valid = ZEPHIR_IS_EQUAL(value, _2);
+ } else {
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "value", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&_2, this_ptr, "hasoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
+ zephir_check_call_status();
+ if (zephir_is_true(_2)) {
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "value", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "getoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
+ zephir_check_call_status();
+ valid = ZEPHIR_IS_EQUAL(value, _3);
+ }
+ }
+ if (!(valid)) {
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "label", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&label, this_ptr, "getoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
zephir_check_call_status();
if (ZEPHIR_IS_EMPTY(label)) {
ZEPHIR_CALL_METHOD(&label, validation, "getlabel", NULL, 0, field);
zephir_check_call_status();
}
- ZEPHIR_INIT_NVAR(_2);
- ZVAL_STRING(_2, "message", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&message, this_ptr, "getoption", NULL, 0, _2);
- zephir_check_temp_parameter(_2);
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "message", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&message, this_ptr, "getoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
zephir_check_call_status();
ZEPHIR_INIT_VAR(replacePairs);
zephir_create_array(replacePairs, 1, 0 TSRMLS_CC);
zephir_array_update_string(&replacePairs, SL(":field"), &label, PH_COPY | PH_SEPARATE);
if (ZEPHIR_IS_EMPTY(message)) {
- ZEPHIR_INIT_NVAR(_2);
- ZVAL_STRING(_2, "Identical", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&message, validation, "getdefaultmessage", NULL, 0, _2);
- zephir_check_temp_parameter(_2);
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "Identical", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&message, validation, "getdefaultmessage", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
zephir_check_call_status();
}
- ZEPHIR_INIT_NVAR(_2);
- object_init_ex(_2, phalcon_validation_message_ce);
- ZEPHIR_CALL_FUNCTION(&_3, "strtr", NULL, 53, message, replacePairs);
+ ZEPHIR_INIT_NVAR(_1);
+ object_init_ex(_1, phalcon_validation_message_ce);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, message, replacePairs);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_4);
ZVAL_STRING(_4, "Identical", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 432, _3, field, _4);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _2, field, _4);
zephir_check_temp_parameter(_4);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _2);
+ ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
zephir_check_call_status();
RETURN_MM_BOOL(0);
}
@@ -135851,7 +136587,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) {
zephir_check_temp_parameter(_1);
zephir_check_call_status();
if (Z_TYPE_P(domain) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'domain' must be an array", "phalcon/validation/validator/inclusionin.zep", 61);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'domain' must be an array", "phalcon/validation/validator/inclusionin.zep", 62);
return;
}
ZEPHIR_INIT_VAR(strict);
@@ -135863,7 +136599,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) {
zephir_check_call_status();
if (zephir_is_true(_3)) {
if (Z_TYPE_P(strict) != IS_BOOL) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'strict' must be a boolean", "phalcon/validation/validator/inclusionin.zep", 67);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'strict' must be a boolean", "phalcon/validation/validator/inclusionin.zep", 68);
return;
}
ZEPHIR_INIT_NVAR(_1);
@@ -135872,7 +136608,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) {
zephir_check_temp_parameter(_1);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_4, "in_array", NULL, 363, value, domain, strict);
+ ZEPHIR_CALL_FUNCTION(&_4, "in_array", NULL, 365, value, domain, strict);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_1);
@@ -135908,7 +136644,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_6);
ZVAL_STRING(_6, "InclusionIn", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _5, field, _6);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6);
zephir_check_temp_parameter(_6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -136014,7 +136750,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Numericality, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_7);
ZVAL_STRING(_7, "Numericality", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 432, _6, field, _7);
+ ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 436, _6, field, _7);
zephir_check_temp_parameter(_7);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _5);
@@ -136107,7 +136843,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_PresenceOf, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_3);
ZVAL_STRING(_3, "PresenceOf", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _2, field, _3);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _2, field, _3);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -136223,7 +136959,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Regex, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_7);
ZVAL_STRING(_7, "Regex", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 432, _6, field, _7);
+ ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 436, _6, field, _7);
zephir_check_temp_parameter(_7);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _4);
@@ -136322,7 +137058,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) {
zephir_check_call_status();
}
if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 364, value);
+ ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, value);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(length);
@@ -136357,7 +137093,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_6);
ZVAL_STRING(_6, "TooLong", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_7, 432, _4, field, _6);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_7, 436, _4, field, _6);
zephir_check_temp_parameter(_6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -136394,7 +137130,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_8);
ZVAL_STRING(_8, "TooShort", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_7, 432, _4, field, _8);
+ ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_7, 436, _4, field, _8);
zephir_check_temp_parameter(_8);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _6);
@@ -136480,7 +137216,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Uniqueness, validate) {
ZEPHIR_INIT_VAR(_1);
zephir_create_array(_1, 2, 0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_2);
- ZEPHIR_CONCAT_VSVS(_2, attribute, "=:value: AND ", attribute, "!= :except:");
+ ZEPHIR_CONCAT_VSVS(_2, attribute, " = :value: AND ", attribute, " != :except:");
zephir_array_fast_append(_1, _2);
ZEPHIR_INIT_VAR(_3);
zephir_create_array(_3, 2, 0 TSRMLS_CC);
@@ -136494,7 +137230,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Uniqueness, validate) {
ZEPHIR_INIT_NVAR(_1);
zephir_create_array(_1, 2, 0 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_2);
- ZEPHIR_CONCAT_VS(_2, attribute, "=:value:");
+ ZEPHIR_CONCAT_VS(_2, attribute, " = :value:");
zephir_array_fast_append(_1, _2);
ZEPHIR_INIT_NVAR(_3);
zephir_create_array(_3, 1, 0 TSRMLS_CC);
@@ -136535,7 +137271,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Uniqueness, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_7);
ZVAL_STRING(_7, "Uniqueness", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 432, _6, field, _7);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _6, field, _7);
zephir_check_temp_parameter(_7);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -136607,7 +137343,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Url, validate) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 273);
- ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 190, value, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_1);
@@ -136640,7 +137376,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Url, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_6);
ZVAL_STRING(_6, "Url", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _5, field, _6);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6);
zephir_check_temp_parameter(_6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -136680,8 +137416,8 @@ zend_class_entry *phalcon_forms_elementinterface_ce;
zend_class_entry *phalcon_validation_validatorinterface_ce;
zend_class_entry *phalcon_mvc_model_validatorinterface_ce;
zend_class_entry *phalcon_cache_backendinterface_ce;
-zend_class_entry *phalcon_cache_frontendinterface_ce;
zend_class_entry *phalcon_mvc_model_metadatainterface_ce;
+zend_class_entry *phalcon_cache_frontendinterface_ce;
zend_class_entry *phalcon_db_dialectinterface_ce;
zend_class_entry *phalcon_dispatcherinterface_ce;
zend_class_entry *phalcon_annotations_adapterinterface_ce;
@@ -136690,11 +137426,11 @@ zend_class_entry *phalcon_logger_adapterinterface_ce;
zend_class_entry *phalcon_logger_formatterinterface_ce;
zend_class_entry *phalcon_mvc_entityinterface_ce;
zend_class_entry *phalcon_mvc_model_resultsetinterface_ce;
+zend_class_entry *phalcon_session_adapterinterface_ce;
zend_class_entry *phalcon_assets_filterinterface_ce;
zend_class_entry *phalcon_diinterface_ce;
zend_class_entry *phalcon_mvc_viewbaseinterface_ce;
zend_class_entry *phalcon_paginator_adapterinterface_ce;
-zend_class_entry *phalcon_session_adapterinterface_ce;
zend_class_entry *phalcon_translate_adapterinterface_ce;
zend_class_entry *phalcon_acl_adapterinterface_ce;
zend_class_entry *phalcon_flashinterface_ce;
@@ -136705,6 +137441,7 @@ zend_class_entry *phalcon_mvc_model_metadata_strategyinterface_ce;
zend_class_entry *phalcon_mvc_model_resultinterface_ce;
zend_class_entry *phalcon_mvc_routerinterface_ce;
zend_class_entry *phalcon_mvc_view_engineinterface_ce;
+zend_class_entry *phalcon_translate_interpolatorinterface_ce;
zend_class_entry *phalcon_acl_roleinterface_ce;
zend_class_entry *phalcon_annotations_readerinterface_ce;
zend_class_entry *phalcon_cryptinterface_ce;
@@ -136760,9 +137497,9 @@ zend_class_entry *phalcon_db_adapter_pdo_ce;
zend_class_entry *phalcon_db_dialect_ce;
zend_class_entry *phalcon_logger_adapter_ce;
zend_class_entry *phalcon_logger_formatter_ce;
+zend_class_entry *phalcon_session_adapter_ce;
zend_class_entry *phalcon_mvc_model_exception_ce;
zend_class_entry *phalcon_paginator_adapter_ce;
-zend_class_entry *phalcon_session_adapter_ce;
zend_class_entry *phalcon_translate_adapter_ce;
zend_class_entry *phalcon_assets_inline_ce;
zend_class_entry *phalcon_assets_resource_ce;
@@ -136937,6 +137674,7 @@ zend_class_entry *phalcon_mvc_model_metadata_files_ce;
zend_class_entry *phalcon_mvc_model_metadata_libmemcached_ce;
zend_class_entry *phalcon_mvc_model_metadata_memcache_ce;
zend_class_entry *phalcon_mvc_model_metadata_memory_ce;
+zend_class_entry *phalcon_mvc_model_metadata_redis_ce;
zend_class_entry *phalcon_mvc_model_metadata_session_ce;
zend_class_entry *phalcon_mvc_model_metadata_strategy_annotations_ce;
zend_class_entry *phalcon_mvc_model_metadata_strategy_introspection_ce;
@@ -136990,6 +137728,7 @@ zend_class_entry *phalcon_security_exception_ce;
zend_class_entry *phalcon_session_adapter_files_ce;
zend_class_entry *phalcon_session_adapter_libmemcached_ce;
zend_class_entry *phalcon_session_adapter_memcache_ce;
+zend_class_entry *phalcon_session_adapter_redis_ce;
zend_class_entry *phalcon_session_bag_ce;
zend_class_entry *phalcon_session_ce;
zend_class_entry *phalcon_session_exception_ce;
@@ -137002,6 +137741,8 @@ zend_class_entry *phalcon_translate_adapter_gettext_ce;
zend_class_entry *phalcon_translate_adapter_nativearray_ce;
zend_class_entry *phalcon_translate_ce;
zend_class_entry *phalcon_translate_exception_ce;
+zend_class_entry *phalcon_translate_interpolator_associativearray_ce;
+zend_class_entry *phalcon_translate_interpolator_indexedarray_ce;
zend_class_entry *phalcon_validation_ce;
zend_class_entry *phalcon_validation_exception_ce;
zend_class_entry *phalcon_validation_message_ce;
@@ -137068,8 +137809,8 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Validation_ValidatorInterface);
ZEPHIR_INIT(Phalcon_Mvc_Model_ValidatorInterface);
ZEPHIR_INIT(Phalcon_Cache_BackendInterface);
- ZEPHIR_INIT(Phalcon_Cache_FrontendInterface);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaDataInterface);
+ ZEPHIR_INIT(Phalcon_Cache_FrontendInterface);
ZEPHIR_INIT(Phalcon_Db_DialectInterface);
ZEPHIR_INIT(Phalcon_DispatcherInterface);
ZEPHIR_INIT(Phalcon_Annotations_AdapterInterface);
@@ -137078,11 +137819,11 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Logger_FormatterInterface);
ZEPHIR_INIT(Phalcon_Mvc_EntityInterface);
ZEPHIR_INIT(Phalcon_Mvc_Model_ResultsetInterface);
+ ZEPHIR_INIT(Phalcon_Session_AdapterInterface);
ZEPHIR_INIT(Phalcon_Assets_FilterInterface);
ZEPHIR_INIT(Phalcon_DiInterface);
ZEPHIR_INIT(Phalcon_Mvc_ViewBaseInterface);
ZEPHIR_INIT(Phalcon_Paginator_AdapterInterface);
- ZEPHIR_INIT(Phalcon_Session_AdapterInterface);
ZEPHIR_INIT(Phalcon_Translate_AdapterInterface);
ZEPHIR_INIT(Phalcon_Acl_AdapterInterface);
ZEPHIR_INIT(Phalcon_FlashInterface);
@@ -137093,6 +137834,7 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Mvc_Model_ResultInterface);
ZEPHIR_INIT(Phalcon_Mvc_RouterInterface);
ZEPHIR_INIT(Phalcon_Mvc_View_EngineInterface);
+ ZEPHIR_INIT(Phalcon_Translate_InterpolatorInterface);
ZEPHIR_INIT(Phalcon_Acl_RoleInterface);
ZEPHIR_INIT(Phalcon_Annotations_ReaderInterface);
ZEPHIR_INIT(Phalcon_CryptInterface);
@@ -137148,9 +137890,9 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Db_Dialect);
ZEPHIR_INIT(Phalcon_Logger_Adapter);
ZEPHIR_INIT(Phalcon_Logger_Formatter);
+ ZEPHIR_INIT(Phalcon_Session_Adapter);
ZEPHIR_INIT(Phalcon_Mvc_Model_Exception);
ZEPHIR_INIT(Phalcon_Paginator_Adapter);
- ZEPHIR_INIT(Phalcon_Session_Adapter);
ZEPHIR_INIT(Phalcon_Translate_Adapter);
ZEPHIR_INIT(Phalcon_Assets_Inline);
ZEPHIR_INIT(Phalcon_Assets_Resource);
@@ -137324,6 +138066,7 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Libmemcached);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Memcache);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Memory);
+ ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Redis);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Session);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Strategy_Annotations);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Strategy_Introspection);
@@ -137378,6 +138121,7 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Session_Adapter_Files);
ZEPHIR_INIT(Phalcon_Session_Adapter_Libmemcached);
ZEPHIR_INIT(Phalcon_Session_Adapter_Memcache);
+ ZEPHIR_INIT(Phalcon_Session_Adapter_Redis);
ZEPHIR_INIT(Phalcon_Session_Bag);
ZEPHIR_INIT(Phalcon_Session_Exception);
ZEPHIR_INIT(Phalcon_Tag);
@@ -137389,6 +138133,8 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Translate_Adapter_Gettext);
ZEPHIR_INIT(Phalcon_Translate_Adapter_NativeArray);
ZEPHIR_INIT(Phalcon_Translate_Exception);
+ ZEPHIR_INIT(Phalcon_Translate_Interpolator_AssociativeArray);
+ ZEPHIR_INIT(Phalcon_Translate_Interpolator_IndexedArray);
ZEPHIR_INIT(Phalcon_Validation);
ZEPHIR_INIT(Phalcon_Validation_Exception);
ZEPHIR_INIT(Phalcon_Validation_Message);
diff --git a/build/32bits/phalcon.zep.h b/build/32bits/phalcon.zep.h
index 984ec057a1c..877bafc5931 100644
--- a/build/32bits/phalcon.zep.h
+++ b/build/32bits/phalcon.zep.h
@@ -593,29 +593,6 @@ ZEPHIR_INIT_FUNCS(phalcon_cache_backendinterface_method_entry) {
PHP_FE_END
};
-zend_class_entry *phalcon_cache_frontendinterface_ce;
-
-ZEPHIR_INIT_CLASS(Phalcon_Cache_FrontendInterface);
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_cache_frontendinterface_beforestore, 0, 0, 1)
- ZEND_ARG_INFO(0, data)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_cache_frontendinterface_afterretrieve, 0, 0, 1)
- ZEND_ARG_INFO(0, data)
-ZEND_END_ARG_INFO()
-
-ZEPHIR_INIT_FUNCS(phalcon_cache_frontendinterface_method_entry) {
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, getLifetime, NULL)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, isBuffering, NULL)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, start, NULL)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, getContent, NULL)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, stop, NULL)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, beforeStore, arginfo_phalcon_cache_frontendinterface_beforestore)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, afterRetrieve, arginfo_phalcon_cache_frontendinterface_afterretrieve)
- PHP_FE_END
-};
-
zend_class_entry *phalcon_mvc_model_metadata_ce;
ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_MetaData);
@@ -950,6 +927,29 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_model_metadatainterface_method_entry) {
PHP_FE_END
};
+zend_class_entry *phalcon_cache_frontendinterface_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Cache_FrontendInterface);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_cache_frontendinterface_beforestore, 0, 0, 1)
+ ZEND_ARG_INFO(0, data)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_cache_frontendinterface_afterretrieve, 0, 0, 1)
+ ZEND_ARG_INFO(0, data)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_cache_frontendinterface_method_entry) {
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, getLifetime, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, isBuffering, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, start, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, getContent, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, stop, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, beforeStore, arginfo_phalcon_cache_frontendinterface_beforestore)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, afterRetrieve, arginfo_phalcon_cache_frontendinterface_afterretrieve)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_db_adapter_ce;
ZEPHIR_INIT_CLASS(Phalcon_Db_Adapter);
@@ -2617,6 +2617,145 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_model_resultsetinterface_method_entry) {
PHP_FE_END
};
+zend_class_entry *phalcon_session_adapter_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Session_Adapter);
+
+static PHP_METHOD(Phalcon_Session_Adapter, __construct);
+static PHP_METHOD(Phalcon_Session_Adapter, start);
+static PHP_METHOD(Phalcon_Session_Adapter, setOptions);
+static PHP_METHOD(Phalcon_Session_Adapter, getOptions);
+static PHP_METHOD(Phalcon_Session_Adapter, setName);
+static PHP_METHOD(Phalcon_Session_Adapter, getName);
+static PHP_METHOD(Phalcon_Session_Adapter, get);
+static PHP_METHOD(Phalcon_Session_Adapter, set);
+static PHP_METHOD(Phalcon_Session_Adapter, has);
+static PHP_METHOD(Phalcon_Session_Adapter, remove);
+static PHP_METHOD(Phalcon_Session_Adapter, getId);
+static PHP_METHOD(Phalcon_Session_Adapter, setId);
+static PHP_METHOD(Phalcon_Session_Adapter, isStarted);
+static PHP_METHOD(Phalcon_Session_Adapter, destroy);
+static PHP_METHOD(Phalcon_Session_Adapter, status);
+static PHP_METHOD(Phalcon_Session_Adapter, __get);
+static PHP_METHOD(Phalcon_Session_Adapter, __set);
+static PHP_METHOD(Phalcon_Session_Adapter, __isset);
+static PHP_METHOD(Phalcon_Session_Adapter, __unset);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___construct, 0, 0, 0)
+ ZEND_ARG_INFO(0, options)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setoptions, 0, 0, 1)
+ ZEND_ARG_ARRAY_INFO(0, options, 0)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setname, 0, 0, 1)
+ ZEND_ARG_INFO(0, name)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_get, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ ZEND_ARG_INFO(0, defaultValue)
+ ZEND_ARG_INFO(0, remove)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_set, 0, 0, 2)
+ ZEND_ARG_INFO(0, index)
+ ZEND_ARG_INFO(0, value)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_has, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_remove, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setid, 0, 0, 1)
+ ZEND_ARG_INFO(0, id)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___get, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___set, 0, 0, 2)
+ ZEND_ARG_INFO(0, index)
+ ZEND_ARG_INFO(0, value)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___isset, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___unset, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_session_adapter_method_entry) {
+ PHP_ME(Phalcon_Session_Adapter, __construct, arginfo_phalcon_session_adapter___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Session_Adapter, start, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, setOptions, arginfo_phalcon_session_adapter_setoptions, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, getOptions, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, setName, arginfo_phalcon_session_adapter_setname, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, getName, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, get, arginfo_phalcon_session_adapter_get, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, set, arginfo_phalcon_session_adapter_set, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, has, arginfo_phalcon_session_adapter_has, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, remove, arginfo_phalcon_session_adapter_remove, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, getId, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, setId, arginfo_phalcon_session_adapter_setid, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, isStarted, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, destroy, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, status, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, __get, arginfo_phalcon_session_adapter___get, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, __set, arginfo_phalcon_session_adapter___set, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, __isset, arginfo_phalcon_session_adapter___isset, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, __unset, arginfo_phalcon_session_adapter___unset, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
+
+zend_class_entry *phalcon_session_adapterinterface_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Session_AdapterInterface);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_setoptions, 0, 0, 1)
+ ZEND_ARG_ARRAY_INFO(0, options, 0)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_get, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ ZEND_ARG_INFO(0, defaultValue)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_set, 0, 0, 2)
+ ZEND_ARG_INFO(0, index)
+ ZEND_ARG_INFO(0, value)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_has, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_remove, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_session_adapterinterface_method_entry) {
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, start, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, setOptions, arginfo_phalcon_session_adapterinterface_setoptions)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, getOptions, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, get, arginfo_phalcon_session_adapterinterface_get)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, set, arginfo_phalcon_session_adapterinterface_set)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, has, arginfo_phalcon_session_adapterinterface_has)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, remove, arginfo_phalcon_session_adapterinterface_remove)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, getId, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, isStarted, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, destroy, NULL)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_assets_filterinterface_ce;
ZEPHIR_INIT_CLASS(Phalcon_Assets_FilterInterface);
@@ -2803,149 +2942,12 @@ ZEPHIR_INIT_FUNCS(phalcon_paginator_adapterinterface_method_entry) {
PHP_FE_END
};
-zend_class_entry *phalcon_session_adapter_ce;
-
-ZEPHIR_INIT_CLASS(Phalcon_Session_Adapter);
-
-static PHP_METHOD(Phalcon_Session_Adapter, __construct);
-static PHP_METHOD(Phalcon_Session_Adapter, start);
-static PHP_METHOD(Phalcon_Session_Adapter, setOptions);
-static PHP_METHOD(Phalcon_Session_Adapter, getOptions);
-static PHP_METHOD(Phalcon_Session_Adapter, setName);
-static PHP_METHOD(Phalcon_Session_Adapter, getName);
-static PHP_METHOD(Phalcon_Session_Adapter, get);
-static PHP_METHOD(Phalcon_Session_Adapter, set);
-static PHP_METHOD(Phalcon_Session_Adapter, has);
-static PHP_METHOD(Phalcon_Session_Adapter, remove);
-static PHP_METHOD(Phalcon_Session_Adapter, getId);
-static PHP_METHOD(Phalcon_Session_Adapter, setId);
-static PHP_METHOD(Phalcon_Session_Adapter, isStarted);
-static PHP_METHOD(Phalcon_Session_Adapter, destroy);
-static PHP_METHOD(Phalcon_Session_Adapter, status);
-static PHP_METHOD(Phalcon_Session_Adapter, __get);
-static PHP_METHOD(Phalcon_Session_Adapter, __set);
-static PHP_METHOD(Phalcon_Session_Adapter, __isset);
-static PHP_METHOD(Phalcon_Session_Adapter, __unset);
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___construct, 0, 0, 0)
- ZEND_ARG_INFO(0, options)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setoptions, 0, 0, 1)
- ZEND_ARG_ARRAY_INFO(0, options, 0)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setname, 0, 0, 1)
- ZEND_ARG_INFO(0, name)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_get, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
- ZEND_ARG_INFO(0, defaultValue)
- ZEND_ARG_INFO(0, remove)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_set, 0, 0, 2)
- ZEND_ARG_INFO(0, index)
- ZEND_ARG_INFO(0, value)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_has, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_remove, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setid, 0, 0, 1)
- ZEND_ARG_INFO(0, id)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___get, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___set, 0, 0, 2)
- ZEND_ARG_INFO(0, index)
- ZEND_ARG_INFO(0, value)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___isset, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___unset, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEPHIR_INIT_FUNCS(phalcon_session_adapter_method_entry) {
- PHP_ME(Phalcon_Session_Adapter, __construct, arginfo_phalcon_session_adapter___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
- PHP_ME(Phalcon_Session_Adapter, start, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, setOptions, arginfo_phalcon_session_adapter_setoptions, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, getOptions, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, setName, arginfo_phalcon_session_adapter_setname, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, getName, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, get, arginfo_phalcon_session_adapter_get, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, set, arginfo_phalcon_session_adapter_set, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, has, arginfo_phalcon_session_adapter_has, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, remove, arginfo_phalcon_session_adapter_remove, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, getId, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, setId, arginfo_phalcon_session_adapter_setid, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, isStarted, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, destroy, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, status, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, __get, arginfo_phalcon_session_adapter___get, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, __set, arginfo_phalcon_session_adapter___set, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, __isset, arginfo_phalcon_session_adapter___isset, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, __unset, arginfo_phalcon_session_adapter___unset, ZEND_ACC_PUBLIC)
- PHP_FE_END
-};
-
-zend_class_entry *phalcon_session_adapterinterface_ce;
-
-ZEPHIR_INIT_CLASS(Phalcon_Session_AdapterInterface);
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_setoptions, 0, 0, 1)
- ZEND_ARG_ARRAY_INFO(0, options, 0)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_get, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
- ZEND_ARG_INFO(0, defaultValue)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_set, 0, 0, 2)
- ZEND_ARG_INFO(0, index)
- ZEND_ARG_INFO(0, value)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_has, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_remove, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEPHIR_INIT_FUNCS(phalcon_session_adapterinterface_method_entry) {
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, start, NULL)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, setOptions, arginfo_phalcon_session_adapterinterface_setoptions)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, getOptions, NULL)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, get, arginfo_phalcon_session_adapterinterface_get)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, set, arginfo_phalcon_session_adapterinterface_set)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, has, arginfo_phalcon_session_adapterinterface_has)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, remove, arginfo_phalcon_session_adapterinterface_remove)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, getId, NULL)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, isStarted, NULL)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, destroy, NULL)
- PHP_FE_END
-};
-
zend_class_entry *phalcon_translate_adapter_ce;
ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter);
+static PHP_METHOD(Phalcon_Translate_Adapter, __construct);
+static PHP_METHOD(Phalcon_Translate_Adapter, setInterpolator);
static PHP_METHOD(Phalcon_Translate_Adapter, t);
static PHP_METHOD(Phalcon_Translate_Adapter, _);
static PHP_METHOD(Phalcon_Translate_Adapter, offsetSet);
@@ -2954,6 +2956,14 @@ static PHP_METHOD(Phalcon_Translate_Adapter, offsetUnset);
static PHP_METHOD(Phalcon_Translate_Adapter, offsetGet);
static PHP_METHOD(Phalcon_Translate_Adapter, replacePlaceholders);
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter___construct, 0, 0, 1)
+ ZEND_ARG_ARRAY_INFO(0, options, 0)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_setinterpolator, 0, 0, 1)
+ ZEND_ARG_OBJ_INFO(0, interpolator, Phalcon\\Translate\\InterpolatorInterface, 0)
+ZEND_END_ARG_INFO()
+
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_t, 0, 0, 1)
ZEND_ARG_INFO(0, translateKey)
ZEND_ARG_INFO(0, placeholders)
@@ -2987,6 +2997,8 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_replaceplaceholders, 0,
ZEND_END_ARG_INFO()
ZEPHIR_INIT_FUNCS(phalcon_translate_adapter_method_entry) {
+ PHP_ME(Phalcon_Translate_Adapter, __construct, arginfo_phalcon_translate_adapter___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Translate_Adapter, setInterpolator, arginfo_phalcon_translate_adapter_setinterpolator, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Translate_Adapter, t, arginfo_phalcon_translate_adapter_t, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Translate_Adapter, _, arginfo_phalcon_translate_adapter__, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Translate_Adapter, offsetSet, arginfo_phalcon_translate_adapter_offsetset, ZEND_ACC_PUBLIC)
@@ -4259,6 +4271,20 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_view_engineinterface_method_entry) {
PHP_FE_END
};
+zend_class_entry *phalcon_translate_interpolatorinterface_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_InterpolatorInterface);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_interpolatorinterface_replaceplaceholders, 0, 0, 1)
+ ZEND_ARG_INFO(0, translation)
+ ZEND_ARG_INFO(0, placeholders)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_translate_interpolatorinterface_method_entry) {
+ PHP_ABSTRACT_ME(Phalcon_Translate_InterpolatorInterface, replacePlaceholders, arginfo_phalcon_translate_interpolatorinterface_replaceplaceholders)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_acl_adapter_ce;
ZEPHIR_INIT_CLASS(Phalcon_Acl_Adapter);
@@ -9050,6 +9076,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, describeReferences);
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, tableOptions);
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, supportsSavepoints);
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, supportsReleaseSavepoints);
+static PHP_METHOD(Phalcon_Db_Dialect_Oracle, prepareTable);
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_dialect_oracle_limit, 0, 0, 2)
ZEND_ARG_INFO(0, sqlQuery)
@@ -9176,6 +9203,13 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_dialect_oracle_tableoptions, 0, 0, 1)
ZEND_ARG_INFO(0, schema)
ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_dialect_oracle_preparetable, 0, 0, 1)
+ ZEND_ARG_INFO(0, table)
+ ZEND_ARG_INFO(0, schema)
+ ZEND_ARG_INFO(0, alias)
+ ZEND_ARG_INFO(0, escapeChar)
+ZEND_END_ARG_INFO()
+
ZEPHIR_INIT_FUNCS(phalcon_db_dialect_oracle_method_entry) {
PHP_ME(Phalcon_Db_Dialect_Oracle, limit, arginfo_phalcon_db_dialect_oracle_limit, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Db_Dialect_Oracle, getColumnDefinition, arginfo_phalcon_db_dialect_oracle_getcolumndefinition, ZEND_ACC_PUBLIC)
@@ -9202,6 +9236,7 @@ ZEPHIR_INIT_FUNCS(phalcon_db_dialect_oracle_method_entry) {
PHP_ME(Phalcon_Db_Dialect_Oracle, tableOptions, arginfo_phalcon_db_dialect_oracle_tableoptions, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Db_Dialect_Oracle, supportsSavepoints, NULL, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Db_Dialect_Oracle, supportsReleaseSavepoints, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Db_Dialect_Oracle, prepareTable, arginfo_phalcon_db_dialect_oracle_preparetable, ZEND_ACC_PROTECTED)
PHP_FE_END
};
@@ -11232,6 +11267,7 @@ static PHP_METHOD(Phalcon_Http_Response, setHeader);
static PHP_METHOD(Phalcon_Http_Response, setRawHeader);
static PHP_METHOD(Phalcon_Http_Response, resetHeaders);
static PHP_METHOD(Phalcon_Http_Response, setExpires);
+static PHP_METHOD(Phalcon_Http_Response, setCache);
static PHP_METHOD(Phalcon_Http_Response, setNotModified);
static PHP_METHOD(Phalcon_Http_Response, setContentType);
static PHP_METHOD(Phalcon_Http_Response, setEtag);
@@ -11282,6 +11318,10 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_response_setexpires, 0, 0, 1)
ZEND_ARG_OBJ_INFO(0, datetime, DateTime, 0)
ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_response_setcache, 0, 0, 1)
+ ZEND_ARG_INFO(0, minutes)
+ZEND_END_ARG_INFO()
+
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_response_setcontenttype, 0, 0, 1)
ZEND_ARG_INFO(0, contentType)
ZEND_ARG_INFO(0, charset)
@@ -11331,6 +11371,7 @@ ZEPHIR_INIT_FUNCS(phalcon_http_response_method_entry) {
PHP_ME(Phalcon_Http_Response, setRawHeader, arginfo_phalcon_http_response_setrawheader, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, resetHeaders, NULL, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, setExpires, arginfo_phalcon_http_response_setexpires, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Http_Response, setCache, arginfo_phalcon_http_response_setcache, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, setNotModified, NULL, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, setContentType, arginfo_phalcon_http_response_setcontenttype, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, setEtag, arginfo_phalcon_http_response_setetag, ZEND_ACC_PUBLIC)
@@ -14498,6 +14539,36 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_model_metadata_memory_method_entry) {
PHP_FE_END
};
+zend_class_entry *phalcon_mvc_model_metadata_redis_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_MetaData_Redis);
+
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, __construct);
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, read);
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, write);
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, reset);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_metadata_redis___construct, 0, 0, 0)
+ ZEND_ARG_INFO(0, options)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_metadata_redis_read, 0, 0, 1)
+ ZEND_ARG_INFO(0, key)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_metadata_redis_write, 0, 0, 2)
+ ZEND_ARG_INFO(0, key)
+ ZEND_ARG_INFO(0, data)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_mvc_model_metadata_redis_method_entry) {
+ PHP_ME(Phalcon_Mvc_Model_MetaData_Redis, __construct, arginfo_phalcon_mvc_model_metadata_redis___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Mvc_Model_MetaData_Redis, read, arginfo_phalcon_mvc_model_metadata_redis_read, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Mvc_Model_MetaData_Redis, write, arginfo_phalcon_mvc_model_metadata_redis_write, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Mvc_Model_MetaData_Redis, reset, NULL, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_mvc_model_metadata_session_ce;
ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_MetaData_Session);
@@ -16852,7 +16923,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, stats);
static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, __wakeup);
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_queue_beanstalk_job___construct, 0, 0, 3)
- ZEND_ARG_INFO(0, queue)
+ ZEND_ARG_OBJ_INFO(0, queue, Phalcon\\Queue\\Beanstalk, 0)
ZEND_ARG_INFO(0, id)
ZEND_ARG_INFO(0, body)
ZEND_END_ARG_INFO()
@@ -17157,6 +17228,50 @@ ZEPHIR_INIT_FUNCS(phalcon_session_adapter_memcache_method_entry) {
PHP_FE_END
};
+zend_class_entry *phalcon_session_adapter_redis_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Session_Adapter_Redis);
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, getRedis);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, getLifetime);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, __construct);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, open);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, close);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, read);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, write);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, destroy);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, gc);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_redis___construct, 0, 0, 0)
+ ZEND_ARG_ARRAY_INFO(0, options, 1)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_redis_read, 0, 0, 1)
+ ZEND_ARG_INFO(0, sessionId)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_redis_write, 0, 0, 2)
+ ZEND_ARG_INFO(0, sessionId)
+ ZEND_ARG_INFO(0, data)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_redis_destroy, 0, 0, 0)
+ ZEND_ARG_INFO(0, sessionId)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_session_adapter_redis_method_entry) {
+ PHP_ME(Phalcon_Session_Adapter_Redis, getRedis, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, getLifetime, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, __construct, arginfo_phalcon_session_adapter_redis___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Session_Adapter_Redis, open, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, close, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, read, arginfo_phalcon_session_adapter_redis_read, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, write, arginfo_phalcon_session_adapter_redis_write, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, destroy, arginfo_phalcon_session_adapter_redis_destroy, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, gc, NULL, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_session_bag_ce;
ZEPHIR_INIT_CLASS(Phalcon_Session_Bag);
@@ -17739,6 +17854,7 @@ zend_class_entry *phalcon_translate_adapter_csv_ce;
ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter_Csv);
static PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct);
+static PHP_METHOD(Phalcon_Translate_Adapter_Csv, _load);
static PHP_METHOD(Phalcon_Translate_Adapter_Csv, query);
static PHP_METHOD(Phalcon_Translate_Adapter_Csv, exists);
static zend_object_value zephir_init_properties_Phalcon_Translate_Adapter_Csv(zend_class_entry *class_type TSRMLS_DC);
@@ -17747,6 +17863,13 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_csv___construct, 0, 0,
ZEND_ARG_ARRAY_INFO(0, options, 0)
ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_csv__load, 0, 0, 4)
+ ZEND_ARG_INFO(0, file)
+ ZEND_ARG_INFO(0, length)
+ ZEND_ARG_INFO(0, delimiter)
+ ZEND_ARG_INFO(0, enclosure)
+ZEND_END_ARG_INFO()
+
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_csv_query, 0, 0, 1)
ZEND_ARG_INFO(0, index)
ZEND_ARG_INFO(0, placeholders)
@@ -17758,6 +17881,7 @@ ZEND_END_ARG_INFO()
ZEPHIR_INIT_FUNCS(phalcon_translate_adapter_csv_method_entry) {
PHP_ME(Phalcon_Translate_Adapter_Csv, __construct, arginfo_phalcon_translate_adapter_csv___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Translate_Adapter_Csv, _load, arginfo_phalcon_translate_adapter_csv__load, ZEND_ACC_PRIVATE)
PHP_ME(Phalcon_Translate_Adapter_Csv, query, arginfo_phalcon_translate_adapter_csv_query, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Translate_Adapter_Csv, exists, arginfo_phalcon_translate_adapter_csv_exists, ZEND_ACC_PUBLIC)
PHP_FE_END
@@ -17881,6 +18005,38 @@ zend_class_entry *phalcon_translate_exception_ce;
ZEPHIR_INIT_CLASS(Phalcon_Translate_Exception);
+zend_class_entry *phalcon_translate_interpolator_associativearray_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_Interpolator_AssociativeArray);
+
+static PHP_METHOD(Phalcon_Translate_Interpolator_AssociativeArray, replacePlaceholders);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_interpolator_associativearray_replaceplaceholders, 0, 0, 1)
+ ZEND_ARG_INFO(0, translation)
+ ZEND_ARG_INFO(0, placeholders)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_translate_interpolator_associativearray_method_entry) {
+ PHP_ME(Phalcon_Translate_Interpolator_AssociativeArray, replacePlaceholders, arginfo_phalcon_translate_interpolator_associativearray_replaceplaceholders, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
+
+zend_class_entry *phalcon_translate_interpolator_indexedarray_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_Interpolator_IndexedArray);
+
+static PHP_METHOD(Phalcon_Translate_Interpolator_IndexedArray, replacePlaceholders);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_interpolator_indexedarray_replaceplaceholders, 0, 0, 1)
+ ZEND_ARG_INFO(0, translation)
+ ZEND_ARG_INFO(0, placeholders)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_translate_interpolator_indexedarray_method_entry) {
+ PHP_ME(Phalcon_Translate_Interpolator_IndexedArray, replacePlaceholders, arginfo_phalcon_translate_interpolator_indexedarray_replaceplaceholders, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_validation_ce;
ZEPHIR_INIT_CLASS(Phalcon_Validation);
diff --git a/build/32bits/php_phalcon.h b/build/32bits/php_phalcon.h
index e67d31674a1..aed59e8482d 100644
--- a/build/32bits/php_phalcon.h
+++ b/build/32bits/php_phalcon.h
@@ -196,7 +196,7 @@ typedef zend_function zephir_fcall_cache_entry;
#define PHP_PHALCON_NAME "phalcon"
-#define PHP_PHALCON_VERSION "2.0.5"
+#define PHP_PHALCON_VERSION "2.0.6"
#define PHP_PHALCON_EXTNAME "phalcon"
#define PHP_PHALCON_AUTHOR "Phalcon Team and contributors"
#define PHP_PHALCON_ZEPVERSION "0.7.1b"
diff --git a/build/64bits/phalcon.zep.c b/build/64bits/phalcon.zep.c
index 889eaa24e83..f03e012a1f9 100644
--- a/build/64bits/phalcon.zep.c
+++ b/build/64bits/phalcon.zep.c
@@ -3605,6 +3605,11 @@ long zephir_safe_mod_double_zval(double op1, zval *op2 TSRMLS_DC);
#define ZEPHIR_SCONCAT_SVSVSVS(result, op1, op2, op3, op4, op5, op6, op7) \
zephir_concat_svsvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, 1 TSRMLS_CC);
+#define ZEPHIR_CONCAT_SVSVSVSSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9, op10, op11, op12) \
+ zephir_concat_svsvsvssvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, sizeof(op8)-1, op9, op10, sizeof(op10)-1, op11, op12, sizeof(op12)-1, 0 TSRMLS_CC);
+#define ZEPHIR_SCONCAT_SVSVSVSSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9, op10, op11, op12) \
+ zephir_concat_svsvsvssvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, sizeof(op8)-1, op9, op10, sizeof(op10)-1, op11, op12, sizeof(op12)-1, 1 TSRMLS_CC);
+
#define ZEPHIR_CONCAT_SVSVSVSV(result, op1, op2, op3, op4, op5, op6, op7, op8) \
zephir_concat_svsvsvsv(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, 0 TSRMLS_CC);
#define ZEPHIR_SCONCAT_SVSVSVSV(result, op1, op2, op3, op4, op5, op6, op7, op8) \
@@ -3615,6 +3620,11 @@ long zephir_safe_mod_double_zval(double op1, zval *op2 TSRMLS_DC);
#define ZEPHIR_SCONCAT_SVSVSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9) \
zephir_concat_svsvsvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, op9, sizeof(op9)-1, 1 TSRMLS_CC);
+#define ZEPHIR_CONCAT_SVSVSVSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9, op10, op11) \
+ zephir_concat_svsvsvsvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, op9, sizeof(op9)-1, op10, op11, sizeof(op11)-1, 0 TSRMLS_CC);
+#define ZEPHIR_SCONCAT_SVSVSVSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9, op10, op11) \
+ zephir_concat_svsvsvsvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, op9, sizeof(op9)-1, op10, op11, sizeof(op11)-1, 1 TSRMLS_CC);
+
#define ZEPHIR_CONCAT_SVSVV(result, op1, op2, op3, op4, op5) \
zephir_concat_svsvv(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, 0 TSRMLS_CC);
#define ZEPHIR_SCONCAT_SVSVV(result, op1, op2, op3, op4, op5) \
@@ -3718,8 +3728,10 @@ static void zephir_concat_svsvs(zval **result, const char *op1, zend_uint op1_le
static void zephir_concat_svsvssvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, const char *op6, zend_uint op6_len, zval *op7, const char *op8, zend_uint op8_len, zval *op9, const char *op10, zend_uint op10_len, int self_var TSRMLS_DC);
static void zephir_concat_svsvsv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, int self_var TSRMLS_DC);
static void zephir_concat_svsvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, int self_var TSRMLS_DC);
+static void zephir_concat_svsvsvssvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, const char *op8, zend_uint op8_len, zval *op9, const char *op10, zend_uint op10_len, zval *op11, const char *op12, zend_uint op12_len, int self_var TSRMLS_DC);
static void zephir_concat_svsvsvsv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, int self_var TSRMLS_DC);
static void zephir_concat_svsvsvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, const char *op9, zend_uint op9_len, int self_var TSRMLS_DC);
+static void zephir_concat_svsvsvsvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, const char *op9, zend_uint op9_len, zval *op10, const char *op11, zend_uint op11_len, int self_var TSRMLS_DC);
static void zephir_concat_svsvv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, zval *op5, int self_var TSRMLS_DC);
static void zephir_concat_svsvvsv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, zval *op5, const char *op6, zend_uint op6_len, zval *op7, int self_var TSRMLS_DC);
static void zephir_concat_svsvvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, zval *op5, const char *op6, zend_uint op6_len, zval *op7, const char *op8, zend_uint op8_len, int self_var TSRMLS_DC);
@@ -10022,7 +10034,7 @@ static void zephir_fast_join_str(zval *return_value, char *glue, unsigned int gl
static void zephir_camelize(zval *return_value, const zval *str) {
- int i, len;
+ int i, len, first = 0;
smart_str camelize_str = {0};
char *marker, ch;
@@ -10034,35 +10046,40 @@ static void zephir_camelize(zval *return_value, const zval *str) {
marker = Z_STRVAL_P(str);
len = Z_STRLEN_P(str);
- for (i = 0; i < len - 1; i++) {
- ch = *marker;
- if (i == 0 || ch == '-' || ch == '_') {
+ for (i = 0; i < len; i++) {
+
+ ch = marker[i];
+
+ if (first == 0) {
+
if (ch == '-' || ch == '_') {
- i++;
- marker++;
+ continue;
}
- smart_str_appendc(&camelize_str, toupper(*marker));
- }
- else {
- smart_str_appendc(&camelize_str, tolower(*marker));
+ first = 1;
+ smart_str_appendc(&camelize_str, toupper(ch));
+ continue;
}
- marker++;
- }
+ if (ch == '-' || ch == '_') {
+ if (i != (len - 1)) {
+ i++;
+ ch = marker[i];
+ smart_str_appendc(&camelize_str, toupper(ch));
+ }
+ continue;
+ }
- if (likely(i == len - 1)) {
- smart_str_appendc(&camelize_str, *marker);
+ smart_str_appendc(&camelize_str, tolower(ch));
}
smart_str_0(&camelize_str);
if (camelize_str.c) {
RETURN_STRINGL(camelize_str.c, camelize_str.len, 0);
- } else {
- RETURN_EMPTY_STRING();
}
+ RETURN_EMPTY_STRING();
}
static void zephir_uncamelize(zval *return_value, const zval *str) {
@@ -10078,10 +10095,13 @@ static void zephir_uncamelize(zval *return_value, const zval *str) {
marker = Z_STRVAL_P(str);
for (i = 0; i < Z_STRLEN_P(str); i++) {
+
ch = *marker;
+
if (ch == '\0') {
break;
}
+
if (ch >= 'A' && ch <= 'Z') {
if (i > 0) {
smart_str_appendc(&uncamelize_str, '_');
@@ -10090,6 +10110,7 @@ static void zephir_uncamelize(zval *return_value, const zval *str) {
} else {
smart_str_appendc(&uncamelize_str, (*marker));
}
+
marker++;
}
smart_str_0(&uncamelize_str);
@@ -10257,7 +10278,7 @@ static void zephir_fast_str_replace(zval **return_value_ptr, zval *search, zval
if (Z_TYPE_P(search) == IS_ARRAY) {
do {
- zval *params[] = { search, replace, subject };
+ zval *params[] = { search, replace, subject };
zval_ptr_dtor(return_value_ptr);
return_value_ptr = NULL;
zephir_call_func_aparams(return_value_ptr, "str_replace", sizeof("str_replace")-1, NULL, 0, 3, params TSRMLS_CC);
@@ -14452,6 +14473,107 @@ static void zephir_concat_svsvsvs(zval **result, const char *op1, zend_uint op1_
}
+static void zephir_concat_svsvsvssvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, const char *op8, zend_uint op8_len, zval *op9, const char *op10, zend_uint op10_len, zval *op11, const char *op12, zend_uint op12_len, int self_var TSRMLS_DC){
+
+ zval result_copy, op2_copy, op4_copy, op6_copy, op9_copy, op11_copy;
+ int use_copy = 0, use_copy2 = 0, use_copy4 = 0, use_copy6 = 0, use_copy9 = 0, use_copy11 = 0;
+ uint offset = 0, length;
+
+ if (Z_TYPE_P(op2) != IS_STRING) {
+ zend_make_printable_zval(op2, &op2_copy, &use_copy2);
+ if (use_copy2) {
+ op2 = &op2_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op4) != IS_STRING) {
+ zend_make_printable_zval(op4, &op4_copy, &use_copy4);
+ if (use_copy4) {
+ op4 = &op4_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op6) != IS_STRING) {
+ zend_make_printable_zval(op6, &op6_copy, &use_copy6);
+ if (use_copy6) {
+ op6 = &op6_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op9) != IS_STRING) {
+ zend_make_printable_zval(op9, &op9_copy, &use_copy9);
+ if (use_copy9) {
+ op9 = &op9_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op11) != IS_STRING) {
+ zend_make_printable_zval(op11, &op11_copy, &use_copy11);
+ if (use_copy11) {
+ op11 = &op11_copy;
+ }
+ }
+
+ length = op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len + Z_STRLEN_P(op9) + op10_len + Z_STRLEN_P(op11) + op12_len;
+ if (self_var) {
+
+ if (Z_TYPE_PP(result) != IS_STRING) {
+ zend_make_printable_zval(*result, &result_copy, &use_copy);
+ if (use_copy) {
+ ZEPHIR_CPY_WRT_CTOR(*result, (&result_copy));
+ }
+ }
+
+ offset = Z_STRLEN_PP(result);
+ length += offset;
+ Z_STRVAL_PP(result) = (char *) str_erealloc(Z_STRVAL_PP(result), length + 1);
+
+ } else {
+ Z_STRVAL_PP(result) = (char *) emalloc(length + 1);
+ }
+
+ memcpy(Z_STRVAL_PP(result) + offset, op1, op1_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len, Z_STRVAL_P(op2), Z_STRLEN_P(op2));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2), op3, op3_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len, Z_STRVAL_P(op4), Z_STRLEN_P(op4));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4), op5, op5_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len, Z_STRVAL_P(op6), Z_STRLEN_P(op6));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6), op7, op7_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len, op8, op8_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len, Z_STRVAL_P(op9), Z_STRLEN_P(op9));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len + Z_STRLEN_P(op9), op10, op10_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len + Z_STRLEN_P(op9) + op10_len, Z_STRVAL_P(op11), Z_STRLEN_P(op11));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len + Z_STRLEN_P(op9) + op10_len + Z_STRLEN_P(op11), op12, op12_len);
+ Z_STRVAL_PP(result)[length] = 0;
+ Z_TYPE_PP(result) = IS_STRING;
+ Z_STRLEN_PP(result) = length;
+
+ if (use_copy2) {
+ zval_dtor(op2);
+ }
+
+ if (use_copy4) {
+ zval_dtor(op4);
+ }
+
+ if (use_copy6) {
+ zval_dtor(op6);
+ }
+
+ if (use_copy9) {
+ zval_dtor(op9);
+ }
+
+ if (use_copy11) {
+ zval_dtor(op11);
+ }
+
+ if (use_copy) {
+ zval_dtor(&result_copy);
+ }
+
+}
+
static void zephir_concat_svsvsvsv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, int self_var TSRMLS_DC){
zval result_copy, op2_copy, op4_copy, op6_copy, op8_copy;
@@ -14625,6 +14747,106 @@ static void zephir_concat_svsvsvsvs(zval **result, const char *op1, zend_uint op
}
+static void zephir_concat_svsvsvsvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, const char *op9, zend_uint op9_len, zval *op10, const char *op11, zend_uint op11_len, int self_var TSRMLS_DC){
+
+ zval result_copy, op2_copy, op4_copy, op6_copy, op8_copy, op10_copy;
+ int use_copy = 0, use_copy2 = 0, use_copy4 = 0, use_copy6 = 0, use_copy8 = 0, use_copy10 = 0;
+ uint offset = 0, length;
+
+ if (Z_TYPE_P(op2) != IS_STRING) {
+ zend_make_printable_zval(op2, &op2_copy, &use_copy2);
+ if (use_copy2) {
+ op2 = &op2_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op4) != IS_STRING) {
+ zend_make_printable_zval(op4, &op4_copy, &use_copy4);
+ if (use_copy4) {
+ op4 = &op4_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op6) != IS_STRING) {
+ zend_make_printable_zval(op6, &op6_copy, &use_copy6);
+ if (use_copy6) {
+ op6 = &op6_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op8) != IS_STRING) {
+ zend_make_printable_zval(op8, &op8_copy, &use_copy8);
+ if (use_copy8) {
+ op8 = &op8_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op10) != IS_STRING) {
+ zend_make_printable_zval(op10, &op10_copy, &use_copy10);
+ if (use_copy10) {
+ op10 = &op10_copy;
+ }
+ }
+
+ length = op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + Z_STRLEN_P(op8) + op9_len + Z_STRLEN_P(op10) + op11_len;
+ if (self_var) {
+
+ if (Z_TYPE_PP(result) != IS_STRING) {
+ zend_make_printable_zval(*result, &result_copy, &use_copy);
+ if (use_copy) {
+ ZEPHIR_CPY_WRT_CTOR(*result, (&result_copy));
+ }
+ }
+
+ offset = Z_STRLEN_PP(result);
+ length += offset;
+ Z_STRVAL_PP(result) = (char *) str_erealloc(Z_STRVAL_PP(result), length + 1);
+
+ } else {
+ Z_STRVAL_PP(result) = (char *) emalloc(length + 1);
+ }
+
+ memcpy(Z_STRVAL_PP(result) + offset, op1, op1_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len, Z_STRVAL_P(op2), Z_STRLEN_P(op2));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2), op3, op3_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len, Z_STRVAL_P(op4), Z_STRLEN_P(op4));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4), op5, op5_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len, Z_STRVAL_P(op6), Z_STRLEN_P(op6));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6), op7, op7_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len, Z_STRVAL_P(op8), Z_STRLEN_P(op8));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + Z_STRLEN_P(op8), op9, op9_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + Z_STRLEN_P(op8) + op9_len, Z_STRVAL_P(op10), Z_STRLEN_P(op10));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + Z_STRLEN_P(op8) + op9_len + Z_STRLEN_P(op10), op11, op11_len);
+ Z_STRVAL_PP(result)[length] = 0;
+ Z_TYPE_PP(result) = IS_STRING;
+ Z_STRLEN_PP(result) = length;
+
+ if (use_copy2) {
+ zval_dtor(op2);
+ }
+
+ if (use_copy4) {
+ zval_dtor(op4);
+ }
+
+ if (use_copy6) {
+ zval_dtor(op6);
+ }
+
+ if (use_copy8) {
+ zval_dtor(op8);
+ }
+
+ if (use_copy10) {
+ zval_dtor(op10);
+ }
+
+ if (use_copy) {
+ zval_dtor(&result_copy);
+ }
+
+}
+
static void zephir_concat_svsvv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, zval *op5, int self_var TSRMLS_DC){
zval result_copy, op2_copy, op4_copy, op5_copy;
@@ -17401,12 +17623,12 @@ static PHP_METHOD(phalcon_0__closure, __invoke) {
- zephir_array_fetch_long(&_0, matches, 1, PH_NOISY | PH_READONLY, "phalcon/text.zep", 276 TSRMLS_CC);
+ zephir_array_fetch_long(&_0, matches, 1, PH_NOISY | PH_READONLY, "phalcon/text.zep", 272 TSRMLS_CC);
ZEPHIR_INIT_VAR(words);
zephir_fast_explode_str(words, SL("|"), _0, LONG_MAX TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_2, "array_rand", NULL, 438, words);
+ ZEPHIR_CALL_FUNCTION(&_2, "array_rand", NULL, 442, words);
zephir_check_call_status();
- zephir_array_fetch(&_1, words, _2, PH_NOISY | PH_READONLY, "phalcon/text.zep", 277 TSRMLS_CC);
+ zephir_array_fetch(&_1, words, _2, PH_NOISY | PH_READONLY, "phalcon/text.zep", 273 TSRMLS_CC);
RETURN_CTOR(_1);
}
@@ -17967,7 +18189,7 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) {
if (_0) {
paddingSize = (blockSize - (zephir_safe_mod_long_long(zephir_fast_strlen_ev(text), blockSize TSRMLS_CC)));
if (paddingSize >= 256) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Block size is bigger than 256", "phalcon/crypt.zep", 147);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Block size is bigger than 256", "phalcon/crypt.zep", 142);
return;
}
do {
@@ -18076,7 +18298,7 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) {
RETURN_CTOR(text);
}
if (paddingSize > blockSize) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Invalid padding size", "phalcon/crypt.zep", 191);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Invalid padding size", "phalcon/crypt.zep", 186);
return;
}
ZEPHIR_SINIT_NVAR(_1);
@@ -18352,7 +18574,7 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) {
if (!((zephir_function_exists_ex(SS("mcrypt_get_iv_size") TSRMLS_CC) == SUCCESS))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "mcrypt extension is required", "phalcon/crypt.zep", 307);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "mcrypt extension is required", "phalcon/crypt.zep", 302);
return;
}
if (ZEPHIR_IS_STRING_IDENTICAL(key, "")) {
@@ -18362,7 +18584,7 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) {
ZEPHIR_CPY_WRT(encryptKey, key);
}
if (ZEPHIR_IS_EMPTY(encryptKey)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Encryption key cannot be empty", "phalcon/crypt.zep", 317);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Encryption key cannot be empty", "phalcon/crypt.zep", 312);
return;
}
ZEPHIR_OBS_VAR(cipher);
@@ -18372,7 +18594,7 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) {
ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 131, cipher, mode);
zephir_check_call_status();
if (ZEPHIR_LT_LONG(ivSize, zephir_fast_strlen_ev(encryptKey))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 325);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 320);
return;
}
ZEPHIR_SINIT_VAR(_0);
@@ -18441,7 +18663,7 @@ static PHP_METHOD(Phalcon_Crypt, decrypt) {
if (!((zephir_function_exists_ex(SS("mcrypt_get_iv_size") TSRMLS_CC) == SUCCESS))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "mcrypt extension is required", "phalcon/crypt.zep", 361);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "mcrypt extension is required", "phalcon/crypt.zep", 356);
return;
}
if (Z_TYPE_P(key) == IS_NULL) {
@@ -18451,7 +18673,7 @@ static PHP_METHOD(Phalcon_Crypt, decrypt) {
ZEPHIR_CPY_WRT(decryptKey, key);
}
if (ZEPHIR_IS_EMPTY(decryptKey)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Decryption key cannot be empty", "phalcon/crypt.zep", 371);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Decryption key cannot be empty", "phalcon/crypt.zep", 366);
return;
}
ZEPHIR_OBS_VAR(cipher);
@@ -18463,13 +18685,13 @@ static PHP_METHOD(Phalcon_Crypt, decrypt) {
ZEPHIR_INIT_VAR(keySize);
ZVAL_LONG(keySize, zephir_fast_strlen_ev(decryptKey));
if (ZEPHIR_GT(keySize, ivSize)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 380);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 375);
return;
}
ZEPHIR_INIT_VAR(length);
ZVAL_LONG(length, zephir_fast_strlen_ev(text));
if (ZEPHIR_GT(keySize, length)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of IV is larger than text to decrypt", "phalcon/crypt.zep", 385);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of IV is larger than text to decrypt", "phalcon/crypt.zep", 380);
return;
}
ZEPHIR_INIT_VAR(_0);
@@ -18917,7 +19139,7 @@ static PHP_METHOD(Phalcon_Debug, listenExceptions) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "onUncaughtException", 1);
zephir_array_fast_append(_0, _1);
- ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 147, _0);
+ ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 148, _0);
zephir_check_call_status();
RETURN_THIS();
@@ -18937,7 +19159,7 @@ static PHP_METHOD(Phalcon_Debug, listenLowSeverity) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "onUncaughtLowSeverity", 1);
zephir_array_fast_append(_0, _1);
- ZEPHIR_CALL_FUNCTION(NULL, "set_error_handler", NULL, 148, _0);
+ ZEPHIR_CALL_FUNCTION(NULL, "set_error_handler", NULL, 149, _0);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_2);
zephir_create_array(_2, 2, 0 TSRMLS_CC);
@@ -18945,7 +19167,7 @@ static PHP_METHOD(Phalcon_Debug, listenLowSeverity) {
ZEPHIR_INIT_NVAR(_1);
ZVAL_STRING(_1, "onUncaughtException", 1);
zephir_array_fast_append(_2, _1);
- ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 147, _2);
+ ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 148, _2);
zephir_check_call_status();
RETURN_THIS();
@@ -18980,7 +19202,7 @@ static PHP_METHOD(Phalcon_Debug, debugVar) {
ZEPHIR_INIT_VAR(_0);
zephir_create_array(_0, 3, 0 TSRMLS_CC);
zephir_array_fast_append(_0, varz);
- ZEPHIR_CALL_FUNCTION(&_1, "debug_backtrace", NULL, 149);
+ ZEPHIR_CALL_FUNCTION(&_1, "debug_backtrace", NULL, 150);
zephir_check_call_status();
zephir_array_fast_append(_0, _1);
ZEPHIR_INIT_VAR(_2);
@@ -19020,7 +19242,7 @@ static PHP_METHOD(Phalcon_Debug, _escapeString) {
ZVAL_LONG(&_3, 2);
ZEPHIR_SINIT_VAR(_4);
ZVAL_STRING(&_4, "utf-8", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("htmlentities", NULL, 150, _0, &_3, &_4);
+ ZEPHIR_RETURN_CALL_FUNCTION("htmlentities", NULL, 151, _0, &_3, &_4);
zephir_check_call_status();
RETURN_MM();
}
@@ -19071,7 +19293,7 @@ static PHP_METHOD(Phalcon_Debug, _getArrayDump) {
) {
ZEPHIR_GET_HMKEY(k, _2, _1);
ZEPHIR_GET_HVALUE(v, _3);
- ZEPHIR_CALL_FUNCTION(&_4, "is_scalar", &_5, 151, v);
+ ZEPHIR_CALL_FUNCTION(&_4, "is_scalar", &_5, 152, v);
zephir_check_call_status();
if (zephir_is_true(_4)) {
ZEPHIR_INIT_NVAR(varDump);
@@ -19088,7 +19310,7 @@ static PHP_METHOD(Phalcon_Debug, _getArrayDump) {
if (Z_TYPE_P(v) == IS_ARRAY) {
ZEPHIR_INIT_NVAR(_8);
ZVAL_LONG(_8, (zephir_get_numberval(n) + 1));
- ZEPHIR_CALL_METHOD(&_6, this_ptr, "_getarraydump", &_9, 152, v, _8);
+ ZEPHIR_CALL_METHOD(&_6, this_ptr, "_getarraydump", &_9, 153, v, _8);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_10);
ZEPHIR_CONCAT_SVSVS(_10, "[", k, "] => Array(", _6, ")");
@@ -19122,14 +19344,14 @@ static PHP_METHOD(Phalcon_Debug, _getVarDump) {
zephir_fcall_cache_entry *_2 = NULL;
int ZEPHIR_LAST_CALL_STATUS;
- zval *variable, *className, *dumpedObject = NULL, *dump, *_0 = NULL, *_1 = NULL;
+ zval *variable, *className, *dumpedObject = NULL, *_0 = NULL, *_1 = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 0, &variable);
- ZEPHIR_CALL_FUNCTION(&_0, "is_scalar", NULL, 151, variable);
+ ZEPHIR_CALL_FUNCTION(&_0, "is_scalar", NULL, 152, variable);
zephir_check_call_status();
if (zephir_is_true(_0)) {
if (Z_TYPE_P(variable) == IS_BOOL) {
@@ -19150,20 +19372,20 @@ static PHP_METHOD(Phalcon_Debug, _getVarDump) {
if (Z_TYPE_P(variable) == IS_OBJECT) {
ZEPHIR_INIT_VAR(className);
zephir_get_class(className, variable, 0 TSRMLS_CC);
- ZEPHIR_INIT_VAR(dump);
if ((zephir_method_exists_ex(variable, SS("dump") TSRMLS_CC) == SUCCESS)) {
ZEPHIR_CALL_METHOD(&dumpedObject, variable, "dump", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 0, dumpedObject);
zephir_check_call_status();
- ZEPHIR_CONCAT_SVSVS(dump, "Object(", className, ": ", _1, ")");
+ ZEPHIR_CONCAT_SVSVS(return_value, "Object(", className, ": ", _1, ")");
+ RETURN_MM();
} else {
- ZEPHIR_CONCAT_SVS(dump, "Object(", className, ")");
+ ZEPHIR_CONCAT_SVS(return_value, "Object(", className, ")");
+ RETURN_MM();
}
- RETURN_CCTOR(dump);
}
if (Z_TYPE_P(variable) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 152, variable);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 153, variable);
zephir_check_call_status();
ZEPHIR_CONCAT_SVS(return_value, "Array(", _1, ")");
RETURN_MM();
@@ -19184,11 +19406,11 @@ static PHP_METHOD(Phalcon_Debug, getMajorVersion) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_version_ce, "get", &_1, 153);
+ ZEPHIR_CALL_CE_STATIC(&_0, phalcon_version_ce, "get", &_1, 154);
zephir_check_call_status();
ZEPHIR_INIT_VAR(parts);
zephir_fast_explode_str(parts, SL(" "), _0, LONG_MAX TSRMLS_CC);
- zephir_array_fetch_long(&_2, parts, 0, PH_NOISY | PH_READONLY, "phalcon/debug.zep", 290 TSRMLS_CC);
+ zephir_array_fetch_long(&_2, parts, 0, PH_NOISY | PH_READONLY, "phalcon/debug.zep", 289 TSRMLS_CC);
RETURN_CTOR(_2);
}
@@ -19203,7 +19425,7 @@ static PHP_METHOD(Phalcon_Debug, getVersion) {
ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmajorversion", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_CE_STATIC(&_1, phalcon_version_ce, "get", &_2, 153);
+ ZEPHIR_CALL_CE_STATIC(&_1, phalcon_version_ce, "get", &_2, 154);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "");
RETURN_MM();
@@ -19253,12 +19475,13 @@ static PHP_METHOD(Phalcon_Debug, getJsSources) {
static PHP_METHOD(Phalcon_Debug, showTraceItem) {
- zephir_fcall_cache_entry *_15 = NULL, *_21 = NULL;
+ zend_bool _24;
+ zephir_fcall_cache_entry *_15 = NULL, *_26 = NULL;
HashTable *_13;
HashPosition _12;
zval *_1, *_17 = NULL;
zval *trace = NULL;
- zval *n_param = NULL, *trace_param = NULL, *space, *twoSpaces, *underscore, *minus, *className, *prepareInternalClass, *preparedFunctionName, *html = NULL, *classReflection, *prepareUriClass, *functionName, *functionReflection, *traceArgs, *arguments, *argument = NULL, *filez, *line = NULL, *showFiles, *lines = NULL, *numberLines, *showFileFragment, *beforeLine, *afterLine, *lastLine = NULL, *commentPattern, *utf8, *entCompat, *tab, *comment, linePosition = zval_used_for_init, *currentLine = NULL, _0, *_2, *_3 = NULL, _4 = zval_used_for_init, _5 = zval_used_for_init, _6 = zval_used_for_init, *_7 = NULL, *_8 = NULL, *_9 = NULL, *_10 = NULL, *_11, **_14, *_16, *_18, *_19 = NULL, *_20 = NULL;
+ zval *n_param = NULL, *trace_param = NULL, *className, *prepareInternalClass, *preparedFunctionName, *html = NULL, *classReflection, *prepareUriClass, *functionName, *functionReflection, *traceArgs, *arguments, *argument = NULL, *filez, *line = NULL, *showFiles, *lines = NULL, *numberLines, *showFileFragment, *beforeLine, *afterLine, *lastLine = NULL, linePosition = zval_used_for_init, *currentLine = NULL, _0, *_2, *_3 = NULL, _4 = zval_used_for_init, _5 = zval_used_for_init, _6 = zval_used_for_init, *_7 = NULL, *_8 = NULL, *_9 = NULL, *_10 = NULL, *_11, **_14, *_16, *_18, *_19 = NULL, _20 = zval_used_for_init, *_21 = NULL, _22 = zval_used_for_init, _23 = zval_used_for_init, _25 = zval_used_for_init;
int n, firstLine, i, ZEPHIR_LAST_CALL_STATUS;
ZEPHIR_MM_GROW();
@@ -19269,22 +19492,13 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
- ZEPHIR_INIT_VAR(space);
- ZVAL_STRING(space, " ", 1);
- ZEPHIR_INIT_VAR(twoSpaces);
- ZVAL_STRING(twoSpaces, " ", 1);
- ZEPHIR_INIT_VAR(underscore);
- ZVAL_STRING(underscore, "_", 1);
- ZEPHIR_INIT_VAR(minus);
- ZVAL_STRING(minus, "-", 1);
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, n);
ZEPHIR_INIT_VAR(_1);
ZEPHIR_CONCAT_SVS(_1, "#", &_0, " | ");
ZEPHIR_CPY_WRT(html, _1);
- if (zephir_array_isset_string(trace, SS("class"))) {
- ZEPHIR_OBS_VAR(className);
- zephir_array_fetch_string(&className, trace, SL("class"), PH_NOISY, "phalcon/debug.zep", 356 TSRMLS_CC);
+ ZEPHIR_OBS_VAR(className);
+ if (zephir_array_isset_string_fetch(&className, trace, SS("class"), 0 TSRMLS_CC)) {
ZEPHIR_INIT_VAR(_2);
ZEPHIR_INIT_VAR(_3);
ZEPHIR_SINIT_VAR(_4);
@@ -19305,13 +19519,17 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
object_init_ex(classReflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC));
ZEPHIR_CALL_METHOD(NULL, classReflection, "__construct", NULL, 62, className);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, classReflection, "isinternal", NULL, 154);
+ ZEPHIR_CALL_METHOD(&_8, classReflection, "isinternal", NULL, 155);
zephir_check_call_status();
if (zephir_is_true(_8)) {
ZEPHIR_INIT_VAR(_9);
zephir_fast_strtolower(_9, className);
+ ZEPHIR_SINIT_NVAR(_5);
+ ZVAL_STRING(&_5, "_", 0);
+ ZEPHIR_SINIT_NVAR(_6);
+ ZVAL_STRING(&_6, "-", 0);
ZEPHIR_INIT_VAR(prepareInternalClass);
- zephir_fast_str_replace(&prepareInternalClass, underscore, minus, _9 TSRMLS_CC);
+ zephir_fast_str_replace(&prepareInternalClass, &_5, &_6, _9 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVSVS(_7, "", className, "");
zephir_concat_self(&html, _7 TSRMLS_CC);
@@ -19321,11 +19539,11 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
zephir_concat_self(&html, _10 TSRMLS_CC);
}
}
- zephir_array_fetch_string(&_11, trace, SL("type"), PH_NOISY | PH_READONLY, "phalcon/debug.zep", 395 TSRMLS_CC);
+ zephir_array_fetch_string(&_11, trace, SL("type"), PH_NOISY | PH_READONLY, "phalcon/debug.zep", 385 TSRMLS_CC);
zephir_concat_self(&html, _11 TSRMLS_CC);
}
ZEPHIR_OBS_VAR(functionName);
- zephir_array_fetch_string(&functionName, trace, SL("function"), PH_NOISY, "phalcon/debug.zep", 401 TSRMLS_CC);
+ zephir_array_fetch_string(&functionName, trace, SL("function"), PH_NOISY, "phalcon/debug.zep", 391 TSRMLS_CC);
if (zephir_array_isset_string(trace, SS("class"))) {
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVS(_7, "", functionName, "");
@@ -19334,13 +19552,17 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
if ((zephir_function_exists(functionName TSRMLS_CC) == SUCCESS)) {
ZEPHIR_INIT_VAR(functionReflection);
object_init_ex(functionReflection, zephir_get_internal_ce(SS("reflectionfunction") TSRMLS_CC));
- ZEPHIR_CALL_METHOD(NULL, functionReflection, "__construct", NULL, 155, functionName);
+ ZEPHIR_CALL_METHOD(NULL, functionReflection, "__construct", NULL, 156, functionName);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, functionReflection, "isinternal", NULL, 156);
+ ZEPHIR_CALL_METHOD(&_8, functionReflection, "isinternal", NULL, 157);
zephir_check_call_status();
if (zephir_is_true(_8)) {
+ ZEPHIR_SINIT_NVAR(_4);
+ ZVAL_STRING(&_4, "_", 0);
+ ZEPHIR_SINIT_NVAR(_5);
+ ZVAL_STRING(&_5, "-", 0);
ZEPHIR_INIT_VAR(preparedFunctionName);
- zephir_fast_str_replace(&preparedFunctionName, underscore, minus, functionName TSRMLS_CC);
+ zephir_fast_str_replace(&preparedFunctionName, &_4, &_5, functionName TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_10);
ZEPHIR_CONCAT_SVSVS(_10, "", functionName, "");
zephir_concat_self(&html, _10 TSRMLS_CC);
@@ -19355,13 +19577,12 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
zephir_concat_self(&html, _7 TSRMLS_CC);
}
}
- if (zephir_array_isset_string(trace, SS("args"))) {
- ZEPHIR_OBS_VAR(traceArgs);
- zephir_array_fetch_string(&traceArgs, trace, SL("args"), PH_NOISY, "phalcon/debug.zep", 435 TSRMLS_CC);
+ ZEPHIR_OBS_VAR(traceArgs);
+ if (zephir_array_isset_string_fetch(&traceArgs, trace, SS("args"), 0 TSRMLS_CC)) {
if (zephir_fast_count_int(traceArgs TSRMLS_CC)) {
ZEPHIR_INIT_VAR(arguments);
array_init(arguments);
- zephir_is_iterable(traceArgs, &_13, &_12, 0, 0, "phalcon/debug.zep", 450);
+ zephir_is_iterable(traceArgs, &_13, &_12, 0, 0, "phalcon/debug.zep", 439);
for (
; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS
; zephir_hash_move_forward_ex(_13, &_12)
@@ -19371,7 +19592,7 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVS(_7, "", _8, "");
- zephir_array_append(&arguments, _7, PH_SEPARATE, "phalcon/debug.zep", 444);
+ zephir_array_append(&arguments, _7, PH_SEPARATE, "phalcon/debug.zep", 433);
}
ZEPHIR_INIT_NVAR(_3);
zephir_fast_join_str(_3, SL(", "), arguments TSRMLS_CC);
@@ -19385,7 +19606,7 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
ZEPHIR_OBS_VAR(filez);
if (zephir_array_isset_string_fetch(&filez, trace, SS("file"), 0 TSRMLS_CC)) {
ZEPHIR_OBS_VAR(_16);
- zephir_array_fetch_string(&_16, trace, SL("line"), PH_NOISY, "phalcon/debug.zep", 461 TSRMLS_CC);
+ zephir_array_fetch_string(&_16, trace, SL("line"), PH_NOISY, "phalcon/debug.zep", 450 TSRMLS_CC);
zephir_get_strval(_17, _16);
ZEPHIR_CPY_WRT(line, _17);
ZEPHIR_INIT_LNVAR(_7);
@@ -19394,7 +19615,7 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
ZEPHIR_OBS_VAR(showFiles);
zephir_read_property_this(&showFiles, this_ptr, SL("_showFiles"), PH_NOISY_CC);
if (zephir_is_true(showFiles)) {
- ZEPHIR_CALL_FUNCTION(&lines, "file", NULL, 157, filez);
+ ZEPHIR_CALL_FUNCTION(&lines, "file", NULL, 158, filez);
zephir_check_call_status();
ZEPHIR_INIT_VAR(numberLines);
ZVAL_LONG(numberLines, zephir_fast_count_int(lines TSRMLS_CC));
@@ -19431,16 +19652,6 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
ZEPHIR_CONCAT_SVSVS(_10, "");
zephir_concat_self(&html, _10 TSRMLS_CC);
}
- ZEPHIR_INIT_VAR(commentPattern);
- ZVAL_STRING(commentPattern, "#\\*\\/#", 1);
- ZEPHIR_INIT_VAR(utf8);
- ZVAL_STRING(utf8, "UTF-8", 1);
- ZEPHIR_INIT_VAR(entCompat);
- ZVAL_LONG(entCompat, 2);
- ZEPHIR_INIT_VAR(tab);
- ZVAL_STRING(tab, "\t", 1);
- ZEPHIR_INIT_VAR(comment);
- ZVAL_STRING(comment, "* /", 1);
i = firstLine;
while (1) {
if (!(ZEPHIR_GE_LONG(lastLine, i))) {
@@ -19449,33 +19660,47 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
ZEPHIR_SINIT_NVAR(linePosition);
ZVAL_LONG(&linePosition, (i - 1));
ZEPHIR_OBS_NVAR(currentLine);
- zephir_array_fetch(¤tLine, lines, &linePosition, PH_NOISY, "phalcon/debug.zep", 549 TSRMLS_CC);
+ zephir_array_fetch(¤tLine, lines, &linePosition, PH_NOISY, "phalcon/debug.zep", 523 TSRMLS_CC);
if (zephir_is_true(showFileFragment)) {
if (i == firstLine) {
ZEPHIR_INIT_NVAR(_19);
ZEPHIR_INIT_NVAR(_3);
ZEPHIR_INIT_NVAR(_9);
zephir_fast_trim(_9, currentLine, NULL , ZEPHIR_TRIM_RIGHT TSRMLS_CC);
- zephir_preg_match(_3, commentPattern, _9, _19, 0, 0 , 0 TSRMLS_CC);
+ ZEPHIR_SINIT_NVAR(_20);
+ ZVAL_STRING(&_20, "#\\*\\/#", 0);
+ zephir_preg_match(_3, &_20, _9, _19, 0, 0 , 0 TSRMLS_CC);
if (zephir_is_true(_3)) {
- ZEPHIR_INIT_NVAR(_20);
- zephir_fast_str_replace(&_20, comment, space, currentLine TSRMLS_CC);
- ZEPHIR_CPY_WRT(currentLine, _20);
+ ZEPHIR_INIT_NVAR(_21);
+ ZEPHIR_SINIT_NVAR(_22);
+ ZVAL_STRING(&_22, "* /", 0);
+ ZEPHIR_SINIT_NVAR(_23);
+ ZVAL_STRING(&_23, " ", 0);
+ zephir_fast_str_replace(&_21, &_22, &_23, currentLine TSRMLS_CC);
+ ZEPHIR_CPY_WRT(currentLine, _21);
}
}
}
- if (ZEPHIR_IS_STRING(currentLine, "\n")) {
+ _24 = ZEPHIR_IS_STRING(currentLine, "\n");
+ if (!(_24)) {
+ _24 = ZEPHIR_IS_STRING(currentLine, "\r\n");
+ }
+ if (_24) {
zephir_concat_self_str(&html, SL(" \n") TSRMLS_CC);
} else {
- if (ZEPHIR_IS_STRING(currentLine, "\r\n")) {
- zephir_concat_self_str(&html, SL(" \n") TSRMLS_CC);
- } else {
- ZEPHIR_INIT_NVAR(_20);
- zephir_fast_str_replace(&_20, tab, twoSpaces, currentLine TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_8, "htmlentities", &_21, 150, _20, entCompat, utf8);
- zephir_check_call_status();
- zephir_concat_self(&html, _8 TSRMLS_CC);
- }
+ ZEPHIR_INIT_NVAR(_21);
+ ZEPHIR_SINIT_NVAR(_20);
+ ZVAL_STRING(&_20, "\t", 0);
+ ZEPHIR_SINIT_NVAR(_22);
+ ZVAL_STRING(&_22, " ", 0);
+ zephir_fast_str_replace(&_21, &_20, &_22, currentLine TSRMLS_CC);
+ ZEPHIR_SINIT_NVAR(_23);
+ ZVAL_LONG(&_23, 2);
+ ZEPHIR_SINIT_NVAR(_25);
+ ZVAL_STRING(&_25, "UTF-8", 0);
+ ZEPHIR_CALL_FUNCTION(&_8, "htmlentities", &_26, 151, _21, &_23, &_25);
+ zephir_check_call_status();
+ zephir_concat_self(&html, _8 TSRMLS_CC);
}
i++;
}
@@ -19497,7 +19722,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtLowSeverity) {
- ZEPHIR_CALL_FUNCTION(&_0, "error_reporting", NULL, 158);
+ ZEPHIR_CALL_FUNCTION(&_0, "error_reporting", NULL, 159);
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_1);
zephir_bitwise_and_function(&_1, _0, severity TSRMLS_CC);
@@ -19506,9 +19731,9 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtLowSeverity) {
object_init_ex(_2, zephir_get_internal_ce(SS("errorexception") TSRMLS_CC));
ZEPHIR_INIT_VAR(_3);
ZVAL_LONG(_3, 0);
- ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 159, message, _3, severity, file, line);
+ ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 160, message, _3, severity, file, line);
zephir_check_call_status();
- zephir_throw_exception_debug(_2, "phalcon/debug.zep", 592 TSRMLS_CC);
+ zephir_throw_exception_debug(_2, "phalcon/debug.zep", 566 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -19531,7 +19756,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
- ZEPHIR_CALL_FUNCTION(&obLevel, "ob_get_level", NULL, 160);
+ ZEPHIR_CALL_FUNCTION(&obLevel, "ob_get_level", NULL, 161);
zephir_check_call_status();
if (ZEPHIR_GT_LONG(obLevel, 0)) {
ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118);
@@ -19591,21 +19816,21 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
ZEPHIR_CALL_METHOD(&_9, exception, "gettrace", NULL, 0);
zephir_check_call_status();
- zephir_is_iterable(_9, &_11, &_10, 0, 0, "phalcon/debug.zep", 686);
+ zephir_is_iterable(_9, &_11, &_10, 0, 0, "phalcon/debug.zep", 660);
for (
; zephir_hash_get_current_data_ex(_11, (void**) &_12, &_10) == SUCCESS
; zephir_hash_move_forward_ex(_11, &_10)
) {
ZEPHIR_GET_HMKEY(n, _11, _10);
ZEPHIR_GET_HVALUE(traceItem, _12);
- ZEPHIR_CALL_METHOD(&_13, this_ptr, "showtraceitem", &_14, 161, n, traceItem);
+ ZEPHIR_CALL_METHOD(&_13, this_ptr, "showtraceitem", &_14, 162, n, traceItem);
zephir_check_call_status();
zephir_concat_self(&html, _13 TSRMLS_CC);
}
zephir_concat_self_str(&html, SL(" ") TSRMLS_CC);
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
zephir_concat_self_str(&html, SL("Key | Value | ") TSRMLS_CC);
- zephir_is_iterable(_REQUEST, &_16, &_15, 0, 0, "phalcon/debug.zep", 700);
+ zephir_is_iterable(_REQUEST, &_16, &_15, 0, 0, "phalcon/debug.zep", 674);
for (
; zephir_hash_get_current_data_ex(_16, (void**) &_17, &_15) == SUCCESS
; zephir_hash_move_forward_ex(_16, &_15)
@@ -19617,7 +19842,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
ZEPHIR_CONCAT_SVSVS(_18, "", keyRequest, " | ", value, " | ");
zephir_concat_self(&html, _18 TSRMLS_CC);
} else {
- ZEPHIR_CALL_FUNCTION(&_13, "print_r", &_19, 162, value, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(&_13, "print_r", &_19, 163, value, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_18);
ZEPHIR_CONCAT_SVSVS(_18, "", keyRequest, " | ", _13, " | ");
@@ -19627,7 +19852,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
zephir_concat_self_str(&html, SL(" ") TSRMLS_CC);
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
zephir_concat_self_str(&html, SL("Key | Value | ") TSRMLS_CC);
- zephir_is_iterable(_SERVER, &_21, &_20, 0, 0, "phalcon/debug.zep", 710);
+ zephir_is_iterable(_SERVER, &_21, &_20, 0, 0, "phalcon/debug.zep", 684);
for (
; zephir_hash_get_current_data_ex(_21, (void**) &_22, &_20) == SUCCESS
; zephir_hash_move_forward_ex(_21, &_20)
@@ -19643,9 +19868,9 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
zephir_concat_self_str(&html, SL(" ") TSRMLS_CC);
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
zephir_concat_self_str(&html, SL("# | Path | ") TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_13, "get_included_files", NULL, 163);
+ ZEPHIR_CALL_FUNCTION(&_13, "get_included_files", NULL, 164);
zephir_check_call_status();
- zephir_is_iterable(_13, &_25, &_24, 0, 0, "phalcon/debug.zep", 720);
+ zephir_is_iterable(_13, &_25, &_24, 0, 0, "phalcon/debug.zep", 694);
for (
; zephir_hash_get_current_data_ex(_25, (void**) &_26, &_24) == SUCCESS
; zephir_hash_move_forward_ex(_25, &_24)
@@ -19658,7 +19883,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
}
zephir_concat_self_str(&html, SL(" ") TSRMLS_CC);
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_13, "memory_get_usage", NULL, 164, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(&_13, "memory_get_usage", NULL, 165, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_27);
ZEPHIR_CONCAT_SVS(_27, "Memory |
---|
Usage | ", _13, " | ");
@@ -19667,14 +19892,14 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
if (Z_TYPE_P(dataVars) == IS_ARRAY) {
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
zephir_concat_self_str(&html, SL("Key | Value | ") TSRMLS_CC);
- zephir_is_iterable(dataVars, &_29, &_28, 0, 0, "phalcon/debug.zep", 738);
+ zephir_is_iterable(dataVars, &_29, &_28, 0, 0, "phalcon/debug.zep", 712);
for (
; zephir_hash_get_current_data_ex(_29, (void**) &_30, &_28) == SUCCESS
; zephir_hash_move_forward_ex(_29, &_28)
) {
ZEPHIR_GET_HMKEY(keyVar, _29, _28);
ZEPHIR_GET_HVALUE(dataVar, _30);
- zephir_array_fetch_long(&_32, dataVar, 0, PH_NOISY | PH_READONLY, "phalcon/debug.zep", 736 TSRMLS_CC);
+ zephir_array_fetch_long(&_32, dataVar, 0, PH_NOISY | PH_READONLY, "phalcon/debug.zep", 710 TSRMLS_CC);
ZEPHIR_CALL_METHOD(&_31, this_ptr, "_getvardump", &_23, 0, _32);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_33);
@@ -19835,7 +20060,7 @@ static PHP_METHOD(Phalcon_Di, setShared) {
static PHP_METHOD(Phalcon_Di, remove) {
- zval *name_param = NULL, *_0;
+ zval *name_param = NULL, *_0, *_1;
zval *name = NULL;
ZEPHIR_MM_GROW();
@@ -19856,6 +20081,8 @@ static PHP_METHOD(Phalcon_Di, remove) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_services"), PH_NOISY_CC);
zephir_array_unset(&_0, name, PH_SEPARATE);
+ _1 = zephir_fetch_nproperty_this(this_ptr, SL("_sharedInstances"), PH_NOISY_CC);
+ zephir_array_unset(&_1, name, PH_SEPARATE);
ZEPHIR_MM_RESTORE();
}
@@ -19963,7 +20190,7 @@ static PHP_METHOD(Phalcon_Di, getRaw) {
ZEPHIR_CONCAT_SVS(_2, "Service '", name, "' wasn't found in the dependency injection container");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/di.zep", 187 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/di.zep", 189 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -20002,7 +20229,7 @@ static PHP_METHOD(Phalcon_Di, getService) {
ZEPHIR_CONCAT_SVS(_2, "Service '", name, "' wasn't found in the dependency injection container");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/di.zep", 201 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/di.zep", 203 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -20060,7 +20287,7 @@ static PHP_METHOD(Phalcon_Di, get) {
ZEPHIR_CONCAT_SVS(_3, "Service '", name, "' wasn't found in the dependency injection container");
ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_2, "phalcon/di.zep", 227 TSRMLS_CC);
+ zephir_throw_exception_debug(_2, "phalcon/di.zep", 229 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -20383,7 +20610,7 @@ static PHP_METHOD(Phalcon_Di, __call) {
ZEPHIR_CONCAT_SVS(_5, "Call to undefined method or service '", method, "'");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _5);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/di.zep", 425 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/di.zep", 427 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -21419,13 +21646,13 @@ static PHP_METHOD(Phalcon_Escaper, detectEncoding) {
; zephir_hash_move_forward_ex(_3, &_2)
) {
ZEPHIR_GET_HVALUE(charset, _4);
- ZEPHIR_CALL_FUNCTION(&_5, "mb_detect_encoding", &_6, 177, str, charset, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(&_5, "mb_detect_encoding", &_6, 178, str, charset, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
if (zephir_is_true(_5)) {
RETURN_CCTOR(charset);
}
}
- ZEPHIR_RETURN_CALL_FUNCTION("mb_detect_encoding", &_6, 177, str);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_detect_encoding", &_6, 178, str);
zephir_check_call_status();
RETURN_MM();
@@ -21447,11 +21674,11 @@ static PHP_METHOD(Phalcon_Escaper, normalizeEncoding) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_escaper_exception_ce, "Extension 'mbstring' is required", "phalcon/escaper.zep", 128);
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "detectencoding", NULL, 178, str);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "detectencoding", NULL, 179, str);
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "UTF-32", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 179, str, &_1, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 180, str, &_1, _0);
zephir_check_call_status();
RETURN_MM();
@@ -21471,7 +21698,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeHtml) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_htmlQuoteType"), PH_NOISY_CC);
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_encoding"), PH_NOISY_CC);
- ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 180, text, _0, _1);
+ ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 181, text, _0, _1);
zephir_check_call_status();
RETURN_MM();
@@ -21492,7 +21719,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeHtmlAttr) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_encoding"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, 3);
- ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 180, attribute, &_1, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 181, attribute, &_1, _0);
zephir_check_call_status();
RETURN_MM();
@@ -21510,7 +21737,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeCss) {
zephir_get_strval(css, css_param);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 181, css);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 182, css);
zephir_check_call_status();
zephir_escape_css(return_value, _0);
RETURN_MM();
@@ -21529,7 +21756,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeJs) {
zephir_get_strval(js, js_param);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 181, js);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 182, js);
zephir_check_call_status();
zephir_escape_js(return_value, _0);
RETURN_MM();
@@ -21548,7 +21775,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeUrl) {
zephir_get_strval(url, url_param);
- ZEPHIR_RETURN_CALL_FUNCTION("rawurlencode", NULL, 182, url);
+ ZEPHIR_RETURN_CALL_FUNCTION("rawurlencode", NULL, 183, url);
zephir_check_call_status();
RETURN_MM();
@@ -21827,16 +22054,16 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) {
if (ZEPHIR_IS_STRING(filter, "email")) {
ZEPHIR_SINIT_VAR(_3);
ZVAL_STRING(&_3, "FILTER_SANITIZE_EMAIL", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 189, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 190, &_3);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 190, value, _4);
+ ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, _4);
zephir_check_call_status();
RETURN_MM();
}
if (ZEPHIR_IS_STRING(filter, "int")) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 519);
- ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 190, value, &_3);
+ ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3);
zephir_check_call_status();
RETURN_MM();
}
@@ -21846,14 +22073,14 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) {
if (ZEPHIR_IS_STRING(filter, "absint")) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, zephir_get_intval(value));
- ZEPHIR_RETURN_CALL_FUNCTION("abs", NULL, 191, &_3);
+ ZEPHIR_RETURN_CALL_FUNCTION("abs", NULL, 192, &_3);
zephir_check_call_status();
RETURN_MM();
}
if (ZEPHIR_IS_STRING(filter, "string")) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 513);
- ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 190, value, &_3);
+ ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3);
zephir_check_call_status();
RETURN_MM();
}
@@ -21863,7 +22090,7 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) {
add_assoc_long_ex(_2, SS("flags"), 4096);
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 520);
- ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 190, value, &_3, _2);
+ ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3, _2);
zephir_check_call_status();
RETURN_MM();
}
@@ -21886,13 +22113,13 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) {
RETURN_MM();
}
if (ZEPHIR_IS_STRING(filter, "striptags")) {
- ZEPHIR_RETURN_CALL_FUNCTION("strip_tags", NULL, 192, value);
+ ZEPHIR_RETURN_CALL_FUNCTION("strip_tags", NULL, 193, value);
zephir_check_call_status();
RETURN_MM();
}
if (ZEPHIR_IS_STRING(filter, "lower")) {
if ((zephir_function_exists_ex(SS("mb_strtolower") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 193, value);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 194, value);
zephir_check_call_status();
RETURN_MM();
}
@@ -21901,7 +22128,7 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) {
}
if (ZEPHIR_IS_STRING(filter, "upper")) {
if ((zephir_function_exists_ex(SS("mb_strtoupper") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 194, value);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 195, value);
zephir_check_call_status();
RETURN_MM();
}
@@ -22682,7 +22909,7 @@ static PHP_METHOD(Phalcon_Loader, register) {
ZEPHIR_INIT_VAR(_2);
ZVAL_STRING(_2, "autoLoad", 1);
zephir_array_fast_append(_1, _2);
- ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_register", NULL, 292, _1);
+ ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_register", NULL, 293, _1);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_registered"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
}
@@ -22706,7 +22933,7 @@ static PHP_METHOD(Phalcon_Loader, unregister) {
ZEPHIR_INIT_VAR(_2);
ZVAL_STRING(_2, "autoLoad", 1);
zephir_array_fast_append(_1, _2);
- ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_unregister", NULL, 293, _1);
+ ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_unregister", NULL, 294, _1);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_registered"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
}
@@ -22814,7 +23041,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) {
zephir_check_temp_parameter(_9);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 294, filePath);
+ ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath);
zephir_check_call_status();
if (zephir_is_true(_11)) {
if (Z_TYPE_P(eventsManager) == IS_OBJECT) {
@@ -22885,7 +23112,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) {
zephir_check_temp_parameter(_9);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 294, filePath);
+ ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath);
zephir_check_call_status();
if (zephir_is_true(_11)) {
if (Z_TYPE_P(eventsManager) == IS_OBJECT) {
@@ -22943,7 +23170,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) {
zephir_check_temp_parameter(_9);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 294, filePath);
+ ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath);
zephir_check_call_status();
if (zephir_is_true(_11)) {
if (Z_TYPE_P(eventsManager) == IS_OBJECT) {
@@ -23196,7 +23423,7 @@ static PHP_METHOD(Phalcon_Registry, next) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_CALL_FUNCTION(NULL, "next", NULL, 397, _0);
+ ZEPHIR_CALL_FUNCTION(NULL, "next", NULL, 399, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -23212,7 +23439,7 @@ static PHP_METHOD(Phalcon_Registry, key) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_RETURN_CALL_FUNCTION("key", NULL, 398, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("key", NULL, 400, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
RETURN_MM();
@@ -23228,7 +23455,7 @@ static PHP_METHOD(Phalcon_Registry, rewind) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_CALL_FUNCTION(NULL, "reset", NULL, 399, _0);
+ ZEPHIR_CALL_FUNCTION(NULL, "reset", NULL, 401, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -23244,7 +23471,7 @@ static PHP_METHOD(Phalcon_Registry, valid) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_CALL_FUNCTION(&_1, "key", NULL, 398, _0);
+ ZEPHIR_CALL_FUNCTION(&_1, "key", NULL, 400, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
RETURN_MM_BOOL(Z_TYPE_P(_1) != IS_NULL);
@@ -23260,7 +23487,7 @@ static PHP_METHOD(Phalcon_Registry, current) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_RETURN_CALL_FUNCTION("current", NULL, 400, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("current", NULL, 402, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
RETURN_MM();
@@ -23289,7 +23516,7 @@ static PHP_METHOD(Phalcon_Registry, __set) {
}
- ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetset", NULL, 401, key, value);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetset", NULL, 403, key, value);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -23317,7 +23544,7 @@ static PHP_METHOD(Phalcon_Registry, __get) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetget", NULL, 402, key);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetget", NULL, 404, key);
zephir_check_call_status();
RETURN_MM();
@@ -23345,7 +23572,7 @@ static PHP_METHOD(Phalcon_Registry, __isset) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetexists", NULL, 403, key);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetexists", NULL, 405, key);
zephir_check_call_status();
RETURN_MM();
@@ -23373,7 +23600,7 @@ static PHP_METHOD(Phalcon_Registry, __unset) {
}
- ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetunset", NULL, 404, key);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetunset", NULL, 406, key);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -23529,7 +23756,7 @@ static PHP_METHOD(Phalcon_Security, getSaltBytes) {
ZEPHIR_INIT_NVAR(safeBytes);
ZEPHIR_INIT_NVAR(_1);
ZVAL_LONG(_1, numberBytes);
- ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", &_3, 405, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", &_3, 407, _1);
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&_4, "base64_encode", &_5, 112, _2);
zephir_check_call_status();
@@ -23621,7 +23848,7 @@ static PHP_METHOD(Phalcon_Security, hash) {
}
ZEPHIR_INIT_VAR(_3);
ZEPHIR_CONCAT_SVSV(_3, "$", variant, "$", saltBytes);
- ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 406, password, _3);
+ ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 408, password, _3);
zephir_check_call_status();
RETURN_MM();
}
@@ -23644,11 +23871,11 @@ static PHP_METHOD(Phalcon_Security, hash) {
ZVAL_STRING(&_5, "%02s", 0);
ZEPHIR_SINIT_VAR(_6);
ZVAL_LONG(&_6, workFactor);
- ZEPHIR_CALL_FUNCTION(&_7, "sprintf", NULL, 186, &_5, &_6);
+ ZEPHIR_CALL_FUNCTION(&_7, "sprintf", NULL, 187, &_5, &_6);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_3);
ZEPHIR_CONCAT_SVSVSV(_3, "$2", variant, "$", _7, "$", saltBytes);
- ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 406, password, _3);
+ ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 408, password, _3);
zephir_check_call_status();
RETURN_MM();
} while(0);
@@ -23688,7 +23915,7 @@ static PHP_METHOD(Phalcon_Security, checkHash) {
RETURN_MM_BOOL(0);
}
}
- ZEPHIR_CALL_FUNCTION(&_1, "crypt", NULL, 406, password, passwordHash);
+ ZEPHIR_CALL_FUNCTION(&_1, "crypt", NULL, 408, password, passwordHash);
zephir_check_call_status();
zephir_get_strval(_2, _1);
ZEPHIR_CPY_WRT(cryptedHash, _2);
@@ -23752,7 +23979,7 @@ static PHP_METHOD(Phalcon_Security, getTokenKey) {
ZEPHIR_INIT_VAR(safeBytes);
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, numberBytes);
- ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", NULL, 405, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", NULL, 407, _1);
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&_3, "base64_encode", NULL, 112, _2);
zephir_check_call_status();
@@ -23794,7 +24021,7 @@ static PHP_METHOD(Phalcon_Security, getToken) {
}
ZEPHIR_INIT_VAR(_0);
ZVAL_LONG(_0, numberBytes);
- ZEPHIR_CALL_FUNCTION(&token, "openssl_random_pseudo_bytes", NULL, 405, _0);
+ ZEPHIR_CALL_FUNCTION(&token, "openssl_random_pseudo_bytes", NULL, 407, _0);
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&_1, "base64_encode", NULL, 112, token);
zephir_check_call_status();
@@ -23967,7 +24194,7 @@ static PHP_METHOD(Phalcon_Security, computeHmac) {
}
- ZEPHIR_CALL_FUNCTION(&hmac, "hash_hmac", NULL, 407, algo, data, key, (raw ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_FUNCTION(&hmac, "hash_hmac", NULL, 409, algo, data, key, (raw ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
if (!(zephir_is_true(hmac))) {
ZEPHIR_INIT_VAR(_0);
@@ -24758,7 +24985,7 @@ static PHP_METHOD(Phalcon_Tag, colorField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "color", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24778,7 +25005,7 @@ static PHP_METHOD(Phalcon_Tag, textField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "text", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24798,7 +25025,7 @@ static PHP_METHOD(Phalcon_Tag, numericField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "number", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24818,7 +25045,7 @@ static PHP_METHOD(Phalcon_Tag, rangeField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "range", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24838,7 +25065,7 @@ static PHP_METHOD(Phalcon_Tag, emailField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "email", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24858,7 +25085,7 @@ static PHP_METHOD(Phalcon_Tag, dateField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "date", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24878,7 +25105,7 @@ static PHP_METHOD(Phalcon_Tag, dateTimeField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "datetime", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24898,7 +25125,7 @@ static PHP_METHOD(Phalcon_Tag, dateTimeLocalField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "datetime-local", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24918,7 +25145,7 @@ static PHP_METHOD(Phalcon_Tag, monthField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "month", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24938,7 +25165,7 @@ static PHP_METHOD(Phalcon_Tag, timeField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "time", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24958,7 +25185,7 @@ static PHP_METHOD(Phalcon_Tag, weekField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "week", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24978,7 +25205,7 @@ static PHP_METHOD(Phalcon_Tag, passwordField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "password", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24998,7 +25225,7 @@ static PHP_METHOD(Phalcon_Tag, hiddenField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "hidden", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25018,7 +25245,7 @@ static PHP_METHOD(Phalcon_Tag, fileField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "file", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25038,7 +25265,7 @@ static PHP_METHOD(Phalcon_Tag, searchField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "search", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25058,7 +25285,7 @@ static PHP_METHOD(Phalcon_Tag, telField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "tel", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25078,7 +25305,7 @@ static PHP_METHOD(Phalcon_Tag, urlField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "url", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25098,7 +25325,7 @@ static PHP_METHOD(Phalcon_Tag, checkField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "checkbox", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 412, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 414, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25118,7 +25345,7 @@ static PHP_METHOD(Phalcon_Tag, radioField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "radio", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 412, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 414, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25140,7 +25367,7 @@ static PHP_METHOD(Phalcon_Tag, imageInput) {
ZVAL_STRING(_1, "image", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_2);
ZVAL_BOOL(_2, 1);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters, _2);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters, _2);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25162,7 +25389,7 @@ static PHP_METHOD(Phalcon_Tag, submitButton) {
ZVAL_STRING(_1, "submit", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_2);
ZVAL_BOOL(_2, 1);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters, _2);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters, _2);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25183,7 +25410,7 @@ static PHP_METHOD(Phalcon_Tag, selectStatic) {
}
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 205, parameters, data);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, parameters, data);
zephir_check_call_status();
RETURN_MM();
@@ -25203,7 +25430,7 @@ static PHP_METHOD(Phalcon_Tag, select) {
}
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 205, parameters, data);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, parameters, data);
zephir_check_call_status();
RETURN_MM();
@@ -25714,13 +25941,13 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_VAR(_3);
ZVAL_STRING(&_3, "en_US.UTF-8", 0);
- ZEPHIR_CALL_FUNCTION(&locale, "setlocale", &_4, 413, &_0, &_3);
+ ZEPHIR_CALL_FUNCTION(&locale, "setlocale", &_4, 415, &_0, &_3);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "UTF-8", 0);
ZEPHIR_SINIT_NVAR(_3);
ZVAL_STRING(&_3, "ASCII//TRANSLIT", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "iconv", NULL, 376, &_0, &_3, text);
+ ZEPHIR_CALL_FUNCTION(&_5, "iconv", NULL, 378, &_0, &_3, text);
zephir_check_call_status();
zephir_get_strval(text, _5);
}
@@ -25783,7 +26010,7 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) {
if (zephir_is_true(_5)) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 0);
- ZEPHIR_CALL_FUNCTION(NULL, "setlocale", &_4, 413, &_3, locale);
+ ZEPHIR_CALL_FUNCTION(NULL, "setlocale", &_4, 415, &_3, locale);
zephir_check_call_status();
}
RETURN_CCTOR(friendly);
@@ -26090,24 +26317,21 @@ static PHP_METHOD(Phalcon_Text, uncamelize) {
static PHP_METHOD(Phalcon_Text, increment) {
- zval *str_param = NULL, *separator = NULL, *parts, *number = NULL, *_0;
- zval *str = NULL;
+ zval *str_param = NULL, *separator_param = NULL, *parts, *number = NULL, *_0;
+ zval *str = NULL, *separator = NULL;
ZEPHIR_MM_GROW();
- zephir_fetch_params(1, 1, 1, &str_param, &separator);
+ zephir_fetch_params(1, 1, 1, &str_param, &separator_param);
zephir_get_strval(str, str_param);
- if (!separator) {
- ZEPHIR_CPY_WRT(separator, ZEPHIR_GLOBAL(global_null));
+ if (!separator_param) {
+ ZEPHIR_INIT_VAR(separator);
+ ZVAL_STRING(separator, "_", 1);
} else {
- ZEPHIR_SEPARATE_PARAM(separator);
+ zephir_get_strval(separator, separator_param);
}
- if (Z_TYPE_P(separator) == IS_NULL) {
- ZEPHIR_INIT_NVAR(separator);
- ZVAL_STRING(separator, "_", 1);
- }
ZEPHIR_INIT_VAR(parts);
zephir_fast_explode(parts, separator, str, LONG_MAX TSRMLS_CC);
ZEPHIR_OBS_VAR(number);
@@ -26118,7 +26342,7 @@ static PHP_METHOD(Phalcon_Text, increment) {
ZEPHIR_INIT_NVAR(number);
ZVAL_LONG(number, 1);
}
- zephir_array_fetch_long(&_0, parts, 0, PH_NOISY | PH_READONLY, "phalcon/text.zep", 88 TSRMLS_CC);
+ zephir_array_fetch_long(&_0, parts, 0, PH_NOISY | PH_READONLY, "phalcon/text.zep", 84 TSRMLS_CC);
ZEPHIR_CONCAT_VVV(return_value, _0, separator, number);
RETURN_MM();
@@ -26154,13 +26378,13 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_STRING(&_0, "a", 0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "z", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "A", 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "Z", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_INIT_VAR(pool);
zephir_fast_array_merge(pool, &(_2), &(_4) TSRMLS_CC);
@@ -26171,13 +26395,13 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 9);
- ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "a", 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "f", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(pool);
zephir_fast_array_merge(pool, &(_2), &(_4) TSRMLS_CC);
@@ -26188,7 +26412,7 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 9);
- ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
break;
}
@@ -26197,7 +26421,7 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 1);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 9);
- ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
break;
}
@@ -26205,21 +26429,21 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 9);
- ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "a", 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "z", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "A", 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "Z", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_5, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&pool, "array_merge", &_6, 417, _2, _4, _5);
+ ZEPHIR_CALL_FUNCTION(&pool, "array_merge", &_6, 419, _2, _4, _5);
zephir_check_call_status();
break;
} while(0);
@@ -26233,7 +26457,7 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, end);
- zephir_array_fetch_long(&_7, pool, zephir_mt_rand(zephir_get_intval(&_0), zephir_get_intval(&_1) TSRMLS_CC), PH_NOISY | PH_READONLY, "phalcon/text.zep", 130 TSRMLS_CC);
+ zephir_array_fetch_long(&_7, pool, zephir_mt_rand(zephir_get_intval(&_0), zephir_get_intval(&_1) TSRMLS_CC), PH_NOISY | PH_READONLY, "phalcon/text.zep", 126 TSRMLS_CC);
zephir_concat_self(&str, _7 TSRMLS_CC);
}
RETURN_CCTOR(str);
@@ -26323,7 +26547,7 @@ static PHP_METHOD(Phalcon_Text, lower) {
if ((zephir_function_exists_ex(SS("mb_strtolower") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 193, str, encoding);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 194, str, encoding);
zephir_check_call_status();
RETURN_MM();
}
@@ -26371,7 +26595,7 @@ static PHP_METHOD(Phalcon_Text, upper) {
if ((zephir_function_exists_ex(SS("mb_strtoupper") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 194, str, encoding);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 195, str, encoding);
zephir_check_call_status();
RETURN_MM();
}
@@ -26416,26 +26640,26 @@ static PHP_METHOD(Phalcon_Text, concat) {
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, 0);
- ZEPHIR_CALL_FUNCTION(&separator, "func_get_arg", &_1, 418, &_0);
+ ZEPHIR_CALL_FUNCTION(&separator, "func_get_arg", &_1, 420, &_0);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, 1);
- ZEPHIR_CALL_FUNCTION(&a, "func_get_arg", &_1, 418, &_0);
+ ZEPHIR_CALL_FUNCTION(&a, "func_get_arg", &_1, 420, &_0);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, 2);
- ZEPHIR_CALL_FUNCTION(&b, "func_get_arg", &_1, 418, &_0);
+ ZEPHIR_CALL_FUNCTION(&b, "func_get_arg", &_1, 420, &_0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_2, "func_num_args", NULL, 419);
+ ZEPHIR_CALL_FUNCTION(&_2, "func_num_args", NULL, 421);
zephir_check_call_status();
if (ZEPHIR_GT_LONG(_2, 3)) {
- ZEPHIR_CALL_FUNCTION(&_3, "func_get_args", NULL, 165);
+ ZEPHIR_CALL_FUNCTION(&_3, "func_get_args", NULL, 166);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, 3);
- ZEPHIR_CALL_FUNCTION(&_4, "array_slice", NULL, 377, _3, &_0);
+ ZEPHIR_CALL_FUNCTION(&_4, "array_slice", NULL, 379, _3, &_0);
zephir_check_call_status();
- zephir_is_iterable(_4, &_6, &_5, 0, 0, "phalcon/text.zep", 246);
+ zephir_is_iterable(_4, &_6, &_5, 0, 0, "phalcon/text.zep", 242);
for (
; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS
; zephir_hash_move_forward_ex(_6, &_5)
@@ -26530,36 +26754,36 @@ static PHP_METHOD(Phalcon_Text, dynamic) {
}
- ZEPHIR_CALL_FUNCTION(&_0, "substr_count", &_1, 420, text, leftDelimiter);
+ ZEPHIR_CALL_FUNCTION(&_0, "substr_count", &_1, 422, text, leftDelimiter);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_2, "substr_count", &_1, 420, text, rightDelimiter);
+ ZEPHIR_CALL_FUNCTION(&_2, "substr_count", &_1, 422, text, rightDelimiter);
zephir_check_call_status();
if (!ZEPHIR_IS_IDENTICAL(_0, _2)) {
ZEPHIR_INIT_VAR(_3);
object_init_ex(_3, spl_ce_RuntimeException);
ZEPHIR_INIT_VAR(_4);
ZEPHIR_CONCAT_SVS(_4, "Syntax error in string \"", text, "\"");
- ZEPHIR_CALL_METHOD(NULL, _3, "__construct", NULL, 421, _4);
+ ZEPHIR_CALL_METHOD(NULL, _3, "__construct", NULL, 423, _4);
zephir_check_call_status();
- zephir_throw_exception_debug(_3, "phalcon/text.zep", 265 TSRMLS_CC);
+ zephir_throw_exception_debug(_3, "phalcon/text.zep", 261 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_CALL_FUNCTION(&ld_s, "preg_quote", &_5, 422, leftDelimiter);
+ ZEPHIR_CALL_FUNCTION(&ld_s, "preg_quote", &_5, 424, leftDelimiter);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&rd_s, "preg_quote", &_5, 422, rightDelimiter);
+ ZEPHIR_CALL_FUNCTION(&rd_s, "preg_quote", &_5, 424, rightDelimiter);
zephir_check_call_status();
ZEPHIR_INIT_VAR(pattern);
ZEPHIR_CONCAT_SVSVVSVS(pattern, "/", ld_s, "([^", ld_s, rd_s, "]+)", rd_s, "/");
ZEPHIR_CPY_WRT(result, text);
while (1) {
- if (!(zephir_memnstr(result, leftDelimiter, "phalcon/text.zep", 273))) {
+ if (!(zephir_memnstr(result, leftDelimiter, "phalcon/text.zep", 269))) {
break;
}
ZEPHIR_INIT_NVAR(_3);
ZEPHIR_INIT_NVAR(_3);
zephir_create_closure_ex(_3, NULL, phalcon_0__closure_ce, SS("__invoke") TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_6, "preg_replace_callback", &_7, 423, pattern, _3, result);
+ ZEPHIR_CALL_FUNCTION(&_6, "preg_replace_callback", &_7, 425, pattern, _3, result);
zephir_check_call_status();
ZEPHIR_CPY_WRT(result, _6);
}
@@ -27223,7 +27447,7 @@ static PHP_METHOD(Phalcon_Version, _getVersion) {
ZVAL_LONG(_0, 0);
zephir_array_fast_append(return_value, _0);
ZEPHIR_INIT_NVAR(_0);
- ZVAL_LONG(_0, 5);
+ ZVAL_LONG(_0, 6);
zephir_array_fast_append(return_value, _0);
ZEPHIR_INIT_NVAR(_0);
ZVAL_LONG(_0, 4);
@@ -27292,7 +27516,7 @@ static PHP_METHOD(Phalcon_Version, get) {
zephir_array_fetch_long(&specialNumber, version, 4, PH_NOISY, "phalcon/version.zep", 128 TSRMLS_CC);
ZEPHIR_INIT_VAR(result);
ZEPHIR_CONCAT_VSVSVS(result, major, ".", medium, ".", minor, " ");
- ZEPHIR_CALL_STATIC(&suffix, "_getspecial", &_0, 437, special);
+ ZEPHIR_CALL_STATIC(&suffix, "_getspecial", &_0, 441, special);
zephir_check_call_status();
if (!ZEPHIR_IS_STRING(suffix, "")) {
ZEPHIR_INIT_VAR(_1);
@@ -27326,11 +27550,11 @@ static PHP_METHOD(Phalcon_Version, getId) {
zephir_array_fetch_long(&specialNumber, version, 4, PH_NOISY, "phalcon/version.zep", 158 TSRMLS_CC);
ZEPHIR_SINIT_VAR(_0);
ZVAL_STRING(&_0, "%02s", 0);
- ZEPHIR_CALL_FUNCTION(&_1, "sprintf", &_2, 186, &_0, medium);
+ ZEPHIR_CALL_FUNCTION(&_1, "sprintf", &_2, 187, &_0, medium);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "%02s", 0);
- ZEPHIR_CALL_FUNCTION(&_3, "sprintf", &_2, 186, &_0, minor);
+ ZEPHIR_CALL_FUNCTION(&_3, "sprintf", &_2, 187, &_0, minor);
zephir_check_call_status();
ZEPHIR_CONCAT_VVVVV(return_value, major, _1, _3, special, specialNumber);
RETURN_MM();
@@ -27359,7 +27583,7 @@ static PHP_METHOD(Phalcon_Version, getPart) {
}
if (part == 3) {
zephir_array_fetch_long(&_1, version, 3, PH_NOISY | PH_READONLY, "phalcon/version.zep", 187 TSRMLS_CC);
- ZEPHIR_CALL_STATIC(&result, "_getspecial", &_0, 437, _1);
+ ZEPHIR_CALL_STATIC(&result, "_getspecial", &_0, 441, _1);
zephir_check_call_status();
break;
}
@@ -36858,7 +37082,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Libmemcached, save) {
int ZEPHIR_LAST_CALL_STATUS;
zend_bool stopBuffer;
- zval *keyName = NULL, *content = NULL, *lifetime = NULL, *stopBuffer_param = NULL, *lastKey = NULL, *frontend, *memcache = NULL, *cachedContent = NULL, *preparedContent = NULL, *tmp, *tt1 = NULL, *success = NULL, *options, *specialKey, *keys = NULL, *isBuffering = NULL, *_0;
+ zval *keyName = NULL, *content = NULL, *lifetime = NULL, *stopBuffer_param = NULL, *lastKey = NULL, *frontend, *memcache = NULL, *cachedContent = NULL, *preparedContent = NULL, *tmp, *tt1 = NULL, *success = NULL, *options, *specialKey, *keys = NULL, *isBuffering = NULL, *_0, *_1, *_2 = NULL, *_3;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 0, 4, &keyName, &content, &lifetime, &stopBuffer_param);
@@ -36931,7 +37155,16 @@ static PHP_METHOD(Phalcon_Cache_Backend_Libmemcached, save) {
zephir_check_call_status();
}
if (!(zephir_is_true(success))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "Failed storing data in memcached", "phalcon/cache/backend/libmemcached.zep", 223);
+ ZEPHIR_INIT_VAR(_1);
+ object_init_ex(_1, phalcon_cache_exception_ce);
+ ZEPHIR_CALL_METHOD(&_2, memcache, "getresultcode", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_INIT_VAR(_3);
+ ZEPHIR_CONCAT_SV(_3, "Failed storing data in memcached, error code: ", _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3);
+ zephir_check_call_status();
+ zephir_throw_exception_debug(_1, "phalcon/cache/backend/libmemcached.zep", 223 TSRMLS_CC);
+ ZEPHIR_MM_RESTORE();
return;
}
ZEPHIR_OBS_VAR(options);
@@ -43122,7 +43355,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, fetchAll) {
if (!(zephir_is_true(row))) {
break;
}
- zephir_array_append(&results, row, PH_SEPARATE, "phalcon/db/adapter.zep", 249);
+ zephir_array_append(&results, row, PH_SEPARATE, "phalcon/db/adapter.zep", 243);
}
}
RETURN_CCTOR(results);
@@ -43192,7 +43425,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, insert) {
ZEPHIR_CONCAT_SVS(_1, "Unable to insert into ", table, " without data");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _1);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/db/adapter.zep", 317 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/db/adapter.zep", 312 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -43202,7 +43435,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, insert) {
array_init(insertValues);
ZEPHIR_INIT_VAR(bindDataTypes);
array_init(bindDataTypes);
- zephir_is_iterable(values, &_3, &_2, 0, 0, "phalcon/db/adapter.zep", 347);
+ zephir_is_iterable(values, &_3, &_2, 0, 0, "phalcon/db/adapter.zep", 342);
for (
; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS
; zephir_hash_move_forward_ex(_3, &_2)
@@ -43211,24 +43444,24 @@ static PHP_METHOD(Phalcon_Db_Adapter, insert) {
ZEPHIR_GET_HVALUE(value, _4);
if (Z_TYPE_P(value) == IS_OBJECT) {
zephir_get_strval(_5, value);
- zephir_array_append(&placeholders, _5, PH_SEPARATE, "phalcon/db/adapter.zep", 330);
+ zephir_array_append(&placeholders, _5, PH_SEPARATE, "phalcon/db/adapter.zep", 325);
} else {
if (Z_TYPE_P(value) == IS_NULL) {
ZEPHIR_INIT_NVAR(_0);
ZVAL_STRING(_0, "null", 1);
- zephir_array_append(&placeholders, _0, PH_SEPARATE, "phalcon/db/adapter.zep", 333);
+ zephir_array_append(&placeholders, _0, PH_SEPARATE, "phalcon/db/adapter.zep", 328);
} else {
ZEPHIR_INIT_NVAR(_0);
ZVAL_STRING(_0, "?", 1);
- zephir_array_append(&placeholders, _0, PH_SEPARATE, "phalcon/db/adapter.zep", 335);
- zephir_array_append(&insertValues, value, PH_SEPARATE, "phalcon/db/adapter.zep", 336);
+ zephir_array_append(&placeholders, _0, PH_SEPARATE, "phalcon/db/adapter.zep", 330);
+ zephir_array_append(&insertValues, value, PH_SEPARATE, "phalcon/db/adapter.zep", 331);
if (Z_TYPE_P(dataTypes) == IS_ARRAY) {
ZEPHIR_OBS_NVAR(bindType);
if (!(zephir_array_isset_fetch(&bindType, dataTypes, position, 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Incomplete number of bind types", "phalcon/db/adapter.zep", 339);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Incomplete number of bind types", "phalcon/db/adapter.zep", 334);
return;
}
- zephir_array_append(&bindDataTypes, bindType, PH_SEPARATE, "phalcon/db/adapter.zep", 341);
+ zephir_array_append(&bindDataTypes, bindType, PH_SEPARATE, "phalcon/db/adapter.zep", 336);
}
}
}
@@ -43246,7 +43479,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, insert) {
if (ZEPHIR_GLOBAL(db).escape_identifiers) {
ZEPHIR_INIT_VAR(escapedFields);
array_init(escapedFields);
- zephir_is_iterable(fields, &_7, &_6, 0, 0, "phalcon/db/adapter.zep", 364);
+ zephir_is_iterable(fields, &_7, &_6, 0, 0, "phalcon/db/adapter.zep", 359);
for (
; zephir_hash_get_current_data_ex(_7, (void**) &_8, &_6) == SUCCESS
; zephir_hash_move_forward_ex(_7, &_6)
@@ -43254,7 +43487,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, insert) {
ZEPHIR_GET_HVALUE(field, _8);
ZEPHIR_CALL_METHOD(&_9, this_ptr, "escapeidentifier", &_10, 0, field);
zephir_check_call_status();
- zephir_array_append(&escapedFields, _9, PH_SEPARATE, "phalcon/db/adapter.zep", 362);
+ zephir_array_append(&escapedFields, _9, PH_SEPARATE, "phalcon/db/adapter.zep", 357);
}
} else {
ZEPHIR_CPY_WRT(escapedFields, fields);
@@ -43303,15 +43536,15 @@ static PHP_METHOD(Phalcon_Db_Adapter, insertAsDict) {
if (_0) {
RETURN_MM_BOOL(0);
}
- zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/db/adapter.zep", 419);
+ zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/db/adapter.zep", 414);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
) {
ZEPHIR_GET_HMKEY(field, _2, _1);
ZEPHIR_GET_HVALUE(value, _3);
- zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/db/adapter.zep", 415);
- zephir_array_append(&values, value, PH_SEPARATE, "phalcon/db/adapter.zep", 416);
+ zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/db/adapter.zep", 410);
+ zephir_array_append(&values, value, PH_SEPARATE, "phalcon/db/adapter.zep", 411);
}
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "insert", NULL, 0, table, values, fields, dataTypes);
zephir_check_call_status();
@@ -43344,7 +43577,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, update) {
array_init(updateValues);
ZEPHIR_INIT_VAR(bindDataTypes);
array_init(bindDataTypes);
- zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/db/adapter.zep", 505);
+ zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/db/adapter.zep", 500);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -43353,7 +43586,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, update) {
ZEPHIR_GET_HVALUE(value, _2);
ZEPHIR_OBS_NVAR(field);
if (!(zephir_array_isset_fetch(&field, fields, position, 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The number of values in the update is not the same as fields", "phalcon/db/adapter.zep", 478);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The number of values in the update is not the same as fields", "phalcon/db/adapter.zep", 473);
return;
}
if (ZEPHIR_GLOBAL(db).escape_identifiers) {
@@ -43365,25 +43598,25 @@ static PHP_METHOD(Phalcon_Db_Adapter, update) {
if (Z_TYPE_P(value) == IS_OBJECT) {
ZEPHIR_INIT_LNVAR(_4);
ZEPHIR_CONCAT_VSV(_4, escapedField, " = ", value);
- zephir_array_append(&placeholders, _4, PH_SEPARATE, "phalcon/db/adapter.zep", 488);
+ zephir_array_append(&placeholders, _4, PH_SEPARATE, "phalcon/db/adapter.zep", 483);
} else {
if (Z_TYPE_P(value) == IS_NULL) {
ZEPHIR_INIT_LNVAR(_4);
ZEPHIR_CONCAT_VS(_4, escapedField, " = null");
- zephir_array_append(&placeholders, _4, PH_SEPARATE, "phalcon/db/adapter.zep", 491);
+ zephir_array_append(&placeholders, _4, PH_SEPARATE, "phalcon/db/adapter.zep", 486);
} else {
- zephir_array_append(&updateValues, value, PH_SEPARATE, "phalcon/db/adapter.zep", 493);
+ zephir_array_append(&updateValues, value, PH_SEPARATE, "phalcon/db/adapter.zep", 488);
if (Z_TYPE_P(dataTypes) == IS_ARRAY) {
ZEPHIR_OBS_NVAR(bindType);
if (!(zephir_array_isset_fetch(&bindType, dataTypes, position, 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Incomplete number of bind types", "phalcon/db/adapter.zep", 496);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Incomplete number of bind types", "phalcon/db/adapter.zep", 491);
return;
}
- zephir_array_append(&bindDataTypes, bindType, PH_SEPARATE, "phalcon/db/adapter.zep", 498);
+ zephir_array_append(&bindDataTypes, bindType, PH_SEPARATE, "phalcon/db/adapter.zep", 493);
}
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_VS(_5, escapedField, " = ?");
- zephir_array_append(&placeholders, _5, PH_SEPARATE, "phalcon/db/adapter.zep", 500);
+ zephir_array_append(&placeholders, _5, PH_SEPARATE, "phalcon/db/adapter.zep", 495);
}
}
}
@@ -43402,7 +43635,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, update) {
zephir_concat_self(&updateSql, whereCondition TSRMLS_CC);
} else {
if (Z_TYPE_P(whereCondition) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Invalid WHERE clause conditions", "phalcon/db/adapter.zep", 528);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Invalid WHERE clause conditions", "phalcon/db/adapter.zep", 523);
return;
}
ZEPHIR_OBS_VAR(conditions);
@@ -43462,15 +43695,15 @@ static PHP_METHOD(Phalcon_Db_Adapter, updateAsDict) {
if (_0) {
RETURN_MM_BOOL(0);
}
- zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/db/adapter.zep", 604);
+ zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/db/adapter.zep", 599);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
) {
ZEPHIR_GET_HMKEY(field, _2, _1);
ZEPHIR_GET_HVALUE(value, _3);
- zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/db/adapter.zep", 600);
- zephir_array_append(&values, value, PH_SEPARATE, "phalcon/db/adapter.zep", 601);
+ zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/db/adapter.zep", 595);
+ zephir_array_append(&values, value, PH_SEPARATE, "phalcon/db/adapter.zep", 596);
}
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "update", NULL, 0, table, fields, values, whereCondition, dataTypes);
zephir_check_call_status();
@@ -43609,7 +43842,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, tableExists) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchone", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_array_fetch_long(&_4, _0, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 681 TSRMLS_CC);
+ zephir_array_fetch_long(&_4, _0, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 676 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_GT_LONG(_4, 0));
}
@@ -43659,7 +43892,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, viewExists) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchone", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_array_fetch_long(&_4, _0, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 693 TSRMLS_CC);
+ zephir_array_fetch_long(&_4, _0, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 688 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_GT_LONG(_4, 0));
}
@@ -43760,11 +43993,11 @@ static PHP_METHOD(Phalcon_Db_Adapter, createTable) {
ZEPHIR_OBS_VAR(columns);
if (!(zephir_array_isset_string_fetch(&columns, definition, SS("columns"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 720);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 715);
return;
}
if (!(zephir_fast_count_int(columns TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 724);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 719);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dialect"), PH_NOISY_CC);
@@ -43858,7 +44091,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, createView) {
if (!(zephir_array_isset_string(definition, SS("sql")))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 749);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 739);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dialect"), PH_NOISY_CC);
@@ -44371,14 +44604,14 @@ static PHP_METHOD(Phalcon_Db_Adapter, listTables) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchall", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 858);
+ zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 848);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
) {
ZEPHIR_GET_HVALUE(table, _6);
- zephir_array_fetch_long(&_7, table, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 856 TSRMLS_CC);
- zephir_array_append(&allTables, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 856);
+ zephir_array_fetch_long(&_7, table, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 846 TSRMLS_CC);
+ zephir_array_append(&allTables, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 846);
}
RETURN_CCTOR(allTables);
@@ -44422,14 +44655,14 @@ static PHP_METHOD(Phalcon_Db_Adapter, listViews) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchall", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 876);
+ zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 866);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
) {
ZEPHIR_GET_HVALUE(table, _6);
- zephir_array_fetch_long(&_7, table, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 874 TSRMLS_CC);
- zephir_array_append(&allTables, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 874);
+ zephir_array_fetch_long(&_7, table, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 864 TSRMLS_CC);
+ zephir_array_append(&allTables, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 864);
}
RETURN_CCTOR(allTables);
@@ -44472,27 +44705,27 @@ static PHP_METHOD(Phalcon_Db_Adapter, describeIndexes) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchall", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 908);
+ zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 898);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
) {
ZEPHIR_GET_HVALUE(index, _6);
- zephir_array_fetch_long(&keyName, index, 2, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 897 TSRMLS_CC);
+ zephir_array_fetch_long(&keyName, index, 2, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 887 TSRMLS_CC);
if (!(zephir_array_isset(indexes, keyName))) {
ZEPHIR_INIT_NVAR(columns);
array_init(columns);
} else {
ZEPHIR_OBS_NVAR(columns);
- zephir_array_fetch(&columns, indexes, keyName, PH_NOISY, "phalcon/db/adapter.zep", 901 TSRMLS_CC);
+ zephir_array_fetch(&columns, indexes, keyName, PH_NOISY, "phalcon/db/adapter.zep", 891 TSRMLS_CC);
}
- zephir_array_fetch_long(&_7, index, 4, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 904 TSRMLS_CC);
- zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 904);
+ zephir_array_fetch_long(&_7, index, 4, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 894 TSRMLS_CC);
+ zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 894);
zephir_array_update_zval(&indexes, keyName, &columns, PH_COPY | PH_SEPARATE);
}
ZEPHIR_INIT_VAR(indexObjects);
array_init(indexObjects);
- zephir_is_iterable(indexes, &_9, &_8, 0, 0, "phalcon/db/adapter.zep", 917);
+ zephir_is_iterable(indexes, &_9, &_8, 0, 0, "phalcon/db/adapter.zep", 907);
for (
; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS
; zephir_hash_move_forward_ex(_9, &_8)
@@ -44560,40 +44793,40 @@ static PHP_METHOD(Phalcon_Db_Adapter, describeReferences) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchall", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 961);
+ zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 951);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
) {
ZEPHIR_GET_HVALUE(reference, _6);
- zephir_array_fetch_long(&constraintName, reference, 2, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 937 TSRMLS_CC);
+ zephir_array_fetch_long(&constraintName, reference, 2, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 927 TSRMLS_CC);
if (!(zephir_array_isset(references, constraintName))) {
ZEPHIR_OBS_NVAR(referencedSchema);
- zephir_array_fetch_long(&referencedSchema, reference, 3, PH_NOISY, "phalcon/db/adapter.zep", 939 TSRMLS_CC);
+ zephir_array_fetch_long(&referencedSchema, reference, 3, PH_NOISY, "phalcon/db/adapter.zep", 929 TSRMLS_CC);
ZEPHIR_OBS_NVAR(referencedTable);
- zephir_array_fetch_long(&referencedTable, reference, 4, PH_NOISY, "phalcon/db/adapter.zep", 940 TSRMLS_CC);
+ zephir_array_fetch_long(&referencedTable, reference, 4, PH_NOISY, "phalcon/db/adapter.zep", 930 TSRMLS_CC);
ZEPHIR_INIT_NVAR(columns);
array_init(columns);
ZEPHIR_INIT_NVAR(referencedColumns);
array_init(referencedColumns);
} else {
- zephir_array_fetch(&_7, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 944 TSRMLS_CC);
+ zephir_array_fetch(&_7, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 934 TSRMLS_CC);
ZEPHIR_OBS_NVAR(referencedSchema);
- zephir_array_fetch_string(&referencedSchema, _7, SL("referencedSchema"), PH_NOISY, "phalcon/db/adapter.zep", 944 TSRMLS_CC);
- zephir_array_fetch(&_8, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 945 TSRMLS_CC);
+ zephir_array_fetch_string(&referencedSchema, _7, SL("referencedSchema"), PH_NOISY, "phalcon/db/adapter.zep", 934 TSRMLS_CC);
+ zephir_array_fetch(&_8, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 935 TSRMLS_CC);
ZEPHIR_OBS_NVAR(referencedTable);
- zephir_array_fetch_string(&referencedTable, _8, SL("referencedTable"), PH_NOISY, "phalcon/db/adapter.zep", 945 TSRMLS_CC);
- zephir_array_fetch(&_9, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 946 TSRMLS_CC);
+ zephir_array_fetch_string(&referencedTable, _8, SL("referencedTable"), PH_NOISY, "phalcon/db/adapter.zep", 935 TSRMLS_CC);
+ zephir_array_fetch(&_9, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 936 TSRMLS_CC);
ZEPHIR_OBS_NVAR(columns);
- zephir_array_fetch_string(&columns, _9, SL("columns"), PH_NOISY, "phalcon/db/adapter.zep", 946 TSRMLS_CC);
- zephir_array_fetch(&_10, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 947 TSRMLS_CC);
+ zephir_array_fetch_string(&columns, _9, SL("columns"), PH_NOISY, "phalcon/db/adapter.zep", 936 TSRMLS_CC);
+ zephir_array_fetch(&_10, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 937 TSRMLS_CC);
ZEPHIR_OBS_NVAR(referencedColumns);
- zephir_array_fetch_string(&referencedColumns, _10, SL("referencedColumns"), PH_NOISY, "phalcon/db/adapter.zep", 947 TSRMLS_CC);
+ zephir_array_fetch_string(&referencedColumns, _10, SL("referencedColumns"), PH_NOISY, "phalcon/db/adapter.zep", 937 TSRMLS_CC);
}
- zephir_array_fetch_long(&_7, reference, 1, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 950 TSRMLS_CC);
- zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 950);
- zephir_array_fetch_long(&_8, reference, 5, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 951 TSRMLS_CC);
- zephir_array_append(&referencedColumns, _8, PH_SEPARATE, "phalcon/db/adapter.zep", 951);
+ zephir_array_fetch_long(&_7, reference, 1, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 940 TSRMLS_CC);
+ zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 940);
+ zephir_array_fetch_long(&_8, reference, 5, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 941 TSRMLS_CC);
+ zephir_array_append(&referencedColumns, _8, PH_SEPARATE, "phalcon/db/adapter.zep", 941);
ZEPHIR_INIT_NVAR(_11);
zephir_create_array(_11, 4, 0 TSRMLS_CC);
zephir_array_update_string(&_11, SL("referencedSchema"), &referencedSchema, PH_COPY | PH_SEPARATE);
@@ -44604,7 +44837,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, describeReferences) {
}
ZEPHIR_INIT_VAR(referenceObjects);
array_init(referenceObjects);
- zephir_is_iterable(references, &_13, &_12, 0, 0, "phalcon/db/adapter.zep", 971);
+ zephir_is_iterable(references, &_13, &_12, 0, 0, "phalcon/db/adapter.zep", 961);
for (
; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS
; zephir_hash_move_forward_ex(_13, &_12)
@@ -44616,16 +44849,16 @@ static PHP_METHOD(Phalcon_Db_Adapter, describeReferences) {
ZEPHIR_INIT_NVAR(_11);
zephir_create_array(_11, 4, 0 TSRMLS_CC);
ZEPHIR_OBS_NVAR(_15);
- zephir_array_fetch_string(&_15, arrayReference, SL("referencedSchema"), PH_NOISY, "phalcon/db/adapter.zep", 964 TSRMLS_CC);
+ zephir_array_fetch_string(&_15, arrayReference, SL("referencedSchema"), PH_NOISY, "phalcon/db/adapter.zep", 954 TSRMLS_CC);
zephir_array_update_string(&_11, SL("referencedSchema"), &_15, PH_COPY | PH_SEPARATE);
ZEPHIR_OBS_NVAR(_15);
- zephir_array_fetch_string(&_15, arrayReference, SL("referencedTable"), PH_NOISY, "phalcon/db/adapter.zep", 965 TSRMLS_CC);
+ zephir_array_fetch_string(&_15, arrayReference, SL("referencedTable"), PH_NOISY, "phalcon/db/adapter.zep", 955 TSRMLS_CC);
zephir_array_update_string(&_11, SL("referencedTable"), &_15, PH_COPY | PH_SEPARATE);
ZEPHIR_OBS_NVAR(_15);
- zephir_array_fetch_string(&_15, arrayReference, SL("columns"), PH_NOISY, "phalcon/db/adapter.zep", 966 TSRMLS_CC);
+ zephir_array_fetch_string(&_15, arrayReference, SL("columns"), PH_NOISY, "phalcon/db/adapter.zep", 956 TSRMLS_CC);
zephir_array_update_string(&_11, SL("columns"), &_15, PH_COPY | PH_SEPARATE);
ZEPHIR_OBS_NVAR(_15);
- zephir_array_fetch_string(&_15, arrayReference, SL("referencedColumns"), PH_NOISY, "phalcon/db/adapter.zep", 968 TSRMLS_CC);
+ zephir_array_fetch_string(&_15, arrayReference, SL("referencedColumns"), PH_NOISY, "phalcon/db/adapter.zep", 958 TSRMLS_CC);
zephir_array_update_string(&_11, SL("referencedColumns"), &_15, PH_COPY | PH_SEPARATE);
ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_16, 16, name, _11);
zephir_check_call_status();
@@ -44671,7 +44904,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, tableOptions) {
ZVAL_LONG(_2, 2);
ZEPHIR_CALL_METHOD(&_1, this_ptr, "fetchall", NULL, 0, sql, _2);
zephir_check_call_status();
- zephir_array_fetch_long(&_3, _1, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 987 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, _1, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 977 TSRMLS_CC);
RETURN_CTOR(_3);
}
array_init(return_value);
@@ -44706,7 +44939,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, createSavepoint) {
ZEPHIR_CALL_METHOD(&_0, dialect, "supportssavepoints", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_0))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter.", "phalcon/db/adapter.zep", 1002);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter.", "phalcon/db/adapter.zep", 992);
return;
}
ZEPHIR_CALL_METHOD(&_1, dialect, "createsavepoint", NULL, 0, name);
@@ -44744,7 +44977,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, releaseSavepoint) {
ZEPHIR_CALL_METHOD(&_0, dialect, "supportssavepoints", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_0))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1018);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1008);
return;
}
ZEPHIR_CALL_METHOD(&_1, dialect, "supportsreleasesavepoints", NULL, 0);
@@ -44787,7 +45020,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, rollbackSavepoint) {
ZEPHIR_CALL_METHOD(&_0, dialect, "supportssavepoints", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_0))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1038);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1028);
return;
}
ZEPHIR_CALL_METHOD(&_1, dialect, "rollbacksavepoint", NULL, 0, name);
@@ -44812,14 +45045,14 @@ static PHP_METHOD(Phalcon_Db_Adapter, setNestedTransactionsWithSavepoints) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_transactionLevel"), PH_NOISY_CC);
if (ZEPHIR_GT_LONG(_0, 0)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Nested transaction with savepoints behavior cannot be changed while a transaction is open", "phalcon/db/adapter.zep", 1051);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Nested transaction with savepoints behavior cannot be changed while a transaction is open", "phalcon/db/adapter.zep", 1041);
return;
}
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_dialect"), PH_NOISY_CC);
ZEPHIR_CALL_METHOD(&_2, _1, "supportssavepoints", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_2))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1055);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1045);
return;
}
zephir_update_property_this(this_ptr, SL("_transactionsWithSavepoints"), nestedTransactionsWithSavepoints ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
@@ -47020,11 +47253,10 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionGroupBy) {
if (unlikely(Z_TYPE_P(filed) != IS_ARRAY)) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Invalid SQL-GROUP-BY expression", "phalcon/db/dialect.zep", 829);
return;
- } else {
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqlexpression", &_4, 0, filed, escapeChar, bindCounts);
- zephir_check_call_status();
- zephir_array_append(&fields, _3, PH_SEPARATE, "phalcon/db/dialect.zep", 831);
}
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqlexpression", &_4, 0, filed, escapeChar, bindCounts);
+ zephir_check_call_status();
+ zephir_array_append(&fields, _3, PH_SEPARATE, "phalcon/db/dialect.zep", 832);
}
ZEPHIR_INIT_VAR(_5);
zephir_fast_join_str(_5, SL(", "), fields TSRMLS_CC);
@@ -47106,11 +47338,10 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionOrderBy) {
if (unlikely(Z_TYPE_P(filed) != IS_ARRAY)) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Invalid SQL-ORDER-BY expression", "phalcon/db/dialect.zep", 870);
return;
- } else {
- zephir_array_fetch_long(&_3, filed, 0, PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 872 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&fieldSql, this_ptr, "getsqlexpression", &_4, 0, _3, escapeChar, bindCounts);
- zephir_check_call_status();
}
+ zephir_array_fetch_long(&_3, filed, 0, PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 873 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&fieldSql, this_ptr, "getsqlexpression", &_4, 0, _3, escapeChar, bindCounts);
+ zephir_check_call_status();
ZEPHIR_OBS_NVAR(type);
_5 = zephir_array_isset_long_fetch(&type, filed, 1, 0 TSRMLS_CC);
if (_5) {
@@ -47659,19 +47890,19 @@ static PHP_METHOD(Phalcon_Db_Profiler, startProfile) {
ZEPHIR_CALL_METHOD(NULL, activeProfile, "__construct", NULL, 0);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlstatement", NULL, 143, sqlStatement);
+ ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlstatement", NULL, 144, sqlStatement);
zephir_check_call_status();
if (Z_TYPE_P(sqlVariables) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlvariables", NULL, 144, sqlVariables);
+ ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlvariables", NULL, 145, sqlVariables);
zephir_check_call_status();
}
if (Z_TYPE_P(sqlBindTypes) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlbindtypes", NULL, 145, sqlBindTypes);
+ ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlbindtypes", NULL, 146, sqlBindTypes);
zephir_check_call_status();
}
ZEPHIR_INIT_VAR(_0);
zephir_microtime(_0, ZEPHIR_GLOBAL(global_true) TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, activeProfile, "setinitialtime", NULL, 146, _0);
+ ZEPHIR_CALL_METHOD(NULL, activeProfile, "setinitialtime", NULL, 147, _0);
zephir_check_call_status();
if ((zephir_method_exists_ex(this_ptr, SS("beforestartprofile") TSRMLS_CC) == SUCCESS)) {
ZEPHIR_CALL_METHOD(NULL, this_ptr, "beforestartprofile", NULL, 0, activeProfile);
@@ -50756,15 +50987,14 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) {
if (zephir_is_true(size)) {
ZEPHIR_CALL_METHOD(&scale, column, "getscale", NULL, 0);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_1);
- ZEPHIR_CONCAT_SV(_1, "(", size);
- zephir_concat_self(&columnSql, _1 TSRMLS_CC);
if (zephir_is_true(scale)) {
+ ZEPHIR_INIT_LNVAR(_1);
+ ZEPHIR_CONCAT_SVSVS(_1, "(", size, ",", scale, ")");
+ zephir_concat_self(&columnSql, _1 TSRMLS_CC);
+ } else {
ZEPHIR_INIT_VAR(_4);
- ZEPHIR_CONCAT_SVS(_4, ",", scale, ")");
+ ZEPHIR_CONCAT_SVS(_4, "(", size, ")");
zephir_concat_self(&columnSql, _4 TSRMLS_CC);
- } else {
- zephir_concat_self_str(&columnSql, SL(")") TSRMLS_CC);
}
}
ZEPHIR_CALL_METHOD(&_0, column, "isunsigned", NULL, 0);
@@ -50846,7 +51076,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) {
break;
}
if (ZEPHIR_IS_EMPTY(columnSql)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Unrecognized MySQL data type", "phalcon/db/dialect/mysql.zep", 192);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Unrecognized MySQL data type", "phalcon/db/dialect/mysql.zep", 191);
return;
}
ZEPHIR_CALL_METHOD(&typeValues, column, "gettypevalues", NULL, 0);
@@ -50855,7 +51085,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) {
if (Z_TYPE_P(typeValues) == IS_ARRAY) {
ZEPHIR_INIT_VAR(valueSql);
ZVAL_STRING(valueSql, "", 1);
- zephir_is_iterable(typeValues, &_6, &_5, 0, 0, "phalcon/db/dialect/mysql.zep", 203);
+ zephir_is_iterable(typeValues, &_6, &_5, 0, 0, "phalcon/db/dialect/mysql.zep", 202);
for (
; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS
; zephir_hash_move_forward_ex(_6, &_5)
@@ -50897,8 +51127,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addColumn) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *afterPosition = NULL, *sql = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *afterPosition = NULL, *sql, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, _3, *_4 = NULL, *_5 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &column);
@@ -50927,50 +51157,41 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addColumn) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` ADD ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` ADD ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumndefinition", NULL, 0, column);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVSV(_3, "`", _1, "` ", _2);
- zephir_concat_self(&sql, _3 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(sql);
+ ZEPHIR_CONCAT_SVSVSV(sql, "ALTER TABLE ", _0, " ADD `", _1, "` ", _2);
ZEPHIR_CALL_METHOD(&defaultValue, column, "getdefault", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(defaultValue))) {
- ZEPHIR_SINIT_VAR(_4);
- ZVAL_STRING(&_4, "\"", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 141, defaultValue, &_4);
+ ZEPHIR_SINIT_VAR(_3);
+ ZVAL_STRING(&_3, "\"", 0);
+ ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 141, defaultValue, &_3);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_6);
- ZEPHIR_CONCAT_SVS(_6, " DEFAULT \"", _5, "\"");
- zephir_concat_self(&sql, _6 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_5);
+ ZEPHIR_CONCAT_SVS(_5, " DEFAULT \"", _4, "\"");
+ zephir_concat_self(&sql, _5 TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_5, column, "isnotnull", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, column, "isnotnull", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_5)) {
+ if (zephir_is_true(_4)) {
zephir_concat_self_str(&sql, SL(" NOT NULL") TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_5, column, "isfirst", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, column, "isfirst", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_5)) {
+ if (zephir_is_true(_4)) {
zephir_concat_self_str(&sql, SL(" FIRST") TSRMLS_CC);
} else {
ZEPHIR_CALL_METHOD(&afterPosition, column, "getafterposition", NULL, 0);
zephir_check_call_status();
if (zephir_is_true(afterPosition)) {
- ZEPHIR_INIT_LNVAR(_6);
- ZEPHIR_CONCAT_SV(_6, " AFTER ", afterPosition);
- zephir_concat_self(&sql, _6 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_5);
+ ZEPHIR_CONCAT_SV(_5, " AFTER ", afterPosition);
+ zephir_concat_self(&sql, _5 TSRMLS_CC);
}
}
RETURN_CCTOR(sql);
@@ -50980,8 +51201,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addColumn) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, modifyColumn) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *currentColumn = NULL, *sql = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *currentColumn = NULL, *sql, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, _3, *_4 = NULL, *_5;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 1, &tableName_param, &schemaName_param, &column, ¤tColumn);
@@ -51013,37 +51234,28 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, modifyColumn) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` MODIFY ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` MODIFY ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumndefinition", NULL, 0, column);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVSV(_3, "`", _1, "` ", _2);
- zephir_concat_self(&sql, _3 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(sql);
+ ZEPHIR_CONCAT_SVSVSV(sql, "ALTER TABLE ", _0, " MODIFY `", _1, "` ", _2);
ZEPHIR_CALL_METHOD(&defaultValue, column, "getdefault", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(defaultValue))) {
- ZEPHIR_SINIT_VAR(_4);
- ZVAL_STRING(&_4, "\"", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 141, defaultValue, &_4);
+ ZEPHIR_SINIT_VAR(_3);
+ ZVAL_STRING(&_3, "\"", 0);
+ ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 141, defaultValue, &_3);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_6);
- ZEPHIR_CONCAT_SVS(_6, " DEFAULT \"", _5, "\"");
- zephir_concat_self(&sql, _6 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_5);
+ ZEPHIR_CONCAT_SVS(_5, " DEFAULT \"", _4, "\"");
+ zephir_concat_self(&sql, _5 TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_5, column, "isnotnull", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, column, "isnotnull", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_5)) {
+ if (zephir_is_true(_4)) {
zephir_concat_self_str(&sql, SL(" NOT NULL") TSRMLS_CC);
}
RETURN_CCTOR(sql);
@@ -51052,8 +51264,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, modifyColumn) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropColumn) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *columnName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *columnName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *columnName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *columnName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &columnName_param);
@@ -51093,28 +51306,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropColumn) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` DROP COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` DROP COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", columnName, "`");
- zephir_concat_self(&sql, _0 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP COLUMN `", columnName, "`");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addIndex) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql = NULL, *indexType = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql, *indexType = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
@@ -51143,24 +51346,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addIndex) {
}
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSV(_0, "ALTER TABLE `", schemaName, "`.`", tableName);
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SV(_0, "ALTER TABLE `", tableName);
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CONCAT_SV(sql, "ALTER TABLE ", _0);
ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(indexType))) {
ZEPHIR_INIT_VAR(_1);
- ZEPHIR_CONCAT_SVS(_1, "` ADD ", indexType, " INDEX ");
+ ZEPHIR_CONCAT_SVS(_1, " ADD ", indexType, " INDEX ");
zephir_concat_self(&sql, _1 TSRMLS_CC);
} else {
- zephir_concat_self_str(&sql, SL("` ADD INDEX ") TSRMLS_CC);
+ zephir_concat_self_str(&sql, SL(" ADD INDEX ") TSRMLS_CC);
}
ZEPHIR_CALL_METHOD(&_2, index, "getname", NULL, 0);
zephir_check_call_status();
@@ -51177,8 +51374,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addIndex) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropIndex) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *indexName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *indexName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *indexName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *indexName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &indexName_param);
@@ -51218,28 +51416,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropIndex) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` DROP INDEX ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` DROP INDEX ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", indexName, "`");
- zephir_concat_self(&sql, _0 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP INDEX `", indexName, "`");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addPrimaryKey) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql = NULL, *_1 = NULL, *_2 = NULL, *_3;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *index, *_0 = NULL, *_1 = NULL, *_2 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
@@ -51268,31 +51456,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addPrimaryKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` ADD PRIMARY KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` ADD PRIMARY KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 43, _2);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVS(_3, "(", _1, ")");
- zephir_concat_self(&sql, _3 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " ADD PRIMARY KEY (", _1, ")");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropPrimaryKey) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 0, &tableName_param, &schemaName_param);
@@ -51321,25 +51500,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropPrimaryKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` DROP PRIMARY KEY");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` DROP PRIMARY KEY");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVS(return_value, "ALTER TABLE ", _0, " DROP PRIMARY KEY");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *reference, *sql = NULL, *referencedSchema = NULL, *onDelete = NULL, *onUpdate = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *reference, *sql, *onDelete = NULL, *onUpdate = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &reference);
@@ -51368,41 +51540,26 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` ADD FOREIGN KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` ADD FOREIGN KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, reference, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_3, reference, "getcolumns", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 43, _3);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_4);
- ZEPHIR_CONCAT_SVSVS(_4, "`", _1, "`(", _2, ") REFERENCES ");
- zephir_concat_self(&sql, _4 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&referencedSchema, reference, "getreferencedschema", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_5, reference, "getreferencedtable", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(referencedSchema)) {
- ZEPHIR_INIT_VAR(_5);
- ZEPHIR_CONCAT_SVS(_5, "`", referencedSchema, "`.");
- zephir_concat_self(&sql, _5 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_6, reference, "getreferencedtable", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_6, reference, "getreferencedschema", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "preparetable", NULL, 0, _5, _6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_8, reference, "getreferencedcolumns", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", NULL, 43, _8);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_5);
- ZEPHIR_CONCAT_SVSVS(_5, "`", _6, "`(", _7, ")");
- zephir_concat_self(&sql, _5 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(sql);
+ ZEPHIR_CONCAT_SVSVSVSVSVS(sql, "ALTER TABLE ", _0, " ADD FOREIGN KEY `", _1, "`(", _2, ") REFERENCES ", _4, "(", _7, ")");
ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onDelete))) {
@@ -51413,9 +51570,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) {
ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onUpdate))) {
- ZEPHIR_INIT_LNVAR(_5);
- ZEPHIR_CONCAT_SV(_5, " ON UPDATE ", onUpdate);
- zephir_concat_self(&sql, _5 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SV(_9, " ON UPDATE ", onUpdate);
+ zephir_concat_self(&sql, _9 TSRMLS_CC);
}
RETURN_CCTOR(sql);
@@ -51423,8 +51580,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropForeignKey) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *referenceName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *referenceName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *referenceName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *referenceName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &referenceName_param);
@@ -51464,30 +51622,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropForeignKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` DROP FOREIGN KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` DROP FOREIGN KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_CONCAT_VSVS(return_value, sql, "`", referenceName, "`");
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP FOREIGN KEY `", referenceName, "`");
RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) {
- zephir_fcall_cache_entry *_6 = NULL, *_9 = NULL, *_14 = NULL;
+ zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_13 = NULL;
+ HashTable *_1, *_11, *_17;
+ HashPosition _0, _10, _16;
int ZEPHIR_LAST_CALL_STATUS;
- HashTable *_2, *_12, *_18;
- HashPosition _1, _11, _17;
zval *definition = NULL;
- zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, **_3, *_4 = NULL, *_5 = NULL, _7 = zval_used_for_init, *_8 = NULL, *_10 = NULL, **_13, *_15 = NULL, *_16 = NULL, **_19, *_20 = NULL, *_21 = NULL, *_22;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, **_2, *_3 = NULL, *_4 = NULL, _6 = zval_used_for_init, *_7 = NULL, *_9 = NULL, **_12, *_14 = NULL, *_15 = NULL, **_18, *_19 = NULL, *_20 = NULL, *_21;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &definition_param);
@@ -51520,19 +51670,11 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) {
ZEPHIR_OBS_VAR(columns);
if (!(zephir_array_isset_string_fetch(&columns, definition, SS("columns"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'columns' is required in the definition array", "phalcon/db/dialect/mysql.zep", 424);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'columns' is required in the definition array", "phalcon/db/dialect/mysql.zep", 354);
return;
}
- ZEPHIR_INIT_VAR(table);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "`", schemaName, "`.`", tableName, "`");
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", tableName, "`");
- ZEPHIR_CPY_WRT(table, _0);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(temporary);
ZVAL_BOOL(temporary, 0);
ZEPHIR_OBS_VAR(options);
@@ -51548,134 +51690,134 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) {
}
ZEPHIR_INIT_VAR(createLines);
array_init(createLines);
- zephir_is_iterable(columns, &_2, &_1, 0, 0, "phalcon/db/dialect/mysql.zep", 487);
+ zephir_is_iterable(columns, &_1, &_0, 0, 0, "phalcon/db/dialect/mysql.zep", 413);
for (
- ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
- ; zephir_hash_move_forward_ex(_2, &_1)
+ ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
+ ; zephir_hash_move_forward_ex(_1, &_0)
) {
- ZEPHIR_GET_HVALUE(column, _3);
- ZEPHIR_CALL_METHOD(&_4, column, "getname", NULL, 0);
+ ZEPHIR_GET_HVALUE(column, _2);
+ ZEPHIR_CALL_METHOD(&_3, column, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumndefinition", &_6, 0, column);
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumndefinition", &_5, 0, column);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(columnLine);
- ZEPHIR_CONCAT_SVSV(columnLine, "`", _4, "` ", _5);
+ ZEPHIR_CONCAT_SVSV(columnLine, "`", _3, "` ", _4);
ZEPHIR_CALL_METHOD(&defaultValue, column, "getdefault", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(defaultValue))) {
- ZEPHIR_SINIT_NVAR(_7);
- ZVAL_STRING(&_7, "\"", 0);
- ZEPHIR_CALL_FUNCTION(&_8, "addcslashes", &_9, 141, defaultValue, &_7);
+ ZEPHIR_SINIT_NVAR(_6);
+ ZVAL_STRING(&_6, "\"", 0);
+ ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 141, defaultValue, &_6);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SVS(_10, " DEFAULT \"", _8, "\"");
- zephir_concat_self(&columnLine, _10 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, " DEFAULT \"", _7, "\"");
+ zephir_concat_self(&columnLine, _9 TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isnotnull", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isnotnull", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
zephir_concat_self_str(&columnLine, SL(" NOT NULL") TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isautoincrement", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isautoincrement", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
zephir_concat_self_str(&columnLine, SL(" AUTO_INCREMENT") TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isprimary", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isprimary", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
zephir_concat_self_str(&columnLine, SL(" PRIMARY KEY") TSRMLS_CC);
}
- zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 481);
+ zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 407);
}
ZEPHIR_OBS_VAR(indexes);
if (zephir_array_isset_string_fetch(&indexes, definition, SS("indexes"), 0 TSRMLS_CC)) {
- zephir_is_iterable(indexes, &_12, &_11, 0, 0, "phalcon/db/dialect/mysql.zep", 509);
+ zephir_is_iterable(indexes, &_11, &_10, 0, 0, "phalcon/db/dialect/mysql.zep", 435);
for (
- ; zephir_hash_get_current_data_ex(_12, (void**) &_13, &_11) == SUCCESS
- ; zephir_hash_move_forward_ex(_12, &_11)
+ ; zephir_hash_get_current_data_ex(_11, (void**) &_12, &_10) == SUCCESS
+ ; zephir_hash_move_forward_ex(_11, &_10)
) {
- ZEPHIR_GET_HVALUE(index, _13);
+ ZEPHIR_GET_HVALUE(index, _12);
ZEPHIR_CALL_METHOD(&indexName, index, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
zephir_check_call_status();
if (ZEPHIR_IS_STRING(indexName, "PRIMARY")) {
- ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_14, 43, _5);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_13, 43, _4);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(indexSql);
- ZEPHIR_CONCAT_SVS(indexSql, "PRIMARY KEY (", _4, ")");
+ ZEPHIR_CONCAT_SVS(indexSql, "PRIMARY KEY (", _3, ")");
} else {
ZEPHIR_INIT_NVAR(indexSql);
if (!(ZEPHIR_IS_EMPTY(indexType))) {
- ZEPHIR_CALL_METHOD(&_15, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_14, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, this_ptr, "getcolumnlist", &_14, 43, _15);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_13, 43, _14);
zephir_check_call_status();
- ZEPHIR_CONCAT_VSVSVS(indexSql, indexType, " KEY `", indexName, "` (", _8, ")");
+ ZEPHIR_CONCAT_VSVSVS(indexSql, indexType, " KEY `", indexName, "` (", _7, ")");
} else {
- ZEPHIR_CALL_METHOD(&_16, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_15, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", &_14, 43, _16);
+ ZEPHIR_CALL_METHOD(&_14, this_ptr, "getcolumnlist", &_13, 43, _15);
zephir_check_call_status();
- ZEPHIR_CONCAT_SVSVS(indexSql, "KEY `", indexName, "` (", _15, ")");
+ ZEPHIR_CONCAT_SVSVS(indexSql, "KEY `", indexName, "` (", _14, ")");
}
}
- zephir_array_append(&createLines, indexSql, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 507);
+ zephir_array_append(&createLines, indexSql, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 433);
}
}
ZEPHIR_OBS_VAR(references);
if (zephir_array_isset_string_fetch(&references, definition, SS("references"), 0 TSRMLS_CC)) {
- zephir_is_iterable(references, &_18, &_17, 0, 0, "phalcon/db/dialect/mysql.zep", 531);
+ zephir_is_iterable(references, &_17, &_16, 0, 0, "phalcon/db/dialect/mysql.zep", 457);
for (
- ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS
- ; zephir_hash_move_forward_ex(_18, &_17)
+ ; zephir_hash_get_current_data_ex(_17, (void**) &_18, &_16) == SUCCESS
+ ; zephir_hash_move_forward_ex(_17, &_16)
) {
- ZEPHIR_GET_HVALUE(reference, _19);
- ZEPHIR_CALL_METHOD(&_4, reference, "getname", NULL, 0);
+ ZEPHIR_GET_HVALUE(reference, _18);
+ ZEPHIR_CALL_METHOD(&_3, reference, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, reference, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, reference, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", &_14, 43, _8);
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_13, 43, _7);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_15, reference, "getreferencedtable", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_14, reference, "getreferencedtable", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_20, reference, "getreferencedcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_19, reference, "getreferencedcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_16, this_ptr, "getcolumnlist", &_14, 43, _20);
+ ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", &_13, 43, _19);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(referenceSql);
- ZEPHIR_CONCAT_SVSVSSVSVS(referenceSql, "CONSTRAINT `", _4, "` FOREIGN KEY (", _5, ")", " REFERENCES `", _15, "`(", _16, ")");
+ ZEPHIR_CONCAT_SVSVSSVSVS(referenceSql, "CONSTRAINT `", _3, "` FOREIGN KEY (", _4, ")", " REFERENCES `", _14, "`(", _15, ")");
ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onDelete))) {
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SV(_10, " ON DELETE ", onDelete);
- zephir_concat_self(&referenceSql, _10 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SV(_9, " ON DELETE ", onDelete);
+ zephir_concat_self(&referenceSql, _9 TSRMLS_CC);
}
ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onUpdate))) {
- ZEPHIR_INIT_LNVAR(_21);
- ZEPHIR_CONCAT_SV(_21, " ON UPDATE ", onUpdate);
- zephir_concat_self(&referenceSql, _21 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_20);
+ ZEPHIR_CONCAT_SV(_20, " ON UPDATE ", onUpdate);
+ zephir_concat_self(&referenceSql, _20 TSRMLS_CC);
}
- zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 529);
+ zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 455);
}
}
- ZEPHIR_INIT_VAR(_22);
- zephir_fast_join_str(_22, SL(",\n\t"), createLines TSRMLS_CC);
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_VS(_10, _22, "\n)");
- zephir_concat_self(&sql, _10 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_21);
+ zephir_fast_join_str(_21, SL(",\n\t"), createLines TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_VS(_9, _21, "\n)");
+ zephir_concat_self(&sql, _9 TSRMLS_CC);
if (zephir_array_isset_string(definition, SS("options"))) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "_gettableoptions", NULL, 0, definition);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_gettableoptions", NULL, 0, definition);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_21);
- ZEPHIR_CONCAT_SV(_21, " ", _4);
- zephir_concat_self(&sql, _21 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_20);
+ ZEPHIR_CONCAT_SV(_20, " ", _3);
+ zephir_concat_self(&sql, _20 TSRMLS_CC);
}
RETURN_CCTOR(sql);
@@ -51683,9 +51825,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropTable) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *sql, *table = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &tableName_param, &schemaName_param, &ifExists_param);
@@ -51719,16 +51862,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropTable) {
}
- ZEPHIR_INIT_VAR(table);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "`", schemaName, "`.`", tableName, "`");
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", tableName, "`");
- ZEPHIR_CPY_WRT(table, _0);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
ZEPHIR_CONCAT_SV(sql, "DROP TABLE IF EXISTS ", table);
@@ -51741,9 +51876,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropTable) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zval *definition = NULL;
- zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *view = NULL, *viewSql;
- zval *viewName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *_0 = NULL;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 1, &viewName_param, &definition_param, &schemaName_param);
@@ -51771,29 +51907,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createView) {
ZEPHIR_OBS_VAR(viewSql);
if (!(zephir_array_isset_string_fetch(&viewSql, definition, SS("sql"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/mysql.zep", 571);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/mysql.zep", 493);
return;
}
- ZEPHIR_INIT_VAR(view);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "`", schemaName, "`.`", viewName, "`");
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", viewName, "`");
- ZEPHIR_CPY_WRT(view, _0);
- }
- ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", view, " AS ", viewSql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", _0, " AS ", viewSql);
RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *sql, *view = NULL;
- zval *viewName = NULL, *schemaName = NULL, *_0;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &viewName_param, &schemaName_param, &ifExists_param);
@@ -51827,13 +51956,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropView) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_VSV(_0, schemaName, ".", viewName);
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_CPY_WRT(view, viewName);
- }
+ ZEPHIR_CALL_METHOD(&view, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
ZEPHIR_CONCAT_SV(sql, "DROP VIEW IF EXISTS ", view);
@@ -51918,7 +52042,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, viewExists) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, describeColumns) {
- zval *table_param = NULL, *schema_param = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *table_param = NULL, *schema_param = NULL, *_0 = NULL;
zval *table = NULL, *schema = NULL;
ZEPHIR_MM_GROW();
@@ -51943,11 +52068,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, describeColumns) {
}
- if (schema && Z_STRLEN_P(schema)) {
- ZEPHIR_CONCAT_SVSVS(return_value, "DESCRIBE `", schema, "`.`", table, "`");
- RETURN_MM();
- }
- ZEPHIR_CONCAT_SVS(return_value, "DESCRIBE `", table, "`");
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, table, schema);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SV(return_value, "DESCRIBE ", _0);
RETURN_MM();
}
@@ -52012,7 +52135,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, listViews) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, describeIndexes) {
- zval *table_param = NULL, *schema_param = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *table_param = NULL, *schema_param = NULL, *_0 = NULL;
zval *table = NULL, *schema = NULL;
ZEPHIR_MM_GROW();
@@ -52037,11 +52161,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, describeIndexes) {
}
- if (schema && Z_STRLEN_P(schema)) {
- ZEPHIR_CONCAT_SVSVS(return_value, "SHOW INDEXES FROM `", schema, "`.`", table, "`");
- RETURN_MM();
- }
- ZEPHIR_CONCAT_SVS(return_value, "SHOW INDEXES FROM `", table, "`");
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, table, schema);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SV(return_value, "SHOW INDEXES FROM ", _0);
RETURN_MM();
}
@@ -52147,7 +52269,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, _getTableOptions) {
if (zephir_is_true(engine)) {
ZEPHIR_INIT_VAR(_0);
ZEPHIR_CONCAT_SV(_0, "ENGINE=", engine);
- zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 727);
+ zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 633);
}
}
ZEPHIR_OBS_VAR(autoIncrement);
@@ -52155,7 +52277,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, _getTableOptions) {
if (zephir_is_true(autoIncrement)) {
ZEPHIR_INIT_LNVAR(_0);
ZEPHIR_CONCAT_SV(_0, "AUTO_INCREMENT=", autoIncrement);
- zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 736);
+ zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 642);
}
}
ZEPHIR_OBS_VAR(tableCollation);
@@ -52163,13 +52285,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, _getTableOptions) {
if (zephir_is_true(tableCollation)) {
ZEPHIR_INIT_VAR(collationParts);
zephir_fast_explode_str(collationParts, SL("_"), tableCollation, LONG_MAX TSRMLS_CC);
- zephir_array_fetch_long(&_1, collationParts, 0, PH_NOISY | PH_READONLY, "phalcon/db/dialect/mysql.zep", 746 TSRMLS_CC);
+ zephir_array_fetch_long(&_1, collationParts, 0, PH_NOISY | PH_READONLY, "phalcon/db/dialect/mysql.zep", 652 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_0);
ZEPHIR_CONCAT_SV(_0, "DEFAULT CHARSET=", _1);
- zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 746);
+ zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 652);
ZEPHIR_INIT_VAR(_2);
ZEPHIR_CONCAT_SV(_2, "COLLATE=", tableCollation);
- zephir_array_append(&tableOptions, _2, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 747);
+ zephir_array_append(&tableOptions, _2, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 653);
}
}
if (zephir_fast_count_int(tableOptions TSRMLS_CC)) {
@@ -52719,9 +52841,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, createTable) {
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropTable) {
int ZEPHIR_LAST_CALL_STATUS;
- zephir_fcall_cache_entry *_2 = NULL;
zend_bool ifExists;
- zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *table = NULL, *_0 = NULL, *_1 = NULL, *_3 = NULL, *_4 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *table = NULL;
zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
@@ -52761,23 +52882,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropTable) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_CALL_CE_STATIC(&_1, phalcon_text_ce, "upper", &_2, 142, schemaName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", NULL, 42, _1);
- zephir_check_call_status();
- ZEPHIR_CALL_CE_STATIC(&_4, phalcon_text_ce, "upper", &_2, 142, tableName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "escape", NULL, 42, _4);
- zephir_check_call_status();
- ZEPHIR_INIT_VAR(table);
- ZEPHIR_CONCAT_VSV(table, _0, ".", _3);
- } else {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_2, 142, tableName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&table, this_ptr, "escape", NULL, 42, _0);
- zephir_check_call_status();
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
if (ifExists) {
ZEPHIR_CONCAT_SV(return_value, "DROP TABLE IF EXISTS ", table);
RETURN_MM();
@@ -52790,9 +52896,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropTable) {
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, createView) {
int ZEPHIR_LAST_CALL_STATUS;
- zephir_fcall_cache_entry *_1 = NULL;
zval *definition = NULL;
- zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *view = NULL, *viewSql, *_0 = NULL, *_2 = NULL, *_3;
+ zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *_0 = NULL;
zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
@@ -52821,25 +52926,12 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, createView) {
ZEPHIR_OBS_VAR(viewSql);
if (!(zephir_array_isset_string_fetch(&viewSql, definition, SS("sql"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/oracle.zep", 234);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/oracle.zep", 230);
return;
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schemaName);
- zephir_check_call_status();
- ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, viewName);
- zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_VSV(_3, _0, ".", _2);
- ZEPHIR_CALL_METHOD(&view, this_ptr, "escape", NULL, 42, _3);
- zephir_check_call_status();
- } else {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, viewName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&view, this_ptr, "escape", NULL, 42, _0);
- zephir_check_call_status();
- }
- ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", view, " AS ", viewSql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", _0, " AS ", viewSql);
RETURN_MM();
}
@@ -52847,9 +52939,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, createView) {
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropView) {
int ZEPHIR_LAST_CALL_STATUS;
- zephir_fcall_cache_entry *_1 = NULL;
zend_bool ifExists;
- zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *view = NULL, *_0 = NULL, *_2 = NULL, *_3;
+ zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *view = NULL;
zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
@@ -52884,21 +52975,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropView) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schemaName);
- zephir_check_call_status();
- ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, viewName);
- zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_VSV(_3, _0, ".", _2);
- ZEPHIR_CALL_METHOD(&view, this_ptr, "escape", NULL, 42, _3);
- zephir_check_call_status();
- } else {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, viewName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&view, this_ptr, "escape", NULL, 42, _0);
- zephir_check_call_status();
- }
+ ZEPHIR_CALL_METHOD(&view, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
if (ifExists) {
ZEPHIR_CONCAT_SV(return_value, "DROP VIEW IF EXISTS ", view);
RETURN_MM();
@@ -53235,6 +53313,57 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, supportsReleaseSavepoints) {
}
+static PHP_METHOD(Phalcon_Db_Dialect_Oracle, prepareTable) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zephir_fcall_cache_entry *_0 = NULL, *_2 = NULL;
+ zval *table_param = NULL, *schema_param = NULL, *alias_param = NULL, *escapeChar_param = NULL, *_1 = NULL, *_3 = NULL;
+ zval *table = NULL, *schema = NULL, *alias = NULL, *escapeChar = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 3, &table_param, &schema_param, &alias_param, &escapeChar_param);
+
+ if (unlikely(Z_TYPE_P(table_param) != IS_STRING && Z_TYPE_P(table_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'table' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(table_param) == IS_STRING)) {
+ zephir_get_strval(table, table_param);
+ } else {
+ ZEPHIR_INIT_VAR(table);
+ ZVAL_EMPTY_STRING(table);
+ }
+ if (!schema_param) {
+ ZEPHIR_INIT_VAR(schema);
+ ZVAL_EMPTY_STRING(schema);
+ } else {
+ zephir_get_strval(schema, schema_param);
+ }
+ if (!alias_param) {
+ ZEPHIR_INIT_VAR(alias);
+ ZVAL_EMPTY_STRING(alias);
+ } else {
+ zephir_get_strval(alias, alias_param);
+ }
+ if (!escapeChar_param) {
+ ZEPHIR_INIT_VAR(escapeChar);
+ ZVAL_EMPTY_STRING(escapeChar);
+ } else {
+ zephir_get_strval(escapeChar, escapeChar_param);
+ }
+
+
+ ZEPHIR_CALL_CE_STATIC(&_1, phalcon_text_ce, "upper", &_2, 142, table);
+ zephir_check_call_status();
+ ZEPHIR_CALL_CE_STATIC(&_3, phalcon_text_ce, "upper", &_2, 142, schema);
+ zephir_check_call_status();
+ ZEPHIR_RETURN_CALL_PARENT(phalcon_db_dialect_oracle_ce, this_ptr, "preparetable", &_0, 143, _1, _3, alias, escapeChar);
+ zephir_check_call_status();
+ RETURN_MM();
+
+}
+
@@ -53432,8 +53561,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, getColumnDefinition) {
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addColumn) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *sql = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *sql, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &column);
@@ -53462,16 +53591,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addColumn) {
}
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\" ADD COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\" ADD COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CONCAT_SVS(sql, "ALTER TABLE ", _0, " ADD COLUMN ");
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumndefinition", NULL, 0, column);
@@ -53503,8 +53626,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, modifyColumn) {
zend_bool _10;
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *currentColumn = NULL, *sql, *sqlAlterTable = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9 = NULL, _11, *_12 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *currentColumn = NULL, *sql, *sqlAlterTable, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9 = NULL, _11, *_12 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 1, &tableName_param, &schemaName_param, &column, ¤tColumn);
@@ -53538,16 +53661,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, modifyColumn) {
ZVAL_STRING(sql, "", 1);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sqlAlterTable);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(sqlAlterTable, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\"");
- ZEPHIR_CPY_WRT(sqlAlterTable, _0);
- }
+ ZEPHIR_CONCAT_SV(sqlAlterTable, "ALTER TABLE ", _0);
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, currentColumn, "getname", NULL, 0);
@@ -53635,8 +53752,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, modifyColumn) {
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropColumn) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *columnName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *columnName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *columnName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *columnName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &columnName_param);
@@ -53676,150 +53794,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropColumn) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\" ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\" ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, " DROP COLUMN \"", columnName, "\"");
- zephir_concat_self(&sql, _0 TSRMLS_CC);
- RETURN_CCTOR(sql);
-
-}
-
-static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addIndex) {
-
- int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql, *indexType = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_4 = NULL, *_5 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_3 = NULL;
-
- ZEPHIR_MM_GROW();
- zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
-
- if (unlikely(Z_TYPE_P(tableName_param) != IS_STRING && Z_TYPE_P(tableName_param) != IS_NULL)) {
- zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'tableName' must be a string") TSRMLS_CC);
- RETURN_MM_NULL();
- }
-
- if (likely(Z_TYPE_P(tableName_param) == IS_STRING)) {
- zephir_get_strval(tableName, tableName_param);
- } else {
- ZEPHIR_INIT_VAR(tableName);
- ZVAL_EMPTY_STRING(tableName);
- }
- if (unlikely(Z_TYPE_P(schemaName_param) != IS_STRING && Z_TYPE_P(schemaName_param) != IS_NULL)) {
- zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'schemaName' must be a string") TSRMLS_CC);
- RETURN_MM_NULL();
- }
-
- if (likely(Z_TYPE_P(schemaName_param) == IS_STRING)) {
- zephir_get_strval(schemaName, schemaName_param);
- } else {
- ZEPHIR_INIT_VAR(schemaName);
- ZVAL_EMPTY_STRING(schemaName);
- }
-
-
- ZEPHIR_CALL_METHOD(&_0, index, "getname", NULL, 0);
- zephir_check_call_status();
- if (ZEPHIR_IS_STRING_IDENTICAL(_0, "PRIMARY")) {
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "addprimarykey", NULL, 0, tableName, schemaName, index);
- zephir_check_call_status();
- RETURN_MM();
- }
- ZEPHIR_INIT_VAR(sql);
- ZVAL_STRING(sql, "CREATE", 1);
- ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
- zephir_check_call_status();
- if (!(ZEPHIR_IS_EMPTY(indexType))) {
- ZEPHIR_INIT_VAR(_1);
- ZEPHIR_CONCAT_SV(_1, " ", indexType);
- zephir_concat_self(&sql, _1 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_2, index, "getname", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_1);
- ZEPHIR_CONCAT_SVS(_1, " INDEX \"", _2, "\" ON");
- zephir_concat_self(&sql, _1 TSRMLS_CC);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVSVS(_3, " \"", schemaName, "\".\"", tableName, "\"");
- zephir_concat_self(&sql, _3 TSRMLS_CC);
- } else {
- ZEPHIR_INIT_LNVAR(_3);
- ZEPHIR_CONCAT_SVS(_3, " \"", tableName, "\"");
- zephir_concat_self(&sql, _3 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 43, _5);
- zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_1);
- ZEPHIR_CONCAT_SVS(_1, " (", _4, ")");
- zephir_concat_self(&sql, _1 TSRMLS_CC);
- RETURN_CCTOR(sql);
-
-}
-
-static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropIndex) {
-
- zval *tableName_param = NULL, *schemaName_param = NULL, *indexName_param = NULL;
- zval *tableName = NULL, *schemaName = NULL, *indexName = NULL;
-
- ZEPHIR_MM_GROW();
- zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &indexName_param);
-
- if (unlikely(Z_TYPE_P(tableName_param) != IS_STRING && Z_TYPE_P(tableName_param) != IS_NULL)) {
- zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'tableName' must be a string") TSRMLS_CC);
- RETURN_MM_NULL();
- }
-
- if (likely(Z_TYPE_P(tableName_param) == IS_STRING)) {
- zephir_get_strval(tableName, tableName_param);
- } else {
- ZEPHIR_INIT_VAR(tableName);
- ZVAL_EMPTY_STRING(tableName);
- }
- if (unlikely(Z_TYPE_P(schemaName_param) != IS_STRING && Z_TYPE_P(schemaName_param) != IS_NULL)) {
- zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'schemaName' must be a string") TSRMLS_CC);
- RETURN_MM_NULL();
- }
-
- if (likely(Z_TYPE_P(schemaName_param) == IS_STRING)) {
- zephir_get_strval(schemaName, schemaName_param);
- } else {
- ZEPHIR_INIT_VAR(schemaName);
- ZVAL_EMPTY_STRING(schemaName);
- }
- if (unlikely(Z_TYPE_P(indexName_param) != IS_STRING && Z_TYPE_P(indexName_param) != IS_NULL)) {
- zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'indexName' must be a string") TSRMLS_CC);
- RETURN_MM_NULL();
- }
-
- if (likely(Z_TYPE_P(indexName_param) == IS_STRING)) {
- zephir_get_strval(indexName, indexName_param);
- } else {
- ZEPHIR_INIT_VAR(indexName);
- ZVAL_EMPTY_STRING(indexName);
- }
-
-
- ZEPHIR_CONCAT_SVS(return_value, "DROP INDEX \"", indexName, "\"");
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP COLUMN \"", columnName, "\"");
RETURN_MM();
}
-static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addPrimaryKey) {
+static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addIndex) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql = NULL, *_1 = NULL, *_2 = NULL, *_3;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql, *indexType = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
@@ -53848,31 +53834,137 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addPrimaryKey) {
}
+ ZEPHIR_CALL_METHOD(&_0, index, "getname", NULL, 0);
+ zephir_check_call_status();
+ if (ZEPHIR_IS_STRING_IDENTICAL(_0, "PRIMARY")) {
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "addprimarykey", NULL, 0, tableName, schemaName, index);
+ zephir_check_call_status();
+ RETURN_MM();
+ }
ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
+ ZVAL_STRING(sql, "CREATE", 1);
+ ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
+ zephir_check_call_status();
+ if (!(ZEPHIR_IS_EMPTY(indexType))) {
+ ZEPHIR_INIT_VAR(_1);
+ ZEPHIR_CONCAT_SV(_1, " ", indexType);
+ zephir_concat_self(&sql, _1 TSRMLS_CC);
+ }
+ ZEPHIR_CALL_METHOD(&_2, index, "getname", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_INIT_LNVAR(_1);
+ ZEPHIR_CONCAT_SVSV(_1, " INDEX \"", _2, "\" ON ", _3);
+ zephir_concat_self(&sql, _1 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 43, _5);
+ zephir_check_call_status();
+ ZEPHIR_INIT_VAR(_6);
+ ZEPHIR_CONCAT_SVS(_6, " (", _4, ")");
+ zephir_concat_self(&sql, _6 TSRMLS_CC);
+ RETURN_CCTOR(sql);
+
+}
+
+static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropIndex) {
+
+ zval *tableName_param = NULL, *schemaName_param = NULL, *indexName_param = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *indexName = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &indexName_param);
+
+ if (unlikely(Z_TYPE_P(tableName_param) != IS_STRING && Z_TYPE_P(tableName_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'tableName' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(tableName_param) == IS_STRING)) {
+ zephir_get_strval(tableName, tableName_param);
} else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
+ ZEPHIR_INIT_VAR(tableName);
+ ZVAL_EMPTY_STRING(tableName);
}
+ if (unlikely(Z_TYPE_P(schemaName_param) != IS_STRING && Z_TYPE_P(schemaName_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'schemaName' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(schemaName_param) == IS_STRING)) {
+ zephir_get_strval(schemaName, schemaName_param);
+ } else {
+ ZEPHIR_INIT_VAR(schemaName);
+ ZVAL_EMPTY_STRING(schemaName);
+ }
+ if (unlikely(Z_TYPE_P(indexName_param) != IS_STRING && Z_TYPE_P(indexName_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'indexName' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(indexName_param) == IS_STRING)) {
+ zephir_get_strval(indexName, indexName_param);
+ } else {
+ ZEPHIR_INIT_VAR(indexName);
+ ZVAL_EMPTY_STRING(indexName);
+ }
+
+
+ ZEPHIR_CONCAT_SVS(return_value, "DROP INDEX \"", indexName, "\"");
+ RETURN_MM();
+
+}
+
+static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addPrimaryKey) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *index, *_0 = NULL, *_1 = NULL, *_2 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
+
+ if (unlikely(Z_TYPE_P(tableName_param) != IS_STRING && Z_TYPE_P(tableName_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'tableName' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(tableName_param) == IS_STRING)) {
+ zephir_get_strval(tableName, tableName_param);
+ } else {
+ ZEPHIR_INIT_VAR(tableName);
+ ZVAL_EMPTY_STRING(tableName);
+ }
+ if (unlikely(Z_TYPE_P(schemaName_param) != IS_STRING && Z_TYPE_P(schemaName_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'schemaName' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(schemaName_param) == IS_STRING)) {
+ zephir_get_strval(schemaName, schemaName_param);
+ } else {
+ ZEPHIR_INIT_VAR(schemaName);
+ ZVAL_EMPTY_STRING(schemaName);
+ }
+
+
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 43, _2);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVS(_3, " ADD CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _1, ")");
- zephir_concat_self(&sql, _3 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " ADD CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _1, ")");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropPrimaryKey) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 0, &tableName_param, &schemaName_param);
@@ -53901,26 +53993,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropPrimaryKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- zephir_concat_self_str(&sql, SL(" DROP CONSTRAINT \"PRIMARY\"") TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVS(return_value, "ALTER TABLE ", _0, " DROP CONSTRAINT \"PRIMARY\"");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *reference, *sql = NULL, *onDelete = NULL, *onUpdate = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7, *_8 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *reference, *sql, *onDelete = NULL, *onUpdate = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &reference);
@@ -53949,16 +54033,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\" ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\" ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, reference, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_3, reference, "getcolumns", NULL, 0);
@@ -53971,22 +54047,21 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", NULL, 43, _6);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_7);
- ZEPHIR_CONCAT_SVSVSSVSVS(_7, "ADD CONSTRAINT \"", _1, "\" FOREIGN KEY (", _2, ")", " REFERENCES \"", _4, "\" (", _5, ")");
- zephir_concat_self(&sql, _7 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(sql);
+ ZEPHIR_CONCAT_SVSVSVSSVSVS(sql, "ALTER TABLE ", _0, " ADD CONSTRAINT \"", _1, "\" FOREIGN KEY (", _2, ")", " REFERENCES \"", _4, "\" (", _5, ")");
ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onDelete))) {
- ZEPHIR_INIT_VAR(_8);
- ZEPHIR_CONCAT_SV(_8, " ON DELETE ", onDelete);
- zephir_concat_self(&sql, _8 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_7);
+ ZEPHIR_CONCAT_SV(_7, " ON DELETE ", onDelete);
+ zephir_concat_self(&sql, _7 TSRMLS_CC);
}
ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onUpdate))) {
- ZEPHIR_INIT_LNVAR(_8);
- ZEPHIR_CONCAT_SV(_8, " ON UPDATE ", onUpdate);
- zephir_concat_self(&sql, _8 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_7);
+ ZEPHIR_CONCAT_SV(_7, " ON UPDATE ", onUpdate);
+ zephir_concat_self(&sql, _7 TSRMLS_CC);
}
RETURN_CCTOR(sql);
@@ -53994,8 +54069,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) {
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropForeignKey) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *referenceName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *referenceName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *referenceName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *referenceName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &referenceName_param);
@@ -54035,32 +54111,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropForeignKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, " DROP CONSTRAINT \"", referenceName, "\"");
- zephir_concat_self(&sql, _0 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP CONSTRAINT \"", referenceName, "\"");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) {
- zephir_fcall_cache_entry *_6 = NULL, *_9 = NULL, *_17 = NULL;
+ zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_16 = NULL;
+ HashTable *_1, *_14, *_23;
+ HashPosition _0, _13, _22;
int ZEPHIR_LAST_CALL_STATUS;
- HashTable *_2, *_15, *_24;
- HashPosition _1, _14, _23;
zval *definition = NULL;
- zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *indexSqlAfterCreate, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, *primaryColumns, **_3, *_4 = NULL, *_5 = NULL, _7 = zval_used_for_init, *_8 = NULL, *_10 = NULL, *_11 = NULL, *_12 = NULL, *_13 = NULL, **_16, *_18 = NULL, *_20 = NULL, *_21 = NULL, *_22 = NULL, **_25, *_26 = NULL, *_27;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL, *_19 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *indexSqlAfterCreate, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, *primaryColumns, **_2, *_3 = NULL, *_4 = NULL, _6 = zval_used_for_init, *_7 = NULL, *_9 = NULL, *_10 = NULL, *_11 = NULL, *_12 = NULL, **_15, *_17 = NULL, *_18 = NULL, *_19 = NULL, *_20 = NULL, *_21 = NULL, **_24, *_25 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &definition_param);
@@ -54093,19 +54159,11 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) {
ZEPHIR_OBS_VAR(columns);
if (!(zephir_array_isset_string_fetch(&columns, definition, SS("columns"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'columns' is required in the definition array", "phalcon/db/dialect/postgresql.zep", 383);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'columns' is required in the definition array", "phalcon/db/dialect/postgresql.zep", 327);
return;
}
- ZEPHIR_INIT_VAR(table);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "\"", tableName, "\"");
- ZEPHIR_CPY_WRT(table, _0);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(temporary);
ZVAL_BOOL(temporary, 0);
ZEPHIR_OBS_VAR(options);
@@ -54123,64 +54181,64 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) {
array_init(createLines);
ZEPHIR_INIT_VAR(primaryColumns);
array_init(primaryColumns);
- zephir_is_iterable(columns, &_2, &_1, 0, 0, "phalcon/db/dialect/postgresql.zep", 443);
+ zephir_is_iterable(columns, &_1, &_0, 0, 0, "phalcon/db/dialect/postgresql.zep", 383);
for (
- ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
- ; zephir_hash_move_forward_ex(_2, &_1)
+ ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
+ ; zephir_hash_move_forward_ex(_1, &_0)
) {
- ZEPHIR_GET_HVALUE(column, _3);
- ZEPHIR_CALL_METHOD(&_4, column, "getname", NULL, 0);
+ ZEPHIR_GET_HVALUE(column, _2);
+ ZEPHIR_CALL_METHOD(&_3, column, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumndefinition", &_6, 0, column);
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumndefinition", &_5, 0, column);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(columnLine);
- ZEPHIR_CONCAT_SVSV(columnLine, "\"", _4, "\" ", _5);
+ ZEPHIR_CONCAT_SVSV(columnLine, "\"", _3, "\" ", _4);
ZEPHIR_CALL_METHOD(&defaultValue, column, "getdefault", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(defaultValue))) {
- ZEPHIR_SINIT_NVAR(_7);
- ZVAL_STRING(&_7, "\"", 0);
- ZEPHIR_CALL_FUNCTION(&_8, "addcslashes", &_9, 141, defaultValue, &_7);
+ ZEPHIR_SINIT_NVAR(_6);
+ ZVAL_STRING(&_6, "\"", 0);
+ ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 141, defaultValue, &_6);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SVS(_10, " DEFAULT \"", _8, "\"");
- zephir_concat_self(&columnLine, _10 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, " DEFAULT \"", _7, "\"");
+ zephir_concat_self(&columnLine, _9 TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isnotnull", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isnotnull", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
zephir_concat_self_str(&columnLine, SL(" NOT NULL") TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isautoincrement", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isautoincrement", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
}
- ZEPHIR_CALL_METHOD(&_11, column, "isprimary", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_10, column, "isprimary", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_11)) {
- ZEPHIR_CALL_METHOD(&_12, column, "getname", NULL, 0);
+ if (zephir_is_true(_10)) {
+ ZEPHIR_CALL_METHOD(&_11, column, "getname", NULL, 0);
zephir_check_call_status();
- zephir_array_append(&primaryColumns, _12, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 438);
+ zephir_array_append(&primaryColumns, _11, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 378);
}
- zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 441);
+ zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 381);
}
if (!(ZEPHIR_IS_EMPTY(primaryColumns))) {
- ZEPHIR_INIT_VAR(_13);
- zephir_fast_join_str(_13, SL(","), primaryColumns TSRMLS_CC);
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SVS(_10, "PRIMARY KEY (", _13, ")");
- zephir_array_append(&createLines, _10, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 444);
+ ZEPHIR_INIT_VAR(_12);
+ zephir_fast_join_str(_12, SL(","), primaryColumns TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, "PRIMARY KEY (", _12, ")");
+ zephir_array_append(&createLines, _9, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 384);
}
ZEPHIR_INIT_VAR(indexSqlAfterCreate);
ZVAL_STRING(indexSqlAfterCreate, "", 1);
ZEPHIR_OBS_VAR(indexes);
if (zephir_array_isset_string_fetch(&indexes, definition, SS("indexes"), 0 TSRMLS_CC)) {
- zephir_is_iterable(indexes, &_15, &_14, 0, 0, "phalcon/db/dialect/postgresql.zep", 484);
+ zephir_is_iterable(indexes, &_14, &_13, 0, 0, "phalcon/db/dialect/postgresql.zep", 418);
for (
- ; zephir_hash_get_current_data_ex(_15, (void**) &_16, &_14) == SUCCESS
- ; zephir_hash_move_forward_ex(_15, &_14)
+ ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS
+ ; zephir_hash_move_forward_ex(_14, &_13)
) {
- ZEPHIR_GET_HVALUE(index, _16);
+ ZEPHIR_GET_HVALUE(index, _15);
ZEPHIR_CALL_METHOD(&indexName, index, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
@@ -54188,126 +54246,112 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) {
ZEPHIR_INIT_NVAR(indexSql);
ZVAL_STRING(indexSql, "", 1);
if (ZEPHIR_IS_STRING(indexName, "PRIMARY")) {
- ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_17, 43, _5);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_16, 43, _4);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(indexSql);
- ZEPHIR_CONCAT_SVS(indexSql, "CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _4, ")");
+ ZEPHIR_CONCAT_SVS(indexSql, "CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _3, ")");
} else {
if (!(ZEPHIR_IS_EMPTY(indexType))) {
- ZEPHIR_CALL_METHOD(&_11, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_10, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, this_ptr, "getcolumnlist", &_17, 43, _11);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_16, 43, _10);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(indexSql);
- ZEPHIR_CONCAT_SVSVSVS(indexSql, "CONSTRAINT \"", indexName, "\" ", indexType, " (", _8, ")");
+ ZEPHIR_CONCAT_SVSVSVS(indexSql, "CONSTRAINT \"", indexName, "\" ", indexType, " (", _7, ")");
} else {
- ZEPHIR_CALL_METHOD(&_12, index, "getname", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_11, index, "getname", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_17, this_ptr, "preparetable", NULL, 143, tableName, schemaName);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_18);
- ZEPHIR_CONCAT_SVS(_18, "CREATE INDEX \"", _12, "\" ON ");
+ ZEPHIR_CONCAT_SVSV(_18, "CREATE INDEX \"", _11, "\" ON ", _17);
zephir_concat_self(&indexSqlAfterCreate, _18 TSRMLS_CC);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", tableName, "\"");
- zephir_concat_self(&indexSqlAfterCreate, _0 TSRMLS_CC);
- } else {
- ZEPHIR_INIT_LNVAR(_19);
- ZEPHIR_CONCAT_SVS(_19, "\"", tableName, "\"");
- zephir_concat_self(&indexSqlAfterCreate, _19 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_21, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_20, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_20, this_ptr, "getcolumnlist", &_17, 43, _21);
+ ZEPHIR_CALL_METHOD(&_19, this_ptr, "getcolumnlist", &_16, 43, _20);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_22);
- ZEPHIR_CONCAT_SVS(_22, " (", _20, ");");
- zephir_concat_self(&indexSqlAfterCreate, _22 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_21);
+ ZEPHIR_CONCAT_SVS(_21, " (", _19, ");");
+ zephir_concat_self(&indexSqlAfterCreate, _21 TSRMLS_CC);
}
}
if (!(ZEPHIR_IS_EMPTY(indexSql))) {
- zephir_array_append(&createLines, indexSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 481);
+ zephir_array_append(&createLines, indexSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 415);
}
}
}
ZEPHIR_OBS_VAR(references);
if (zephir_array_isset_string_fetch(&references, definition, SS("references"), 0 TSRMLS_CC)) {
- zephir_is_iterable(references, &_24, &_23, 0, 0, "phalcon/db/dialect/postgresql.zep", 513);
+ zephir_is_iterable(references, &_23, &_22, 0, 0, "phalcon/db/dialect/postgresql.zep", 443);
for (
- ; zephir_hash_get_current_data_ex(_24, (void**) &_25, &_23) == SUCCESS
- ; zephir_hash_move_forward_ex(_24, &_23)
+ ; zephir_hash_get_current_data_ex(_23, (void**) &_24, &_22) == SUCCESS
+ ; zephir_hash_move_forward_ex(_23, &_22)
) {
- ZEPHIR_GET_HVALUE(reference, _25);
- ZEPHIR_CALL_METHOD(&_4, reference, "getname", NULL, 0);
+ ZEPHIR_GET_HVALUE(reference, _24);
+ ZEPHIR_CALL_METHOD(&_3, reference, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, reference, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, reference, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", &_17, 43, _8);
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_16, 43, _7);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(referenceSql);
- ZEPHIR_CONCAT_SVSVS(referenceSql, "CONSTRAINT \"", _4, "\" FOREIGN KEY (", _5, ") REFERENCES ");
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_CALL_METHOD(&_11, reference, "getreferencedtable", NULL, 0);
- zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SVSVS(_10, "\"", schemaName, "\".\"", _11, "\" ");
- zephir_concat_self(&referenceSql, _10 TSRMLS_CC);
- } else {
- ZEPHIR_CALL_METHOD(&_12, reference, "getreferencedtable", NULL, 0);
- zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_18);
- ZEPHIR_CONCAT_SVS(_18, "\"", _12, "\" ");
- zephir_concat_self(&referenceSql, _18 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_21, reference, "getreferencedcolumns", NULL, 0);
+ ZEPHIR_CONCAT_SVSVS(referenceSql, "CONSTRAINT \"", _3, "\" FOREIGN KEY (", _4, ") REFERENCES ");
+ ZEPHIR_CALL_METHOD(&_11, reference, "getreferencedtable", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_10, this_ptr, "preparetable", NULL, 143, _11, schemaName);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_20, this_ptr, "getcolumnlist", &_17, 43, _21);
+ zephir_concat_self(&referenceSql, _10 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_19, reference, "getreferencedcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_22);
- ZEPHIR_CONCAT_SVS(_22, "(", _20, ")");
- zephir_concat_self(&referenceSql, _22 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_17, this_ptr, "getcolumnlist", &_16, 43, _19);
+ zephir_check_call_status();
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, " (", _17, ")");
+ zephir_concat_self(&referenceSql, _9 TSRMLS_CC);
ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onDelete))) {
- ZEPHIR_INIT_LNVAR(_26);
- ZEPHIR_CONCAT_SV(_26, " ON DELETE ", onDelete);
- zephir_concat_self(&referenceSql, _26 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_18);
+ ZEPHIR_CONCAT_SV(_18, " ON DELETE ", onDelete);
+ zephir_concat_self(&referenceSql, _18 TSRMLS_CC);
}
ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onUpdate))) {
- ZEPHIR_INIT_LNVAR(_26);
- ZEPHIR_CONCAT_SV(_26, " ON UPDATE ", onUpdate);
- zephir_concat_self(&referenceSql, _26 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_21);
+ ZEPHIR_CONCAT_SV(_21, " ON UPDATE ", onUpdate);
+ zephir_concat_self(&referenceSql, _21 TSRMLS_CC);
}
- zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 511);
+ zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 441);
}
}
- ZEPHIR_INIT_NVAR(_13);
- zephir_fast_join_str(_13, SL(",\n\t"), createLines TSRMLS_CC);
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_VS(_10, _13, "\n)");
- zephir_concat_self(&sql, _10 TSRMLS_CC);
+ ZEPHIR_INIT_NVAR(_12);
+ zephir_fast_join_str(_12, SL(",\n\t"), createLines TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_VS(_9, _12, "\n)");
+ zephir_concat_self(&sql, _9 TSRMLS_CC);
if (zephir_array_isset_string(definition, SS("options"))) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "_gettableoptions", NULL, 0, definition);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_gettableoptions", NULL, 0, definition);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_26);
- ZEPHIR_CONCAT_SV(_26, " ", _4);
- zephir_concat_self(&sql, _26 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_25);
+ ZEPHIR_CONCAT_SV(_25, " ", _3);
+ zephir_concat_self(&sql, _25 TSRMLS_CC);
}
- ZEPHIR_INIT_VAR(_27);
- ZEPHIR_CONCAT_SV(_27, ";", indexSqlAfterCreate);
- zephir_concat_self(&sql, _27 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_25);
+ ZEPHIR_CONCAT_SV(_25, ";", indexSqlAfterCreate);
+ zephir_concat_self(&sql, _25 TSRMLS_CC);
RETURN_CCTOR(sql);
}
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropTable) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *table = NULL, *sql;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &tableName_param, &schemaName_param, &ifExists_param);
@@ -54341,21 +54385,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropTable) {
}
- ZEPHIR_INIT_VAR(table);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "\"", tableName, "\"");
- ZEPHIR_CPY_WRT(table, _0);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
- ZEPHIR_CONCAT_SVS(sql, "DROP TABLE IF EXISTS \"", table, "\"");
+ ZEPHIR_CONCAT_SV(sql, "DROP TABLE IF EXISTS ", table);
} else {
- ZEPHIR_CONCAT_SVS(sql, "DROP TABLE \"", table, "\"");
+ ZEPHIR_CONCAT_SV(sql, "DROP TABLE ", table);
}
RETURN_CCTOR(sql);
@@ -54363,9 +54399,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropTable) {
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zval *definition = NULL;
- zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *view = NULL;
- zval *viewName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *_0 = NULL;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 1, &viewName_param, &definition_param, &schemaName_param);
@@ -54393,29 +54430,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createView) {
ZEPHIR_OBS_VAR(viewSql);
if (!(zephir_array_isset_string_fetch(&viewSql, definition, SS("sql"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/postgresql.zep", 554);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/postgresql.zep", 480);
return;
}
- ZEPHIR_INIT_VAR(view);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", viewName, "\"");
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "\"", viewName, "\"");
- ZEPHIR_CPY_WRT(view, _0);
- }
- ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", view, " AS ", viewSql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", _0, " AS ", viewSql);
RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *view = NULL, *sql;
- zval *viewName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &viewName_param, &schemaName_param, &ifExists_param);
@@ -54449,21 +54479,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropView) {
}
- ZEPHIR_INIT_VAR(view);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", viewName, "\"");
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "\"", viewName, "\"");
- ZEPHIR_CPY_WRT(view, _0);
- }
+ ZEPHIR_CALL_METHOD(&view, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
- ZEPHIR_CONCAT_SVS(sql, "DROP VIEW IF EXISTS ", view, "");
+ ZEPHIR_CONCAT_SV(sql, "DROP VIEW IF EXISTS ", view);
} else {
- ZEPHIR_CONCAT_SVS(sql, "DROP VIEW ", view, "");
+ ZEPHIR_CONCAT_SV(sql, "DROP VIEW ", view);
}
RETURN_CCTOR(sql);
@@ -54904,8 +54926,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, getColumnDefinition) {
static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addColumn) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *sql = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *sql, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &column);
@@ -54934,16 +54956,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addColumn) {
}
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\" ADD COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\" ADD COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CONCAT_SVS(sql, "ALTER TABLE ", _0, " ADD COLUMN ");
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumndefinition", NULL, 0, column);
@@ -55011,7 +55027,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, modifyColumn) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Altering a DB column is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 169);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Altering a DB column is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 165);
return;
}
@@ -55059,7 +55075,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropColumn) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Dropping DB column is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 177);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Dropping DB column is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 173);
return;
}
@@ -55213,7 +55229,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addPrimaryKey) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Adding a primary key after table has been created is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 221);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Adding a primary key after table has been created is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 217);
return;
}
@@ -55250,7 +55266,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropPrimaryKey) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Removing a primary key after table has been created is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 229);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Removing a primary key after table has been created is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 225);
return;
}
@@ -55287,7 +55303,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addForeignKey) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Adding a foreign key constraint to an existing table is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 237);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Adding a foreign key constraint to an existing table is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 233);
return;
}
@@ -55335,7 +55351,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropForeignKey) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Dropping a foreign key constraint is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 245);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Dropping a foreign key constraint is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 241);
return;
}
@@ -55375,16 +55391,17 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, createTable) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Not implemented yet", "phalcon/db/dialect/sqlite.zep", 253);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Not implemented yet", "phalcon/db/dialect/sqlite.zep", 249);
return;
}
static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropTable) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *sql, *table = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &tableName_param, &schemaName_param, &ifExists_param);
@@ -55418,18 +55435,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropTable) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_VSV(_0, schemaName, "\".\"", tableName);
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_CPY_WRT(table, tableName);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
- ZEPHIR_CONCAT_SVS(sql, "DROP TABLE IF EXISTS \"", table, "\"");
+ ZEPHIR_CONCAT_SV(sql, "DROP TABLE IF EXISTS ", table);
} else {
- ZEPHIR_CONCAT_SVS(sql, "DROP TABLE \"", table, "\"");
+ ZEPHIR_CONCAT_SV(sql, "DROP TABLE ", table);
}
RETURN_CCTOR(sql);
@@ -55437,9 +55449,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropTable) {
static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, createView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zval *definition = NULL;
- zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *view = NULL, *viewSql;
- zval *viewName = NULL, *schemaName = NULL, *_0;
+ zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *_0 = NULL;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 1, &viewName_param, &definition_param, &schemaName_param);
@@ -55467,26 +55480,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, createView) {
ZEPHIR_OBS_VAR(viewSql);
if (!(zephir_array_isset_string_fetch(&viewSql, definition, SS("sql"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/sqlite.zep", 286);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/sqlite.zep", 278);
return;
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_VSV(_0, schemaName, "\".\"", viewName);
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_CPY_WRT(view, viewName);
- }
- ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW \"", view, "\" AS ", viewSql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", _0, " AS ", viewSql);
RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *view = NULL;
- zval *viewName = NULL, *schemaName = NULL, *_0;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &viewName_param, &schemaName_param, &ifExists_param);
@@ -55520,18 +55529,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropView) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_VSV(_0, schemaName, "\".\"", viewName);
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_CPY_WRT(view, viewName);
- }
+ ZEPHIR_CALL_METHOD(&view, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
if (ifExists) {
- ZEPHIR_CONCAT_SVS(return_value, "DROP VIEW IF EXISTS \"", view, "\"");
+ ZEPHIR_CONCAT_SV(return_value, "DROP VIEW IF EXISTS ", view);
RETURN_MM();
}
- ZEPHIR_CONCAT_SVS(return_value, "DROP VIEW \"", view, "\"");
+ ZEPHIR_CONCAT_SV(return_value, "DROP VIEW ", view);
RETURN_MM();
}
@@ -56421,7 +56425,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, all) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "variables", 1);
zephir_array_fast_append(_0, _1);
- ZEPHIR_CALL_FUNCTION(&_2, "func_get_args", NULL, 165);
+ ZEPHIR_CALL_FUNCTION(&_2, "func_get_args", NULL, 166);
zephir_check_call_status();
ZEPHIR_CALL_USER_FUNC_ARRAY(return_value, _0, _2);
zephir_check_call_status();
@@ -56621,7 +56625,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, (tab + 1));
- ZEPHIR_CALL_METHOD(&_18, this_ptr, "output", &_19, 166, value, _3, &_5);
+ ZEPHIR_CALL_METHOD(&_18, this_ptr, "output", &_19, 167, value, _3, &_5);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_20);
@@ -56653,7 +56657,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
zephir_concat_self(&output, _2 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_13, "get_parent_class", &_21, 167, variable);
+ ZEPHIR_CALL_FUNCTION(&_13, "get_parent_class", &_21, 168, variable);
zephir_check_call_status();
if (zephir_is_true(_13)) {
ZEPHIR_INIT_NVAR(_12);
@@ -56664,7 +56668,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_check_temp_parameter(_3);
zephir_check_call_status();
zephir_array_update_string(&_12, SL(":style"), &_18, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_FUNCTION(&_18, "get_parent_class", &_21, 167, variable);
+ ZEPHIR_CALL_FUNCTION(&_18, "get_parent_class", &_21, 168, variable);
zephir_check_call_status();
zephir_array_update_string(&_12, SL(":parent"), &_18, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
@@ -56710,7 +56714,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, (tab + 1));
- ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 166, value, _3, &_5);
+ ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 167, value, _3, &_5);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_20);
@@ -56720,7 +56724,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
} else {
do {
Z_SET_ISREF_P(variable);
- ZEPHIR_CALL_FUNCTION(&attr, "each", &_28, 168, variable);
+ ZEPHIR_CALL_FUNCTION(&attr, "each", &_28, 169, variable);
Z_UNSET_ISREF_P(variable);
zephir_check_call_status();
if (!(zephir_is_true(attr))) {
@@ -56766,7 +56770,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_check_call_status();
zephir_array_update_string(&_12, SL(":style"), &_26, PH_COPY | PH_SEPARATE);
Z_SET_ISREF_P(key);
- ZEPHIR_CALL_FUNCTION(&_26, "end", &_32, 169, key);
+ ZEPHIR_CALL_FUNCTION(&_26, "end", &_32, 170, key);
Z_UNSET_ISREF_P(key);
zephir_check_call_status();
zephir_array_update_string(&_12, SL(":key"), &_26, PH_COPY | PH_SEPARATE);
@@ -56782,7 +56786,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, (tab + 1));
- ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 166, value, _3, &_5);
+ ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 167, value, _3, &_5);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_20);
@@ -56790,7 +56794,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_concat_self(&output, _20 TSRMLS_CC);
} while (zephir_is_true(attr));
}
- ZEPHIR_CALL_FUNCTION(&attr, "get_class_methods", NULL, 170, variable);
+ ZEPHIR_CALL_FUNCTION(&attr, "get_class_methods", NULL, 171, variable);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, tab);
@@ -56907,11 +56911,12 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Integer (:var)", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
- ZEPHIR_CALL_FUNCTION(&_2, "is_float", NULL, 171, variable);
+ ZEPHIR_CALL_FUNCTION(&_2, "is_float", NULL, 172, variable);
zephir_check_call_status();
if (zephir_is_true(_2)) {
ZEPHIR_INIT_NVAR(_1);
@@ -56925,8 +56930,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Float (:var)", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _13);
RETURN_MM();
}
if (zephir_is_numeric(variable)) {
@@ -56942,8 +56948,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Numeric string (:length) \":var\"", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
if (Z_TYPE_P(variable) == IS_STRING) {
@@ -56960,15 +56967,16 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
ZVAL_LONG(&_5, 4);
ZEPHIR_SINIT_VAR(_40);
ZVAL_STRING(&_40, "utf-8", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "htmlentities", NULL, 150, variable, &_5, &_40);
+ ZEPHIR_CALL_FUNCTION(&_2, "htmlentities", NULL, 151, variable, &_5, &_40);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_13, "nl2br", NULL, 172, _2);
+ ZEPHIR_CALL_FUNCTION(&_26, "nl2br", NULL, 173, _2);
zephir_check_call_status();
- zephir_array_update_string(&_1, SL(":var"), &_13, PH_COPY | PH_SEPARATE);
+ zephir_array_update_string(&_1, SL(":var"), &_26, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "String (:length) \":var\"", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _26);
RETURN_MM();
}
if (Z_TYPE_P(variable) == IS_BOOL) {
@@ -56991,8 +56999,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &_14, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Boolean (:var)", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
if (Z_TYPE_P(variable) == IS_NULL) {
@@ -57006,8 +57015,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":style"), &_2, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "NULL", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
ZEPHIR_INIT_NVAR(_1);
@@ -57021,8 +57031,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "(:var)", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
@@ -57076,7 +57087,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, variables) {
ZEPHIR_INIT_VAR(output);
ZVAL_STRING(output, "", 1);
- ZEPHIR_CALL_FUNCTION(&_0, "func_get_args", NULL, 165);
+ ZEPHIR_CALL_FUNCTION(&_0, "func_get_args", NULL, 166);
zephir_check_call_status();
zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/debug/dump.zep", 290);
for (
@@ -57835,7 +57846,7 @@ static PHP_METHOD(Phalcon_Di_Service, resolve) {
ZEPHIR_CALL_METHOD(NULL, builder, "__construct", NULL, 0);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&instance, builder, "build", NULL, 174, dependencyInjector, definition, parameters);
+ ZEPHIR_CALL_METHOD(&instance, builder, "build", NULL, 175, dependencyInjector, definition, parameters);
zephir_check_call_status();
} else {
found = 0;
@@ -58031,7 +58042,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_cli_ce, this_ptr, "__construct", &_0, 173);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_cli_ce, this_ptr, "__construct", &_0, 174);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_1);
zephir_create_array(_1, 10, 0 TSRMLS_CC);
@@ -58333,7 +58344,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, _buildParameters) {
) {
ZEPHIR_GET_HMKEY(position, _1, _0);
ZEPHIR_GET_HVALUE(argument, _2);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_buildparameter", &_4, 175, dependencyInjector, position, argument);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_buildparameter", &_4, 176, dependencyInjector, position, argument);
zephir_check_call_status();
zephir_array_append(&buildArguments, _3, PH_SEPARATE, "phalcon/di/service/builder.zep", 117);
}
@@ -58378,7 +58389,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) {
} else {
ZEPHIR_OBS_VAR(arguments);
if (zephir_array_isset_string_fetch(&arguments, definition, SS("arguments"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 176, dependencyInjector, arguments);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 177, dependencyInjector, arguments);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(instance);
ZEPHIR_LAST_CALL_STATUS = zephir_create_instance_params(instance, className, _0 TSRMLS_CC);
@@ -58448,7 +58459,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) {
}
if (zephir_fast_count_int(arguments TSRMLS_CC)) {
ZEPHIR_INIT_NVAR(_5);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 176, dependencyInjector, arguments);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 177, dependencyInjector, arguments);
zephir_check_call_status();
ZEPHIR_CALL_USER_FUNC_ARRAY(_5, methodCall, _0);
zephir_check_call_status();
@@ -58512,7 +58523,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) {
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameter", &_12, 175, dependencyInjector, propertyPosition, propertyValue);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameter", &_12, 176, dependencyInjector, propertyPosition, propertyValue);
zephir_check_call_status();
zephir_update_property_zval_zval(instance, propertyName, _0 TSRMLS_CC);
}
@@ -58816,7 +58827,7 @@ static PHP_METHOD(Phalcon_Events_Manager, attach) {
}
ZEPHIR_INIT_VAR(_2);
ZVAL_LONG(_2, 1);
- ZEPHIR_CALL_METHOD(NULL, priorityQueue, "setextractflags", NULL, 183, _2);
+ ZEPHIR_CALL_METHOD(NULL, priorityQueue, "setextractflags", NULL, 184, _2);
zephir_check_call_status();
zephir_update_property_array(this_ptr, SL("_events"), eventType, priorityQueue TSRMLS_CC);
} else {
@@ -58826,7 +58837,7 @@ static PHP_METHOD(Phalcon_Events_Manager, attach) {
if (Z_TYPE_P(priorityQueue) == IS_OBJECT) {
ZEPHIR_INIT_NVAR(_2);
ZVAL_LONG(_2, priority);
- ZEPHIR_CALL_METHOD(NULL, priorityQueue, "insert", NULL, 184, handler, _2);
+ ZEPHIR_CALL_METHOD(NULL, priorityQueue, "insert", NULL, 185, handler, _2);
zephir_check_call_status();
} else {
zephir_array_append(&priorityQueue, handler, PH_SEPARATE, "phalcon/events/manager.zep", 82);
@@ -58875,7 +58886,7 @@ static PHP_METHOD(Phalcon_Events_Manager, detach) {
}
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, 1);
- ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "setextractflags", NULL, 183, _1);
+ ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "setextractflags", NULL, 184, _1);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_1);
ZVAL_LONG(_1, 3);
@@ -58897,13 +58908,13 @@ static PHP_METHOD(Phalcon_Events_Manager, detach) {
if (!ZEPHIR_IS_IDENTICAL(_5, handler)) {
zephir_array_fetch_string(&_6, data, SL("data"), PH_NOISY | PH_READONLY, "phalcon/events/manager.zep", 117 TSRMLS_CC);
zephir_array_fetch_string(&_7, data, SL("priority"), PH_NOISY | PH_READONLY, "phalcon/events/manager.zep", 117 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "insert", &_8, 184, _6, _7);
+ ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "insert", &_8, 185, _6, _7);
zephir_check_call_status();
}
}
zephir_update_property_array(this_ptr, SL("_events"), eventType, newPriorityQueue TSRMLS_CC);
} else {
- ZEPHIR_CALL_FUNCTION(&key, "array_search", NULL, 185, handler, priorityQueue, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(&key, "array_search", NULL, 186, handler, priorityQueue, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
if (!ZEPHIR_IS_FALSE_IDENTICAL(key)) {
zephir_array_unset(&priorityQueue, key, PH_SEPARATE);
@@ -59059,7 +59070,7 @@ static PHP_METHOD(Phalcon_Events_Manager, fireQueue) {
zephir_get_class(_1, queue, 0 TSRMLS_CC);
ZEPHIR_SINIT_VAR(_2);
ZVAL_STRING(&_2, "Unexpected value type: expected object of type SplPriorityQueue, %s given", 0);
- ZEPHIR_CALL_FUNCTION(&_3, "sprintf", NULL, 186, &_2, _1);
+ ZEPHIR_CALL_FUNCTION(&_3, "sprintf", NULL, 187, &_2, _1);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3);
zephir_check_call_status();
@@ -59272,9 +59283,9 @@ static PHP_METHOD(Phalcon_Events_Manager, fire) {
if (_3) {
ZEPHIR_INIT_NVAR(event);
object_init_ex(event, phalcon_events_event_ce);
- ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 187, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 188, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 188, fireEvents, event);
+ ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 189, fireEvents, event);
zephir_check_call_status();
}
}
@@ -59288,10 +59299,10 @@ static PHP_METHOD(Phalcon_Events_Manager, fire) {
if (Z_TYPE_P(event) == IS_NULL) {
ZEPHIR_INIT_NVAR(event);
object_init_ex(event, phalcon_events_event_ce);
- ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 187, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 188, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 188, fireEvents, event);
+ ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 189, fireEvents, event);
zephir_check_call_status();
}
}
@@ -59504,7 +59515,7 @@ static PHP_METHOD(Phalcon_Flash_Direct, output) {
}
}
if (remove) {
- ZEPHIR_CALL_PARENT(NULL, phalcon_flash_direct_ce, this_ptr, "clear", &_3, 195);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_flash_direct_ce, this_ptr, "clear", &_3, 196);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -59777,7 +59788,7 @@ static PHP_METHOD(Phalcon_Flash_Session, output) {
zephir_check_call_status();
}
}
- ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_4, 195);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_4, 196);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -59795,7 +59806,7 @@ static PHP_METHOD(Phalcon_Flash_Session, clear) {
ZVAL_BOOL(_0, 1);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "_getsessionmessages", NULL, 0, _0);
zephir_check_call_status();
- ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_1, 195);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_1, 196);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -60921,7 +60932,7 @@ static PHP_METHOD(Phalcon_Forms_Form, isValid) {
} else {
ZEPHIR_INIT_NVAR(validation);
object_init_ex(validation, phalcon_validation_ce);
- ZEPHIR_CALL_METHOD(NULL, validation, "__construct", &_11, 209, preparedValidators);
+ ZEPHIR_CALL_METHOD(NULL, validation, "__construct", &_11, 210, preparedValidators);
zephir_check_call_status();
}
ZEPHIR_CALL_METHOD(&filters, element, "getfilters", NULL, 0);
@@ -60929,10 +60940,10 @@ static PHP_METHOD(Phalcon_Forms_Form, isValid) {
if (Z_TYPE_P(filters) == IS_ARRAY) {
ZEPHIR_CALL_METHOD(&_2, element, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, validation, "setfilters", &_12, 210, _2, filters);
+ ZEPHIR_CALL_METHOD(NULL, validation, "setfilters", &_12, 211, _2, filters);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&elementMessages, validation, "validate", &_13, 211, data, entity);
+ ZEPHIR_CALL_METHOD(&elementMessages, validation, "validate", &_13, 212, data, entity);
zephir_check_call_status();
if (zephir_fast_count_int(elementMessages TSRMLS_CC)) {
ZEPHIR_CALL_METHOD(&_14, element, "getname", NULL, 0);
@@ -60995,7 +61006,7 @@ static PHP_METHOD(Phalcon_Forms_Form, getMessages) {
; zephir_hash_move_forward_ex(_2, &_1)
) {
ZEPHIR_GET_HVALUE(elementMessages, _3);
- ZEPHIR_CALL_METHOD(NULL, group, "appendmessages", &_4, 212, elementMessages);
+ ZEPHIR_CALL_METHOD(NULL, group, "appendmessages", &_4, 213, elementMessages);
zephir_check_call_status();
}
}
@@ -61465,7 +61476,7 @@ static PHP_METHOD(Phalcon_Forms_Form, rewind) {
ZVAL_LONG(_0, 0);
zephir_update_property_this(this_ptr, SL("_position"), _0 TSRMLS_CC);
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_elements"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_1, "array_values", NULL, 213, _0);
+ ZEPHIR_CALL_FUNCTION(&_1, "array_values", NULL, 214, _0);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_elementsIndexed"), _1 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -61557,7 +61568,7 @@ static PHP_METHOD(Phalcon_Forms_Manager, create) {
}
ZEPHIR_INIT_VAR(form);
object_init_ex(form, phalcon_forms_form_ce);
- ZEPHIR_CALL_METHOD(NULL, form, "__construct", NULL, 214, entity);
+ ZEPHIR_CALL_METHOD(NULL, form, "__construct", NULL, 215, entity);
zephir_check_call_status();
zephir_update_property_array(this_ptr, SL("_forms"), name, form TSRMLS_CC);
RETURN_CCTOR(form);
@@ -61666,7 +61677,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Check, render) {
ZVAL_BOOL(_2, 1);
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes, _2);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "checkfield", &_0, 196, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "checkfield", &_0, 197, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61711,7 +61722,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Date, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "datefield", &_0, 197, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "datefield", &_0, 198, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61756,7 +61767,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Email, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "emailfield", &_0, 198, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "emailfield", &_0, 199, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61801,7 +61812,7 @@ static PHP_METHOD(Phalcon_Forms_Element_File, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "filefield", &_0, 199, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "filefield", &_0, 200, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61846,7 +61857,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Hidden, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "hiddenfield", &_0, 200, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "hiddenfield", &_0, 201, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61891,7 +61902,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Numeric, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "numericfield", &_0, 201, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "numericfield", &_0, 202, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61936,7 +61947,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Password, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "passwordfield", &_0, 202, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "passwordfield", &_0, 203, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61983,7 +61994,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Radio, render) {
ZVAL_BOOL(_2, 1);
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes, _2);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "radiofield", &_0, 203, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "radiofield", &_0, 204, _1);
zephir_check_call_status();
RETURN_MM();
@@ -62034,7 +62045,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Select, __construct) {
zephir_update_property_this(this_ptr, SL("_optionsValues"), options TSRMLS_CC);
- ZEPHIR_CALL_PARENT(NULL, phalcon_forms_element_select_ce, this_ptr, "__construct", &_0, 204, name, attributes);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_forms_element_select_ce, this_ptr, "__construct", &_0, 205, name, attributes);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -62090,7 +62101,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Select, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
_2 = zephir_fetch_nproperty_this(this_ptr, SL("_optionsValues"), PH_NOISY_CC);
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 205, _1, _2);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, _1, _2);
zephir_check_call_status();
RETURN_MM();
@@ -62135,7 +62146,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Submit, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "submitbutton", &_0, 206, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "submitbutton", &_0, 207, _1);
zephir_check_call_status();
RETURN_MM();
@@ -62180,7 +62191,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Text, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textfield", &_0, 207, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textfield", &_0, 208, _1);
zephir_check_call_status();
RETURN_MM();
@@ -62225,7 +62236,7 @@ static PHP_METHOD(Phalcon_Forms_Element_TextArea, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textarea", &_0, 208, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textarea", &_0, 209, _1);
zephir_check_call_status();
RETURN_MM();
@@ -62532,7 +62543,7 @@ static PHP_METHOD(Phalcon_Http_Cookie, send) {
} else {
ZEPHIR_CPY_WRT(encryptValue, value);
}
- ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 215, name, encryptValue, expire, path, domain, secure, httpOnly);
+ ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 216, name, encryptValue, expire, path, domain, secure, httpOnly);
zephir_check_call_status();
RETURN_THIS();
@@ -62620,7 +62631,7 @@ static PHP_METHOD(Phalcon_Http_Cookie, delete) {
zephir_time(_2);
ZEPHIR_SINIT_VAR(_4);
ZVAL_LONG(&_4, (zephir_get_numberval(_2) - 691200));
- ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 215, name, ZEPHIR_GLOBAL(global_null), &_4, path, domain, secure, httpOnly);
+ ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 216, name, ZEPHIR_GLOBAL(global_null), &_4, path, domain, secure, httpOnly);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -62977,7 +62988,7 @@ static PHP_METHOD(Phalcon_Http_Request, get) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 216, _REQUEST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _REQUEST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -63028,7 +63039,7 @@ static PHP_METHOD(Phalcon_Http_Request, getPost) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 216, _POST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _POST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -63038,7 +63049,7 @@ static PHP_METHOD(Phalcon_Http_Request, getPut) {
int ZEPHIR_LAST_CALL_STATUS;
zend_bool notAllowEmpty, noRecursive;
- zval *name_param = NULL, *filters = NULL, *defaultValue = NULL, *notAllowEmpty_param = NULL, *noRecursive_param = NULL, *put = NULL, *_0, _1;
+ zval *name_param = NULL, *filters = NULL, *defaultValue = NULL, *notAllowEmpty_param = NULL, *noRecursive_param = NULL, *put = NULL, *_0 = NULL;
zval *name = NULL;
ZEPHIR_MM_GROW();
@@ -63083,17 +63094,15 @@ static PHP_METHOD(Phalcon_Http_Request, getPut) {
if (Z_TYPE_P(put) != IS_ARRAY) {
ZEPHIR_INIT_NVAR(put);
array_init(put);
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_SINIT_VAR(_1);
- ZVAL_STRING(&_1, "php://input", 0);
- zephir_file_get_contents(_0, &_1 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getrawbody", NULL, 0);
+ zephir_check_call_status();
Z_SET_ISREF_P(put);
- ZEPHIR_CALL_FUNCTION(NULL, "parse_str", NULL, 217, _0, put);
+ ZEPHIR_CALL_FUNCTION(NULL, "parse_str", NULL, 218, _0, put);
Z_UNSET_ISREF_P(put);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_putCache"), put TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 216, put, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, put, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -63144,7 +63153,7 @@ static PHP_METHOD(Phalcon_Http_Request, getQuery) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 216, _GET, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _GET, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -63581,7 +63590,7 @@ static PHP_METHOD(Phalcon_Http_Request, getServerAddress) {
}
ZEPHIR_SINIT_VAR(_0);
ZVAL_STRING(&_0, "localhost", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("gethostbyname", NULL, 218, &_0);
+ ZEPHIR_RETURN_CALL_FUNCTION("gethostbyname", NULL, 219, &_0);
zephir_check_call_status();
RETURN_MM();
@@ -63772,7 +63781,7 @@ static PHP_METHOD(Phalcon_Http_Request, isMethod) {
}
- ZEPHIR_CALL_METHOD(&httpMethod, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&httpMethod, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
if (Z_TYPE_P(methods) == IS_STRING) {
_0 = strict;
@@ -63844,7 +63853,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPost) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "POST"));
@@ -63857,7 +63866,7 @@ static PHP_METHOD(Phalcon_Http_Request, isGet) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "GET"));
@@ -63870,7 +63879,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPut) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "PUT"));
@@ -63883,7 +63892,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPatch) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "PATCH"));
@@ -63896,7 +63905,7 @@ static PHP_METHOD(Phalcon_Http_Request, isHead) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "HEAD"));
@@ -63909,7 +63918,7 @@ static PHP_METHOD(Phalcon_Http_Request, isDelete) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "DELETE"));
@@ -63922,7 +63931,7 @@ static PHP_METHOD(Phalcon_Http_Request, isOptions) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "OPTIONS"));
@@ -63970,7 +63979,7 @@ static PHP_METHOD(Phalcon_Http_Request, hasFiles) {
}
}
if (Z_TYPE_P(error) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 220, error, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 221, error, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
numberFiles += zephir_get_numberval(_4);
}
@@ -64014,7 +64023,7 @@ static PHP_METHOD(Phalcon_Http_Request, hasFileHelper) {
}
}
if (Z_TYPE_P(value) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 220, value, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 221, value, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
numberFiles += zephir_get_numberval(_4);
}
@@ -64063,7 +64072,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) {
zephir_array_fetch_string(&_6, input, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC);
zephir_array_fetch_string(&_7, input, SL("size"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC);
zephir_array_fetch_string(&_8, input, SL("error"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&smoothInput, this_ptr, "smoothfiles", &_9, 221, _4, _5, _6, _7, _8, prefix);
+ ZEPHIR_CALL_METHOD(&smoothInput, this_ptr, "smoothfiles", &_9, 222, _4, _5, _6, _7, _8, prefix);
zephir_check_call_status();
zephir_is_iterable(smoothInput, &_11, &_10, 0, 0, "phalcon/http/request.zep", 714);
for (
@@ -64097,7 +64106,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) {
ZEPHIR_INIT_NVAR(_16);
object_init_ex(_16, phalcon_http_request_file_ce);
zephir_array_fetch_string(&_17, file, SL("key"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 711 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 222, dataFile, _17);
+ ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 223, dataFile, _17);
zephir_check_call_status();
zephir_array_append(&files, _16, PH_SEPARATE, "phalcon/http/request.zep", 711);
}
@@ -64111,7 +64120,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) {
if (_13) {
ZEPHIR_INIT_NVAR(_16);
object_init_ex(_16, phalcon_http_request_file_ce);
- ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 222, input, prefix);
+ ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 223, input, prefix);
zephir_check_call_status();
zephir_array_append(&files, _16, PH_SEPARATE, "phalcon/http/request.zep", 716);
}
@@ -64184,7 +64193,7 @@ static PHP_METHOD(Phalcon_Http_Request, smoothFiles) {
zephir_array_fetch(&_7, tmp_names, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC);
zephir_array_fetch(&_8, sizes, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC);
zephir_array_fetch(&_9, errors, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&parentFiles, this_ptr, "smoothfiles", &_10, 221, _5, _6, _7, _8, _9, p);
+ ZEPHIR_CALL_METHOD(&parentFiles, this_ptr, "smoothfiles", &_10, 222, _5, _6, _7, _8, _9, p);
zephir_check_call_status();
zephir_is_iterable(parentFiles, &_12, &_11, 0, 0, "phalcon/http/request.zep", 755);
for (
@@ -64238,7 +64247,7 @@ static PHP_METHOD(Phalcon_Http_Request, getHeaders) {
ZVAL_STRING(&_8, " ", 0);
zephir_fast_str_replace(&_4, &_7, &_8, _6 TSRMLS_CC);
zephir_fast_strtolower(_3, _4);
- ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 223, _3);
+ ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 224, _3);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_10);
ZEPHIR_SINIT_NVAR(_11);
@@ -64257,7 +64266,7 @@ static PHP_METHOD(Phalcon_Http_Request, getHeaders) {
ZVAL_STRING(&_7, " ", 0);
zephir_fast_str_replace(&_4, &_5, &_7, name TSRMLS_CC);
zephir_fast_strtolower(_3, _4);
- ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 223, _3);
+ ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 224, _3);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_6);
ZEPHIR_SINIT_NVAR(_8);
@@ -64332,7 +64341,7 @@ static PHP_METHOD(Phalcon_Http_Request, _getQualityHeader) {
ZVAL_LONG(&_2, -1);
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 1);
- ZEPHIR_CALL_FUNCTION(&_4, "preg_split", &_5, 224, &_1, _0, &_2, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "preg_split", &_5, 225, &_1, _0, &_2, &_3);
zephir_check_call_status();
zephir_is_iterable(_4, &_7, &_6, 0, 0, "phalcon/http/request.zep", 827);
for (
@@ -64350,7 +64359,7 @@ static PHP_METHOD(Phalcon_Http_Request, _getQualityHeader) {
ZVAL_LONG(&_2, -1);
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 1);
- ZEPHIR_CALL_FUNCTION(&_10, "preg_split", &_5, 224, &_1, _9, &_2, &_3);
+ ZEPHIR_CALL_FUNCTION(&_10, "preg_split", &_5, 225, &_1, _9, &_2, &_3);
zephir_check_call_status();
zephir_is_iterable(_10, &_12, &_11, 0, 0, "phalcon/http/request.zep", 824);
for (
@@ -64481,7 +64490,7 @@ static PHP_METHOD(Phalcon_Http_Request, getAcceptableContent) {
ZVAL_STRING(_0, "HTTP_ACCEPT", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "accept", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 225, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1);
zephir_check_temp_parameter(_0);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
@@ -64500,7 +64509,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestAccept) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "accept", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 226, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -64518,7 +64527,7 @@ static PHP_METHOD(Phalcon_Http_Request, getClientCharsets) {
ZVAL_STRING(_0, "HTTP_ACCEPT_CHARSET", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "charset", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 225, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1);
zephir_check_temp_parameter(_0);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
@@ -64537,7 +64546,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestCharset) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "charset", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 226, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -64555,7 +64564,7 @@ static PHP_METHOD(Phalcon_Http_Request, getLanguages) {
ZVAL_STRING(_0, "HTTP_ACCEPT_LANGUAGE", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "language", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 225, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1);
zephir_check_temp_parameter(_0);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
@@ -64574,7 +64583,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestLanguage) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "language", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 226, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -64894,7 +64903,7 @@ static PHP_METHOD(Phalcon_Http_Response, setStatusCode) {
if (_4) {
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "HTTP/", 0);
- ZEPHIR_CALL_FUNCTION(&_6, "strstr", &_7, 233, key, &_5);
+ ZEPHIR_CALL_FUNCTION(&_6, "strstr", &_7, 234, key, &_5);
zephir_check_call_status();
_4 = zephir_is_true(_6);
}
@@ -65165,6 +65174,48 @@ static PHP_METHOD(Phalcon_Http_Response, setExpires) {
}
+static PHP_METHOD(Phalcon_Http_Response, setCache) {
+
+ zval *_1, *_3;
+ zval *minutes_param = NULL, *date, _0, _2, *_4;
+ int minutes, ZEPHIR_LAST_CALL_STATUS;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 0, &minutes_param);
+
+ if (unlikely(Z_TYPE_P(minutes_param) != IS_LONG)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'minutes' must be a long/integer") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ minutes = Z_LVAL_P(minutes_param);
+
+
+ ZEPHIR_INIT_VAR(date);
+ object_init_ex(date, php_date_get_date_ce());
+ ZEPHIR_CALL_METHOD(NULL, date, "__construct", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_SINIT_VAR(_0);
+ ZVAL_LONG(&_0, minutes);
+ ZEPHIR_INIT_VAR(_1);
+ ZEPHIR_CONCAT_SVS(_1, "+", &_0, " minutes");
+ ZEPHIR_CALL_METHOD(NULL, date, "modify", NULL, 0, _1);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "setexpires", NULL, 0, date);
+ zephir_check_call_status();
+ ZEPHIR_SINIT_VAR(_2);
+ ZVAL_LONG(&_2, ((minutes * 60)));
+ ZEPHIR_INIT_VAR(_3);
+ ZEPHIR_CONCAT_SV(_3, "max-age=", &_2);
+ ZEPHIR_INIT_VAR(_4);
+ ZVAL_STRING(_4, "Cache-Control", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "setheader", NULL, 0, _4, _3);
+ zephir_check_temp_parameter(_4);
+ zephir_check_call_status();
+ RETURN_THIS();
+
+}
+
static PHP_METHOD(Phalcon_Http_Response, setNotModified) {
int ZEPHIR_LAST_CALL_STATUS;
@@ -65279,7 +65330,7 @@ static PHP_METHOD(Phalcon_Http_Response, redirect) {
if (_0) {
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "://", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "strstr", NULL, 233, location, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strstr", NULL, 234, location, &_1);
zephir_check_call_status();
_0 = zephir_is_true(_2);
}
@@ -65336,7 +65387,7 @@ static PHP_METHOD(Phalcon_Http_Response, redirect) {
statusCode = 302;
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_statusCodes"), PH_NOISY_CC);
ZEPHIR_OBS_VAR(message);
- zephir_array_fetch_long(&message, _5, 302, PH_NOISY, "phalcon/http/response.zep", 461 TSRMLS_CC);
+ zephir_array_fetch_long(&message, _5, 302, PH_NOISY, "phalcon/http/response.zep", 481 TSRMLS_CC);
} else {
ZEPHIR_OBS_NVAR(message);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_statusCodes"), PH_NOISY_CC);
@@ -65472,7 +65523,7 @@ static PHP_METHOD(Phalcon_Http_Response, send) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_sent"), PH_NOISY_CC);
if (zephir_is_true(_0)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_response_exception_ce, "Response was already sent", "phalcon/http/response.zep", 568);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_response_exception_ce, "Response was already sent", "phalcon/http/response.zep", 588);
return;
}
ZEPHIR_OBS_VAR(headers);
@@ -65499,7 +65550,7 @@ static PHP_METHOD(Phalcon_Http_Response, send) {
_1 = (zephir_fast_strlen_ev(file)) ? 1 : 0;
}
if (_1) {
- ZEPHIR_CALL_FUNCTION(NULL, "readfile", NULL, 234, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "readfile", NULL, 235, file);
zephir_check_call_status();
}
}
@@ -65739,7 +65790,7 @@ static PHP_METHOD(Phalcon_Http_Request_File, __construct) {
zephir_update_property_this(this_ptr, SL("_name"), name TSRMLS_CC);
ZEPHIR_SINIT_VAR(_0);
ZVAL_STRING(&_0, "PATHINFO_EXTENSION", 0);
- ZEPHIR_CALL_FUNCTION(&_1, "defined", NULL, 227, &_0);
+ ZEPHIR_CALL_FUNCTION(&_1, "defined", NULL, 228, &_0);
zephir_check_call_status();
if (zephir_is_true(_1)) {
ZEPHIR_SINIT_NVAR(_0);
@@ -65805,15 +65856,15 @@ static PHP_METHOD(Phalcon_Http_Request_File, getRealType) {
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, 16);
- ZEPHIR_CALL_FUNCTION(&finfo, "finfo_open", NULL, 228, &_0);
+ ZEPHIR_CALL_FUNCTION(&finfo, "finfo_open", NULL, 229, &_0);
zephir_check_call_status();
if (Z_TYPE_P(finfo) != IS_RESOURCE) {
RETURN_MM_STRING("", 1);
}
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_tmp"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 229, finfo, _1);
+ ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 230, finfo, _1);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 230, finfo);
+ ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 231, finfo);
zephir_check_call_status();
RETURN_CCTOR(mime);
@@ -65831,7 +65882,7 @@ static PHP_METHOD(Phalcon_Http_Request_File, isUploadedFile) {
zephir_check_call_status();
_0 = Z_TYPE_P(tmp) == IS_STRING;
if (_0) {
- ZEPHIR_CALL_FUNCTION(&_1, "is_uploaded_file", NULL, 231, tmp);
+ ZEPHIR_CALL_FUNCTION(&_1, "is_uploaded_file", NULL, 232, tmp);
zephir_check_call_status();
_0 = zephir_is_true(_1);
}
@@ -65862,7 +65913,7 @@ static PHP_METHOD(Phalcon_Http_Request_File, moveTo) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_tmp"), PH_NOISY_CC);
- ZEPHIR_RETURN_CALL_FUNCTION("move_uploaded_file", NULL, 232, _0, destination);
+ ZEPHIR_RETURN_CALL_FUNCTION("move_uploaded_file", NULL, 233, _0, destination);
zephir_check_call_status();
RETURN_MM();
@@ -66042,30 +66093,30 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, set) {
object_init_ex(cookie, phalcon_http_cookie_ce);
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, expire);
- ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 235, name, value, _1, path, secure, domain, httpOnly);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 236, name, value, _1, path, secure, domain, httpOnly);
zephir_check_call_status();
_2 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 236, _2);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 237, _2);
zephir_check_call_status();
if (zephir_is_true(encryption)) {
- ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 237, encryption);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 238, encryption);
zephir_check_call_status();
}
zephir_update_property_array(this_ptr, SL("_cookies"), name, cookie TSRMLS_CC);
} else {
- ZEPHIR_CALL_METHOD(NULL, cookie, "setvalue", NULL, 238, value);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setvalue", NULL, 239, value);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_1);
ZVAL_LONG(_1, expire);
- ZEPHIR_CALL_METHOD(NULL, cookie, "setexpiration", NULL, 239, _1);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setexpiration", NULL, 240, _1);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, cookie, "setpath", NULL, 240, path);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setpath", NULL, 241, path);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, cookie, "setsecure", NULL, 241, secure);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setsecure", NULL, 242, secure);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, cookie, "setdomain", NULL, 242, domain);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setdomain", NULL, 243, domain);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, cookie, "sethttponly", NULL, 243, httpOnly);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "sethttponly", NULL, 244, httpOnly);
zephir_check_call_status();
}
_2 = zephir_fetch_nproperty_this(this_ptr, SL("_registered"), PH_NOISY_CC);
@@ -66117,17 +66168,17 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, get) {
}
ZEPHIR_INIT_NVAR(cookie);
object_init_ex(cookie, phalcon_http_cookie_ce);
- ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 235, name);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 236, name);
zephir_check_call_status();
ZEPHIR_OBS_VAR(dependencyInjector);
zephir_read_property_this(&dependencyInjector, this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
if (Z_TYPE_P(dependencyInjector) == IS_OBJECT) {
- ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 236, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 237, dependencyInjector);
zephir_check_call_status();
ZEPHIR_OBS_VAR(encryption);
zephir_read_property_this(&encryption, this_ptr, SL("_useEncryption"), PH_NOISY_CC);
if (zephir_is_true(encryption)) {
- ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 237, encryption);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 238, encryption);
zephir_check_call_status();
}
}
@@ -66411,10 +66462,10 @@ static PHP_METHOD(Phalcon_Http_Response_Headers, send) {
if (!(ZEPHIR_IS_EMPTY(value))) {
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_VSV(_5, header, ": ", value);
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 244, _5, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 245, _5, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
} else {
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 244, header, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 245, header, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
}
}
@@ -66475,7 +66526,7 @@ static PHP_METHOD(Phalcon_Http_Response_Headers, __set_state) {
) {
ZEPHIR_GET_HMKEY(key, _1, _0);
ZEPHIR_GET_HVALUE(value, _2);
- ZEPHIR_CALL_METHOD(NULL, headers, "set", &_3, 245, key, value);
+ ZEPHIR_CALL_METHOD(NULL, headers, "set", &_3, 246, key, value);
zephir_check_call_status();
}
}
@@ -67529,13 +67580,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, check) {
ZVAL_NULL(version);
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "GD_VERSION", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "defined", NULL, 227, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "defined", NULL, 228, &_1);
zephir_check_call_status();
if (zephir_is_true(_2)) {
ZEPHIR_INIT_NVAR(version);
ZEPHIR_GET_CONSTANT(version, "GD_VERSION");
} else {
- ZEPHIR_CALL_FUNCTION(&info, "gd_info", NULL, 246);
+ ZEPHIR_CALL_FUNCTION(&info, "gd_info", NULL, 247);
zephir_check_call_status();
ZEPHIR_INIT_VAR(matches);
ZVAL_NULL(matches);
@@ -67553,7 +67604,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, check) {
ZVAL_STRING(&_5, "2.0.1", 0);
ZEPHIR_SINIT_VAR(_6);
ZVAL_STRING(&_6, ">=", 0);
- ZEPHIR_CALL_FUNCTION(&_7, "version_compare", NULL, 247, version, &_5, &_6);
+ ZEPHIR_CALL_FUNCTION(&_7, "version_compare", NULL, 248, version, &_5, &_6);
zephir_check_call_status();
if (!(zephir_is_true(_7))) {
ZEPHIR_INIT_NVAR(_3);
@@ -67619,7 +67670,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) {
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_realpath"), _3 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&imageinfo, "getimagesize", NULL, 248, _4);
+ ZEPHIR_CALL_FUNCTION(&imageinfo, "getimagesize", NULL, 249, _4);
zephir_check_call_status();
if (zephir_is_true(imageinfo)) {
zephir_array_fetch_long(&_5, imageinfo, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter/gd.zep", 77 TSRMLS_CC);
@@ -67635,35 +67686,35 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) {
do {
if (ZEPHIR_IS_LONG(_9, 1)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromgif", NULL, 249, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromgif", NULL, 250, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(_9, 2)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromjpeg", NULL, 250, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromjpeg", NULL, 251, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(_9, 3)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefrompng", NULL, 251, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefrompng", NULL, 252, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(_9, 15)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromwbmp", NULL, 252, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromwbmp", NULL, 253, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(_9, 16)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromxbm", NULL, 253, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromxbm", NULL, 254, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
@@ -67688,7 +67739,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) {
} while(0);
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 254, _10, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 255, _10, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
} else {
_16 = !width;
@@ -67711,14 +67762,14 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) {
ZVAL_LONG(&_17, width);
ZEPHIR_SINIT_VAR(_18);
ZVAL_LONG(&_18, height);
- ZEPHIR_CALL_FUNCTION(&_3, "imagecreatetruecolor", NULL, 255, &_17, &_18);
+ ZEPHIR_CALL_FUNCTION(&_3, "imagecreatetruecolor", NULL, 256, &_17, &_18);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _3 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 256, _4, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, _4, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 254, _9, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 255, _9, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
zephir_update_property_this(this_ptr, SL("_realpath"), _10 TSRMLS_CC);
@@ -67757,7 +67808,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) {
ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION");
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "5.5.0", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 247, _0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1);
zephir_check_call_status();
if (ZEPHIR_LT_LONG(_2, 0)) {
ZEPHIR_OBS_VAR(pre_width);
@@ -67805,11 +67856,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) {
ZVAL_LONG(&_14, 0);
ZEPHIR_SINIT_VAR(_15);
ZVAL_LONG(&_15, 0);
- ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresized", NULL, 257, image, _9, &_12, &_13, &_14, &_15, pre_width, pre_height, _10, _11);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresized", NULL, 258, image, _9, &_12, &_13, &_14, &_15, pre_width, pre_height, _10, _11);
zephir_check_call_status();
if (zephir_is_true(_16)) {
_17 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 258, _17);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _17);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
}
@@ -67833,17 +67884,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) {
ZVAL_LONG(&_15, width);
ZEPHIR_SINIT_VAR(_21);
ZVAL_LONG(&_21, height);
- ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresampled", NULL, 259, image, _9, &_6, &_12, &_13, &_14, &_15, &_21, pre_width, pre_height);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresampled", NULL, 260, image, _9, &_6, &_12, &_13, &_14, &_15, &_21, pre_width, pre_height);
zephir_check_call_status();
if (zephir_is_true(_16)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 258, _10);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_22, "imagesx", &_23, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_22, "imagesx", &_23, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _22 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_24, "imagesy", &_25, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_24, "imagesy", &_25, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _24 TSRMLS_CC);
}
@@ -67853,16 +67904,16 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) {
ZVAL_LONG(&_6, width);
ZEPHIR_SINIT_NVAR(_12);
ZVAL_LONG(&_12, height);
- ZEPHIR_CALL_FUNCTION(&image, "imagescale", NULL, 262, _3, &_6, &_12);
+ ZEPHIR_CALL_FUNCTION(&image, "imagescale", NULL, 263, _3, &_6, &_12);
zephir_check_call_status();
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 258, _5);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _5);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_23, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_23, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _16 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_22, "imagesy", &_25, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_22, "imagesy", &_25, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _22 TSRMLS_CC);
}
@@ -67889,7 +67940,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) {
ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION");
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "5.5.0", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 247, _0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1);
zephir_check_call_status();
if (ZEPHIR_LT_LONG(_2, 0)) {
ZEPHIR_INIT_VAR(_3);
@@ -67915,17 +67966,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) {
ZVAL_LONG(&_11, width);
ZEPHIR_SINIT_VAR(_12);
ZVAL_LONG(&_12, height);
- ZEPHIR_CALL_FUNCTION(&_13, "imagecopyresampled", NULL, 259, image, _5, &_1, &_6, &_7, &_8, &_9, &_10, &_11, &_12);
+ ZEPHIR_CALL_FUNCTION(&_13, "imagecopyresampled", NULL, 260, image, _5, &_1, &_6, &_7, &_8, &_9, &_10, &_11, &_12);
zephir_check_call_status();
if (zephir_is_true(_13)) {
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 258, _14);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 259, _14);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_17, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_17, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _16 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_18, "imagesy", &_19, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_18, "imagesy", &_19, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _18 TSRMLS_CC);
}
@@ -67945,16 +67996,16 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) {
ZVAL_LONG(_3, height);
zephir_array_update_string(&rect, SL("height"), &_3, PH_COPY | PH_SEPARATE);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&image, "imagecrop", NULL, 263, _5, rect);
+ ZEPHIR_CALL_FUNCTION(&image, "imagecrop", NULL, 264, _5, rect);
zephir_check_call_status();
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 258, _14);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 259, _14);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_13, "imagesx", &_17, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_13, "imagesx", &_17, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _13 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_16, "imagesy", &_19, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagesy", &_19, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _16 TSRMLS_CC);
}
@@ -67982,20 +68033,20 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _rotate) {
ZVAL_LONG(&_3, 0);
ZEPHIR_SINIT_VAR(_4);
ZVAL_LONG(&_4, 127);
- ZEPHIR_CALL_FUNCTION(&transparent, "imagecolorallocatealpha", NULL, 264, _0, &_1, &_2, &_3, &_4);
+ ZEPHIR_CALL_FUNCTION(&transparent, "imagecolorallocatealpha", NULL, 265, _0, &_1, &_2, &_3, &_4);
zephir_check_call_status();
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, (360 - degrees));
ZEPHIR_SINIT_NVAR(_2);
ZVAL_LONG(&_2, 1);
- ZEPHIR_CALL_FUNCTION(&image, "imagerotate", NULL, 265, _5, &_1, transparent, &_2);
+ ZEPHIR_CALL_FUNCTION(&image, "imagerotate", NULL, 266, _5, &_1, transparent, &_2);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 254, image, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, image, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&width, "imagesx", NULL, 260, image);
+ ZEPHIR_CALL_FUNCTION(&width, "imagesx", NULL, 261, image);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&height, "imagesy", NULL, 261, image);
+ ZEPHIR_CALL_FUNCTION(&height, "imagesy", NULL, 262, image);
zephir_check_call_status();
_6 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
@@ -68008,11 +68059,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _rotate) {
ZVAL_LONG(&_4, 0);
ZEPHIR_SINIT_VAR(_7);
ZVAL_LONG(&_7, 100);
- ZEPHIR_CALL_FUNCTION(&_8, "imagecopymerge", NULL, 266, _6, image, &_1, &_2, &_3, &_4, width, height, &_7);
+ ZEPHIR_CALL_FUNCTION(&_8, "imagecopymerge", NULL, 267, _6, image, &_1, &_2, &_3, &_4, width, height, &_7);
zephir_check_call_status();
if (zephir_is_true(_8)) {
_9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, _9);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _9);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_width"), width TSRMLS_CC);
@@ -68038,7 +68089,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) {
ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION");
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "5.5.0", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 247, _0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1);
zephir_check_call_status();
if (ZEPHIR_LT_LONG(_2, 0)) {
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
@@ -68066,7 +68117,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) {
ZVAL_LONG(&_11, 0);
ZEPHIR_SINIT_NVAR(_12);
ZVAL_LONG(&_12, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, image, _6, &_1, &_9, &_10, &_11, &_12, _8);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, image, _6, &_1, &_9, &_10, &_11, &_12, _8);
zephir_check_call_status();
}
} else {
@@ -68090,18 +68141,18 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) {
ZVAL_LONG(&_11, ((zephir_get_numberval(_7) - x) - 1));
ZEPHIR_SINIT_NVAR(_12);
ZVAL_LONG(&_12, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, image, _6, &_1, &_9, &_10, &_11, _8, &_12);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, image, _6, &_1, &_9, &_10, &_11, _8, &_12);
zephir_check_call_status();
}
}
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, _5);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _5);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_14, "imagesx", NULL, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_14, "imagesx", NULL, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _14 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_15, "imagesy", NULL, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_15, "imagesy", NULL, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _15 TSRMLS_CC);
} else {
@@ -68109,13 +68160,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) {
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 268, _3, &_1);
+ ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 269, _3, &_1);
zephir_check_call_status();
} else {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 2);
- ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 268, _4, &_1);
+ ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 269, _4, &_1);
zephir_check_call_status();
}
}
@@ -68138,7 +68189,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _sharpen) {
ZEPHIR_INIT_VAR(_0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, (-18 + ((amount * 0.08))));
- ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 192, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 2);
@@ -68187,15 +68238,15 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _sharpen) {
ZVAL_LONG(&_6, (amount - 8));
ZEPHIR_SINIT_VAR(_7);
ZVAL_LONG(&_7, 0);
- ZEPHIR_CALL_FUNCTION(&_8, "imageconvolution", NULL, 269, _5, matrix, &_6, &_7);
+ ZEPHIR_CALL_FUNCTION(&_8, "imageconvolution", NULL, 270, _5, matrix, &_6, &_7);
zephir_check_call_status();
if (zephir_is_true(_8)) {
_9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "imagesx", NULL, 260, _9);
+ ZEPHIR_CALL_FUNCTION(&_10, "imagesx", NULL, 261, _9);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _10 TSRMLS_CC);
_11 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_12, "imagesy", NULL, 261, _11);
+ ZEPHIR_CALL_FUNCTION(&_12, "imagesy", NULL, 262, _11);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _12 TSRMLS_CC);
}
@@ -68221,7 +68272,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZEPHIR_INIT_VAR(_0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_DOUBLE(&_1, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127)));
- ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 192, &_1);
zephir_check_call_status();
zephir_round(_0, _2, NULL, NULL TSRMLS_CC);
opacity = zephir_get_intval(_0);
@@ -68247,7 +68298,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZVAL_LONG(&_11, 0);
ZEPHIR_SINIT_VAR(_12);
ZVAL_LONG(&_12, 0);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, reflection, _7, &_1, &_10, &_11, &_12, _8, _9);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, reflection, _7, &_1, &_10, &_11, &_12, _8, _9);
zephir_check_call_status();
offset = 0;
while (1) {
@@ -68288,7 +68339,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZVAL_LONG(&_21, src_y);
ZEPHIR_SINIT_NVAR(_22);
ZVAL_LONG(&_22, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, line, _18, &_11, &_12, &_20, &_21, _19, &_22);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, line, _18, &_11, &_12, &_20, &_21, _19, &_22);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_11);
ZVAL_LONG(&_11, 4);
@@ -68300,7 +68351,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZVAL_LONG(&_21, 0);
ZEPHIR_SINIT_NVAR(_22);
ZVAL_LONG(&_22, dst_opacity);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_23, 270, line, &_11, &_12, &_20, &_21, &_22);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_23, 271, line, &_11, &_12, &_20, &_21, &_22);
zephir_check_call_status();
_24 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_11);
@@ -68313,18 +68364,18 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZVAL_LONG(&_21, 0);
ZEPHIR_SINIT_NVAR(_22);
ZVAL_LONG(&_22, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, reflection, line, &_11, &_12, &_20, &_21, _24, &_22);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, reflection, line, &_11, &_12, &_20, &_21, _24, &_22);
zephir_check_call_status();
offset++;
}
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, _14);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _14);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), reflection TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_25, "imagesx", NULL, 260, reflection);
+ ZEPHIR_CALL_FUNCTION(&_25, "imagesx", NULL, 261, reflection);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _25 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_26, "imagesy", NULL, 261, reflection);
+ ZEPHIR_CALL_FUNCTION(&_26, "imagesy", NULL, 262, reflection);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _26 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -68346,21 +68397,21 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) {
ZEPHIR_CALL_METHOD(&_0, watermark, "render", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&overlay, "imagecreatefromstring", NULL, 271, _0);
+ ZEPHIR_CALL_FUNCTION(&overlay, "imagecreatefromstring", NULL, 272, _0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 254, overlay, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, overlay, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 260, overlay);
+ ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 261, overlay);
zephir_check_call_status();
width = zephir_get_intval(_1);
- ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 261, overlay);
+ ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 262, overlay);
zephir_check_call_status();
height = zephir_get_intval(_2);
if (opacity < 100) {
ZEPHIR_INIT_VAR(_3);
ZEPHIR_SINIT_VAR(_4);
ZVAL_DOUBLE(&_4, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127)));
- ZEPHIR_CALL_FUNCTION(&_5, "abs", NULL, 191, &_4);
+ ZEPHIR_CALL_FUNCTION(&_5, "abs", NULL, 192, &_4);
zephir_check_call_status();
zephir_round(_3, _5, NULL, NULL TSRMLS_CC);
opacity = zephir_get_intval(_3);
@@ -68372,11 +68423,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) {
ZVAL_LONG(&_7, 127);
ZEPHIR_SINIT_VAR(_8);
ZVAL_LONG(&_8, opacity);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 264, overlay, &_4, &_6, &_7, &_8);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 265, overlay, &_4, &_6, &_7, &_8);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_4);
ZVAL_LONG(&_4, 3);
- ZEPHIR_CALL_FUNCTION(NULL, "imagelayereffect", NULL, 272, overlay, &_4);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagelayereffect", NULL, 273, overlay, &_4);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_4);
ZVAL_LONG(&_4, 0);
@@ -68386,11 +68437,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) {
ZVAL_LONG(&_7, width);
ZEPHIR_SINIT_NVAR(_8);
ZVAL_LONG(&_8, height);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", NULL, 273, overlay, &_4, &_6, &_7, &_8, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", NULL, 274, overlay, &_4, &_6, &_7, &_8, color);
zephir_check_call_status();
}
_9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 256, _9, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, _9, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_4);
@@ -68405,10 +68456,10 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) {
ZVAL_LONG(&_11, width);
ZEPHIR_SINIT_VAR(_12);
ZVAL_LONG(&_12, height);
- ZEPHIR_CALL_FUNCTION(&_5, "imagecopy", NULL, 267, _10, overlay, &_4, &_6, &_7, &_8, &_11, &_12);
+ ZEPHIR_CALL_FUNCTION(&_5, "imagecopy", NULL, 268, _10, overlay, &_4, &_6, &_7, &_8, &_11, &_12);
zephir_check_call_status();
if (zephir_is_true(_5)) {
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, overlay);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, overlay);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -68440,7 +68491,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZEPHIR_INIT_VAR(_0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_DOUBLE(&_1, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127)));
- ZEPHIR_CALL_FUNCTION(&_2, "abs", &_3, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "abs", &_3, 192, &_1);
zephir_check_call_status();
zephir_round(_0, _2, NULL, NULL TSRMLS_CC);
opacity = zephir_get_intval(_0);
@@ -68449,7 +68500,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_1, size);
ZEPHIR_SINIT_VAR(_4);
ZVAL_LONG(&_4, 0);
- ZEPHIR_CALL_FUNCTION(&space, "imagettfbbox", NULL, 274, &_1, &_4, fontfile, text);
+ ZEPHIR_CALL_FUNCTION(&space, "imagettfbbox", NULL, 275, &_1, &_4, fontfile, text);
zephir_check_call_status();
if (zephir_array_isset_long(space, 0)) {
ZEPHIR_OBS_VAR(_5);
@@ -68483,12 +68534,12 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, (s4 - s0));
- ZEPHIR_CALL_FUNCTION(&_12, "abs", &_3, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_12, "abs", &_3, 192, &_1);
zephir_check_call_status();
width = (zephir_get_numberval(_12) + 10);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, (s5 - s1));
- ZEPHIR_CALL_FUNCTION(&_13, "abs", &_3, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_13, "abs", &_3, 192, &_1);
zephir_check_call_status();
height = (zephir_get_numberval(_13) + 10);
if (offsetX < 0) {
@@ -68508,7 +68559,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_15, b);
ZEPHIR_SINIT_VAR(_16);
ZVAL_LONG(&_16, opacity);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 264, _14, &_1, &_4, &_15, &_16);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 265, _14, &_1, &_4, &_15, &_16);
zephir_check_call_status();
angle = 0;
_18 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
@@ -68520,17 +68571,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_15, offsetX);
ZEPHIR_SINIT_NVAR(_16);
ZVAL_LONG(&_16, offsetY);
- ZEPHIR_CALL_FUNCTION(NULL, "imagettftext", NULL, 275, _18, &_1, &_4, &_15, &_16, color, fontfile, text);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagettftext", NULL, 276, _18, &_1, &_4, &_15, &_16, color, fontfile, text);
zephir_check_call_status();
} else {
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, size);
- ZEPHIR_CALL_FUNCTION(&_12, "imagefontwidth", NULL, 276, &_1);
+ ZEPHIR_CALL_FUNCTION(&_12, "imagefontwidth", NULL, 277, &_1);
zephir_check_call_status();
width = (zephir_get_intval(_12) * zephir_fast_strlen_ev(text));
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, size);
- ZEPHIR_CALL_FUNCTION(&_13, "imagefontheight", NULL, 277, &_1);
+ ZEPHIR_CALL_FUNCTION(&_13, "imagefontheight", NULL, 278, &_1);
zephir_check_call_status();
height = zephir_get_intval(_13);
if (offsetX < 0) {
@@ -68550,7 +68601,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_15, b);
ZEPHIR_SINIT_NVAR(_16);
ZVAL_LONG(&_16, opacity);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 264, _14, &_1, &_4, &_15, &_16);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 265, _14, &_1, &_4, &_15, &_16);
zephir_check_call_status();
_19 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
@@ -68559,7 +68610,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_4, offsetX);
ZEPHIR_SINIT_NVAR(_15);
ZVAL_LONG(&_15, offsetY);
- ZEPHIR_CALL_FUNCTION(NULL, "imagestring", NULL, 278, _19, &_1, &_4, &_15, text, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagestring", NULL, 279, _19, &_1, &_4, &_15, text, color);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -68580,22 +68631,22 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZEPHIR_CALL_METHOD(&_0, mask, "render", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&maskImage, "imagecreatefromstring", NULL, 271, _0);
+ ZEPHIR_CALL_FUNCTION(&maskImage, "imagecreatefromstring", NULL, 272, _0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 260, maskImage);
+ ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 261, maskImage);
zephir_check_call_status();
mask_width = zephir_get_intval(_1);
- ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 261, maskImage);
+ ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 262, maskImage);
zephir_check_call_status();
mask_height = zephir_get_intval(_2);
alpha = 127;
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 254, maskImage, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 255, maskImage, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC);
ZEPHIR_CALL_METHOD(&newimage, this_ptr, "_create", NULL, 0, _4, _5);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 254, newimage, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 255, newimage, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_6);
ZVAL_LONG(&_6, 0);
@@ -68605,13 +68656,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZVAL_LONG(&_8, 0);
ZEPHIR_SINIT_VAR(_9);
ZVAL_LONG(&_9, alpha);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 264, newimage, &_6, &_7, &_8, &_9);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 265, newimage, &_6, &_7, &_8, &_9);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_6);
ZVAL_LONG(&_6, 0);
ZEPHIR_SINIT_NVAR(_7);
ZVAL_LONG(&_7, 0);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefill", NULL, 279, newimage, &_6, &_7, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefill", NULL, 280, newimage, &_6, &_7, color);
zephir_check_call_status();
_11 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
_12 = !ZEPHIR_IS_LONG(_11, mask_width);
@@ -68622,7 +68673,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
if (_12) {
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
_15 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&tempImage, "imagecreatetruecolor", NULL, 255, _14, _15);
+ ZEPHIR_CALL_FUNCTION(&tempImage, "imagecreatetruecolor", NULL, 256, _14, _15);
zephir_check_call_status();
_16 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
_17 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC);
@@ -68638,9 +68689,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZVAL_LONG(&_18, mask_width);
ZEPHIR_SINIT_VAR(_19);
ZVAL_LONG(&_19, mask_height);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopyresampled", NULL, 259, tempImage, maskImage, &_6, &_7, &_8, &_9, _16, _17, &_18, &_19);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopyresampled", NULL, 260, tempImage, maskImage, &_6, &_7, &_8, &_9, _16, _17, &_18, &_19);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 258, maskImage);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, maskImage);
zephir_check_call_status();
ZEPHIR_CPY_WRT(maskImage, tempImage);
}
@@ -68660,9 +68711,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZVAL_LONG(&_6, x);
ZEPHIR_SINIT_NVAR(_7);
ZVAL_LONG(&_7, y);
- ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 280, maskImage, &_6, &_7);
+ ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 281, maskImage, &_6, &_7);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 281, maskImage, index);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 282, maskImage, index);
zephir_check_call_status();
if (zephir_array_isset_string(color, SS("red"))) {
zephir_array_fetch_string(&_23, color, SL("red"), PH_NOISY | PH_READONLY, "phalcon/image/adapter/gd.zep", 431 TSRMLS_CC);
@@ -68675,10 +68726,10 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZVAL_LONG(&_7, x);
ZEPHIR_SINIT_NVAR(_8);
ZVAL_LONG(&_8, y);
- ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 280, _16, &_7, &_8);
+ ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 281, _16, &_7, &_8);
zephir_check_call_status();
_17 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 281, _17, index);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 282, _17, index);
zephir_check_call_status();
ZEPHIR_OBS_NVAR(r);
zephir_array_fetch_string(&r, color, SL("red"), PH_NOISY, "phalcon/image/adapter/gd.zep", 436 TSRMLS_CC);
@@ -68688,22 +68739,22 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
zephir_array_fetch_string(&b, color, SL("blue"), PH_NOISY, "phalcon/image/adapter/gd.zep", 436 TSRMLS_CC);
ZEPHIR_SINIT_NVAR(_7);
ZVAL_LONG(&_7, alpha);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 264, newimage, r, g, b, &_7);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 265, newimage, r, g, b, &_7);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_7);
ZVAL_LONG(&_7, x);
ZEPHIR_SINIT_NVAR(_8);
ZVAL_LONG(&_8, y);
- ZEPHIR_CALL_FUNCTION(NULL, "imagesetpixel", &_24, 282, newimage, &_7, &_8, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesetpixel", &_24, 283, newimage, &_7, &_8, color);
zephir_check_call_status();
y++;
}
x++;
}
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 258, _14);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, _14);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 258, maskImage);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, maskImage);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), newimage TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -68737,9 +68788,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _background) {
ZVAL_LONG(&_4, b);
ZEPHIR_SINIT_VAR(_5);
ZVAL_LONG(&_5, opacity);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 264, background, &_2, &_3, &_4, &_5);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 265, background, &_2, &_3, &_4, &_5);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 256, background, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, background, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_6 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
@@ -68752,11 +68803,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _background) {
ZVAL_LONG(&_4, 0);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, 0);
- ZEPHIR_CALL_FUNCTION(&_9, "imagecopy", NULL, 267, background, _6, &_2, &_3, &_4, &_5, _7, _8);
+ ZEPHIR_CALL_FUNCTION(&_9, "imagecopy", NULL, 268, background, _6, &_2, &_3, &_4, &_5, _7, _8);
zephir_check_call_status();
if (zephir_is_true(_9)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, _10);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), background TSRMLS_CC);
}
@@ -68784,7 +68835,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _blur) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 7);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_2, 270, _0, &_1);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_2, 271, _0, &_1);
zephir_check_call_status();
i++;
}
@@ -68823,7 +68874,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) {
ZVAL_LONG(&_3, x1);
ZEPHIR_SINIT_NVAR(_4);
ZVAL_LONG(&_4, y1);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorat", &_5, 280, _2, &_3, &_4);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorat", &_5, 281, _2, &_3, &_4);
zephir_check_call_status();
x2 = (x + amount);
y2 = (y + amount);
@@ -68836,7 +68887,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) {
ZVAL_LONG(&_7, x2);
ZEPHIR_SINIT_NVAR(_8);
ZVAL_LONG(&_8, y2);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", &_9, 273, _6, &_3, &_4, &_7, &_8, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", &_9, 274, _6, &_3, &_4, &_7, &_8, color);
zephir_check_call_status();
y += amount;
}
@@ -68869,30 +68920,30 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _save) {
zephir_fast_strtolower(ext, _1);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "gif", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_2, 0)) {
ZEPHIR_INIT_ZVAL_NREF(_4);
ZVAL_LONG(_4, 1);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_5, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_5, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _5 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 285, _7, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 286, _7, file);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "jpg", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
_8 = ZEPHIR_IS_LONG(_5, 0);
if (!(_8)) {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "jpeg", 0);
- ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
_8 = ZEPHIR_IS_LONG(_9, 0);
}
@@ -68901,64 +68952,64 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _save) {
ZVAL_LONG(_4, 2);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, quality);
- ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 286, _7, file, &_0);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 287, _7, file, &_0);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "png", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_5, 0)) {
ZEPHIR_INIT_ZVAL_NREF(_4);
ZVAL_LONG(_4, 3);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 287, _7, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 288, _7, file);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "wbmp", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_5, 0)) {
ZEPHIR_INIT_ZVAL_NREF(_4);
ZVAL_LONG(_4, 15);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 288, _7, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 289, _7, file);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "xbm", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_5, 0)) {
ZEPHIR_INIT_ZVAL_NREF(_4);
ZVAL_LONG(_4, 16);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 289, _7, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 290, _7, file);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
@@ -68996,25 +69047,25 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) {
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "gif", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_2, 0)) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 285, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 286, _4);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "jpg", 0);
- ZEPHIR_CALL_FUNCTION(&_6, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_6, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
_7 = ZEPHIR_IS_LONG(_6, 0);
if (!(_7)) {
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "jpeg", 0);
- ZEPHIR_CALL_FUNCTION(&_8, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_8, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
_7 = ZEPHIR_IS_LONG(_8, 0);
}
@@ -69022,45 +69073,45 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, quality);
- ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 286, _4, ZEPHIR_GLOBAL(global_null), &_1);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 287, _4, ZEPHIR_GLOBAL(global_null), &_1);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "png", 0);
- ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_9, 0)) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 287, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 288, _4);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "wbmp", 0);
- ZEPHIR_CALL_FUNCTION(&_10, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_10, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_10, 0)) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 288, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 289, _4);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "xbm", 0);
- ZEPHIR_CALL_FUNCTION(&_11, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_11, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_11, 0)) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 289, _4, ZEPHIR_GLOBAL(global_null));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 290, _4, ZEPHIR_GLOBAL(global_null));
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
@@ -69092,11 +69143,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _create) {
ZVAL_LONG(&_0, width);
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, height);
- ZEPHIR_CALL_FUNCTION(&image, "imagecreatetruecolor", NULL, 255, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&image, "imagecreatetruecolor", NULL, 256, &_0, &_1);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 256, image, ZEPHIR_GLOBAL(global_false));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, image, ZEPHIR_GLOBAL(global_false));
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 254, image, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, image, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
RETURN_CCTOR(image);
@@ -69112,7 +69163,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __destruct) {
ZEPHIR_OBS_VAR(image);
zephir_read_property_this(&image, this_ptr, SL("_image"), PH_NOISY_CC);
if (Z_TYPE_P(image) == IS_RESOURCE) {
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, image);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, image);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -69165,12 +69216,12 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, check) {
}
ZEPHIR_SINIT_VAR(_2);
ZVAL_STRING(&_2, "Imagick::IMAGICK_EXTNUM", 0);
- ZEPHIR_CALL_FUNCTION(&_3, "defined", NULL, 227, &_2);
+ ZEPHIR_CALL_FUNCTION(&_3, "defined", NULL, 228, &_2);
zephir_check_call_status();
if (zephir_is_true(_3)) {
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "Imagick::IMAGICK_EXTNUM", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 189, &_2);
+ ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 190, &_2);
zephir_check_call_status();
zephir_update_static_property_ce(phalcon_image_adapter_imagick_ce, SL("_version"), &_4 TSRMLS_CC);
}
@@ -69255,7 +69306,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, __construct) {
_12 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_13);
ZVAL_STRING(&_13, "Imagick::ALPHACHANNEL_SET", 0);
- ZEPHIR_CALL_FUNCTION(&_14, "constant", NULL, 189, &_13);
+ ZEPHIR_CALL_FUNCTION(&_14, "constant", NULL, 190, &_13);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, _12, "setimagealphachannel", NULL, 0, _14);
zephir_check_call_status();
@@ -69727,7 +69778,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
while (1) {
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::COMPOSITE_DSTOUT", 0);
- ZEPHIR_CALL_FUNCTION(&_12, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_12, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_3);
ZVAL_LONG(_3, 0);
@@ -69741,11 +69792,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
}
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::EVALUATE_MULTIPLY", 0);
- ZEPHIR_CALL_FUNCTION(&_17, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_17, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::CHANNEL_ALPHA", 0);
- ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_3);
ZVAL_LONG(_3, opacity);
@@ -69788,7 +69839,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::ALPHACHANNEL_SET", 0);
- ZEPHIR_CALL_FUNCTION(&_9, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_9, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, image, "setimagealphachannel", &_25, 0, _9);
zephir_check_call_status();
@@ -69805,7 +69856,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
_30 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::COMPOSITE_SRC", 0);
- ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_3);
ZVAL_LONG(_3, 0);
@@ -69835,7 +69886,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
while (1) {
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::COMPOSITE_OVER", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_2, "constant", &_15, 190, &_14);
zephir_check_call_status();
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC);
ZEPHIR_INIT_NVAR(_3);
@@ -69917,7 +69968,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _watermark) {
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_4);
ZVAL_STRING(&_4, "Imagick::COMPOSITE_OVER", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "constant", &_6, 189, &_4);
+ ZEPHIR_CALL_FUNCTION(&_5, "constant", &_6, 190, &_4);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_1);
ZVAL_LONG(_1, offsetX);
@@ -69980,7 +70031,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _text) {
ZVAL_LONG(&_2, g);
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, b);
- ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 186, &_0, &_1, &_2, &_3);
+ ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 187, &_0, &_1, &_2, &_3);
zephir_check_call_status();
ZEPHIR_INIT_VAR(pixel);
object_init_ex(pixel, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC));
@@ -70009,23 +70060,23 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _text) {
if (offsetX < 0) {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, offsetX);
- ZEPHIR_CALL_FUNCTION(&_5, "abs", &_6, 191, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "abs", &_6, 192, &_0);
zephir_check_call_status();
offsetX = zephir_get_numberval(_5);
if (offsetY < 0) {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, offsetY);
- ZEPHIR_CALL_FUNCTION(&_7, "abs", &_6, 191, &_0);
+ ZEPHIR_CALL_FUNCTION(&_7, "abs", &_6, 192, &_0);
zephir_check_call_status();
offsetY = zephir_get_numberval(_7);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0);
- ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 190, &_0);
zephir_check_call_status();
} else {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHEAST", 0);
- ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 190, &_0);
zephir_check_call_status();
}
}
@@ -70094,7 +70145,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _mask) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Imagick::COMPOSITE_DSTIN", 0);
- ZEPHIR_CALL_FUNCTION(&_6, "constant", &_7, 189, &_5);
+ ZEPHIR_CALL_FUNCTION(&_6, "constant", &_7, 190, &_5);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_2);
ZVAL_LONG(_2, 0);
@@ -70144,7 +70195,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) {
ZVAL_LONG(&_2, g);
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, b);
- ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 186, &_0, &_1, &_2, &_3);
+ ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 187, &_0, &_1, &_2, &_3);
zephir_check_call_status();
ZEPHIR_INIT_VAR(pixel1);
object_init_ex(pixel1, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC));
@@ -70183,7 +70234,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) {
if (!(zephir_is_true(_9))) {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::ALPHACHANNEL_SET", 0);
- ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 190, &_0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, background, "setimagealphachannel", &_13, 0, _11);
zephir_check_call_status();
@@ -70192,11 +70243,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) {
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::EVALUATE_MULTIPLY", 0);
- ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 190, &_0);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::CHANNEL_ALPHA", 0);
- ZEPHIR_CALL_FUNCTION(&_15, "constant", &_12, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_15, "constant", &_12, 190, &_0);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_4);
ZVAL_LONG(_4, opacity);
@@ -70210,7 +70261,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) {
_20 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::COMPOSITE_DISSOLVE", 0);
- ZEPHIR_CALL_FUNCTION(&_21, "constant", &_12, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_21, "constant", &_12, 190, &_0);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_4);
ZVAL_LONG(_4, 0);
@@ -70364,7 +70415,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) {
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "w", 0);
- ZEPHIR_CALL_FUNCTION(&fp, "fopen", NULL, 291, file, &_0);
+ ZEPHIR_CALL_FUNCTION(&fp, "fopen", NULL, 292, file, &_0);
zephir_check_call_status();
_11 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_CALL_METHOD(NULL, _11, "writeimagesfile", NULL, 0, fp);
@@ -70388,7 +70439,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::COMPRESSION_JPEG", 0);
- ZEPHIR_CALL_FUNCTION(&_15, "constant", NULL, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_15, "constant", NULL, 190, &_0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, _10, "setimagecompression", NULL, 0, _15);
zephir_check_call_status();
@@ -70460,7 +70511,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _render) {
if (_7) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_STRING(&_3, "Imagick::COMPRESSION_JPEG", 0);
- ZEPHIR_CALL_FUNCTION(&_9, "constant", NULL, 189, &_3);
+ ZEPHIR_CALL_FUNCTION(&_9, "constant", NULL, 190, &_3);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, image, "setimagecompression", NULL, 0, _9);
zephir_check_call_status();
@@ -71859,7 +71910,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, __construct) {
ZEPHIR_INIT_NVAR(mode);
ZVAL_STRING(mode, "ab", 1);
}
- ZEPHIR_CALL_FUNCTION(&handler, "fopen", NULL, 291, name, mode);
+ ZEPHIR_CALL_FUNCTION(&handler, "fopen", NULL, 292, name, mode);
zephir_check_call_status();
if (Z_TYPE_P(handler) != IS_RESOURCE) {
ZEPHIR_INIT_VAR(_0);
@@ -71891,7 +71942,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, getFormatter) {
if (Z_TYPE_P(_0) != IS_OBJECT) {
ZEPHIR_INIT_VAR(_1);
object_init_ex(_1, phalcon_logger_formatter_line_ce);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 295);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 296);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_formatter"), _1 TSRMLS_CC);
}
@@ -71903,7 +71954,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, logInternal) {
zval *context = NULL;
int type, time, ZEPHIR_LAST_CALL_STATUS;
- zval *message_param = NULL, *type_param = NULL, *time_param = NULL, *context_param = NULL, *fileHandler, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3, *_4;
+ zval *message_param = NULL, *type_param = NULL, *time_param = NULL, *context_param = NULL, *fileHandler, *_0 = NULL, *_1 = NULL, *_2, *_3;
zval *message = NULL;
ZEPHIR_MM_GROW();
@@ -71929,11 +71980,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, logInternal) {
ZVAL_LONG(_3, time);
ZEPHIR_CALL_METHOD(&_1, _0, "format", NULL, 0, message, _2, _3, context);
zephir_check_call_status();
- ZEPHIR_INIT_NVAR(_2);
- ZEPHIR_GET_CONSTANT(_2, "PHP_EOL");
- ZEPHIR_INIT_VAR(_4);
- ZEPHIR_CONCAT_VV(_4, _1, _2);
- zephir_fwrite(NULL, fileHandler, _4 TSRMLS_CC);
+ zephir_fwrite(NULL, fileHandler, _1 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
}
@@ -71975,7 +72022,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, __wakeup) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_logger_exception_ce, "Logger must be opened in append or write mode", "phalcon/logger/adapter/file.zep", 152);
return;
}
- ZEPHIR_CALL_FUNCTION(&_1, "fopen", NULL, 291, path, mode);
+ ZEPHIR_CALL_FUNCTION(&_1, "fopen", NULL, 292, path, mode);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_fileHandler"), _1 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -72060,15 +72107,15 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) {
if (!ZEPHIR_IS_TRUE_IDENTICAL(_1)) {
ZEPHIR_SINIT_VAR(_2);
ZVAL_STRING(&_2, "X-Wf-Protocol-1: http://meta.wildfirehq.org/Protocol/JsonStream/0.2", 0);
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 244, &_2);
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "X-Wf-1-Plugin-1: http://meta.firephp.org/Wildfire/Plugin/FirePHP/Library-FirePHPCore/0.3", 0);
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 244, &_2);
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "X-Wf-Structure-1: http://meta.firephp.org/Wildfire/Structure/FirePHP/FirebugConsole/0.1", 0);
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 244, &_2);
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2);
zephir_check_call_status();
zephir_update_static_property_ce(phalcon_logger_adapter_firephp_ce, SL("_initialized"), &(ZEPHIR_GLOBAL(global_true)) TSRMLS_CC);
}
@@ -72098,7 +72145,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) {
if (zephir_array_isset_long(chunk, (zephir_get_numberval(key) + 1))) {
zephir_concat_self_str(&content, SL("|\\") TSRMLS_CC);
}
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 244, content);
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, content);
zephir_check_call_status();
_10 = zephir_fetch_static_property_ce(phalcon_logger_adapter_firephp_ce, SL("_index") TSRMLS_CC);
ZEPHIR_INIT_ZVAL_NREF(_11);
@@ -72176,7 +72223,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Stream, __construct) {
ZEPHIR_INIT_NVAR(mode);
ZVAL_STRING(mode, "ab", 1);
}
- ZEPHIR_CALL_FUNCTION(&stream, "fopen", NULL, 291, name, mode);
+ ZEPHIR_CALL_FUNCTION(&stream, "fopen", NULL, 292, name, mode);
zephir_check_call_status();
if (!(zephir_is_true(stream))) {
ZEPHIR_INIT_VAR(_0);
@@ -72206,7 +72253,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Stream, getFormatter) {
if (Z_TYPE_P(_0) != IS_OBJECT) {
ZEPHIR_INIT_VAR(_1);
object_init_ex(_1, phalcon_logger_formatter_line_ce);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 295);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 296);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_formatter"), _1 TSRMLS_CC);
}
@@ -72308,7 +72355,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, __construct) {
ZEPHIR_INIT_NVAR(facility);
ZVAL_LONG(facility, 8);
}
- ZEPHIR_CALL_FUNCTION(NULL, "openlog", NULL, 296, name, option, facility);
+ ZEPHIR_CALL_FUNCTION(NULL, "openlog", NULL, 297, name, option, facility);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_opened"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
}
@@ -72368,7 +72415,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, logInternal) {
}
zephir_array_fetch_long(&_3, appliedFormat, 0, PH_NOISY | PH_READONLY, "phalcon/logger/adapter/syslog.zep", 102 TSRMLS_CC);
zephir_array_fetch_long(&_4, appliedFormat, 1, PH_NOISY | PH_READONLY, "phalcon/logger/adapter/syslog.zep", 102 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "syslog", NULL, 297, _3, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "syslog", NULL, 298, _3, _4);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -72383,7 +72430,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, close) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_opened"), PH_NOISY_CC);
if (zephir_is_true(_0)) {
- ZEPHIR_CALL_FUNCTION(NULL, "closelog", NULL, 298);
+ ZEPHIR_CALL_FUNCTION(NULL, "closelog", NULL, 299);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -72540,15 +72587,15 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Firephp, format) {
ZVAL_STRING(&_3, "5.3.6", 0);
ZEPHIR_SINIT_VAR(_4);
ZVAL_STRING(&_4, "<", 0);
- ZEPHIR_CALL_FUNCTION(&_0, "version_compare", NULL, 247, _1, &_3, &_4);
+ ZEPHIR_CALL_FUNCTION(&_0, "version_compare", NULL, 248, _1, &_3, &_4);
zephir_check_call_status();
if (!(zephir_is_true(_0))) {
param = (2) ? 1 : 0;
}
- ZEPHIR_CALL_FUNCTION(&backtrace, "debug_backtrace", NULL, 149, (param ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_FUNCTION(&backtrace, "debug_backtrace", NULL, 150, (param ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
Z_SET_ISREF_P(backtrace);
- ZEPHIR_CALL_FUNCTION(&lastTrace, "end", NULL, 169, backtrace);
+ ZEPHIR_CALL_FUNCTION(&lastTrace, "end", NULL, 170, backtrace);
Z_UNSET_ISREF_P(backtrace);
zephir_check_call_status();
if (zephir_array_isset_string(lastTrace, SS("file"))) {
@@ -72642,9 +72689,9 @@ ZEPHIR_INIT_CLASS(Phalcon_Logger_Formatter_Json) {
static PHP_METHOD(Phalcon_Logger_Formatter_Json, format) {
- zval *_1;
+ zval *_2;
int type, timestamp, ZEPHIR_LAST_CALL_STATUS;
- zval *message_param = NULL, *type_param = NULL, *timestamp_param = NULL, *context = NULL, *_0 = NULL, *_2 = NULL;
+ zval *message_param = NULL, *type_param = NULL, *timestamp_param = NULL, *context = NULL, *_0 = NULL, *_1, *_3 = NULL;
zval *message = NULL;
ZEPHIR_MM_GROW();
@@ -72664,17 +72711,21 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Json, format) {
zephir_get_strval(message, _0);
}
ZEPHIR_INIT_VAR(_1);
- zephir_create_array(_1, 3, 0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_2);
- ZVAL_LONG(_2, type);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "gettypestring", NULL, 0, _2);
+ zephir_create_array(_2, 3, 0 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_3);
+ ZVAL_LONG(_3, type);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "gettypestring", NULL, 0, _3);
zephir_check_call_status();
- zephir_array_update_string(&_1, SL("type"), &_0, PH_COPY | PH_SEPARATE);
- zephir_array_update_string(&_1, SL("message"), &message, PH_COPY | PH_SEPARATE);
- ZEPHIR_INIT_NVAR(_2);
- ZVAL_LONG(_2, timestamp);
- zephir_array_update_string(&_1, SL("timestamp"), &_2, PH_COPY | PH_SEPARATE);
- zephir_json_encode(return_value, &(return_value), _1, 0 TSRMLS_CC);
+ zephir_array_update_string(&_2, SL("type"), &_0, PH_COPY | PH_SEPARATE);
+ zephir_array_update_string(&_2, SL("message"), &message, PH_COPY | PH_SEPARATE);
+ ZEPHIR_INIT_NVAR(_3);
+ ZVAL_LONG(_3, timestamp);
+ zephir_array_update_string(&_2, SL("timestamp"), &_3, PH_COPY | PH_SEPARATE);
+ zephir_json_encode(_1, &(_1), _2, 0 TSRMLS_CC);
+ ZEPHIR_INIT_NVAR(_3);
+ ZEPHIR_GET_CONSTANT(_3, "PHP_EOL");
+ ZEPHIR_CONCAT_VV(return_value, _1, _3);
RETURN_MM();
}
@@ -72770,7 +72821,7 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, __construct) {
static PHP_METHOD(Phalcon_Logger_Formatter_Line, format) {
int type, timestamp, ZEPHIR_LAST_CALL_STATUS;
- zval *message_param = NULL, *type_param = NULL, *timestamp_param = NULL, *context = NULL, *format = NULL, *_0 = NULL, *_1, _2 = zval_used_for_init, *_3 = NULL, *_4;
+ zval *message_param = NULL, *type_param = NULL, *timestamp_param = NULL, *context = NULL, *format = NULL, *_0 = NULL, *_1, _2 = zval_used_for_init, *_3 = NULL, *_4 = NULL, *_5;
zval *message = NULL;
ZEPHIR_MM_GROW();
@@ -72791,7 +72842,7 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, format) {
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_dateFormat"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_2);
ZVAL_LONG(&_2, timestamp);
- ZEPHIR_CALL_FUNCTION(&_3, "date", NULL, 299, _1, &_2);
+ ZEPHIR_CALL_FUNCTION(&_3, "date", NULL, 300, _1, &_2);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "%date%", 0);
@@ -72813,7 +72864,11 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, format) {
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "%message%", 0);
zephir_fast_str_replace(&_0, &_2, message, format TSRMLS_CC);
- ZEPHIR_CPY_WRT(format, _0);
+ ZEPHIR_INIT_NVAR(_4);
+ ZEPHIR_GET_CONSTANT(_4, "PHP_EOL");
+ ZEPHIR_INIT_VAR(_5);
+ ZEPHIR_CONCAT_VV(_5, _0, _4);
+ ZEPHIR_CPY_WRT(format, _5);
if (Z_TYPE_P(context) == IS_ARRAY) {
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "interpolate", NULL, 0, format, context);
zephir_check_call_status();
@@ -73841,7 +73896,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, _getResultset) {
}
ZEPHIR_INIT_VAR(collections);
array_init(collections);
- ZEPHIR_CALL_FUNCTION(&_0, "iterator_to_array", NULL, 300, documentsCursor);
+ ZEPHIR_CALL_FUNCTION(&_0, "iterator_to_array", NULL, 301, documentsCursor);
zephir_check_call_status();
zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/collection.zep", 440);
for (
@@ -74304,7 +74359,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, save) {
zephir_update_property_this(this_ptr, SL("_errorMessages"), _1 TSRMLS_CC);
ZEPHIR_OBS_VAR(disableEvents);
zephir_read_static_property_ce(&disableEvents, phalcon_mvc_collection_ce, SL("_disableEvents") TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_2, this_ptr, "_presave", NULL, 301, dependencyInjector, disableEvents, exists);
+ ZEPHIR_CALL_METHOD(&_2, this_ptr, "_presave", NULL, 302, dependencyInjector, disableEvents, exists);
zephir_check_call_status();
if (ZEPHIR_IS_FALSE_IDENTICAL(_2)) {
RETURN_MM_BOOL(0);
@@ -74333,7 +74388,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, save) {
} else {
success = 0;
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_postsave", NULL, 302, disableEvents, (success ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), exists);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_postsave", NULL, 303, disableEvents, (success ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), exists);
zephir_check_call_status();
RETURN_MM();
@@ -75662,7 +75717,7 @@ static PHP_METHOD(Phalcon_Mvc_Micro, mount) {
if (zephir_is_true(_0)) {
ZEPHIR_INIT_VAR(lazyHandler);
object_init_ex(lazyHandler, phalcon_mvc_micro_lazyloader_ce);
- ZEPHIR_CALL_METHOD(NULL, lazyHandler, "__construct", NULL, 303, mainHandler);
+ ZEPHIR_CALL_METHOD(NULL, lazyHandler, "__construct", NULL, 304, mainHandler);
zephir_check_call_status();
} else {
ZEPHIR_CPY_WRT(lazyHandler, mainHandler);
@@ -75811,11 +75866,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, setService) {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
ZEPHIR_INIT_NVAR(dependencyInjector);
object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce);
- ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 173);
+ ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "set", NULL, 304, serviceName, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "set", NULL, 305, serviceName, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -75848,11 +75903,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, hasService) {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
ZEPHIR_INIT_NVAR(dependencyInjector);
object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce);
- ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 173);
+ ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "has", NULL, 305, serviceName);
+ ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "has", NULL, 306, serviceName);
zephir_check_call_status();
RETURN_MM();
@@ -75885,11 +75940,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, getService) {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
ZEPHIR_INIT_NVAR(dependencyInjector);
object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce);
- ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 173);
+ ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "get", NULL, 306, serviceName);
+ ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "get", NULL, 307, serviceName);
zephir_check_call_status();
RETURN_MM();
@@ -75910,11 +75965,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, getSharedService) {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
ZEPHIR_INIT_NVAR(dependencyInjector);
object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce);
- ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 173);
+ ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "getshared", NULL, 307, serviceName);
+ ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "getshared", NULL, 308, serviceName);
zephir_check_call_status();
RETURN_MM();
@@ -77404,12 +77459,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, query) {
ZEPHIR_CALL_METHOD(NULL, criteria, "__construct", NULL, 0);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(NULL, criteria, "setdi", NULL, 308, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "setdi", NULL, 309, dependencyInjector);
zephir_check_call_status();
}
ZEPHIR_INIT_NVAR(_2);
zephir_get_called_class(_2 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 309, _2);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 310, _2);
zephir_check_call_status();
RETURN_CCTOR(criteria);
@@ -78964,9 +79019,9 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) {
break;
}
if (ZEPHIR_IS_LONG(bindType, 3) || ZEPHIR_IS_LONG(bindType, 7)) {
- ZEPHIR_CALL_FUNCTION(&_1, "floatval", &_8, 310, snapshotValue);
+ ZEPHIR_CALL_FUNCTION(&_1, "floatval", &_8, 311, snapshotValue);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_9, "floatval", &_8, 310, value);
+ ZEPHIR_CALL_FUNCTION(&_9, "floatval", &_8, 311, value);
zephir_check_call_status();
changed = !ZEPHIR_IS_IDENTICAL(_1, _9);
break;
@@ -79403,7 +79458,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, save) {
ZEPHIR_INIT_NVAR(_4);
object_init_ex(_4, phalcon_mvc_model_validationfailed_ce);
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_errorMessages"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 311, this_ptr, _3);
+ ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 312, this_ptr, _3);
zephir_check_call_status();
zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 2877 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -80191,7 +80246,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) {
int ZEPHIR_LAST_CALL_STATUS;
HashTable *_1;
HashPosition _0;
- zval *data_param = NULL, *columnMap = NULL, *key = NULL, *value = NULL, *snapshot, *attribute = NULL, **_2, *_3 = NULL, *_4 = NULL, *_6 = NULL;
+ zval *data_param = NULL, *columnMap = NULL, *key = NULL, *value = NULL, *snapshot, *attribute = NULL, **_2, *_3 = NULL, *_4 = NULL;
zval *data = NULL;
ZEPHIR_MM_GROW();
@@ -80207,7 +80262,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) {
if (Z_TYPE_P(columnMap) == IS_ARRAY) {
ZEPHIR_INIT_VAR(snapshot);
array_init(snapshot);
- zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3606);
+ zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3605);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -80250,12 +80305,8 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) {
continue;
}
}
- ZEPHIR_OBS_NVAR(_6);
- zephir_array_fetch_long(&_6, attribute, 0, PH_NOISY, "phalcon/mvc/model.zep", 3600 TSRMLS_CC);
- zephir_array_update_zval(&snapshot, _6, &value, PH_COPY | PH_SEPARATE);
- } else {
- zephir_array_update_zval(&snapshot, attribute, &value, PH_COPY | PH_SEPARATE);
}
+ zephir_array_update_zval(&snapshot, attribute, &value, PH_COPY | PH_SEPARATE);
}
zephir_update_property_this(this_ptr, SL("_snapshot"), snapshot TSRMLS_CC);
RETURN_MM_NULL();
@@ -80300,12 +80351,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_OBS_VAR(snapshot);
zephir_read_property_this(&snapshot, this_ptr, SL("_snapshot"), PH_NOISY_CC);
if (Z_TYPE_P(snapshot) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3645);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3644);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC);
if (!ZEPHIR_IS_LONG(_0, 0)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3652);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3651);
return;
}
ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0);
@@ -80327,7 +80378,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not part of the model");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3684 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3683 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80339,7 +80390,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not part of the model");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3688 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3687 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80352,7 +80403,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not defined on the model");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3696 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3695 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80364,14 +80415,14 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_CONCAT_SVS(_3, "The field '", fieldName, "' was not found in the snapshot");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3703 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3702 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
RETURN_MM_BOOL(!ZEPHIR_IS_EQUAL(value, originalValue));
}
ZEPHIR_INIT_NVAR(_1);
- zephir_is_iterable(allAttributes, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 3739);
+ zephir_is_iterable(allAttributes, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 3738);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
@@ -80406,12 +80457,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) {
ZEPHIR_OBS_VAR(snapshot);
zephir_read_property_this(&snapshot, this_ptr, SL("_snapshot"), PH_NOISY_CC);
if (Z_TYPE_P(snapshot) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3752);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3751);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC);
if (!ZEPHIR_IS_LONG(_0, 0)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3759);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3758);
return;
}
ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0);
@@ -80427,7 +80478,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) {
ZEPHIR_INIT_VAR(changed);
array_init(changed);
ZEPHIR_INIT_VAR(_1);
- zephir_is_iterable(allAttributes, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3813);
+ zephir_is_iterable(allAttributes, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3812);
for (
; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS
; zephir_hash_move_forward_ex(_3, &_2)
@@ -80435,17 +80486,17 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) {
ZEPHIR_GET_HMKEY(name, _3, _2);
ZEPHIR_GET_HVALUE(_1, _4);
if (!(zephir_array_isset(snapshot, name))) {
- zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3792);
+ zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3791);
continue;
}
ZEPHIR_OBS_NVAR(value);
if (!(zephir_fetch_property_zval(&value, this_ptr, name, PH_SILENT_CC))) {
- zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3800);
+ zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3799);
continue;
}
- zephir_array_fetch(&_5, snapshot, name, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 3807 TSRMLS_CC);
+ zephir_array_fetch(&_5, snapshot, name, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 3806 TSRMLS_CC);
if (!ZEPHIR_IS_EQUAL(value, _5)) {
- zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3808);
+ zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3807);
continue;
}
}
@@ -80502,7 +80553,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getRelated) {
ZEPHIR_CONCAT_SVSVS(_3, "There is no defined relations for the model '", className, "' using alias '", alias, "'");
ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_2, "phalcon/mvc/model.zep", 3855 TSRMLS_CC);
+ zephir_throw_exception_debug(_2, "phalcon/mvc/model.zep", 3854 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80640,7 +80691,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __call) {
ZEPHIR_CONCAT_SVSVS(_2, "The method '", method, "' doesn't exist on model '", modelName, "'");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3947 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3946 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -80702,7 +80753,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) {
ZEPHIR_CONCAT_SVSVS(_2, "The static method '", method, "' doesn't exist on model '", modelName, "'");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3998 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3997 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80714,7 +80765,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) {
ZEPHIR_CONCAT_SVS(_3, "The static method '", method, "' requires one argument");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4002 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4001 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80751,7 +80802,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) {
ZEPHIR_CONCAT_SVS(_2, "Cannot resolve attribute '", extraMethod, "' in the model");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4036 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4035 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80810,7 +80861,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __set) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(related);
array_init(related);
- zephir_is_iterable(value, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4100);
+ zephir_is_iterable(value, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4099);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -80819,7 +80870,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __set) {
ZEPHIR_GET_HVALUE(item, _3);
if (Z_TYPE_P(item) == IS_OBJECT) {
if (zephir_instance_of_ev(item, phalcon_mvc_modelinterface_ce TSRMLS_CC)) {
- zephir_array_append(&related, item, PH_SEPARATE, "phalcon/mvc/model.zep", 4087);
+ zephir_array_append(&related, item, PH_SEPARATE, "phalcon/mvc/model.zep", 4086);
}
} else {
ZEPHIR_INIT_NVAR(lowerKey);
@@ -81006,7 +81057,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, unserialize) {
ZEPHIR_CALL_CE_STATIC(&dependencyInjector, phalcon_di_ce, "getdefault", &_0, 1);
zephir_check_call_status();
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 4224);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 4223);
return;
}
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
@@ -81017,13 +81068,13 @@ static PHP_METHOD(Phalcon_Mvc_Model, unserialize) {
zephir_check_call_status();
ZEPHIR_CPY_WRT(manager, _1);
if (Z_TYPE_P(manager) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 4237);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 4236);
return;
}
zephir_update_property_this(this_ptr, SL("_modelsManager"), manager TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, manager, "initialize", NULL, 0, this_ptr);
zephir_check_call_status();
- zephir_is_iterable(attributes, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 4256);
+ zephir_is_iterable(attributes, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 4255);
for (
; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS
; zephir_hash_move_forward_ex(_4, &_3)
@@ -81073,7 +81124,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, toArray) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_0, metaData, "getattributes", NULL, 0, this_ptr);
zephir_check_call_status();
- zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4320);
+ zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4319);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -81089,7 +81140,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, toArray) {
ZEPHIR_CONCAT_SVS(_5, "Column '", attribute, "' doesn't make part of the column map");
ZEPHIR_CALL_METHOD(NULL, _4, "__construct", &_6, 9, _5);
zephir_check_call_status();
- zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 4298 TSRMLS_CC);
+ zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 4297 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
} else {
@@ -82839,9 +82890,11 @@ static PHP_METHOD(Phalcon_Mvc_Url, getBasePath) {
static PHP_METHOD(Phalcon_Mvc_Url, get) {
+ unsigned char _10, _12;
int ZEPHIR_LAST_CALL_STATUS;
- zend_bool _0, _1;
- zval *uri = NULL, *args = NULL, *local = NULL, *baseUri = NULL, *router = NULL, *dependencyInjector = NULL, *routeName, *route = NULL, *queryString = NULL, *_2, *_3 = NULL, _4 = zval_used_for_init, *_5, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9;
+ zend_bool _0, _1, _11;
+ zval *strUri = NULL, *_9 = NULL;
+ zval *uri = NULL, *args = NULL, *local = NULL, *baseUri = NULL, *router = NULL, *dependencyInjector = NULL, *routeName, *route = NULL, *queryString = NULL, *_2, *_3 = NULL, _4 = zval_used_for_init, *_5, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_13;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 0, 4, &uri, &args, &local, &baseUri);
@@ -82869,9 +82922,9 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
if (Z_TYPE_P(local) == IS_NULL) {
_0 = Z_TYPE_P(uri) == IS_STRING;
if (_0) {
- _1 = zephir_memnstr_str(uri, SL("//"), "phalcon/mvc/url.zep", 178);
+ _1 = zephir_memnstr_str(uri, SL("//"), "phalcon/mvc/url.zep", 181);
if (!(_1)) {
- _1 = zephir_memnstr_str(uri, SL(":"), "phalcon/mvc/url.zep", 178);
+ _1 = zephir_memnstr_str(uri, SL(":"), "phalcon/mvc/url.zep", 181);
}
_0 = _1;
}
@@ -82899,7 +82952,7 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
if (Z_TYPE_P(uri) == IS_ARRAY) {
ZEPHIR_OBS_VAR(routeName);
if (!(zephir_array_isset_string_fetch(&routeName, uri, SS("for"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_url_exception_ce, "It's necessary to define the route name with the parameter 'for'", "phalcon/mvc/url.zep", 196);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_url_exception_ce, "It's necessary to define the route name with the parameter 'for'", "phalcon/mvc/url.zep", 199);
return;
}
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_router"), PH_NOISY_CC);
@@ -82908,7 +82961,7 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
ZEPHIR_CPY_WRT(dependencyInjector, _5);
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_url_exception_ce, "A dependency injector container is required to obtain the 'router' service", "phalcon/mvc/url.zep", 208);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_url_exception_ce, "A dependency injector container is required to obtain the 'router' service", "phalcon/mvc/url.zep", 211);
return;
}
ZEPHIR_INIT_NVAR(_3);
@@ -82929,7 +82982,7 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
ZEPHIR_CONCAT_SVS(_7, "Cannot obtain a route using the name '", routeName, "'");
ZEPHIR_CALL_METHOD(NULL, _3, "__construct", NULL, 9, _7);
zephir_check_call_status();
- zephir_throw_exception_debug(_3, "phalcon/mvc/url.zep", 220 TSRMLS_CC);
+ zephir_throw_exception_debug(_3, "phalcon/mvc/url.zep", 223 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -82942,12 +82995,35 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
ZEPHIR_CPY_WRT(uri, _3);
}
if (zephir_is_true(local)) {
- ZEPHIR_INIT_LNVAR(_7);
- ZEPHIR_CONCAT_VV(_7, baseUri, uri);
- ZEPHIR_CPY_WRT(uri, _7);
+ zephir_get_strval(_9, uri);
+ ZEPHIR_CPY_WRT(strUri, _9);
+ _0 = ZEPHIR_IS_STRING(baseUri, "/");
+ if (_0) {
+ _0 = zephir_fast_strlen_ev(strUri) > 2;
+ }
+ _1 = _0;
+ if (_1) {
+ _10 = ZEPHIR_STRING_OFFSET(strUri, 0);
+ _1 = _10 == '/';
+ }
+ _11 = _1;
+ if (_11) {
+ _12 = ZEPHIR_STRING_OFFSET(strUri, 1);
+ _11 = _12 != '/';
+ }
+ ZEPHIR_INIT_NVAR(uri);
+ if (_11) {
+ ZEPHIR_SINIT_NVAR(_4);
+ ZVAL_LONG(&_4, 1);
+ ZEPHIR_INIT_NVAR(_3);
+ zephir_substr(_3, strUri, 1 , 0, ZEPHIR_SUBSTR_NO_LENGTH);
+ ZEPHIR_CONCAT_VV(uri, baseUri, _3);
+ } else {
+ ZEPHIR_CONCAT_VV(uri, baseUri, strUri);
+ }
}
if (zephir_is_true(args)) {
- ZEPHIR_CALL_FUNCTION(&queryString, "http_build_query", NULL, 367, args);
+ ZEPHIR_CALL_FUNCTION(&queryString, "http_build_query", NULL, 369, args);
zephir_check_call_status();
_0 = Z_TYPE_P(queryString) == IS_STRING;
if (_0) {
@@ -82963,9 +83039,9 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
ZEPHIR_CONCAT_SV(_7, "&", queryString);
zephir_concat_self(&uri, _7 TSRMLS_CC);
} else {
- ZEPHIR_INIT_VAR(_9);
- ZEPHIR_CONCAT_SV(_9, "?", queryString);
- zephir_concat_self(&uri, _9 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_13);
+ ZEPHIR_CONCAT_SV(_13, "?", queryString);
+ zephir_concat_self(&uri, _13 TSRMLS_CC);
}
}
}
@@ -83598,19 +83674,19 @@ static PHP_METHOD(Phalcon_Mvc_View, _loadTemplateEngines) {
if (Z_TYPE_P(registeredEngines) != IS_ARRAY) {
ZEPHIR_INIT_VAR(_1);
object_init_ex(_1, phalcon_mvc_view_engine_php_ce);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 368, this_ptr, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 370, this_ptr, dependencyInjector);
zephir_check_call_status();
zephir_array_update_string(&engines, SL(".phtml"), &_1, PH_COPY | PH_SEPARATE);
} else {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "A dependency injector container is required to obtain the application services", "phalcon/mvc/view.zep", 524);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "A dependency injector container is required to obtain the application services", "phalcon/mvc/view.zep", 526);
return;
}
ZEPHIR_INIT_VAR(arguments);
zephir_create_array(arguments, 2, 0 TSRMLS_CC);
zephir_array_fast_append(arguments, this_ptr);
zephir_array_fast_append(arguments, dependencyInjector);
- zephir_is_iterable(registeredEngines, &_3, &_2, 0, 0, "phalcon/mvc/view.zep", 553);
+ zephir_is_iterable(registeredEngines, &_3, &_2, 0, 0, "phalcon/mvc/view.zep", 555);
for (
; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS
; zephir_hash_move_forward_ex(_3, &_2)
@@ -83634,7 +83710,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _loadTemplateEngines) {
ZEPHIR_CONCAT_SV(_6, "Invalid template engine registration for extension: ", extension);
ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6);
zephir_check_call_status();
- zephir_throw_exception_debug(_5, "phalcon/mvc/view.zep", 547 TSRMLS_CC);
+ zephir_throw_exception_debug(_5, "phalcon/mvc/view.zep", 549 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -83728,7 +83804,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _engineRender) {
zephir_read_property_this(&viewParams, this_ptr, SL("_viewParams"), PH_NOISY_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_eventsManager"), PH_NOISY_CC);
ZEPHIR_CPY_WRT(eventsManager, _4);
- zephir_is_iterable(engines, &_6, &_5, 0, 0, "phalcon/mvc/view.zep", 671);
+ zephir_is_iterable(engines, &_6, &_5, 0, 0, "phalcon/mvc/view.zep", 673);
for (
; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS
; zephir_hash_move_forward_ex(_6, &_5)
@@ -83778,7 +83854,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _engineRender) {
ZEPHIR_CONCAT_SVS(_11, "View '", viewsDirPath, "' was not found in the views directory");
ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _11);
zephir_check_call_status();
- zephir_throw_exception_debug(_8, "phalcon/mvc/view.zep", 682 TSRMLS_CC);
+ zephir_throw_exception_debug(_8, "phalcon/mvc/view.zep", 684 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -83843,7 +83919,7 @@ static PHP_METHOD(Phalcon_Mvc_View, exists) {
}
exists = 0;
ZEPHIR_INIT_NVAR(_0);
- zephir_is_iterable(engines, &_2, &_1, 0, 0, "phalcon/mvc/view.zep", 730);
+ zephir_is_iterable(engines, &_2, &_1, 0, 0, "phalcon/mvc/view.zep", 732);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -83937,7 +84013,7 @@ static PHP_METHOD(Phalcon_Mvc_View, render) {
ZEPHIR_CPY_WRT(renderView, _3);
} else {
ZEPHIR_OBS_NVAR(renderView);
- zephir_array_fetch_long(&renderView, pickView, 0, PH_NOISY, "phalcon/mvc/view.zep", 803 TSRMLS_CC);
+ zephir_array_fetch_long(&renderView, pickView, 0, PH_NOISY, "phalcon/mvc/view.zep", 805 TSRMLS_CC);
ZEPHIR_OBS_VAR(pickViewAction);
if (zephir_array_isset_long_fetch(&pickViewAction, pickView, 1, 0 TSRMLS_CC)) {
ZEPHIR_CPY_WRT(layoutName, pickViewAction);
@@ -83995,7 +84071,7 @@ static PHP_METHOD(Phalcon_Mvc_View, render) {
zephir_read_property_this(&templatesBefore, this_ptr, SL("_templatesBefore"), PH_NOISY_CC);
if (Z_TYPE_P(templatesBefore) == IS_ARRAY) {
silence = 0;
- zephir_is_iterable(templatesBefore, &_11, &_10, 0, 0, "phalcon/mvc/view.zep", 879);
+ zephir_is_iterable(templatesBefore, &_11, &_10, 0, 0, "phalcon/mvc/view.zep", 881);
for (
; zephir_hash_get_current_data_ex(_11, (void**) &_12, &_10) == SUCCESS
; zephir_hash_move_forward_ex(_11, &_10)
@@ -84030,7 +84106,7 @@ static PHP_METHOD(Phalcon_Mvc_View, render) {
zephir_read_property_this(&templatesAfter, this_ptr, SL("_templatesAfter"), PH_NOISY_CC);
if (Z_TYPE_P(templatesAfter) == IS_ARRAY) {
silence = 0;
- zephir_is_iterable(templatesAfter, &_15, &_14, 0, 0, "phalcon/mvc/view.zep", 910);
+ zephir_is_iterable(templatesAfter, &_15, &_14, 0, 0, "phalcon/mvc/view.zep", 912);
for (
; zephir_hash_get_current_data_ex(_15, (void**) &_16, &_14) == SUCCESS
; zephir_hash_move_forward_ex(_15, &_14)
@@ -84102,17 +84178,17 @@ static PHP_METHOD(Phalcon_Mvc_View, pick) {
} else {
ZEPHIR_INIT_VAR(layout);
ZVAL_NULL(layout);
- if (zephir_memnstr_str(renderView, SL("/"), "phalcon/mvc/view.zep", 983)) {
+ if (zephir_memnstr_str(renderView, SL("/"), "phalcon/mvc/view.zep", 985)) {
ZEPHIR_INIT_VAR(parts);
zephir_fast_explode_str(parts, SL("/"), renderView, LONG_MAX TSRMLS_CC);
ZEPHIR_OBS_NVAR(layout);
- zephir_array_fetch_long(&layout, parts, 0, PH_NOISY, "phalcon/mvc/view.zep", 984 TSRMLS_CC);
+ zephir_array_fetch_long(&layout, parts, 0, PH_NOISY, "phalcon/mvc/view.zep", 986 TSRMLS_CC);
}
ZEPHIR_INIT_NVAR(pickView);
zephir_create_array(pickView, 1, 0 TSRMLS_CC);
zephir_array_fast_append(pickView, renderView);
if (Z_TYPE_P(layout) != IS_NULL) {
- zephir_array_append(&pickView, layout, PH_SEPARATE, "phalcon/mvc/view.zep", 989);
+ zephir_array_append(&pickView, layout, PH_SEPARATE, "phalcon/mvc/view.zep", 991);
}
}
zephir_update_property_this(this_ptr, SL("_pickView"), pickView TSRMLS_CC);
@@ -84149,7 +84225,7 @@ static PHP_METHOD(Phalcon_Mvc_View, getPartial) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, this_ptr, "partial", NULL, 0, partialPath, params);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", NULL, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", NULL, 291);
zephir_check_call_status();
RETURN_MM();
@@ -84304,7 +84380,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _createCache) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
ZEPHIR_CPY_WRT(dependencyInjector, _0);
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "A dependency injector container is required to obtain the view cache services", "phalcon/mvc/view.zep", 1163);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "A dependency injector container is required to obtain the view cache services", "phalcon/mvc/view.zep", 1165);
return;
}
ZEPHIR_INIT_VAR(cacheService);
@@ -84316,7 +84392,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _createCache) {
if (zephir_array_isset_string_fetch(&cacheOptions, viewOptions, SS("cache"), 0 TSRMLS_CC)) {
if (zephir_array_isset_string(cacheOptions, SS("service"))) {
ZEPHIR_OBS_NVAR(cacheService);
- zephir_array_fetch_string(&cacheService, cacheOptions, SL("service"), PH_NOISY, "phalcon/mvc/view.zep", 1172 TSRMLS_CC);
+ zephir_array_fetch_string(&cacheService, cacheOptions, SL("service"), PH_NOISY, "phalcon/mvc/view.zep", 1174 TSRMLS_CC);
}
}
}
@@ -84324,7 +84400,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _createCache) {
zephir_check_call_status();
ZEPHIR_CPY_WRT(viewCache, _1);
if (Z_TYPE_P(viewCache) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "The injected caching service is invalid", "phalcon/mvc/view.zep", 1182);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "The injected caching service is invalid", "phalcon/mvc/view.zep", 1184);
return;
}
RETURN_CCTOR(viewCache);
@@ -84392,7 +84468,7 @@ static PHP_METHOD(Phalcon_Mvc_View, cache) {
ZEPHIR_INIT_NVAR(cacheOptions);
array_init(cacheOptions);
}
- zephir_is_iterable(options, &_1, &_0, 0, 0, "phalcon/mvc/view.zep", 1250);
+ zephir_is_iterable(options, &_1, &_0, 0, 0, "phalcon/mvc/view.zep", 1252);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -85730,7 +85806,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection_Behavior_Timestampable, notify) {
ZVAL_NULL(timestamp);
ZEPHIR_OBS_VAR(format);
if (zephir_array_isset_string_fetch(&format, options, SS("format"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 299, format);
+ ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 300, format);
zephir_check_call_status();
} else {
ZEPHIR_OBS_VAR(generator);
@@ -87271,7 +87347,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, inWhere) {
array_init(bindParams);
ZEPHIR_INIT_VAR(bindKeys);
array_init(bindKeys);
- zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 450);
+ zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 451);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -87281,7 +87357,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, inWhere) {
ZEPHIR_CONCAT_SV(key, "AP", hiddenParam);
ZEPHIR_INIT_NVAR(queryKey);
ZEPHIR_CONCAT_SVS(queryKey, ":", key, ":");
- zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 441);
+ zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 442);
zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE);
ZEPHIR_SEPARATE(hiddenParam);
zephir_increment(hiddenParam);
@@ -87330,7 +87406,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, notInWhere) {
array_init(bindParams);
ZEPHIR_INIT_VAR(bindKeys);
array_init(bindKeys);
- zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 487);
+ zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 488);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -87340,7 +87416,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, notInWhere) {
ZEPHIR_CONCAT_SV(key, "AP", hiddenParam);
ZEPHIR_INIT_LNVAR(_3);
ZEPHIR_CONCAT_SVS(_3, ":", key, ":");
- zephir_array_append(&bindKeys, _3, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 477);
+ zephir_array_append(&bindKeys, _3, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 478);
zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE);
ZEPHIR_SEPARATE(hiddenParam);
zephir_increment(hiddenParam);
@@ -87669,14 +87745,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, getParams) {
static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) {
- zend_bool _6;
+ zend_bool _6, _7;
HashTable *_4;
HashPosition _3;
zend_class_entry *_2;
int ZEPHIR_LAST_CALL_STATUS;
zval *data = NULL;
zval *modelName = NULL;
- zval *dependencyInjector, *modelName_param = NULL, *data_param = NULL, *conditions, *field = NULL, *value = NULL, *type = NULL, *metaData = NULL, *model, *dataTypes = NULL, *bind, *criteria, *_0 = NULL, *_1 = NULL, **_5, *_7 = NULL, *_8 = NULL;
+ zval *dependencyInjector, *modelName_param = NULL, *data_param = NULL, *attribute = NULL, *conditions, *field = NULL, *value = NULL, *type = NULL, *metaData = NULL, *model, *dataTypes = NULL, *bind, *criteria, *columnMap = NULL, *_0 = NULL, *_1 = NULL, **_5, *_8 = NULL, *_9 = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &dependencyInjector, &modelName_param, &data_param);
@@ -87714,35 +87790,47 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) {
}
ZEPHIR_CALL_METHOD(&dataTypes, metaData, "getdatatypes", NULL, 0, model);
zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&columnMap, metaData, "getreversecolumnmap", NULL, 0, model);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(bind);
array_init(bind);
- zephir_is_iterable(data, &_4, &_3, 0, 0, "phalcon/mvc/model/criteria.zep", 720);
+ zephir_is_iterable(data, &_4, &_3, 0, 0, "phalcon/mvc/model/criteria.zep", 732);
for (
; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS
; zephir_hash_move_forward_ex(_4, &_3)
) {
ZEPHIR_GET_HMKEY(field, _4, _3);
ZEPHIR_GET_HVALUE(value, _5);
+ _6 = Z_TYPE_P(columnMap) == IS_ARRAY;
+ if (_6) {
+ _6 = (zephir_fast_count_int(columnMap TSRMLS_CC)) ? 1 : 0;
+ }
+ if (_6) {
+ ZEPHIR_OBS_NVAR(attribute);
+ zephir_array_fetch(&attribute, columnMap, field, PH_NOISY, "phalcon/mvc/model/criteria.zep", 709 TSRMLS_CC);
+ } else {
+ ZEPHIR_CPY_WRT(attribute, field);
+ }
ZEPHIR_OBS_NVAR(type);
- if (zephir_array_isset_fetch(&type, dataTypes, field, 0 TSRMLS_CC)) {
- _6 = Z_TYPE_P(value) != IS_NULL;
- if (_6) {
- _6 = !ZEPHIR_IS_STRING_IDENTICAL(value, "");
+ if (zephir_array_isset_fetch(&type, dataTypes, attribute, 0 TSRMLS_CC)) {
+ _7 = Z_TYPE_P(value) != IS_NULL;
+ if (_7) {
+ _7 = !ZEPHIR_IS_STRING_IDENTICAL(value, "");
}
- if (_6) {
+ if (_7) {
if (ZEPHIR_IS_LONG(type, 2)) {
- ZEPHIR_INIT_LNVAR(_7);
- ZEPHIR_CONCAT_VSVS(_7, field, " LIKE :", field, ":");
- zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 710);
ZEPHIR_INIT_LNVAR(_8);
- ZEPHIR_CONCAT_SVS(_8, "%", value, "%");
- zephir_array_update_zval(&bind, field, &_8, PH_COPY | PH_SEPARATE);
- } else {
- ZEPHIR_INIT_LNVAR(_7);
- ZEPHIR_CONCAT_VSVS(_7, field, " = :", field, ":");
- zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 715);
- zephir_array_update_zval(&bind, field, &value, PH_COPY | PH_SEPARATE);
+ ZEPHIR_CONCAT_SVSVS(_8, "[", field, "] LIKE :", field, ":");
+ zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 721);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, "%", value, "%");
+ zephir_array_update_zval(&bind, field, &_9, PH_COPY | PH_SEPARATE);
+ continue;
}
+ ZEPHIR_INIT_LNVAR(_8);
+ ZEPHIR_CONCAT_SVSVS(_8, "[", field, "] = :", field, ":");
+ zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 728);
+ zephir_array_update_zval(&bind, field, &value, PH_COPY | PH_SEPARATE);
}
}
}
@@ -87756,12 +87844,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) {
if (zephir_fast_count_int(conditions TSRMLS_CC)) {
ZEPHIR_INIT_NVAR(_0);
zephir_fast_join_str(_0, SL(" AND "), conditions TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, criteria, "where", NULL, 312, _0);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "where", NULL, 313, _0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, criteria, "bind", NULL, 313, bind);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "bind", NULL, 314, bind);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 309, modelName);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 310, modelName);
zephir_check_call_status();
RETURN_CCTOR(criteria);
@@ -87778,7 +87866,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, execute) {
ZEPHIR_CALL_METHOD(&model, this_ptr, "getmodelname", NULL, 0);
zephir_check_call_status();
if (Z_TYPE_P(model) != IS_STRING) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Model name must be string", "phalcon/mvc/model/criteria.zep", 744);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Model name must be string", "phalcon/mvc/model/criteria.zep", 756);
return;
}
ZEPHIR_CALL_METHOD(&_0, this_ptr, "getparams", NULL, 0);
@@ -88783,7 +88871,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasOne) {
object_init_ex(relation, phalcon_mvc_model_relation_ce);
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, 1);
- ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 314, _1, referencedModel, fields, referencedFields, options);
+ ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _1, referencedModel, fields, referencedFields, options);
zephir_check_call_status();
ZEPHIR_OBS_VAR(alias);
if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) {
@@ -88860,7 +88948,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addBelongsTo) {
object_init_ex(relation, phalcon_mvc_model_relation_ce);
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, 0);
- ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 314, _1, referencedModel, fields, referencedFields, options);
+ ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _1, referencedModel, fields, referencedFields, options);
zephir_check_call_status();
ZEPHIR_OBS_VAR(alias);
if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) {
@@ -88938,7 +89026,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasMany) {
object_init_ex(relation, phalcon_mvc_model_relation_ce);
ZEPHIR_INIT_VAR(_0);
ZVAL_LONG(_0, 2);
- ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 314, _0, referencedModel, fields, referencedFields, options);
+ ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _0, referencedModel, fields, referencedFields, options);
zephir_check_call_status();
ZEPHIR_OBS_VAR(alias);
if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) {
@@ -89035,9 +89123,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasManyToMany) {
object_init_ex(relation, phalcon_mvc_model_relation_ce);
ZEPHIR_INIT_VAR(_0);
ZVAL_LONG(_0, 4);
- ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 314, _0, referencedModel, fields, referencedFields, options);
+ ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _0, referencedModel, fields, referencedFields, options);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, relation, "setintermediaterelation", NULL, 315, intermediateFields, intermediateModel, intermediateReferencedFields);
+ ZEPHIR_CALL_METHOD(NULL, relation, "setintermediaterelation", NULL, 316, intermediateFields, intermediateModel, intermediateReferencedFields);
zephir_check_call_status();
ZEPHIR_OBS_VAR(alias);
if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) {
@@ -89498,7 +89586,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1245);
return;
}
- ZEPHIR_CALL_METHOD(&_2, this_ptr, "_mergefindparameters", &_3, 316, extraParameters, parameters);
+ ZEPHIR_CALL_METHOD(&_2, this_ptr, "_mergefindparameters", &_3, 317, extraParameters, parameters);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&builder, this_ptr, "createbuilder", NULL, 0, _2);
zephir_check_call_status();
@@ -89563,10 +89651,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) {
ZEPHIR_CALL_METHOD(&_2, record, "getdi", NULL, 0);
zephir_check_call_status();
zephir_array_update_string(&findParams, SL("di"), &_2, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&findArguments, this_ptr, "_mergefindparameters", &_3, 316, findParams, parameters);
+ ZEPHIR_CALL_METHOD(&findArguments, this_ptr, "_mergefindparameters", &_3, 317, findParams, parameters);
zephir_check_call_status();
if (Z_TYPE_P(extraParameters) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&findParams, this_ptr, "_mergefindparameters", &_3, 316, findArguments, extraParameters);
+ ZEPHIR_CALL_METHOD(&findParams, this_ptr, "_mergefindparameters", &_3, 317, findArguments, extraParameters);
zephir_check_call_status();
} else {
ZEPHIR_CPY_WRT(findParams, findArguments);
@@ -91989,7 +92077,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCallArgument) {
add_assoc_stringl_ex(return_value, SS("type"), SL("all"), 1);
RETURN_MM();
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getexpression", NULL, 321, argument);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getexpression", NULL, 323, argument);
zephir_check_call_status();
RETURN_MM();
@@ -92025,11 +92113,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) {
zephir_create_array(_4, 3, 0 TSRMLS_CC);
add_assoc_stringl_ex(_4, SS("type"), SL("when"), 1);
zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 344 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 321, _6);
+ ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6);
zephir_check_call_status();
zephir_array_update_string(&_4, SL("expr"), &_5, PH_COPY | PH_SEPARATE);
zephir_array_fetch_string(&_8, whenExpr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 345 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 321, _8);
+ ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _8);
zephir_check_call_status();
zephir_array_update_string(&_4, SL("then"), &_5, PH_COPY | PH_SEPARATE);
zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 346);
@@ -92038,7 +92126,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) {
zephir_create_array(_4, 2, 0 TSRMLS_CC);
add_assoc_stringl_ex(_4, SS("type"), SL("else"), 1);
zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 350 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 321, _6);
+ ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6);
zephir_check_call_status();
zephir_array_update_string(&_4, SL("expr"), &_5, PH_COPY | PH_SEPARATE);
zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 351);
@@ -92047,7 +92135,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) {
zephir_create_array(return_value, 3, 0 TSRMLS_CC);
add_assoc_stringl_ex(return_value, SS("type"), SL("case"), 1);
zephir_array_fetch_string(&_6, expr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 357 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 321, _6);
+ ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6);
zephir_check_call_status();
zephir_array_update_string(&return_value, SL("expr"), &_5, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&return_value, SL("when-clauses"), &whenClauses, PH_COPY | PH_SEPARATE);
@@ -92087,13 +92175,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) {
; zephir_hash_move_forward_ex(_1, &_0)
) {
ZEPHIR_GET_HVALUE(argument, _2);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 322, argument);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 324, argument);
zephir_check_call_status();
zephir_array_append(&functionArgs, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 381);
}
} else {
zephir_create_array(functionArgs, 1, 0 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 322, arguments);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 324, arguments);
zephir_check_call_status();
zephir_array_fast_append(functionArgs, _3);
}
@@ -92156,12 +92244,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
if (!ZEPHIR_IS_LONG(exprType, 409)) {
ZEPHIR_OBS_VAR(exprLeft);
if (zephir_array_isset_string_fetch(&exprLeft, expr, SS("left"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&left, this_ptr, "_getexpression", &_0, 321, exprLeft, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&left, this_ptr, "_getexpression", &_0, 323, exprLeft, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
}
ZEPHIR_OBS_VAR(exprRight);
if (zephir_array_isset_string_fetch(&exprRight, expr, SS("right"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&right, this_ptr, "_getexpression", &_0, 321, exprRight, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&right, this_ptr, "_getexpression", &_0, 323, exprRight, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
}
}
@@ -92239,7 +92327,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
break;
}
if (ZEPHIR_IS_LONG(exprType, 355)) {
- ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getqualified", &_1, 323, expr);
+ ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getqualified", &_1, 325, expr);
zephir_check_call_status();
break;
}
@@ -92684,12 +92772,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
break;
}
if (ZEPHIR_IS_LONG(exprType, 350)) {
- ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getfunctioncall", NULL, 324, expr);
+ ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getfunctioncall", NULL, 326, expr);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(exprType, 409)) {
- ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getcaseexpression", NULL, 325, expr);
+ ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getcaseexpression", NULL, 327, expr);
zephir_check_call_status();
break;
}
@@ -92699,7 +92787,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
add_assoc_stringl_ex(exprReturn, SS("type"), SL("select"), 1);
ZEPHIR_INIT_NVAR(_3);
ZVAL_BOOL(_3, 1);
- ZEPHIR_CALL_METHOD(&_12, this_ptr, "_prepareselect", NULL, 326, expr, _3);
+ ZEPHIR_CALL_METHOD(&_12, this_ptr, "_prepareselect", NULL, 328, expr, _3);
zephir_check_call_status();
zephir_array_update_string(&exprReturn, SL("value"), &_12, PH_COPY | PH_SEPARATE);
break;
@@ -92718,7 +92806,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
RETURN_CCTOR(exprReturn);
}
if (zephir_array_isset_string(expr, SS("domain"))) {
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualified", &_1, 323, expr);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualified", &_1, 325, expr);
zephir_check_call_status();
RETURN_MM();
}
@@ -92731,7 +92819,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
; zephir_hash_move_forward_ex(_14, &_13)
) {
ZEPHIR_GET_HVALUE(exprListItem, _15);
- ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_0, 321, exprListItem);
+ ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_0, 323, exprListItem);
zephir_check_call_status();
zephir_array_append(&listItems, _12, PH_SEPARATE, "phalcon/mvc/model/query.zep", 735);
}
@@ -92833,7 +92921,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSelectColumn) {
add_assoc_stringl_ex(sqlColumn, SS("type"), SL("scalar"), 1);
ZEPHIR_OBS_VAR(columnData);
zephir_array_fetch_string(&columnData, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 838 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&sqlExprColumn, this_ptr, "_getexpression", NULL, 321, columnData);
+ ZEPHIR_CALL_METHOD(&sqlExprColumn, this_ptr, "_getexpression", NULL, 323, columnData);
zephir_check_call_status();
ZEPHIR_OBS_VAR(balias);
if (zephir_array_isset_string_fetch(&balias, sqlExprColumn, SS("balias"), 0 TSRMLS_CC)) {
@@ -93026,7 +93114,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) {
add_assoc_long_ex(_2, SS("type"), 355);
zephir_array_update_string(&_2, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_2, SL("name"), &fields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 323, _2);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _2);
zephir_check_call_status();
zephir_array_update_string(&_0, SL("left"), &_1, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_VAR(_4);
@@ -93034,7 +93122,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) {
add_assoc_stringl_ex(_4, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_4, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 323, _4);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _4);
zephir_check_call_status();
zephir_array_update_string(&_0, SL("right"), &_1, PH_COPY | PH_SEPARATE);
zephir_array_fast_append(sqlJoinConditions, _0);
@@ -93070,7 +93158,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) {
add_assoc_long_ex(_2, SS("type"), 355);
zephir_array_update_string(&_2, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_2, SL("name"), &field, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 323, _2);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _2);
zephir_check_call_status();
zephir_array_update_string(&_0, SL("left"), &_1, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_NVAR(_4);
@@ -93078,7 +93166,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) {
add_assoc_stringl_ex(_4, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_4, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("name"), &referencedField, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 323, _4);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _4);
zephir_check_call_status();
zephir_array_update_string(&_0, SL("right"), &_1, PH_COPY | PH_SEPARATE);
zephir_array_append(&sqlJoinPartialConditions, _0, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1041);
@@ -93161,7 +93249,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_long_ex(_8, SS("type"), 355);
zephir_array_update_string(&_8, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_8, SL("name"), &field, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _8);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _8);
zephir_check_call_status();
zephir_array_update_string(&sqlEqualsJoinCondition, SL("left"), &_7, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_NVAR(_10);
@@ -93169,7 +93257,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_stringl_ex(_10, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_10, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_10, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _10);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _10);
zephir_check_call_status();
zephir_array_update_string(&sqlEqualsJoinCondition, SL("right"), &_7, PH_COPY | PH_SEPARATE);
}
@@ -93191,7 +93279,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_long_ex(_12, SS("type"), 355);
zephir_array_update_string(&_12, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_12, SL("name"), &fields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _12);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _12);
zephir_check_call_status();
zephir_array_update_string(&_11, SL("left"), &_7, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_VAR(_13);
@@ -93199,7 +93287,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_stringl_ex(_13, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_13, SL("domain"), &intermediateModelName, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_13, SL("name"), &intermediateFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _13);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _13);
zephir_check_call_status();
zephir_array_update_string(&_11, SL("right"), &_7, PH_COPY | PH_SEPARATE);
zephir_array_fast_append(_10, _11);
@@ -93220,7 +93308,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_long_ex(_14, SS("type"), 355);
zephir_array_update_string(&_14, SL("domain"), &intermediateModelName, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_14, SL("name"), &intermediateReferencedFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _14);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _14);
zephir_check_call_status();
zephir_array_update_string(&_11, SL("left"), &_7, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_VAR(_15);
@@ -93228,7 +93316,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_stringl_ex(_15, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_15, SL("domain"), &referencedModelName, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_15, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _15);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _15);
zephir_check_call_status();
zephir_array_update_string(&_11, SL("right"), &_7, PH_COPY | PH_SEPARATE);
zephir_array_fast_append(_10, _11);
@@ -93295,7 +93383,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) {
; zephir_hash_move_forward_ex(_1, &_0)
) {
ZEPHIR_GET_HVALUE(joinItem, _2);
- ZEPHIR_CALL_METHOD(&joinData, this_ptr, "_getjoin", &_3, 327, manager, joinItem);
+ ZEPHIR_CALL_METHOD(&joinData, this_ptr, "_getjoin", &_3, 329, manager, joinItem);
zephir_check_call_status();
ZEPHIR_OBS_NVAR(source);
zephir_array_fetch_string(&source, joinData, SL("source"), PH_NOISY, "phalcon/mvc/model/query.zep", 1273 TSRMLS_CC);
@@ -93309,7 +93397,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) {
zephir_create_array(completeSource, 2, 0 TSRMLS_CC);
zephir_array_fast_append(completeSource, source);
zephir_array_fast_append(completeSource, schema);
- ZEPHIR_CALL_METHOD(&joinType, this_ptr, "_getjointype", &_4, 328, joinItem);
+ ZEPHIR_CALL_METHOD(&joinType, this_ptr, "_getjointype", &_4, 330, joinItem);
zephir_check_call_status();
ZEPHIR_OBS_NVAR(aliasExpr);
if (zephir_array_isset_string_fetch(&aliasExpr, joinItem, SS("alias"), 0 TSRMLS_CC)) {
@@ -93377,7 +93465,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) {
ZEPHIR_GET_HVALUE(joinItem, _11);
ZEPHIR_OBS_NVAR(joinExpr);
if (zephir_array_isset_string_fetch(&joinExpr, joinItem, SS("conditions"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_13, 321, joinExpr);
+ ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_13, 323, joinExpr);
zephir_check_call_status();
zephir_array_update_zval(&joinPreCondition, joinAliasName, &_12, PH_COPY | PH_SEPARATE);
}
@@ -93435,10 +93523,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) {
ZEPHIR_CALL_METHOD(&_12, relation, "isthrough", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_12))) {
- ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getsinglejoin", &_23, 329, joinType, joinSource, modelAlias, joinAlias, relation);
+ ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getsinglejoin", &_23, 331, joinType, joinSource, modelAlias, joinAlias, relation);
zephir_check_call_status();
} else {
- ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getmultijoin", &_24, 330, joinType, joinSource, modelAlias, joinAlias, relation);
+ ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getmultijoin", &_24, 332, joinType, joinSource, modelAlias, joinAlias, relation);
zephir_check_call_status();
}
if (zephir_array_isset_long(sqlJoin, 0)) {
@@ -93509,7 +93597,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getOrderClause) {
) {
ZEPHIR_GET_HVALUE(orderItem, _2);
zephir_array_fetch_string(&_3, orderItem, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1560 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&orderPartExpr, this_ptr, "_getexpression", &_4, 321, _3);
+ ZEPHIR_CALL_METHOD(&orderPartExpr, this_ptr, "_getexpression", &_4, 323, _3);
zephir_check_call_status();
if (zephir_array_isset_string_fetch(&orderSort, orderItem, SS("sort"), 1 TSRMLS_CC)) {
ZEPHIR_INIT_NVAR(orderPartSort);
@@ -93562,13 +93650,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getGroupClause) {
; zephir_hash_move_forward_ex(_1, &_0)
) {
ZEPHIR_GET_HVALUE(groupItem, _2);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 321, groupItem);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 323, groupItem);
zephir_check_call_status();
zephir_array_append(&groupParts, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1594);
}
} else {
zephir_create_array(groupParts, 1, 0 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 321, group);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 323, group);
zephir_check_call_status();
zephir_array_fast_append(groupParts, _3);
}
@@ -93594,13 +93682,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getLimitClause) {
ZEPHIR_OBS_VAR(number);
if (zephir_array_isset_string_fetch(&number, limitClause, SS("number"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 321, number);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 323, number);
zephir_check_call_status();
zephir_array_update_string(&limit, SL("number"), &_0, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(offset);
if (zephir_array_isset_string_fetch(&offset, limitClause, SS("offset"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 321, offset);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 323, offset);
zephir_check_call_status();
zephir_array_update_string(&limit, SL("offset"), &_0, PH_COPY | PH_SEPARATE);
}
@@ -93804,7 +93892,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) {
ZEPHIR_OBS_VAR(joins);
if (zephir_array_isset_string_fetch(&joins, select, SS("joins"), 0 TSRMLS_CC)) {
if (zephir_fast_count_int(joins TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", NULL, 331, select);
+ ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", NULL, 333, select);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(sqlJoins);
@@ -93830,7 +93918,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) {
; zephir_hash_move_forward_ex(_23, &_22)
) {
ZEPHIR_GET_HVALUE(column, _24);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getselectcolumn", &_25, 332, column);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getselectcolumn", &_25, 334, column);
zephir_check_call_status();
zephir_is_iterable(_3, &_27, &_26, 0, 0, "phalcon/mvc/model/query.zep", 1856);
for (
@@ -93879,31 +93967,31 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) {
}
ZEPHIR_OBS_VAR(where);
if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_31, 321, where);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_31, 323, where);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("where"), &_3, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(groupBy);
if (zephir_array_isset_string_fetch(&groupBy, ast, SS("groupBy"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getgroupclause", NULL, 333, groupBy);
+ ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getgroupclause", NULL, 335, groupBy);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("group"), &_32, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(having);
if (zephir_array_isset_string_fetch(&having, ast, SS("having"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getexpression", &_31, 321, having);
+ ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getexpression", &_31, 323, having);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("having"), &_32, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(order);
if (zephir_array_isset_string_fetch(&order, ast, SS("orderBy"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getorderclause", NULL, 334, order);
+ ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getorderclause", NULL, 336, order);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("order"), &_32, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(limit);
if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getlimitclause", NULL, 335, limit);
+ ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getlimitclause", NULL, 337, limit);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("limit"), &_32, PH_COPY | PH_SEPARATE);
}
@@ -93987,7 +94075,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) {
ZEPHIR_OBS_NVAR(_8);
zephir_array_fetch_string(&_8, exprValue, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 1960 TSRMLS_CC);
zephir_array_update_string(&_7, SL("type"), &_8, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_9, 321, exprValue, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_9, 323, exprValue, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_array_update_string(&_7, SL("value"), &_0, PH_COPY | PH_SEPARATE);
zephir_array_append(&exprValues, _7, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1962);
@@ -94162,7 +94250,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) {
) {
ZEPHIR_GET_HVALUE(updateValue, _11);
zephir_array_fetch_string(&_4, updateValue, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2110 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_12, 321, _4, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_12, 323, _4, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_array_append(&sqlFields, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2110);
ZEPHIR_OBS_NVAR(exprColumn);
@@ -94172,7 +94260,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) {
ZEPHIR_OBS_NVAR(_14);
zephir_array_fetch_string(&_14, exprColumn, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 2113 TSRMLS_CC);
zephir_array_update_string(&_13, SL("type"), &_14, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 321, exprColumn, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 323, exprColumn, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_array_update_string(&_13, SL("value"), &_15, PH_COPY | PH_SEPARATE);
zephir_array_append(&sqlValues, _13, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2115);
@@ -94187,13 +94275,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) {
if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) {
ZEPHIR_SINIT_VAR(_16);
ZVAL_BOOL(&_16, 1);
- ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 321, where, &_16);
+ ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 323, where, &_16);
zephir_check_call_status();
zephir_array_update_string(&sqlUpdate, SL("where"), &_15, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(limit);
if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getlimitclause", NULL, 335, limit);
+ ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getlimitclause", NULL, 337, limit);
zephir_check_call_status();
zephir_array_update_string(&sqlUpdate, SL("limit"), &_15, PH_COPY | PH_SEPARATE);
}
@@ -94312,13 +94400,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) {
if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) {
ZEPHIR_SINIT_VAR(_9);
ZVAL_BOOL(&_9, 1);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", NULL, 321, where, &_9);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", NULL, 323, where, &_9);
zephir_check_call_status();
zephir_array_update_string(&sqlDelete, SL("where"), &_3, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(limit);
if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_10, this_ptr, "_getlimitclause", NULL, 335, limit);
+ ZEPHIR_CALL_METHOD(&_10, this_ptr, "_getlimitclause", NULL, 337, limit);
zephir_check_call_status();
zephir_array_update_string(&sqlDelete, SL("limit"), &_10, PH_COPY | PH_SEPARATE);
}
@@ -94366,22 +94454,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, parse) {
zephir_update_property_this(this_ptr, SL("_type"), type TSRMLS_CC);
do {
if (ZEPHIR_IS_LONG(type, 309)) {
- ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareselect", NULL, 326);
+ ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareselect", NULL, 328);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 306)) {
- ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareinsert", NULL, 336);
+ ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareinsert", NULL, 338);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 300)) {
- ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareupdate", NULL, 337);
+ ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareupdate", NULL, 339);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 303)) {
- ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_preparedelete", NULL, 338);
+ ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_preparedelete", NULL, 340);
zephir_check_call_status();
break;
}
@@ -94768,12 +94856,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) {
isKeepingSnapshots = zephir_get_boolval(_40);
}
object_init_ex(return_value, phalcon_mvc_model_resultset_simple_ce);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 339, simpleColumnMap, resultObject, resultData, cache, (isKeepingSnapshots ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 341, simpleColumnMap, resultObject, resultData, cache, (isKeepingSnapshots ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
}
object_init_ex(return_value, phalcon_mvc_model_resultset_complex_ce);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 340, columns1, resultData, cache);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 342, columns1, resultData, cache);
zephir_check_call_status();
RETURN_MM();
@@ -94933,7 +95021,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_CALL_METHOD(&_15, insertModel, "create", NULL, 0, insertValues);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 341, _15, insertModel);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 343, _15, insertModel);
zephir_check_call_status();
RETURN_MM();
@@ -95064,13 +95152,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) {
zephir_array_update_zval(&updateValues, fieldName, &updateValue, PH_COPY | PH_SEPARATE);
}
- ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 342, model, intermediate, selectBindParams, selectBindTypes);
+ ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 344, model, intermediate, selectBindParams, selectBindTypes);
zephir_check_call_status();
if (!(zephir_fast_count_int(records TSRMLS_CC))) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_11);
ZVAL_BOOL(_11, 1);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 341, _11);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11);
zephir_check_call_status();
RETURN_MM();
}
@@ -95103,7 +95191,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_11);
ZVAL_BOOL(_11, 0);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 341, _11, record);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11, record);
zephir_check_call_status();
RETURN_MM();
}
@@ -95114,7 +95202,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_11);
ZVAL_BOOL(_11, 1);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 341, _11);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11);
zephir_check_call_status();
RETURN_MM();
@@ -95147,13 +95235,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) {
ZEPHIR_CALL_METHOD(&model, _1, "load", NULL, 0, modelName);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 342, model, intermediate, bindParams, bindTypes);
+ ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 344, model, intermediate, bindParams, bindTypes);
zephir_check_call_status();
if (!(zephir_fast_count_int(records TSRMLS_CC))) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_VAR(_2);
ZVAL_BOOL(_2, 1);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 341, _2);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2);
zephir_check_call_status();
RETURN_MM();
}
@@ -95186,7 +95274,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_2);
ZVAL_BOOL(_2, 0);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 341, _2, record);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2, record);
zephir_check_call_status();
RETURN_MM();
}
@@ -95197,7 +95285,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_2);
ZVAL_BOOL(_2, 1);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 341, _2);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2);
zephir_check_call_status();
RETURN_MM();
@@ -95245,18 +95333,18 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getRelatedRecords) {
}
ZEPHIR_INIT_VAR(query);
object_init_ex(query, phalcon_mvc_model_query_ce);
- ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 343);
+ ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 345);
zephir_check_call_status();
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, query, "setdi", NULL, 344, _5);
+ ZEPHIR_CALL_METHOD(NULL, query, "setdi", NULL, 346, _5);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_2);
ZVAL_LONG(_2, 309);
- ZEPHIR_CALL_METHOD(NULL, query, "settype", NULL, 345, _2);
+ ZEPHIR_CALL_METHOD(NULL, query, "settype", NULL, 347, _2);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, query, "setintermediate", NULL, 346, selectIr);
+ ZEPHIR_CALL_METHOD(NULL, query, "setintermediate", NULL, 348, selectIr);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_METHOD(query, "execute", NULL, 347, bindParams, bindTypes);
+ ZEPHIR_RETURN_CALL_METHOD(query, "execute", NULL, 349, bindParams, bindTypes);
zephir_check_call_status();
RETURN_MM();
@@ -95377,22 +95465,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) {
zephir_read_property_this(&type, this_ptr, SL("_type"), PH_NOISY_CC);
do {
if (ZEPHIR_IS_LONG(type, 309)) {
- ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeselect", NULL, 348, intermediate, mergedParams, mergedTypes);
+ ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeselect", NULL, 350, intermediate, mergedParams, mergedTypes);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 306)) {
- ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeinsert", NULL, 349, intermediate, mergedParams, mergedTypes);
+ ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeinsert", NULL, 351, intermediate, mergedParams, mergedTypes);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 300)) {
- ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeupdate", NULL, 350, intermediate, mergedParams, mergedTypes);
+ ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeupdate", NULL, 352, intermediate, mergedParams, mergedTypes);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 303)) {
- ZEPHIR_CALL_METHOD(&result, this_ptr, "_executedelete", NULL, 351, intermediate, mergedParams, mergedTypes);
+ ZEPHIR_CALL_METHOD(&result, this_ptr, "_executedelete", NULL, 353, intermediate, mergedParams, mergedTypes);
zephir_check_call_status();
break;
}
@@ -95447,7 +95535,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, getSingleResult) {
zephir_check_call_status();
RETURN_MM();
}
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "execute", NULL, 347, bindParams, bindTypes);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "execute", NULL, 349, bindParams, bindTypes);
zephir_check_call_status();
ZEPHIR_RETURN_CALL_METHOD(_1, "getfirst", NULL, 0);
zephir_check_call_status();
@@ -95619,7 +95707,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, getSql) {
_2 = zephir_fetch_nproperty_this(this_ptr, SL("_bindTypes"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_3);
ZVAL_BOOL(&_3, 1);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_executeselect", NULL, 348, intermediate, _1, _2, &_3);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_executeselect", NULL, 350, intermediate, _1, _2, &_3);
zephir_check_call_status();
RETURN_MM();
}
@@ -96572,6 +96660,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, delete) {
static PHP_METHOD(Phalcon_Mvc_Model_Resultset, filter) {
+ zend_bool _1;
int ZEPHIR_LAST_CALL_STATUS;
zend_object_iterator *_0;
zval *filter, *records, *record = NULL, *parameters, *processedRecord = NULL;
@@ -96597,12 +96686,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, filter) {
ZEPHIR_INIT_NVAR(processedRecord);
ZEPHIR_CALL_USER_FUNC_ARRAY(processedRecord, filter, parameters);
zephir_check_call_status();
- if (Z_TYPE_P(processedRecord) != IS_OBJECT) {
- if (Z_TYPE_P(processedRecord) != IS_ARRAY) {
- continue;
- }
+ _1 = Z_TYPE_P(processedRecord) != IS_OBJECT;
+ if (_1) {
+ _1 = Z_TYPE_P(processedRecord) != IS_ARRAY;
+ }
+ if (_1) {
+ continue;
}
- zephir_array_append(&records, processedRecord, PH_SEPARATE, "phalcon/mvc/model/resultset.zep", 558);
+ zephir_array_append(&records, processedRecord, PH_SEPARATE, "phalcon/mvc/model/resultset.zep", 556);
}
_0->funcs->dtor(_0 TSRMLS_CC);
RETURN_CCTOR(records);
@@ -96977,7 +97068,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction, rollback) {
ZEPHIR_INIT_NVAR(_0);
object_init_ex(_0, phalcon_mvc_model_transaction_failed_ce);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_rollbackRecord"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 358, rollbackMessage, _5);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 360, rollbackMessage, _5);
zephir_check_call_status();
zephir_throw_exception_debug(_0, "phalcon/mvc/model/transaction.zep", 160 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -96996,7 +97087,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction, getConnection) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_rollbackOnAbort"), PH_NOISY_CC);
if (zephir_is_true(_0)) {
- ZEPHIR_CALL_FUNCTION(&_1, "connection_aborted", NULL, 359);
+ ZEPHIR_CALL_FUNCTION(&_1, "connection_aborted", NULL, 361);
zephir_check_call_status();
if (zephir_is_true(_1)) {
ZEPHIR_INIT_VAR(_2);
@@ -97566,7 +97657,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Behavior_Timestampable, notify) {
ZVAL_NULL(timestamp);
ZEPHIR_OBS_VAR(format);
if (zephir_array_isset_string_fetch(&format, options, SS("format"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 299, format);
+ ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 300, format);
zephir_check_call_status();
} else {
ZEPHIR_OBS_VAR(generator);
@@ -97922,9 +98013,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Libmemcached, __construct) {
ZEPHIR_OBS_VAR(_3);
zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC);
zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 317, _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 318, _1, options);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 319, _1, options);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_4);
@@ -98023,7 +98114,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Libmemcached, reset) {
zephir_check_call_status();
}
}
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_libmemcached_ce, this_ptr, "reset", &_5, 319);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_libmemcached_ce, this_ptr, "reset", &_5, 320);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -98108,9 +98199,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memcache, __construct) {
ZEPHIR_OBS_VAR(_3);
zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC);
zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 317, _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 320, _1, options);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 321, _1, options);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_4);
@@ -98209,7 +98300,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memcache, reset) {
zephir_check_call_status();
}
}
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_memcache_ce, this_ptr, "reset", &_5, 319);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_memcache_ce, this_ptr, "reset", &_5, 320);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -98310,6 +98401,192 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memory, write) {
+#ifdef HAVE_CONFIG_H
+#endif
+
+#include
+
+#include
+#include
+#include
+
+
+
+ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_MetaData_Redis) {
+
+ ZEPHIR_REGISTER_CLASS_EX(Phalcon\\Mvc\\Model\\MetaData, Redis, phalcon, mvc_model_metadata_redis, phalcon_mvc_model_metadata_ce, phalcon_mvc_model_metadata_redis_method_entry, 0);
+
+ zend_declare_property_long(phalcon_mvc_model_metadata_redis_ce, SL("_ttl"), 172800, ZEND_ACC_PROTECTED TSRMLS_CC);
+
+ zend_declare_property_null(phalcon_mvc_model_metadata_redis_ce, SL("_redis"), ZEND_ACC_PROTECTED TSRMLS_CC);
+
+ zend_class_implements(phalcon_mvc_model_metadata_redis_ce TSRMLS_CC, 1, phalcon_mvc_model_metadatainterface_ce);
+ return SUCCESS;
+
+}
+
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, __construct) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *_2;
+ zval *options = NULL, *ttl, *_0 = NULL, *_1, *_3, *_4;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 0, 1, &options);
+
+ if (!options) {
+ ZEPHIR_CPY_WRT(options, ZEPHIR_GLOBAL(global_null));
+ } else {
+ ZEPHIR_SEPARATE_PARAM(options);
+ }
+
+
+ if (Z_TYPE_P(options) != IS_ARRAY) {
+ ZEPHIR_INIT_NVAR(options);
+ array_init(options);
+ }
+ if (!(zephir_array_isset_string(options, SS("host")))) {
+ ZEPHIR_INIT_VAR(_0);
+ ZVAL_STRING(_0, "127.0.0.1", 1);
+ zephir_array_update_string(&options, SL("host"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("port")))) {
+ ZEPHIR_INIT_NVAR(_0);
+ ZVAL_LONG(_0, 6379);
+ zephir_array_update_string(&options, SL("port"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("persistent")))) {
+ ZEPHIR_INIT_NVAR(_0);
+ ZVAL_LONG(_0, 0);
+ zephir_array_update_string(&options, SL("persistent"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("statsKey")))) {
+ ZEPHIR_INIT_NVAR(_0);
+ ZVAL_STRING(_0, "_PHCM_MM", 1);
+ zephir_array_update_string(&options, SL("statsKey"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (zephir_array_isset_string_fetch(&ttl, options, SS("lifetime"), 1 TSRMLS_CC)) {
+ zephir_update_property_this(this_ptr, SL("_ttl"), ttl TSRMLS_CC);
+ }
+ ZEPHIR_INIT_NVAR(_0);
+ object_init_ex(_0, phalcon_cache_backend_redis_ce);
+ ZEPHIR_INIT_VAR(_1);
+ object_init_ex(_1, phalcon_cache_frontend_data_ce);
+ ZEPHIR_INIT_VAR(_2);
+ zephir_create_array(_2, 1, 0 TSRMLS_CC);
+ ZEPHIR_OBS_VAR(_3);
+ zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC);
+ zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 322, _1, options);
+ zephir_check_call_status();
+ zephir_update_property_this(this_ptr, SL("_redis"), _0 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_4);
+ array_init(_4);
+ zephir_update_property_this(this_ptr, SL("_metaData"), _4 TSRMLS_CC);
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, read) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *key_param = NULL, *data = NULL, *_0;
+ zval *key = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 0, &key_param);
+
+ if (unlikely(Z_TYPE_P(key_param) != IS_STRING && Z_TYPE_P(key_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'key' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(key_param) == IS_STRING)) {
+ zephir_get_strval(key, key_param);
+ } else {
+ ZEPHIR_INIT_VAR(key);
+ ZVAL_EMPTY_STRING(key);
+ }
+
+
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ ZEPHIR_CALL_METHOD(&data, _0, "get", NULL, 0, key);
+ zephir_check_call_status();
+ if (Z_TYPE_P(data) == IS_ARRAY) {
+ RETURN_CCTOR(data);
+ }
+ RETURN_MM_NULL();
+
+}
+
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, write) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *key_param = NULL, *data, *_0;
+ zval *key = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 2, 0, &key_param, &data);
+
+ if (unlikely(Z_TYPE_P(key_param) != IS_STRING && Z_TYPE_P(key_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'key' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(key_param) == IS_STRING)) {
+ zephir_get_strval(key, key_param);
+ } else {
+ ZEPHIR_INIT_VAR(key);
+ ZVAL_EMPTY_STRING(key);
+ }
+
+
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ ZEPHIR_CALL_METHOD(NULL, _0, "save", NULL, 0, key, data);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, reset) {
+
+ zephir_fcall_cache_entry *_5 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ HashTable *_2;
+ HashPosition _1;
+ zval *meta, *key = NULL, *realKey = NULL, *_0 = NULL, **_3, *_4;
+
+ ZEPHIR_MM_GROW();
+
+ ZEPHIR_OBS_VAR(meta);
+ zephir_read_property_this(&meta, this_ptr, SL("_metaData"), PH_NOISY_CC);
+ if (Z_TYPE_P(meta) == IS_ARRAY) {
+ ZEPHIR_INIT_VAR(_0);
+ zephir_is_iterable(meta, &_2, &_1, 0, 0, "phalcon/mvc/model/metadata/redis.zep", 131);
+ for (
+ ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
+ ; zephir_hash_move_forward_ex(_2, &_1)
+ ) {
+ ZEPHIR_GET_HMKEY(key, _2, _1);
+ ZEPHIR_GET_HVALUE(_0, _3);
+ ZEPHIR_INIT_NVAR(realKey);
+ ZEPHIR_CONCAT_SV(realKey, "meta-", key);
+ _4 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ ZEPHIR_CALL_METHOD(NULL, _4, "delete", NULL, 0, realKey);
+ zephir_check_call_status();
+ }
+ }
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_redis_ce, this_ptr, "reset", &_5, 320);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+
+
+
#ifdef HAVE_CONFIG_H
#endif
@@ -100603,7 +100880,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) {
}
}
}
- if (zephir_is_numeric(limit)) {
+ if (zephir_is_numeric(number)) {
ZEPHIR_OBS_VAR(hiddenParam);
zephir_read_property_this(&hiddenParam, this_ptr, SL("_hiddenParamNumber"), PH_NOISY_CC);
ZEPHIR_INIT_LNVAR(_4);
@@ -100664,21 +100941,21 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getQuery) {
ZEPHIR_INIT_VAR(query);
object_init_ex(query, phalcon_mvc_model_query_ce);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getphql", NULL, 352);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getphql", NULL, 354);
zephir_check_call_status();
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 343, _0, _1);
+ ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 345, _0, _1);
zephir_check_call_status();
ZEPHIR_OBS_VAR(bindParams);
zephir_read_property_this(&bindParams, this_ptr, SL("_bindParams"), PH_NOISY_CC);
if (Z_TYPE_P(bindParams) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, query, "setbindparams", NULL, 353, bindParams);
+ ZEPHIR_CALL_METHOD(NULL, query, "setbindparams", NULL, 355, bindParams);
zephir_check_call_status();
}
ZEPHIR_OBS_VAR(bindTypes);
zephir_read_property_this(&bindTypes, this_ptr, SL("_bindTypes"), PH_NOISY_CC);
if (Z_TYPE_P(bindTypes) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, query, "setbindtypes", NULL, 354, bindTypes);
+ ZEPHIR_CALL_METHOD(NULL, query, "setbindtypes", NULL, 356, bindTypes);
zephir_check_call_status();
}
RETURN_CCTOR(query);
@@ -110560,7 +110837,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, __construct) {
zephir_update_property_this(this_ptr, SL("_columnTypes"), columnTypes TSRMLS_CC);
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_complex_ce, this_ptr, "__construct", &_0, 355, result, cache);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_complex_ce, this_ptr, "__construct", &_0, 357, result, cache);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -110877,7 +111154,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, __construct) {
zephir_update_property_this(this_ptr, SL("_model"), model TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_columnMap"), columnMap TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_keepSnapshots"), keepSnapshots TSRMLS_CC);
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_simple_ce, this_ptr, "__construct", &_0, 355, result, cache);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_simple_ce, this_ptr, "__construct", &_0, 357, result, cache);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -110932,12 +111209,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, current) {
_6 = zephir_fetch_nproperty_this(this_ptr, SL("_keepSnapshots"), PH_NOISY_CC);
ZEPHIR_INIT_NVAR(_3);
ZVAL_LONG(_3, 0);
- ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmap", &_5, 356, _2, row, columnMap, _3, _6);
+ ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmap", &_5, 358, _2, row, columnMap, _3, _6);
zephir_check_call_status();
}
break;
}
- ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_7, 357, row, columnMap, hydrateMode);
+ ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_7, 359, row, columnMap, hydrateMode);
zephir_check_call_status();
break;
} while(0);
@@ -110953,7 +111230,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, toArray) {
HashTable *_2, *_5;
HashPosition _1, _4;
int ZEPHIR_LAST_CALL_STATUS;
- zval *renameColumns_param = NULL, *result, *records = NULL, *record = NULL, *renamed = NULL, *renamedKey = NULL, *key = NULL, *value = NULL, *renamedRecords, *columnMap, *_0, **_3, **_6, *_7 = NULL, *_8 = NULL, *_10 = NULL;
+ zval *renameColumns_param = NULL, *result, *records = NULL, *record = NULL, *renamed = NULL, *renamedKey = NULL, *key = NULL, *value = NULL, *renamedRecords, *columnMap, *_0, **_3, **_6, *_7 = NULL, *_8 = NULL;
zend_bool renameColumns;
ZEPHIR_MM_GROW();
@@ -110990,7 +111267,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, toArray) {
ZEPHIR_INIT_VAR(renamedRecords);
array_init(renamedRecords);
if (Z_TYPE_P(records) == IS_ARRAY) {
- zephir_is_iterable(records, &_2, &_1, 0, 0, "phalcon/mvc/model/resultset/simple.zep", 220);
+ zephir_is_iterable(records, &_2, &_1, 0, 0, "phalcon/mvc/model/resultset/simple.zep", 218);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -110998,7 +111275,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, toArray) {
ZEPHIR_GET_HVALUE(record, _3);
ZEPHIR_INIT_NVAR(renamed);
array_init(renamed);
- zephir_is_iterable(record, &_5, &_4, 0, 0, "phalcon/mvc/model/resultset/simple.zep", 218);
+ zephir_is_iterable(record, &_5, &_4, 0, 0, "phalcon/mvc/model/resultset/simple.zep", 216);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
@@ -111030,14 +111307,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, toArray) {
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_OBS_NVAR(_10);
- zephir_array_fetch_long(&_10, renamedKey, 0, PH_NOISY, "phalcon/mvc/model/resultset/simple.zep", 209 TSRMLS_CC);
- zephir_array_update_zval(&renamed, _10, &value, PH_COPY | PH_SEPARATE);
- } else {
- zephir_array_update_zval(&renamed, renamedKey, &value, PH_COPY | PH_SEPARATE);
}
+ zephir_array_update_zval(&renamed, renamedKey, &value, PH_COPY | PH_SEPARATE);
}
- zephir_array_append(&renamedRecords, renamed, PH_SEPARATE, "phalcon/mvc/model/resultset/simple.zep", 218);
+ zephir_array_append(&renamedRecords, renamed, PH_SEPARATE, "phalcon/mvc/model/resultset/simple.zep", 216);
}
}
RETURN_CCTOR(renamedRecords);
@@ -111104,22 +111377,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, unserialize) {
ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 72, data);
zephir_check_call_status();
if (Z_TYPE_P(resultset) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/simple.zep", 254);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/simple.zep", 252);
return;
}
- zephir_array_fetch_string(&_0, resultset, SL("model"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 257 TSRMLS_CC);
+ zephir_array_fetch_string(&_0, resultset, SL("model"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 255 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_model"), _0 TSRMLS_CC);
- zephir_array_fetch_string(&_1, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 258 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 256 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_rows"), _1 TSRMLS_CC);
- zephir_array_fetch_string(&_2, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 259 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 257 TSRMLS_CC);
ZEPHIR_INIT_ZVAL_NREF(_3);
ZVAL_LONG(_3, zephir_fast_count_int(_2 TSRMLS_CC));
zephir_update_property_this(this_ptr, SL("_count"), _3 TSRMLS_CC);
- zephir_array_fetch_string(&_4, resultset, SL("cache"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 260 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, resultset, SL("cache"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 258 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_cache"), _4 TSRMLS_CC);
- zephir_array_fetch_string(&_5, resultset, SL("columnMap"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 261 TSRMLS_CC);
+ zephir_array_fetch_string(&_5, resultset, SL("columnMap"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 259 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_columnMap"), _5 TSRMLS_CC);
- zephir_array_fetch_string(&_6, resultset, SL("hydrateMode"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 262 TSRMLS_CC);
+ zephir_array_fetch_string(&_6, resultset, SL("hydrateMode"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 260 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_hydrateMode"), _6 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -111408,7 +111681,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction_Manager, get) {
ZEPHIR_INIT_VAR(_3);
ZVAL_STRING(_3, "rollbackPendent", 1);
zephir_array_fast_append(_2, _3);
- ZEPHIR_CALL_FUNCTION(NULL, "register_shutdown_function", NULL, 360, _2);
+ ZEPHIR_CALL_FUNCTION(NULL, "register_shutdown_function", NULL, 362, _2);
zephir_check_call_status();
}
zephir_update_property_this(this_ptr, SL("_initialized"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
@@ -111467,9 +111740,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction_Manager, getOrCreateTransaction)
ZEPHIR_INIT_VAR(transaction);
object_init_ex(transaction, phalcon_mvc_model_transaction_ce);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_service"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, transaction, "__construct", NULL, 361, dependencyInjector, (autoBegin ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), _5);
+ ZEPHIR_CALL_METHOD(NULL, transaction, "__construct", NULL, 363, dependencyInjector, (autoBegin ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), _5);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, transaction, "settransactionmanager", NULL, 362, this_ptr);
+ ZEPHIR_CALL_METHOD(NULL, transaction, "settransactionmanager", NULL, 364, this_ptr);
zephir_check_call_status();
zephir_update_property_array_append(this_ptr, SL("_transactions"), transaction TSRMLS_CC);
RETURN_ON_FAILURE(zephir_property_incr(this_ptr, SL("_number") TSRMLS_CC));
@@ -111757,7 +112030,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Email, validate) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 274);
- ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 190, value, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_0);
@@ -112030,7 +112303,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Inclusionin, validate) {
zephir_check_temp_parameter(_0);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_5, "in_array", NULL, 363, value, domain, strict);
+ ZEPHIR_CALL_FUNCTION(&_5, "in_array", NULL, 365, value, domain, strict);
zephir_check_call_status();
if (!(zephir_is_true(_5))) {
ZEPHIR_INIT_NVAR(_0);
@@ -112176,7 +112449,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Ip, validate) {
zephir_array_update_string(&options, SL("flags"), &_6, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, 275);
- ZEPHIR_CALL_FUNCTION(&_7, "filter_var", NULL, 190, value, &_5, options);
+ ZEPHIR_CALL_FUNCTION(&_7, "filter_var", NULL, 191, value, &_5, options);
zephir_check_call_status();
if (!(zephir_is_true(_7))) {
ZEPHIR_INIT_NVAR(_0);
@@ -112646,7 +112919,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_StringLength, validate) {
RETURN_MM_BOOL(1);
}
if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 364, value);
+ ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, value);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(length);
@@ -112805,7 +113078,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
zephir_check_temp_parameter(_0);
zephir_check_call_status();
if (Z_TYPE_P(field) == IS_ARRAY) {
- zephir_is_iterable(field, &_2, &_1, 0, 0, "phalcon/mvc/model/validator/uniqueness.zep", 119);
+ zephir_is_iterable(field, &_2, &_1, 0, 0, "phalcon/mvc/model/validator/uniqueness.zep", 120);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -112820,7 +113093,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_4, "Column '", composeField, "' isn't part of the column map");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _4);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 96 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 97 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -112835,7 +113108,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_4, "Column '", columnField, "' isn't part of the table columns");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _4);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 106 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 107 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -112843,11 +113116,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZVAL_LONG(&_6, number);
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVSV(_7, "[", composeField, "] = ?", &_6);
- zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 112);
+ zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 113);
ZEPHIR_CALL_METHOD(&_8, record, "readattribute", &_9, 0, composeField);
zephir_check_call_status();
- zephir_array_append(&bindParams, _8, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 113);
- zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 114);
+ zephir_array_append(&bindParams, _8, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 114);
+ zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 115);
number++;
}
} else {
@@ -112860,7 +113133,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_7, "Column '", field, "' isn't part of the column map");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _7);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 126 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 127 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -112875,17 +113148,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_7, "Column '", columnField, "' isn't part of the table columns");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _7);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 136 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 137 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVS(_7, "[", field, "] = ?0");
- zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 142);
+ zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 143);
ZEPHIR_CALL_METHOD(&_8, record, "readattribute", NULL, 0, field);
zephir_check_call_status();
- zephir_array_append(&bindParams, _8, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 143);
- zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 144);
+ zephir_array_append(&bindParams, _8, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 144);
+ zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 145);
number++;
}
ZEPHIR_CALL_METHOD(&_10, record, "getoperationmade", NULL, 0);
@@ -112900,7 +113173,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
}
ZEPHIR_CALL_METHOD(&_8, metaData, "getprimarykeyattributes", NULL, 0, record);
zephir_check_call_status();
- zephir_is_iterable(_8, &_12, &_11, 0, 0, "phalcon/mvc/model/validator/uniqueness.zep", 189);
+ zephir_is_iterable(_8, &_12, &_11, 0, 0, "phalcon/mvc/model/validator/uniqueness.zep", 190);
for (
; zephir_hash_get_current_data_ex(_12, (void**) &_13, &_11) == SUCCESS
; zephir_hash_move_forward_ex(_12, &_11)
@@ -112914,7 +113187,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_7, "Column '", primaryField, "' isn't part of the table columns");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _7);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 166 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 167 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -112927,7 +113200,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_14, "Column '", primaryField, "' isn't part of the column map");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _14);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 174 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 175 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -112938,11 +113211,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZVAL_LONG(&_6, number);
ZEPHIR_INIT_LNVAR(_4);
ZEPHIR_CONCAT_SVSV(_4, "[", attributeField, "] <> ?", &_6);
- zephir_array_append(&conditions, _4, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 183);
+ zephir_array_append(&conditions, _4, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 184);
ZEPHIR_CALL_METHOD(&_15, record, "readattribute", &_16, 0, primaryField);
zephir_check_call_status();
- zephir_array_append(&bindParams, _15, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 184);
- zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 185);
+ zephir_array_append(&bindParams, _15, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 185);
+ zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 186);
number++;
}
}
@@ -113079,7 +113352,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Url, validate) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 273);
- ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 190, value, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_0);
@@ -113414,7 +113687,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Annotations, handle) {
}
zephir_update_property_this(this_ptr, SL("_processed"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
}
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_router_annotations_ce, this_ptr, "handle", &_18, 365, realUri);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_router_annotations_ce, this_ptr, "handle", &_18, 367, realUri);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -113809,6 +114082,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Router_Group) {
static PHP_METHOD(Phalcon_Mvc_Router_Group, __construct) {
int ZEPHIR_LAST_CALL_STATUS;
+ zend_bool _0;
zval *paths = NULL;
ZEPHIR_MM_GROW();
@@ -113819,12 +114093,12 @@ static PHP_METHOD(Phalcon_Mvc_Router_Group, __construct) {
}
- if (Z_TYPE_P(paths) == IS_ARRAY) {
+ _0 = Z_TYPE_P(paths) == IS_ARRAY;
+ if (!(_0)) {
+ _0 = Z_TYPE_P(paths) == IS_STRING;
+ }
+ if (_0) {
zephir_update_property_this(this_ptr, SL("_paths"), paths TSRMLS_CC);
- } else {
- if (Z_TYPE_P(paths) == IS_STRING) {
- zephir_update_property_this(this_ptr, SL("_paths"), paths TSRMLS_CC);
- }
}
if ((zephir_method_exists_ex(this_ptr, SS("initialize") TSRMLS_CC) == SUCCESS)) {
ZEPHIR_CALL_METHOD(NULL, this_ptr, "initialize", NULL, 0, paths);
@@ -114267,7 +114541,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Group, _addRoute) {
ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 74, _2, mergedPaths, httpMethods);
zephir_check_call_status();
zephir_update_property_array_append(this_ptr, SL("_routes"), route TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, route, "setgroup", NULL, 366, this_ptr);
+ ZEPHIR_CALL_METHOD(NULL, route, "setgroup", NULL, 368, this_ptr);
zephir_check_call_status();
RETURN_CCTOR(route);
@@ -114523,7 +114797,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, extractNamedParams) {
int tmp, cursor, cursorVar, marker, bracketCount = 0, parenthesesCount = 0, foundPattern = 0, intermediate = 0, numberMatches = 0;
char ch;
zval *pattern_param = NULL, *matches, _1 = zval_used_for_init, _2 = zval_used_for_init, *_3 = NULL, _18 = zval_used_for_init, _19 = zval_used_for_init, *_20 = NULL, _22 = zval_used_for_init, *_23 = NULL;
- zval *pattern = NULL, *route, *item = NULL, *variable = NULL, *regexp = NULL, *_4 = NULL, *_21 = NULL, *_24 = NULL;
+ zval *pattern = NULL, *route, *item = NULL, *variable = NULL, *regexp = NULL, *_4 = NULL, *_21 = NULL, *_24 = NULL, *_26 = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 0, &pattern_param);
@@ -114683,9 +114957,9 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, extractNamedParams) {
}
}
if (foundPattern != 2) {
- zephir_concat_self_str(&route, "(", sizeof("(")-1 TSRMLS_CC);
- zephir_concat_self(&route, regexp TSRMLS_CC);
- zephir_concat_self_str(&route, ")", sizeof(")")-1 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_26);
+ ZEPHIR_CONCAT_SVS(_26, "(", regexp, ")");
+ zephir_concat_self(&route, _26 TSRMLS_CC);
} else {
zephir_concat_self(&route, regexp TSRMLS_CC);
}
@@ -114699,9 +114973,9 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, extractNamedParams) {
zephir_array_update_zval(&matches, item, &_23, PH_COPY | PH_SEPARATE);
}
} else {
- zephir_concat_self_str(&route, "{", sizeof("{")-1 TSRMLS_CC);
- zephir_concat_self(&route, item TSRMLS_CC);
- zephir_concat_self_str(&route, "}", sizeof("}")-1 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_26);
+ ZEPHIR_CONCAT_SVS(_26, "{", item, "}");
+ zephir_concat_self(&route, _26 TSRMLS_CC);
}
continue;
}
@@ -114762,13 +115036,13 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, reConfigure) {
ZEPHIR_CALL_SELF(&routePaths, "getroutepaths", NULL, 0, paths);
zephir_check_call_status();
if (!(zephir_start_with_str(pattern, SL("#")))) {
- if (zephir_memnstr_str(pattern, SL("{"), "phalcon/mvc/router/route.zep", 299)) {
+ if (zephir_memnstr_str(pattern, SL("{"), "phalcon/mvc/router/route.zep", 295)) {
ZEPHIR_CALL_METHOD(&extracted, this_ptr, "extractnamedparams", NULL, 0, pattern);
zephir_check_call_status();
ZEPHIR_OBS_VAR(pcrePattern);
- zephir_array_fetch_long(&pcrePattern, extracted, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 304 TSRMLS_CC);
+ zephir_array_fetch_long(&pcrePattern, extracted, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 300 TSRMLS_CC);
ZEPHIR_INIT_VAR(_0);
- zephir_array_fetch_long(&_1, extracted, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/router/route.zep", 305 TSRMLS_CC);
+ zephir_array_fetch_long(&_1, extracted, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/router/route.zep", 301 TSRMLS_CC);
zephir_fast_array_merge(_0, &(routePaths), &(_1) TSRMLS_CC);
ZEPHIR_CPY_WRT(routePaths, _0);
} else {
@@ -114813,23 +115087,23 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, getRoutePaths) {
_0 = zephir_fast_count_int(parts TSRMLS_CC);
if (_0 == 3) {
ZEPHIR_OBS_NVAR(moduleName);
- zephir_array_fetch_long(&moduleName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 357 TSRMLS_CC);
+ zephir_array_fetch_long(&moduleName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 353 TSRMLS_CC);
ZEPHIR_OBS_NVAR(controllerName);
- zephir_array_fetch_long(&controllerName, parts, 1, PH_NOISY, "phalcon/mvc/router/route.zep", 358 TSRMLS_CC);
+ zephir_array_fetch_long(&controllerName, parts, 1, PH_NOISY, "phalcon/mvc/router/route.zep", 354 TSRMLS_CC);
ZEPHIR_OBS_NVAR(actionName);
- zephir_array_fetch_long(&actionName, parts, 2, PH_NOISY, "phalcon/mvc/router/route.zep", 359 TSRMLS_CC);
+ zephir_array_fetch_long(&actionName, parts, 2, PH_NOISY, "phalcon/mvc/router/route.zep", 355 TSRMLS_CC);
break;
}
if (_0 == 2) {
ZEPHIR_OBS_NVAR(controllerName);
- zephir_array_fetch_long(&controllerName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 363 TSRMLS_CC);
+ zephir_array_fetch_long(&controllerName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 359 TSRMLS_CC);
ZEPHIR_OBS_NVAR(actionName);
- zephir_array_fetch_long(&actionName, parts, 1, PH_NOISY, "phalcon/mvc/router/route.zep", 364 TSRMLS_CC);
+ zephir_array_fetch_long(&actionName, parts, 1, PH_NOISY, "phalcon/mvc/router/route.zep", 360 TSRMLS_CC);
break;
}
if (_0 == 1) {
ZEPHIR_OBS_NVAR(controllerName);
- zephir_array_fetch_long(&controllerName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 368 TSRMLS_CC);
+ zephir_array_fetch_long(&controllerName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 364 TSRMLS_CC);
break;
}
} while(0);
@@ -114840,7 +115114,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, getRoutePaths) {
zephir_array_update_string(&routePaths, SL("module"), &moduleName, PH_COPY | PH_SEPARATE);
}
if (Z_TYPE_P(controllerName) != IS_NULL) {
- if (zephir_memnstr_str(controllerName, SL("\\"), "phalcon/mvc/router/route.zep", 383)) {
+ if (zephir_memnstr_str(controllerName, SL("\\"), "phalcon/mvc/router/route.zep", 379)) {
ZEPHIR_INIT_VAR(realClassName);
zephir_get_class_ns(realClassName, controllerName, 0 TSRMLS_CC);
ZEPHIR_INIT_VAR(namespaceName);
@@ -114866,7 +115140,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, getRoutePaths) {
array_init(routePaths);
}
if (Z_TYPE_P(routePaths) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_router_exception_ce, "The route contains invalid paths", "phalcon/mvc/router/route.zep", 415);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_router_exception_ce, "The route contains invalid paths", "phalcon/mvc/router/route.zep", 411);
return;
}
RETURN_CCTOR(routePaths);
@@ -114955,7 +115229,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, getReversedPaths) {
ZEPHIR_INIT_VAR(reversed);
array_init(reversed);
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_paths"), PH_NOISY_CC);
- zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/router/route.zep", 506);
+ zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/router/route.zep", 502);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -115776,7 +116050,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, _loadTemplateEngines) {
if (Z_TYPE_P(registeredEngines) != IS_ARRAY) {
ZEPHIR_INIT_VAR(_0);
object_init_ex(_0, phalcon_mvc_view_engine_php_ce);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 368, this_ptr, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 370, this_ptr, dependencyInjector);
zephir_check_call_status();
zephir_array_update_string(&engines, SL(".phtml"), &_0, PH_COPY | PH_SEPARATE);
} else {
@@ -116029,7 +116303,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, render) {
} else {
ZEPHIR_CPY_WRT(mergedParams, viewParams);
}
- ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 387, path, mergedParams);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 389, path, mergedParams);
zephir_check_call_status();
if (Z_TYPE_P(cache) == IS_OBJECT) {
ZEPHIR_CALL_METHOD(&_0, cache, "isstarted", NULL, 0);
@@ -116097,7 +116371,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, partial) {
} else {
ZEPHIR_CPY_WRT(mergedParams, params);
}
- ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 387, partialPath, mergedParams);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 389, partialPath, mergedParams);
zephir_check_call_status();
if (Z_TYPE_P(params) == IS_ARRAY) {
zephir_update_property_this(this_ptr, SL("_viewParams"), viewParams TSRMLS_CC);
@@ -116481,7 +116755,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Php, render) {
if (mustClean == 1) {
- ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 369);
+ ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 371);
zephir_check_call_status();
}
if (Z_TYPE_P(params) == IS_ARRAY) {
@@ -116576,18 +116850,18 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, getCompiler) {
ZEPHIR_INIT_NVAR(compiler);
object_init_ex(compiler, phalcon_mvc_view_engine_volt_compiler_ce);
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_view"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, compiler, "__construct", NULL, 370, _0);
+ ZEPHIR_CALL_METHOD(NULL, compiler, "__construct", NULL, 372, _0);
zephir_check_call_status();
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
ZEPHIR_CPY_WRT(dependencyInjector, _1);
if (Z_TYPE_P(dependencyInjector) == IS_OBJECT) {
- ZEPHIR_CALL_METHOD(NULL, compiler, "setdi", NULL, 371, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, compiler, "setdi", NULL, 373, dependencyInjector);
zephir_check_call_status();
}
ZEPHIR_OBS_VAR(options);
zephir_read_property_this(&options, this_ptr, SL("_options"), PH_NOISY_CC);
if (Z_TYPE_P(options) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, compiler, "setoptions", NULL, 372, options);
+ ZEPHIR_CALL_METHOD(NULL, compiler, "setoptions", NULL, 374, options);
zephir_check_call_status();
}
zephir_update_property_this(this_ptr, SL("_compiler"), compiler TSRMLS_CC);
@@ -116627,7 +116901,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, render) {
if (mustClean) {
- ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 369);
+ ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 371);
zephir_check_call_status();
}
ZEPHIR_CALL_METHOD(&compiler, this_ptr, "getcompiler", NULL, 0);
@@ -116667,6 +116941,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, render) {
static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, length) {
int ZEPHIR_LAST_CALL_STATUS;
+ zend_bool _0;
zval *item, *length = NULL;
ZEPHIR_MM_GROW();
@@ -116676,21 +116951,20 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, length) {
ZEPHIR_INIT_VAR(length);
ZVAL_LONG(length, 0);
- if (Z_TYPE_P(item) == IS_OBJECT) {
+ _0 = Z_TYPE_P(item) == IS_OBJECT;
+ if (!(_0)) {
+ _0 = Z_TYPE_P(item) == IS_ARRAY;
+ }
+ if (_0) {
ZEPHIR_INIT_NVAR(length);
ZVAL_LONG(length, zephir_fast_count_int(item TSRMLS_CC));
} else {
- if (Z_TYPE_P(item) == IS_ARRAY) {
- ZEPHIR_INIT_NVAR(length);
- ZVAL_LONG(length, zephir_fast_count_int(item TSRMLS_CC));
+ if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) {
+ ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, item);
+ zephir_check_call_status();
} else {
- if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 364, item);
- zephir_check_call_status();
- } else {
- ZEPHIR_INIT_NVAR(length);
- ZVAL_LONG(length, zephir_fast_strlen_ev(item));
- }
+ ZEPHIR_INIT_NVAR(length);
+ ZVAL_LONG(length, zephir_fast_strlen_ev(item));
}
}
RETURN_CCTOR(length);
@@ -116712,7 +116986,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, isIncluded) {
}
if (Z_TYPE_P(haystack) == IS_STRING) {
if ((zephir_function_exists_ex(SS("mb_strpos") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_CALL_FUNCTION(&_0, "mb_strpos", NULL, 373, haystack, needle);
+ ZEPHIR_CALL_FUNCTION(&_0, "mb_strpos", NULL, 375, haystack, needle);
zephir_check_call_status();
RETURN_MM_BOOL(!ZEPHIR_IS_FALSE_IDENTICAL(_0));
}
@@ -116720,7 +116994,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, isIncluded) {
zephir_fast_strpos(_1, haystack, needle, 0 );
RETURN_MM_BOOL(!ZEPHIR_IS_FALSE_IDENTICAL(_1));
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Invalid haystack", "phalcon/mvc/view/engine/volt.zep", 170);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Invalid haystack", "phalcon/mvc/view/engine/volt.zep", 166);
return;
}
@@ -116765,7 +117039,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, convertEncoding) {
_0 = ZEPHIR_IS_STRING(to, "utf8");
}
if (_0) {
- ZEPHIR_RETURN_CALL_FUNCTION("utf8_encode", NULL, 374, text);
+ ZEPHIR_RETURN_CALL_FUNCTION("utf8_encode", NULL, 376, text);
zephir_check_call_status();
RETURN_MM();
}
@@ -116774,21 +117048,21 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, convertEncoding) {
_1 = ZEPHIR_IS_STRING(from, "utf8");
}
if (_1) {
- ZEPHIR_RETURN_CALL_FUNCTION("utf8_decode", NULL, 375, text);
+ ZEPHIR_RETURN_CALL_FUNCTION("utf8_decode", NULL, 377, text);
zephir_check_call_status();
RETURN_MM();
}
if ((zephir_function_exists_ex(SS("mb_convert_encoding") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 179, text, from, to);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 180, text, from, to);
zephir_check_call_status();
RETURN_MM();
}
if ((zephir_function_exists_ex(SS("iconv") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("iconv", NULL, 376, from, to, text);
+ ZEPHIR_RETURN_CALL_FUNCTION("iconv", NULL, 378, from, to, text);
zephir_check_call_status();
RETURN_MM();
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Any of 'mbstring' or 'iconv' is required to perform the charset conversion", "phalcon/mvc/view/engine/volt.zep", 209);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Any of 'mbstring' or 'iconv' is required to perform the charset conversion", "phalcon/mvc/view/engine/volt.zep", 205);
return;
}
@@ -116838,7 +117112,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) {
if (_1) {
ZEPHIR_CALL_METHOD(&_2, value, "current", &_3, 0);
zephir_check_call_status();
- zephir_array_append(&slice, _2, PH_SEPARATE, "phalcon/mvc/view/engine/volt.zep", 235);
+ zephir_array_append(&slice, _2, PH_SEPARATE, "phalcon/mvc/view/engine/volt.zep", 231);
}
ZEPHIR_CALL_METHOD(NULL, value, "next", &_4, 0);
zephir_check_call_status();
@@ -116855,7 +117129,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) {
if (Z_TYPE_P(value) == IS_ARRAY) {
ZEPHIR_SINIT_VAR(_5);
ZVAL_LONG(&_5, start);
- ZEPHIR_RETURN_CALL_FUNCTION("array_slice", NULL, 377, value, &_5, length);
+ ZEPHIR_RETURN_CALL_FUNCTION("array_slice", NULL, 379, value, &_5, length);
zephir_check_call_status();
RETURN_MM();
}
@@ -116863,13 +117137,13 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) {
if (Z_TYPE_P(length) != IS_NULL) {
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, start);
- ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 378, value, &_5, length);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 380, value, &_5, length);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, start);
- ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 378, value, &_5);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 380, value, &_5);
zephir_check_call_status();
RETURN_MM();
}
@@ -116899,7 +117173,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, sort) {
Z_SET_ISREF_P(value);
- ZEPHIR_CALL_FUNCTION(NULL, "asort", NULL, 379, value);
+ ZEPHIR_CALL_FUNCTION(NULL, "asort", NULL, 381, value);
Z_UNSET_ISREF_P(value);
zephir_check_call_status();
RETURN_CTOR(value);
@@ -116939,11 +117213,11 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, callMacro) {
ZEPHIR_CONCAT_SVS(_2, "Macro '", name, "' does not exist");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt.zep", 297 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt.zep", 293 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_RETURN_CALL_FUNCTION("call_user_func", NULL, 380, macro, arguments);
+ ZEPHIR_RETURN_CALL_FUNCTION("call_user_func", NULL, 382, macro, arguments);
zephir_check_call_status();
RETURN_MM();
@@ -117406,7 +117680,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) {
}
}
} else {
- ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_4, 381, left);
+ ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_4, 383, left);
zephir_check_call_status();
ZEPHIR_OBS_VAR(leftType);
zephir_array_fetch_string(&leftType, left, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 339 TSRMLS_CC);
@@ -117428,7 +117702,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) {
zephir_array_fetch_string(&_7, right, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 352 TSRMLS_CC);
zephir_concat_self(&exprCode, _7 TSRMLS_CC);
} else {
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_4, 381, right);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_4, 383, right);
zephir_check_call_status();
zephir_concat_self(&exprCode, _1 TSRMLS_CC);
}
@@ -117457,7 +117731,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
ZVAL_NULL(funcArguments);
ZEPHIR_OBS_NVAR(funcArguments);
if (zephir_array_isset_string_fetch(&funcArguments, expr, SS("arguments"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", &_0, 381, funcArguments);
+ ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", &_0, 383, funcArguments);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(arguments);
@@ -117480,7 +117754,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
zephir_array_fast_append(_1, funcArguments);
ZEPHIR_INIT_VAR(_2);
ZVAL_STRING(_2, "compileFunction", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 382, _2, _1);
+ ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 384, _2, _1);
zephir_check_temp_parameter(_2);
zephir_check_call_status();
if (Z_TYPE_P(code) == IS_STRING) {
@@ -117547,7 +117821,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
ZEPHIR_OBS_VAR(exprLevel);
zephir_read_property_this(&exprLevel, this_ptr, SL("_exprLevel"), PH_NOISY_CC);
if (Z_TYPE_P(block) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlistorextends", NULL, 383, block);
+ ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlistorextends", NULL, 385, block);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(exprLevel, 1)) {
ZEPHIR_CPY_WRT(escapedCode, code);
@@ -117583,7 +117857,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
zephir_read_property_this(&arrayHelpers, this_ptr, SL("_arrayHelpers"), PH_NOISY_CC);
if (Z_TYPE_P(arrayHelpers) != IS_ARRAY) {
ZEPHIR_INIT_NVAR(arrayHelpers);
- zephir_create_array(arrayHelpers, 17, 0 TSRMLS_CC);
+ zephir_create_array(arrayHelpers, 18, 0 TSRMLS_CC);
zephir_array_update_string(&arrayHelpers, SL("link_to"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("image"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("form"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
@@ -117599,6 +117873,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
zephir_array_update_string(&arrayHelpers, SL("text_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("email_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("date_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
+ zephir_array_update_string(&arrayHelpers, SL("tel_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("numeric_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("image_input"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_update_property_this(this_ptr, SL("_arrayHelpers"), arrayHelpers TSRMLS_CC);
@@ -117641,17 +117916,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
}
ZEPHIR_INIT_NVAR(_2);
object_init_ex(_2, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_3, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 572 TSRMLS_CC);
- zephir_array_fetch_string(&_4, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 572 TSRMLS_CC);
+ zephir_array_fetch_string(&_3, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVSVSV(_5, "Undefined function '", name, "' in ", _3, " on line ", _4);
ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _5);
zephir_check_call_status();
- zephir_throw_exception_debug(_2, "phalcon/mvc/view/engine/volt/compiler.zep", 572 TSRMLS_CC);
+ zephir_throw_exception_debug(_2, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_CALL_METHOD(&_8, this_ptr, "expression", &_0, 381, nameExpr);
+ ZEPHIR_CALL_METHOD(&_8, this_ptr, "expression", &_0, 383, nameExpr);
zephir_check_call_status();
ZEPHIR_CONCAT_VSVS(return_value, _8, "(", arguments, ")");
RETURN_MM();
@@ -117675,10 +117950,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveTest) {
ZEPHIR_OBS_VAR(type);
- zephir_array_fetch_string(&type, test, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 585 TSRMLS_CC);
+ zephir_array_fetch_string(&type, test, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 586 TSRMLS_CC);
if (ZEPHIR_IS_LONG(type, 265)) {
ZEPHIR_OBS_VAR(name);
- zephir_array_fetch_string(&name, test, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 592 TSRMLS_CC);
+ zephir_array_fetch_string(&name, test, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 593 TSRMLS_CC);
if (ZEPHIR_IS_STRING(name, "empty")) {
ZEPHIR_CONCAT_SVS(return_value, "empty(", left, ")");
RETURN_MM();
@@ -117706,33 +117981,33 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveTest) {
}
if (ZEPHIR_IS_LONG(type, 350)) {
ZEPHIR_OBS_VAR(testName);
- zephir_array_fetch_string(&testName, test, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 643 TSRMLS_CC);
+ zephir_array_fetch_string(&testName, test, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 644 TSRMLS_CC);
ZEPHIR_OBS_NVAR(name);
if (zephir_array_isset_string_fetch(&name, testName, SS("value"), 0 TSRMLS_CC)) {
if (ZEPHIR_IS_STRING(name, "divisibleby")) {
- zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 647 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 381, _1);
+ zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 648 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "(((", left, ") % (", _0, ")) == 0)");
RETURN_MM();
}
if (ZEPHIR_IS_STRING(name, "sameas")) {
- zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 654 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 381, _1);
+ zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 655 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "(", left, ") === (", _0, ")");
RETURN_MM();
}
if (ZEPHIR_IS_STRING(name, "type")) {
- zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 661 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 381, _1);
+ zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 662 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "gettype(", left, ") === (", _0, ")");
RETURN_MM();
}
}
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 381, test);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, test);
zephir_check_call_status();
ZEPHIR_CONCAT_VSV(return_value, left, " == ", _0);
RETURN_MM();
@@ -117758,28 +118033,28 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
ZEPHIR_INIT_VAR(code);
ZVAL_NULL(code);
ZEPHIR_OBS_VAR(type);
- zephir_array_fetch_string(&type, filter, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 680 TSRMLS_CC);
+ zephir_array_fetch_string(&type, filter, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 681 TSRMLS_CC);
if (ZEPHIR_IS_LONG(type, 265)) {
ZEPHIR_OBS_VAR(name);
- zephir_array_fetch_string(&name, filter, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 686 TSRMLS_CC);
+ zephir_array_fetch_string(&name, filter, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 687 TSRMLS_CC);
} else {
if (!ZEPHIR_IS_LONG(type, 350)) {
ZEPHIR_INIT_VAR(_0);
object_init_ex(_0, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 694 TSRMLS_CC);
- zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 694 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC);
ZEPHIR_INIT_VAR(_3);
ZEPHIR_CONCAT_SVSV(_3, "Unknown filter type in ", _1, " on line ", _2);
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 694 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
ZEPHIR_OBS_VAR(functionName);
- zephir_array_fetch_string(&functionName, filter, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 697 TSRMLS_CC);
+ zephir_array_fetch_string(&functionName, filter, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 698 TSRMLS_CC);
ZEPHIR_OBS_NVAR(name);
- zephir_array_fetch_string(&name, functionName, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 698 TSRMLS_CC);
+ zephir_array_fetch_string(&name, functionName, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 699 TSRMLS_CC);
}
ZEPHIR_INIT_VAR(funcArguments);
ZVAL_NULL(funcArguments);
@@ -117789,9 +118064,9 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
if (zephir_array_isset_string_fetch(&funcArguments, filter, SS("arguments"), 0 TSRMLS_CC)) {
if (!ZEPHIR_IS_STRING(name, "default")) {
ZEPHIR_OBS_VAR(file);
- zephir_array_fetch_string(&file, filter, SL("file"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 713 TSRMLS_CC);
+ zephir_array_fetch_string(&file, filter, SL("file"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 714 TSRMLS_CC);
ZEPHIR_OBS_VAR(line);
- zephir_array_fetch_string(&line, filter, SL("line"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 713 TSRMLS_CC);
+ zephir_array_fetch_string(&line, filter, SL("line"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 714 TSRMLS_CC);
ZEPHIR_INIT_VAR(_4);
zephir_create_array(_4, 3, 0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_5);
@@ -117804,11 +118079,11 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
zephir_array_update_string(&_4, SL("file"), &file, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("line"), &line, PH_COPY | PH_SEPARATE);
Z_SET_ISREF_P(funcArguments);
- ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 384, funcArguments, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 386, funcArguments, _4);
Z_UNSET_ISREF_P(funcArguments);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", NULL, 381, funcArguments);
+ ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", NULL, 383, funcArguments);
zephir_check_call_status();
} else {
ZEPHIR_CPY_WRT(arguments, left);
@@ -117823,7 +118098,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
zephir_array_fast_append(_4, funcArguments);
ZEPHIR_INIT_NVAR(_0);
ZVAL_STRING(_0, "compileFilter", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 382, _0, _4);
+ ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 384, _0, _4);
zephir_check_temp_parameter(_0);
zephir_check_call_status();
if (Z_TYPE_P(code) == IS_STRING) {
@@ -117852,13 +118127,13 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
}
ZEPHIR_INIT_NVAR(_0);
object_init_ex(_0, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 776 TSRMLS_CC);
- zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 776 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_3);
ZEPHIR_CONCAT_SVSVSV(_3, "Invalid definition for user filter '", name, "' in ", _1, " on line ", _2);
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 776 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -117981,13 +118256,13 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
}
ZEPHIR_INIT_NVAR(_0);
object_init_ex(_0, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 965 TSRMLS_CC);
- zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 965 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_3);
ZEPHIR_CONCAT_SVSVSV(_3, "Unknown filter \"", name, "\" in ", _1, " on line ", _2);
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 965 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -118021,7 +118296,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
zephir_array_fast_append(_0, expr);
ZEPHIR_INIT_NVAR(_1);
ZVAL_STRING(_1, "resolveExpression", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "fireextensionevent", &_2, 382, _1, _0);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "fireextensionevent", &_2, 384, _1, _0);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
if (Z_TYPE_P(exprCode) == IS_STRING) {
@@ -118032,22 +118307,22 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
if (!(zephir_array_isset_string_fetch(&type, expr, SS("type"), 0 TSRMLS_CC))) {
ZEPHIR_INIT_NVAR(items);
array_init(items);
- zephir_is_iterable(expr, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1006);
+ zephir_is_iterable(expr, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1007);
for (
; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS
; zephir_hash_move_forward_ex(_4, &_3)
) {
ZEPHIR_GET_HVALUE(singleExpr, _5);
- zephir_array_fetch_string(&_6, singleExpr, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 999 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&singleExprCode, this_ptr, "expression", &_7, 381, _6);
+ zephir_array_fetch_string(&_6, singleExpr, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1000 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&singleExprCode, this_ptr, "expression", &_7, 383, _6);
zephir_check_call_status();
ZEPHIR_OBS_NVAR(name);
if (zephir_array_isset_string_fetch(&name, singleExpr, SS("name"), 0 TSRMLS_CC)) {
ZEPHIR_INIT_LNVAR(_8);
ZEPHIR_CONCAT_SVSV(_8, "'", name, "' => ", singleExprCode);
- zephir_array_append(&items, _8, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1001);
+ zephir_array_append(&items, _8, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1002);
} else {
- zephir_array_append(&items, singleExprCode, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1003);
+ zephir_array_append(&items, singleExprCode, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1004);
}
}
ZEPHIR_INIT_NVAR(exprCode);
@@ -118061,24 +118336,24 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
}
ZEPHIR_OBS_NVAR(left);
if (zephir_array_isset_string_fetch(&left, expr, SS("left"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_7, 381, left);
+ ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_7, 383, left);
zephir_check_call_status();
}
if (ZEPHIR_IS_LONG(type, 311)) {
- zephir_array_fetch_string(&_6, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1029 TSRMLS_CC);
+ zephir_array_fetch_string(&_6, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1030 TSRMLS_CC);
ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvetest", &_10, 0, _6, leftCode);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 124)) {
- zephir_array_fetch_string(&_11, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1037 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvefilter", &_12, 385, _11, leftCode);
+ zephir_array_fetch_string(&_11, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1038 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvefilter", &_12, 387, _11, leftCode);
zephir_check_call_status();
break;
}
ZEPHIR_OBS_NVAR(right);
if (zephir_array_isset_string_fetch(&right, expr, SS("right"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&rightCode, this_ptr, "expression", &_7, 381, right);
+ ZEPHIR_CALL_METHOD(&rightCode, this_ptr, "expression", &_7, 383, right);
zephir_check_call_status();
}
ZEPHIR_INIT_NVAR(exprCode);
@@ -118150,17 +118425,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
}
if (ZEPHIR_IS_LONG(type, 258)) {
ZEPHIR_OBS_NVAR(exprCode);
- zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1104 TSRMLS_CC);
+ zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1105 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(type, 259)) {
ZEPHIR_OBS_NVAR(exprCode);
- zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1108 TSRMLS_CC);
+ zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1109 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(type, 260)) {
ZEPHIR_INIT_NVAR(_1);
- zephir_array_fetch_string(&_6, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1112 TSRMLS_CC);
+ zephir_array_fetch_string(&_6, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1113 TSRMLS_CC);
ZEPHIR_SINIT_NVAR(_13);
ZVAL_STRING(&_13, "'", 0);
ZEPHIR_SINIT_NVAR(_14);
@@ -118186,7 +118461,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
break;
}
if (ZEPHIR_IS_LONG(type, 265)) {
- zephir_array_fetch_string(&_11, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1128 TSRMLS_CC);
+ zephir_array_fetch_string(&_11, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1129 TSRMLS_CC);
ZEPHIR_INIT_NVAR(exprCode);
ZEPHIR_CONCAT_SV(exprCode, "$", _11);
break;
@@ -118254,7 +118529,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
if (ZEPHIR_IS_LONG(type, 365)) {
ZEPHIR_OBS_NVAR(start);
if (zephir_array_isset_string_fetch(&start, expr, SS("start"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&startCode, this_ptr, "expression", &_7, 381, start);
+ ZEPHIR_CALL_METHOD(&startCode, this_ptr, "expression", &_7, 383, start);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(startCode);
@@ -118262,7 +118537,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
}
ZEPHIR_OBS_NVAR(end);
if (zephir_array_isset_string_fetch(&end, expr, SS("end"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&endCode, this_ptr, "expression", &_7, 381, end);
+ ZEPHIR_CALL_METHOD(&endCode, this_ptr, "expression", &_7, 383, end);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(endCode);
@@ -118353,8 +118628,8 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
break;
}
if (ZEPHIR_IS_LONG(type, 366)) {
- zephir_array_fetch_string(&_6, expr, SL("ternary"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1267 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_16, this_ptr, "expression", &_7, 381, _6);
+ zephir_array_fetch_string(&_6, expr, SL("ternary"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1268 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_16, this_ptr, "expression", &_7, 383, _6);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(exprCode);
ZEPHIR_CONCAT_SVSVSVS(exprCode, "(", _16, " ? ", leftCode, " : ", rightCode, ")");
@@ -118372,18 +118647,18 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
}
if (ZEPHIR_IS_LONG(type, 364)) {
ZEPHIR_OBS_NVAR(exprCode);
- zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1279 TSRMLS_CC);
+ zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1280 TSRMLS_CC);
break;
}
ZEPHIR_INIT_NVAR(_1);
object_init_ex(_1, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_11, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1283 TSRMLS_CC);
- zephir_array_fetch_string(&_17, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1283 TSRMLS_CC);
+ zephir_array_fetch_string(&_11, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC);
+ zephir_array_fetch_string(&_17, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_8);
ZEPHIR_CONCAT_SVSVSV(_8, "Unknown expression ", type, " in ", _11, " on line ", _17);
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_18, 9, _8);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1283 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
} while(0);
@@ -118414,7 +118689,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, _statementListOrExtends
}
isStatementList = 1;
if (!(zephir_array_isset_string(statements, SS("type")))) {
- zephir_is_iterable(statements, &_1, &_0, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1323);
+ zephir_is_iterable(statements, &_1, &_0, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1324);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -118427,7 +118702,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, _statementListOrExtends
}
}
if (isStatementList == 1) {
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_statementlist", NULL, 386, statements);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_statementlist", NULL, 388, statements);
zephir_check_call_status();
RETURN_MM();
}
@@ -118459,7 +118734,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
if (!(zephir_array_isset_string(statement, SS("expr")))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1351);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1352);
return;
}
ZEPHIR_INIT_VAR(compilation);
@@ -118474,15 +118749,15 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
ZEPHIR_INIT_VAR(prefixLevel);
ZEPHIR_CONCAT_VV(prefixLevel, prefix, level);
ZEPHIR_OBS_VAR(expr);
- zephir_array_fetch_string(&expr, statement, SL("expr"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1369 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 381, expr);
+ zephir_array_fetch_string(&expr, statement, SL("expr"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1370 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 383, expr);
zephir_check_call_status();
ZEPHIR_OBS_VAR(blockStatements);
- zephir_array_fetch_string(&blockStatements, statement, SL("block_statements"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1375 TSRMLS_CC);
+ zephir_array_fetch_string(&blockStatements, statement, SL("block_statements"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1376 TSRMLS_CC);
ZEPHIR_INIT_NVAR(forElse);
ZVAL_BOOL(forElse, 0);
if (Z_TYPE_P(blockStatements) == IS_ARRAY) {
- zephir_is_iterable(blockStatements, &_2, &_1, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1401);
+ zephir_is_iterable(blockStatements, &_2, &_1, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1402);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -118505,7 +118780,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
}
}
}
- ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlist", NULL, 386, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlist", NULL, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
ZEPHIR_OBS_VAR(loopContext);
zephir_read_property_this(&loopContext, this_ptr, SL("_loopPointers"), PH_NOISY_CC);
@@ -118540,7 +118815,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
ZEPHIR_CPY_WRT(iterator, exprCode);
}
ZEPHIR_OBS_VAR(variable);
- zephir_array_fetch_string(&variable, statement, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1430 TSRMLS_CC);
+ zephir_array_fetch_string(&variable, statement, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1431 TSRMLS_CC);
ZEPHIR_OBS_VAR(key);
if (zephir_array_isset_string_fetch(&key, statement, SS("key"), 0 TSRMLS_CC)) {
ZEPHIR_INIT_LNVAR(_5);
@@ -118553,7 +118828,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
}
ZEPHIR_OBS_VAR(ifExpr);
if (zephir_array_isset_string_fetch(&ifExpr, statement, SS("if_expr"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_12, this_ptr, "expression", &_0, 381, ifExpr);
+ ZEPHIR_CALL_METHOD(&_12, this_ptr, "expression", &_0, 383, ifExpr);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVS(_5, "if (", _12, ") { ?>");
@@ -118648,19 +118923,19 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileIf) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1521);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1522);
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 381, expr);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr);
zephir_check_call_status();
- zephir_array_fetch_string(&_2, statement, SL("true_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1527 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_statementlist", &_3, 386, _2, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ zephir_array_fetch_string(&_2, statement, SL("true_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1528 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_statementlist", &_3, 388, _2, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
ZEPHIR_INIT_VAR(compilation);
ZEPHIR_CONCAT_SVSV(compilation, "", _1);
ZEPHIR_OBS_VAR(blockStatements);
if (zephir_array_isset_string_fetch(&blockStatements, statement, SS("false_statements"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "_statementlist", &_3, 386, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "_statementlist", &_3, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZEPHIR_CONCAT_SV(_5, "", _4);
@@ -118686,10 +118961,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileElseIf) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1556);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1557);
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 381, expr);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr);
zephir_check_call_status();
ZEPHIR_CONCAT_SVS(return_value, "");
RETURN_MM();
@@ -118718,12 +118993,12 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1576);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1577);
return;
}
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 381, expr);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 383, expr);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_0, 381, expr);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_0, 383, expr);
zephir_check_call_status();
ZEPHIR_INIT_VAR(compilation);
ZEPHIR_CONCAT_SVS(compilation, "di->get('viewCache'); ");
@@ -118732,14 +119007,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) {
ZEPHIR_INIT_VAR(_2);
ZEPHIR_CONCAT_SVS(_2, "$_cacheKey[", exprCode, "]");
zephir_concat_self(&compilation, _2 TSRMLS_CC);
- zephir_array_fetch_string(&_3, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1586 TSRMLS_CC);
+ zephir_array_fetch_string(&_3, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1587 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_3, 265)) {
- zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1587 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1588 TSRMLS_CC);
ZEPHIR_INIT_VAR(_5);
ZEPHIR_CONCAT_SVSVSVS(_5, " = $_cache[", exprCode, "]->start(", exprCode, ", $", _4, "); ");
zephir_concat_self(&compilation, _5 TSRMLS_CC);
} else {
- zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1589 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1590 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVSVSVS(_5, " = $_cache[", exprCode, "]->start(", exprCode, ", ", _4, "); ");
zephir_concat_self(&compilation, _5 TSRMLS_CC);
@@ -118752,20 +119027,20 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) {
ZEPHIR_INIT_LNVAR(_2);
ZEPHIR_CONCAT_SVS(_2, "if ($_cacheKey[", exprCode, "] === null) { ?>");
zephir_concat_self(&compilation, _2 TSRMLS_CC);
- zephir_array_fetch_string(&_3, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1599 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_6, this_ptr, "_statementlist", NULL, 386, _3, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ zephir_array_fetch_string(&_3, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1600 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_6, this_ptr, "_statementlist", NULL, 388, _3, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_concat_self(&compilation, _6 TSRMLS_CC);
ZEPHIR_OBS_NVAR(lifetime);
if (zephir_array_isset_string_fetch(&lifetime, statement, SS("lifetime"), 0 TSRMLS_CC)) {
- zephir_array_fetch_string(&_4, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1605 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1606 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_4, 265)) {
- zephir_array_fetch_string(&_7, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1606 TSRMLS_CC);
+ zephir_array_fetch_string(&_7, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1607 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVSVSVS(_5, "save(", exprCode, ", null, $", _7, "); ");
zephir_concat_self(&compilation, _5 TSRMLS_CC);
} else {
- zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1608 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1609 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVSVSVS(_5, "save(", exprCode, ", null, ", _4, "); ");
zephir_concat_self(&compilation, _5 TSRMLS_CC);
@@ -118800,24 +119075,24 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileSet) {
ZEPHIR_OBS_VAR(assignments);
if (!(zephir_array_isset_string_fetch(&assignments, statement, SS("assignments"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1629);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1630);
return;
}
ZEPHIR_INIT_VAR(compilation);
ZVAL_STRING(compilation, "");
RETURN_MM();
@@ -118895,10 +119170,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileReturn) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1710);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1711);
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 381, expr);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr);
zephir_check_call_status();
ZEPHIR_CONCAT_SVS(return_value, "");
RETURN_MM();
@@ -118922,14 +119197,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileAutoEscape) {
ZEPHIR_OBS_VAR(autoescape);
if (!(zephir_array_isset_string_fetch(&autoescape, statement, SS("enable"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1730);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1731);
return;
}
ZEPHIR_OBS_VAR(oldAutoescape);
zephir_read_property_this(&oldAutoescape, this_ptr, SL("_autoescape"), PH_NOISY_CC);
zephir_update_property_this(this_ptr, SL("_autoescape"), autoescape TSRMLS_CC);
- zephir_array_fetch_string(&_0, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1739 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&compilation, this_ptr, "_statementlist", NULL, 386, _0, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ zephir_array_fetch_string(&_0, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1740 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&compilation, this_ptr, "_statementlist", NULL, 388, _0, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_autoescape"), oldAutoescape TSRMLS_CC);
RETURN_CCTOR(compilation);
@@ -118951,17 +119226,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileEcho) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1760);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1761);
return;
}
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", NULL, 381, expr);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", NULL, 383, expr);
zephir_check_call_status();
- zephir_array_fetch_string(&_0, expr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1768 TSRMLS_CC);
+ zephir_array_fetch_string(&_0, expr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1769 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_0, 350)) {
- zephir_array_fetch_string(&name, expr, SL("name"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1770 TSRMLS_CC);
- zephir_array_fetch_string(&_1, name, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1772 TSRMLS_CC);
+ zephir_array_fetch_string(&name, expr, SL("name"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1771 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, name, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1773 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_1, 265)) {
- zephir_array_fetch_string(&_2, name, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1777 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, name, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1778 TSRMLS_CC);
if (ZEPHIR_IS_STRING(_2, "super")) {
RETURN_CCTOR(exprCode);
}
@@ -118993,14 +119268,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileInclude) {
ZEPHIR_OBS_VAR(pathExpr);
if (!(zephir_array_isset_string_fetch(&pathExpr, statement, SS("path"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1805);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1806);
return;
}
- zephir_array_fetch_string(&_0, pathExpr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1812 TSRMLS_CC);
+ zephir_array_fetch_string(&_0, pathExpr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1813 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_0, 260)) {
if (!(zephir_array_isset_string(statement, SS("params")))) {
ZEPHIR_OBS_VAR(path);
- zephir_array_fetch_string(&path, pathExpr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1822 TSRMLS_CC);
+ zephir_array_fetch_string(&path, pathExpr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1823 TSRMLS_CC);
ZEPHIR_OBS_VAR(view);
zephir_read_property_this(&view, this_ptr, SL("_view"), PH_NOISY_CC);
if (Z_TYPE_P(view) == IS_OBJECT) {
@@ -119028,14 +119303,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileInclude) {
RETURN_CCTOR(compilation);
}
}
- ZEPHIR_CALL_METHOD(&path, this_ptr, "expression", &_3, 381, pathExpr);
+ ZEPHIR_CALL_METHOD(&path, this_ptr, "expression", &_3, 383, pathExpr);
zephir_check_call_status();
ZEPHIR_OBS_VAR(params);
if (!(zephir_array_isset_string_fetch(¶ms, statement, SS("params"), 0 TSRMLS_CC))) {
ZEPHIR_CONCAT_SVS(return_value, "partial(", path, "); ?>");
RETURN_MM();
}
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_3, 381, params);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_3, 383, params);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "partial(", path, ", ", _1, "); ?>");
RETURN_MM();
@@ -119062,7 +119337,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
ZEPHIR_OBS_VAR(name);
if (!(zephir_array_isset_string_fetch(&name, statement, SS("name"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1877);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1878);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_macros"), PH_NOISY_CC);
@@ -119073,7 +119348,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
ZEPHIR_CONCAT_SVS(_2, "Macro '", name, "' is already defined");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1884 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1885 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -119091,7 +119366,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
ZEPHIR_INIT_LNVAR(_2);
ZEPHIR_CONCAT_VS(_2, macroName, " = function($__p = null) { ");
zephir_concat_self(&code, _2 TSRMLS_CC);
- zephir_is_iterable(parameters, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1922);
+ zephir_is_iterable(parameters, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1923);
for (
; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS
; zephir_hash_move_forward_ex(_4, &_3)
@@ -119099,7 +119374,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
ZEPHIR_GET_HMKEY(position, _4, _3);
ZEPHIR_GET_HVALUE(parameter, _5);
ZEPHIR_OBS_NVAR(variableName);
- zephir_array_fetch_string(&variableName, parameter, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1906 TSRMLS_CC);
+ zephir_array_fetch_string(&variableName, parameter, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1907 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_6);
ZEPHIR_CONCAT_SVS(_6, "if (isset($__p[", position, "])) { ");
zephir_concat_self(&code, _6 TSRMLS_CC);
@@ -119116,7 +119391,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
zephir_concat_self_str(&code, SL(" } else { ") TSRMLS_CC);
ZEPHIR_OBS_NVAR(defaultValue);
if (zephir_array_isset_string_fetch(&defaultValue, parameter, SS("default"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_10, this_ptr, "expression", &_11, 381, defaultValue);
+ ZEPHIR_CALL_METHOD(&_10, this_ptr, "expression", &_11, 383, defaultValue);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_12);
ZEPHIR_CONCAT_SVSVS(_12, "$", variableName, " = ", _10, ";");
@@ -119132,7 +119407,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
}
ZEPHIR_OBS_VAR(blockStatements);
if (zephir_array_isset_string_fetch(&blockStatements, statement, SS("block_statements"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_10, this_ptr, "_statementlist", NULL, 386, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_10, this_ptr, "_statementlist", NULL, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_2);
ZEPHIR_CONCAT_VS(_2, _10, " 1) {
ZEPHIR_OBS_VAR(numberOfBytes);
- zephir_array_fetch_long(&numberOfBytes, response, 1, PH_NOISY, "phalcon/queue/beanstalk.zep", 288 TSRMLS_CC);
+ zephir_array_fetch_long(&numberOfBytes, response, 1, PH_NOISY, "phalcon/queue/beanstalk.zep", 293 TSRMLS_CC);
ZEPHIR_CALL_METHOD(&response, this_ptr, "read", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&data, "yaml_parse", NULL, 0, response);
@@ -130444,13 +130723,13 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, read) {
}
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, (length + 2));
- ZEPHIR_CALL_FUNCTION(&data, "fread", NULL, 393, connection, &_0);
+ ZEPHIR_CALL_FUNCTION(&data, "fread", NULL, 395, connection, &_0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_1, "stream_get_meta_data", NULL, 394, connection);
+ ZEPHIR_CALL_FUNCTION(&_1, "stream_get_meta_data", NULL, 396, connection);
zephir_check_call_status();
- zephir_array_fetch_string(&_2, _1, SL("timed_out"), PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 332 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, _1, SL("timed_out"), PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 337 TSRMLS_CC);
if (zephir_is_true(_2)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_exception_ce, "Connection timed out", "phalcon/queue/beanstalk.zep", 333);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_exception_ce, "Connection timed out", "phalcon/queue/beanstalk.zep", 338);
return;
}
ZEPHIR_SINIT_NVAR(_0);
@@ -130462,7 +130741,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, read) {
ZVAL_LONG(&_0, 16384);
ZEPHIR_SINIT_VAR(_3);
ZVAL_STRING(&_3, "\r\n", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("stream_get_line", NULL, 395, connection, &_0, &_3);
+ ZEPHIR_RETURN_CALL_FUNCTION("stream_get_line", NULL, 397, connection, &_0, &_3);
zephir_check_call_status();
RETURN_MM();
@@ -130494,7 +130773,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, write) {
ZEPHIR_CPY_WRT(packet, _0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, zephir_fast_strlen_ev(packet));
- ZEPHIR_RETURN_CALL_FUNCTION("fwrite", NULL, 396, connection, packet, &_1);
+ ZEPHIR_RETURN_CALL_FUNCTION("fwrite", NULL, 398, connection, packet, &_1);
zephir_check_call_status();
RETURN_MM();
@@ -130560,15 +130839,19 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, getBody) {
static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, __construct) {
- zval *queue, *id, *body;
+ zval *id = NULL;
+ zval *queue, *id_param = NULL, *body;
- zephir_fetch_params(0, 3, 0, &queue, &id, &body);
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 3, 0, &queue, &id_param, &body);
+ zephir_get_strval(id, id_param);
zephir_update_property_this(this_ptr, SL("_queue"), queue TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_id"), id TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_body"), body TSRMLS_CC);
+ ZEPHIR_MM_RESTORE();
}
@@ -130588,7 +130871,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, delete) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 59 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 57 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_3, "DELETED"));
}
@@ -130626,7 +130909,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, release) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_4, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_5, _4, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 73 TSRMLS_CC);
+ zephir_array_fetch_long(&_5, _4, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 71 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_5, "RELEASED"));
}
@@ -130657,7 +130940,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, bury) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_3, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_4, _3, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 87 TSRMLS_CC);
+ zephir_array_fetch_long(&_4, _3, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 85 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_4, "BURIED"));
}
@@ -130678,7 +130961,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, touch) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 104 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 102 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_3, "TOUCHED"));
}
@@ -130699,7 +130982,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, kick) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 116 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 114 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_3, "KICKED"));
}
@@ -130720,11 +131003,11 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, stats) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&response, queue, "readyaml", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_2, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 130 TSRMLS_CC);
+ zephir_array_fetch_long(&_2, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 128 TSRMLS_CC);
if (ZEPHIR_IS_STRING(_2, "NOT_FOUND")) {
RETURN_MM_BOOL(0);
}
- zephir_array_fetch_long(&_3, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 134 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 132 TSRMLS_CC);
RETURN_CTOR(_3);
}
@@ -130749,7 +131032,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, __wakeup) {
zephir_check_temp_parameter(_2);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/queue/beanstalk/job.zep", 143 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/queue/beanstalk/job.zep", 141 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -131635,7 +131918,7 @@ static PHP_METHOD(Phalcon_Session_Bag, getIterator) {
}
object_init_ex(return_value, zephir_get_internal_ce(SS("arrayiterator") TSRMLS_CC));
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 410, _1);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 412, _1);
zephir_check_call_status();
RETURN_MM();
@@ -131923,7 +132206,7 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) {
ZEPHIR_OBS_VAR(_3);
zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC);
zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 317, _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_4);
zephir_create_array(_4, 4, 0 TSRMLS_CC);
@@ -131931,7 +132214,7 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) {
zephir_array_update_string(&_4, SL("client"), &client, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("prefix"), &prefix, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("statsKey"), &statsKey, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 318, _1, _4);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 319, _1, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_libmemcached"), _0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_5);
@@ -131970,9 +132253,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) {
ZEPHIR_INIT_NVAR(_6);
ZVAL_STRING(_6, "gc", 1);
zephir_array_fast_append(_11, _6);
- ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 408, _5, _7, _8, _9, _10, _11);
+ ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _5, _7, _8, _9, _10, _11);
zephir_check_call_status();
- ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_libmemcached_ce, this_ptr, "__construct", &_12, 409, options);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_libmemcached_ce, this_ptr, "__construct", &_12, 411, options);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -132148,9 +132431,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Memcache, __construct) {
ZEPHIR_OBS_VAR(_3);
zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC);
zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 317, _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 320, _1, options);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 321, _1, options);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_4);
@@ -132189,9 +132472,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Memcache, __construct) {
ZEPHIR_INIT_NVAR(_5);
ZVAL_STRING(_5, "gc", 1);
zephir_array_fast_append(_10, _5);
- ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 408, _4, _6, _7, _8, _9, _10);
+ ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _4, _6, _7, _8, _9, _10);
zephir_check_call_status();
- ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_memcache_ce, this_ptr, "__construct", &_11, 409, options);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_memcache_ce, this_ptr, "__construct", &_11, 411, options);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -132283,6 +132566,223 @@ static PHP_METHOD(Phalcon_Session_Adapter_Memcache, gc) {
+#ifdef HAVE_CONFIG_H
+#endif
+
+#include
+
+#include
+#include
+#include
+
+
+
+ZEPHIR_INIT_CLASS(Phalcon_Session_Adapter_Redis) {
+
+ ZEPHIR_REGISTER_CLASS_EX(Phalcon\\Session\\Adapter, Redis, phalcon, session_adapter_redis, phalcon_session_adapter_ce, phalcon_session_adapter_redis_method_entry, 0);
+
+ zend_declare_property_null(phalcon_session_adapter_redis_ce, SL("_redis"), ZEND_ACC_PROTECTED TSRMLS_CC);
+
+ zend_declare_property_long(phalcon_session_adapter_redis_ce, SL("_lifetime"), 8600, ZEND_ACC_PROTECTED TSRMLS_CC);
+
+ zend_class_implements(phalcon_session_adapter_redis_ce TSRMLS_CC, 1, phalcon_session_adapterinterface_ce);
+ return SUCCESS;
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, getRedis) {
+
+
+ RETURN_MEMBER(this_ptr, "_redis");
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, getLifetime) {
+
+
+ RETURN_MEMBER(this_ptr, "_lifetime");
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, __construct) {
+
+ zephir_fcall_cache_entry *_11 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *options_param = NULL, *lifetime, *_0 = NULL, *_1, *_3, *_5 = NULL;
+ zval *options = NULL, *_2, *_4, *_6, *_7, *_8, *_9, *_10;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 0, 1, &options_param);
+
+ if (!options_param) {
+ ZEPHIR_INIT_VAR(options);
+ array_init(options);
+ } else {
+ zephir_get_arrval(options, options_param);
+ }
+
+
+ if (!(zephir_array_isset_string(options, SS("host")))) {
+ ZEPHIR_INIT_VAR(_0);
+ ZVAL_STRING(_0, "127.0.0.1", 1);
+ zephir_array_update_string(&options, SL("host"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("port")))) {
+ ZEPHIR_INIT_NVAR(_0);
+ ZVAL_LONG(_0, 6379);
+ zephir_array_update_string(&options, SL("port"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("persistent")))) {
+ zephir_array_update_string(&options, SL("persistent"), &ZEPHIR_GLOBAL(global_false), PH_COPY | PH_SEPARATE);
+ }
+ ZEPHIR_OBS_VAR(lifetime);
+ if (zephir_array_isset_string_fetch(&lifetime, options, SS("lifetime"), 0 TSRMLS_CC)) {
+ zephir_update_property_this(this_ptr, SL("_lifetime"), lifetime TSRMLS_CC);
+ }
+ ZEPHIR_INIT_NVAR(_0);
+ object_init_ex(_0, phalcon_cache_backend_redis_ce);
+ ZEPHIR_INIT_VAR(_1);
+ object_init_ex(_1, phalcon_cache_frontend_data_ce);
+ ZEPHIR_INIT_VAR(_2);
+ zephir_create_array(_2, 1, 0 TSRMLS_CC);
+ ZEPHIR_OBS_VAR(_3);
+ zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC);
+ zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 322, _1, options);
+ zephir_check_call_status();
+ zephir_update_property_this(this_ptr, SL("_redis"), _0 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_4);
+ zephir_create_array(_4, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_4, this_ptr);
+ ZEPHIR_INIT_VAR(_5);
+ ZVAL_STRING(_5, "open", 1);
+ zephir_array_fast_append(_4, _5);
+ ZEPHIR_INIT_VAR(_6);
+ zephir_create_array(_6, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_6, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "close", 1);
+ zephir_array_fast_append(_6, _5);
+ ZEPHIR_INIT_VAR(_7);
+ zephir_create_array(_7, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_7, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "read", 1);
+ zephir_array_fast_append(_7, _5);
+ ZEPHIR_INIT_VAR(_8);
+ zephir_create_array(_8, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_8, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "write", 1);
+ zephir_array_fast_append(_8, _5);
+ ZEPHIR_INIT_VAR(_9);
+ zephir_create_array(_9, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_9, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "destroy", 1);
+ zephir_array_fast_append(_9, _5);
+ ZEPHIR_INIT_VAR(_10);
+ zephir_create_array(_10, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_10, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "gc", 1);
+ zephir_array_fast_append(_10, _5);
+ ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _4, _6, _7, _8, _9, _10);
+ zephir_check_call_status();
+ ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_redis_ce, this_ptr, "__construct", &_11, 411, options);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, open) {
+
+
+ RETURN_BOOL(1);
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, close) {
+
+
+ RETURN_BOOL(1);
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, read) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *sessionId, *_0, *_1;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 0, &sessionId);
+
+
+
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ _1 = zephir_fetch_nproperty_this(this_ptr, SL("_lifetime"), PH_NOISY_CC);
+ ZEPHIR_RETURN_CALL_METHOD(_0, "get", NULL, 0, sessionId, _1);
+ zephir_check_call_status();
+ RETURN_MM();
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, write) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *sessionId, *data, *_0, *_1;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 2, 0, &sessionId, &data);
+
+
+
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ _1 = zephir_fetch_nproperty_this(this_ptr, SL("_lifetime"), PH_NOISY_CC);
+ ZEPHIR_CALL_METHOD(NULL, _0, "save", NULL, 0, sessionId, data, _1);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, destroy) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *sessionId = NULL, *_0;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 0, 1, &sessionId);
+
+ if (!sessionId) {
+ ZEPHIR_CPY_WRT(sessionId, ZEPHIR_GLOBAL(global_null));
+ } else {
+ ZEPHIR_SEPARATE_PARAM(sessionId);
+ }
+
+
+ if (Z_TYPE_P(sessionId) == IS_NULL) {
+ ZEPHIR_CALL_METHOD(&sessionId, this_ptr, "getid", NULL, 0);
+ zephir_check_call_status();
+ }
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ ZEPHIR_RETURN_CALL_METHOD(_0, "delete", NULL, 0, sessionId);
+ zephir_check_call_status();
+ RETURN_MM();
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, gc) {
+
+
+ RETURN_BOOL(1);
+
+}
+
+
+
+
#ifdef HAVE_CONFIG_H
#endif
@@ -132432,7 +132932,7 @@ static PHP_METHOD(Phalcon_Tag_Select, selectField) {
ZEPHIR_GET_CONSTANT(_6, "PHP_EOL");
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SV(_7, "", _6);
- ZEPHIR_CALL_SELF(&_8, "_optionsfromresultset", &_9, 414, options, using, value, _7);
+ ZEPHIR_CALL_SELF(&_8, "_optionsfromresultset", &_9, 416, options, using, value, _7);
zephir_check_call_status();
zephir_concat_self(&code, _8 TSRMLS_CC);
} else {
@@ -132441,7 +132941,7 @@ static PHP_METHOD(Phalcon_Tag_Select, selectField) {
ZEPHIR_GET_CONSTANT(_6, "PHP_EOL");
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SV(_7, "", _6);
- ZEPHIR_CALL_SELF(&_8, "_optionsfromarray", &_10, 415, options, value, _7);
+ ZEPHIR_CALL_SELF(&_8, "_optionsfromarray", &_10, 417, options, value, _7);
zephir_check_call_status();
zephir_concat_self(&code, _8 TSRMLS_CC);
} else {
@@ -132579,12 +133079,12 @@ static PHP_METHOD(Phalcon_Tag_Select, _optionsFromArray) {
) {
ZEPHIR_GET_HMKEY(optionValue, _1, _0);
ZEPHIR_GET_HVALUE(optionText, _2);
- ZEPHIR_CALL_FUNCTION(&escaped, "htmlspecialchars", &_3, 180, optionValue);
+ ZEPHIR_CALL_FUNCTION(&escaped, "htmlspecialchars", &_3, 181, optionValue);
zephir_check_call_status();
if (Z_TYPE_P(optionText) == IS_ARRAY) {
ZEPHIR_INIT_NVAR(_4);
ZEPHIR_GET_CONSTANT(_4, "PHP_EOL");
- ZEPHIR_CALL_SELF(&_5, "_optionsfromarray", &_6, 415, optionText, value, closeOption);
+ ZEPHIR_CALL_SELF(&_5, "_optionsfromarray", &_6, 417, optionText, value, closeOption);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_7);
ZEPHIR_GET_CONSTANT(_7, "PHP_EOL");
@@ -132641,10 +133141,53 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter) {
ZEPHIR_REGISTER_CLASS(Phalcon\\Translate, Adapter, phalcon, translate_adapter, phalcon_translate_adapter_method_entry, ZEND_ACC_EXPLICIT_ABSTRACT_CLASS);
+ zend_declare_property_null(phalcon_translate_adapter_ce, SL("_interpolator"), ZEND_ACC_PROTECTED TSRMLS_CC);
+
return SUCCESS;
}
+static PHP_METHOD(Phalcon_Translate_Adapter, __construct) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *options_param = NULL, *interpolator = NULL;
+ zval *options = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 0, &options_param);
+
+ options = options_param;
+
+
+
+ ZEPHIR_OBS_VAR(interpolator);
+ if (!(zephir_array_isset_string_fetch(&interpolator, options, SS("interpolator"), 0 TSRMLS_CC))) {
+ ZEPHIR_INIT_NVAR(interpolator);
+ object_init_ex(interpolator, phalcon_translate_interpolator_associativearray_ce);
+ if (zephir_has_constructor(interpolator TSRMLS_CC)) {
+ ZEPHIR_CALL_METHOD(NULL, interpolator, "__construct", NULL, 0);
+ zephir_check_call_status();
+ }
+ }
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "setinterpolator", NULL, 0, interpolator);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Translate_Adapter, setInterpolator) {
+
+ zval *interpolator;
+
+ zephir_fetch_params(0, 1, 0, &interpolator);
+
+
+
+ zephir_update_property_this(this_ptr, SL("_interpolator"), interpolator TSRMLS_CC);
+ RETURN_THISW();
+
+}
+
static PHP_METHOD(Phalcon_Translate_Adapter, t) {
int ZEPHIR_LAST_CALL_STATUS;
@@ -132715,7 +133258,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter, offsetSet) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_translate_exception_ce, "Translate is an immutable ArrayAccess object", "phalcon/translate/adapter.zep", 64);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_translate_exception_ce, "Translate is an immutable ArrayAccess object", "phalcon/translate/adapter.zep", 86);
return;
}
@@ -132756,7 +133299,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter, offsetUnset) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_translate_exception_ce, "Translate is an immutable ArrayAccess object", "phalcon/translate/adapter.zep", 82);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_translate_exception_ce, "Translate is an immutable ArrayAccess object", "phalcon/translate/adapter.zep", 104);
return;
}
@@ -132793,9 +133336,8 @@ static PHP_METHOD(Phalcon_Translate_Adapter, offsetGet) {
static PHP_METHOD(Phalcon_Translate_Adapter, replacePlaceholders) {
- HashTable *_1;
- HashPosition _0;
- zval *translation_param = NULL, *placeholders = NULL, *key = NULL, *value = NULL, **_2, *_3 = NULL, *_4 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *translation_param = NULL, *placeholders = NULL, *_0;
zval *translation = NULL;
ZEPHIR_MM_GROW();
@@ -132817,24 +133359,10 @@ static PHP_METHOD(Phalcon_Translate_Adapter, replacePlaceholders) {
}
- if (Z_TYPE_P(placeholders) == IS_ARRAY) {
- if (zephir_fast_count_int(placeholders TSRMLS_CC)) {
- zephir_is_iterable(placeholders, &_1, &_0, 0, 0, "phalcon/translate/adapter.zep", 108);
- for (
- ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
- ; zephir_hash_move_forward_ex(_1, &_0)
- ) {
- ZEPHIR_GET_HMKEY(key, _1, _0);
- ZEPHIR_GET_HVALUE(value, _2);
- ZEPHIR_INIT_NVAR(_3);
- ZEPHIR_INIT_LNVAR(_4);
- ZEPHIR_CONCAT_SVS(_4, "%", key, "%");
- zephir_fast_str_replace(&_3, _4, value, translation TSRMLS_CC);
- zephir_get_strval(translation, _3);
- }
- }
- }
- RETURN_CTOR(translation);
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_interpolator"), PH_NOISY_CC);
+ ZEPHIR_RETURN_CALL_METHOD(_0, "replaceplaceholders", NULL, 0, translation, placeholders);
+ zephir_check_call_status();
+ RETURN_MM();
}
@@ -132889,6 +133417,28 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Exception) {
+#ifdef HAVE_CONFIG_H
+#endif
+
+#include
+
+#include
+
+
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_InterpolatorInterface) {
+
+ ZEPHIR_REGISTER_INTERFACE(Phalcon\\Translate, InterpolatorInterface, phalcon, translate_interpolatorinterface, phalcon_translate_interpolatorinterface_method_entry);
+
+ return SUCCESS;
+
+}
+
+ZEPHIR_DOC_METHOD(Phalcon_Translate_InterpolatorInterface, replacePlaceholders);
+
+
+
+
#ifdef HAVE_CONFIG_H
#endif
@@ -132916,11 +133466,10 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter_Csv) {
static PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct) {
- zend_bool _12;
- zephir_fcall_cache_entry *_9 = NULL;
int ZEPHIR_LAST_CALL_STATUS;
- zval *options_param = NULL, *data = NULL, *file = NULL, *_0, *_2, _3 = zval_used_for_init, *_4 = NULL, *_5, *_6, *_7, *_8, *_10, _11 = zval_used_for_init, *_13, *_14 = NULL;
- zval *options = NULL, *_1;
+ zephir_fcall_cache_entry *_0 = NULL;
+ zval *options_param = NULL, *_1, *_2, *_3, *_4;
+ zval *options = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 0, &options_param);
@@ -132929,64 +133478,80 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct) {
+ ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_csv_ce, this_ptr, "__construct", &_0, 426, options);
+ zephir_check_call_status();
if (!(zephir_array_isset_string(options, SS("content")))) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter 'content' is required", "phalcon/translate/adapter/csv.zep", 43);
return;
}
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_INIT_VAR(_1);
- zephir_create_array(_1, 3, 0 TSRMLS_CC);
- add_assoc_stringl_ex(_1, SS("delimiter"), SL(";"), 1);
- add_assoc_long_ex(_1, SS("length"), 0);
- add_assoc_stringl_ex(_1, SS("enclosure"), SL("\""), 1);
- zephir_fast_array_merge(_0, &(_1), &(options) TSRMLS_CC);
- ZEPHIR_CPY_WRT(options, _0);
- zephir_array_fetch_string(&_2, options, SL("content"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 52 TSRMLS_CC);
- ZEPHIR_SINIT_VAR(_3);
- ZVAL_STRING(&_3, "rb", 0);
- ZEPHIR_CALL_FUNCTION(&file, "fopen", NULL, 291, _2, &_3);
+ zephir_array_fetch_string(&_1, options, SL("content"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 46 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_2);
+ ZVAL_LONG(_2, 0);
+ ZEPHIR_INIT_VAR(_3);
+ ZVAL_STRING(_3, ";", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_INIT_VAR(_4);
+ ZVAL_STRING(_4, "\"", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "_load", NULL, 427, _1, _2, _3, _4);
+ zephir_check_temp_parameter(_3);
+ zephir_check_temp_parameter(_4);
zephir_check_call_status();
- if (Z_TYPE_P(file) != IS_RESOURCE) {
- ZEPHIR_INIT_VAR(_4);
- object_init_ex(_4, phalcon_translate_exception_ce);
- zephir_array_fetch_string(&_5, options, SL("content"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 55 TSRMLS_CC);
- ZEPHIR_INIT_VAR(_6);
- ZEPHIR_CONCAT_SVS(_6, "Error opening translation file '", _5, "'");
- ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 9, _6);
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Translate_Adapter_Csv, _load) {
+
+ zend_bool _6;
+ zephir_fcall_cache_entry *_3 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *file, *length, *delimiter, *enclosure, *data = NULL, *fileHandler = NULL, _0 = zval_used_for_init, *_1 = NULL, *_2, *_4, _5 = zval_used_for_init, *_7, *_8 = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 4, 0, &file, &length, &delimiter, &enclosure);
+
+
+
+ ZEPHIR_SINIT_VAR(_0);
+ ZVAL_STRING(&_0, "rb", 0);
+ ZEPHIR_CALL_FUNCTION(&fileHandler, "fopen", NULL, 292, file, &_0);
+ zephir_check_call_status();
+ if (Z_TYPE_P(fileHandler) != IS_RESOURCE) {
+ ZEPHIR_INIT_VAR(_1);
+ object_init_ex(_1, phalcon_translate_exception_ce);
+ ZEPHIR_INIT_VAR(_2);
+ ZEPHIR_CONCAT_SVS(_2, "Error opening translation file '", file, "'");
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_4, "phalcon/translate/adapter/csv.zep", 55 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/translate/adapter/csv.zep", 64 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
while (1) {
- zephir_array_fetch_string(&_5, options, SL("length"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 60 TSRMLS_CC);
- zephir_array_fetch_string(&_7, options, SL("delimiter"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 60 TSRMLS_CC);
- zephir_array_fetch_string(&_8, options, SL("enclosure"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 60 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&data, "fgetcsv", &_9, 424, file, _5, _7, _8);
+ ZEPHIR_CALL_FUNCTION(&data, "fgetcsv", &_3, 428, fileHandler, length, delimiter, enclosure);
zephir_check_call_status();
if (ZEPHIR_IS_FALSE_IDENTICAL(data)) {
break;
}
- zephir_array_fetch_long(&_10, data, 0, PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 65 TSRMLS_CC);
- ZEPHIR_SINIT_NVAR(_3);
- ZVAL_LONG(&_3, 0);
- ZEPHIR_SINIT_NVAR(_11);
- ZVAL_LONG(&_11, 1);
- ZEPHIR_INIT_NVAR(_4);
- zephir_substr(_4, _10, 0 , 1 , 0);
- _12 = ZEPHIR_IS_STRING_IDENTICAL(_4, "#");
- if (!(_12)) {
- _12 = !(zephir_array_isset_long(data, 1));
+ zephir_array_fetch_long(&_4, data, 0, PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 74 TSRMLS_CC);
+ ZEPHIR_SINIT_NVAR(_0);
+ ZVAL_LONG(&_0, 0);
+ ZEPHIR_SINIT_NVAR(_5);
+ ZVAL_LONG(&_5, 1);
+ ZEPHIR_INIT_NVAR(_1);
+ zephir_substr(_1, _4, 0 , 1 , 0);
+ _6 = ZEPHIR_IS_STRING_IDENTICAL(_1, "#");
+ if (!(_6)) {
+ _6 = !(zephir_array_isset_long(data, 1));
}
- if (_12) {
+ if (_6) {
continue;
}
- zephir_array_fetch_long(&_13, data, 1, PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 69 TSRMLS_CC);
- ZEPHIR_OBS_NVAR(_14);
- zephir_array_fetch_long(&_14, data, 0, PH_NOISY, "phalcon/translate/adapter/csv.zep", 69 TSRMLS_CC);
- zephir_update_property_array(this_ptr, SL("_translate"), _14, _13 TSRMLS_CC);
+ zephir_array_fetch_long(&_7, data, 1, PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 78 TSRMLS_CC);
+ ZEPHIR_OBS_NVAR(_8);
+ zephir_array_fetch_long(&_8, data, 0, PH_NOISY, "phalcon/translate/adapter/csv.zep", 78 TSRMLS_CC);
+ zephir_update_property_array(this_ptr, SL("_translate"), _8, _7 TSRMLS_CC);
}
- zephir_fclose(file TSRMLS_CC);
+ zephir_fclose(fileHandler TSRMLS_CC);
ZEPHIR_MM_RESTORE();
}
@@ -133109,6 +133674,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter_Gettext) {
static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, __construct) {
int ZEPHIR_LAST_CALL_STATUS;
+ zephir_fcall_cache_entry *_0 = NULL;
zval *options_param = NULL;
zval *options = NULL;
@@ -133119,6 +133685,8 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, __construct) {
+ ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_gettext_ce, this_ptr, "__construct", &_0, 426, options);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, this_ptr, "prepareoptions", NULL, 0, options);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -133150,22 +133718,22 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, query) {
}
- ZEPHIR_CALL_FUNCTION(&_0, "func_num_args", NULL, 419);
+ ZEPHIR_CALL_FUNCTION(&_0, "func_num_args", NULL, 421);
zephir_check_call_status();
if (ZEPHIR_GT_LONG(_0, 2)) {
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, 2);
- ZEPHIR_CALL_FUNCTION(&domain, "func_get_arg", NULL, 418, &_1);
+ ZEPHIR_CALL_FUNCTION(&domain, "func_get_arg", NULL, 420, &_1);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(domain);
ZVAL_NULL(domain);
}
if (!(zephir_is_true(domain))) {
- ZEPHIR_CALL_FUNCTION(&translation, "gettext", NULL, 425, index);
+ ZEPHIR_CALL_FUNCTION(&translation, "gettext", NULL, 429, index);
zephir_check_call_status();
} else {
- ZEPHIR_CALL_FUNCTION(&translation, "dgettext", NULL, 426, domain, index);
+ ZEPHIR_CALL_FUNCTION(&translation, "dgettext", NULL, 430, domain, index);
zephir_check_call_status();
}
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "replaceplaceholders", NULL, 0, translation, placeholders);
@@ -133263,12 +133831,12 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, nquery) {
if (!(domain && Z_STRLEN_P(domain))) {
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, count);
- ZEPHIR_CALL_FUNCTION(&translation, "ngettext", NULL, 427, msgid1, msgid2, &_0);
+ ZEPHIR_CALL_FUNCTION(&translation, "ngettext", NULL, 431, msgid1, msgid2, &_0);
zephir_check_call_status();
} else {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, count);
- ZEPHIR_CALL_FUNCTION(&translation, "dngettext", NULL, 428, domain, msgid1, msgid2, &_0);
+ ZEPHIR_CALL_FUNCTION(&translation, "dngettext", NULL, 432, domain, msgid1, msgid2, &_0);
zephir_check_call_status();
}
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "replaceplaceholders", NULL, 0, translation, placeholders);
@@ -133299,7 +133867,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setDomain) {
}
- ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 429, domain);
+ ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 433, domain);
zephir_check_call_status();
RETURN_MM();
@@ -133314,7 +133882,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, resetDomain) {
ZEPHIR_CALL_METHOD(&_0, this_ptr, "getdefaultdomain", NULL, 0);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 429, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 433, _0);
zephir_check_call_status();
RETURN_MM();
@@ -133369,21 +133937,21 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setDirectory) {
zephir_update_property_this(this_ptr, SL("_directory"), directory TSRMLS_CC);
if (Z_TYPE_P(directory) == IS_ARRAY) {
if (zephir_fast_count_int(directory TSRMLS_CC)) {
- zephir_is_iterable(directory, &_1, &_0, 0, 0, "phalcon/translate/adapter/gettext.zep", 180);
+ zephir_is_iterable(directory, &_1, &_0, 0, 0, "phalcon/translate/adapter/gettext.zep", 181);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
) {
ZEPHIR_GET_HMKEY(key, _1, _0);
ZEPHIR_GET_HVALUE(value, _2);
- ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 430, key, value);
+ ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 434, key, value);
zephir_check_call_status();
}
}
} else {
ZEPHIR_CALL_METHOD(&_4, this_ptr, "getdefaultdomain", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 430, _4, directory);
+ ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 434, _4, directory);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -133426,7 +133994,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setLocale) {
ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CALL_FUNCTION(&_1, "func_get_args", NULL, 165);
+ ZEPHIR_CALL_FUNCTION(&_1, "func_get_args", NULL, 166);
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_2);
ZVAL_STRING(&_2, "setlocale", 0);
@@ -133439,12 +134007,12 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setLocale) {
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_locale"), PH_NOISY_CC);
ZEPHIR_INIT_VAR(_4);
ZEPHIR_CONCAT_SV(_4, "LC_ALL=", _3);
- ZEPHIR_CALL_FUNCTION(NULL, "putenv", NULL, 431, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "putenv", NULL, 435, _4);
zephir_check_call_status();
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_locale"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_6);
ZVAL_LONG(&_6, 0);
- ZEPHIR_CALL_FUNCTION(NULL, "setlocale", NULL, 413, &_6, _5);
+ ZEPHIR_CALL_FUNCTION(NULL, "setlocale", NULL, 415, &_6, _5);
zephir_check_call_status();
RETURN_MM_MEMBER(this_ptr, "_locale");
@@ -133478,11 +134046,11 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, prepareOptions) {
if (!(zephir_array_isset_string(options, SS("locale")))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter \"locale\" is required", "phalcon/translate/adapter/gettext.zep", 230);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter \"locale\" is required", "phalcon/translate/adapter/gettext.zep", 231);
return;
}
if (!(zephir_array_isset_string(options, SS("directory")))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter \"directory\" is required", "phalcon/translate/adapter/gettext.zep", 234);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter \"directory\" is required", "phalcon/translate/adapter/gettext.zep", 235);
return;
}
ZEPHIR_INIT_VAR(_0);
@@ -133490,17 +134058,17 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, prepareOptions) {
zephir_check_call_status();
zephir_fast_array_merge(_0, &(_1), &(options) TSRMLS_CC);
ZEPHIR_CPY_WRT(options, _0);
- zephir_array_fetch_string(&_2, options, SL("category"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 239 TSRMLS_CC);
- zephir_array_fetch_string(&_3, options, SL("locale"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 239 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, options, SL("category"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 240 TSRMLS_CC);
+ zephir_array_fetch_string(&_3, options, SL("locale"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 240 TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "setlocale", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_array_fetch_string(&_4, options, SL("defaultDomain"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 240 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, options, SL("defaultDomain"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 241 TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "setdefaultdomain", NULL, 0, _4);
zephir_check_call_status();
- zephir_array_fetch_string(&_5, options, SL("directory"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 241 TSRMLS_CC);
+ zephir_array_fetch_string(&_5, options, SL("directory"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 242 TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "setdirectory", NULL, 0, _5);
zephir_check_call_status();
- zephir_array_fetch_string(&_6, options, SL("defaultDomain"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 242 TSRMLS_CC);
+ zephir_array_fetch_string(&_6, options, SL("defaultDomain"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 243 TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "setdomain", NULL, 0, _6);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -133545,6 +134113,8 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter_NativeArray) {
static PHP_METHOD(Phalcon_Translate_Adapter_NativeArray, __construct) {
+ int ZEPHIR_LAST_CALL_STATUS;
+ zephir_fcall_cache_entry *_0 = NULL;
zval *options_param = NULL, *data;
zval *options = NULL;
@@ -133555,13 +134125,15 @@ static PHP_METHOD(Phalcon_Translate_Adapter_NativeArray, __construct) {
+ ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_nativearray_ce, this_ptr, "__construct", &_0, 426, options);
+ zephir_check_call_status();
ZEPHIR_OBS_VAR(data);
if (!(zephir_array_isset_string_fetch(&data, options, SS("content"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Translation content was not provided", "phalcon/translate/adapter/nativearray.zep", 44);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Translation content was not provided", "phalcon/translate/adapter/nativearray.zep", 46);
return;
}
if (Z_TYPE_P(data) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Translation data must be an array", "phalcon/translate/adapter/nativearray.zep", 48);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Translation data must be an array", "phalcon/translate/adapter/nativearray.zep", 50);
return;
}
zephir_update_property_this(this_ptr, SL("_translate"), data TSRMLS_CC);
@@ -133634,6 +134206,147 @@ static PHP_METHOD(Phalcon_Translate_Adapter_NativeArray, exists) {
+#ifdef HAVE_CONFIG_H
+#endif
+
+#include
+
+#include
+#include
+#include
+
+
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_Interpolator_AssociativeArray) {
+
+ ZEPHIR_REGISTER_CLASS(Phalcon\\Translate\\Interpolator, AssociativeArray, phalcon, translate_interpolator_associativearray, phalcon_translate_interpolator_associativearray_method_entry, 0);
+
+ zend_class_implements(phalcon_translate_interpolator_associativearray_ce TSRMLS_CC, 1, phalcon_translate_interpolatorinterface_ce);
+ return SUCCESS;
+
+}
+
+static PHP_METHOD(Phalcon_Translate_Interpolator_AssociativeArray, replacePlaceholders) {
+
+ HashTable *_2;
+ HashPosition _1;
+ zend_bool _0;
+ zval *translation_param = NULL, *placeholders = NULL, *key = NULL, *value = NULL, **_3, *_4 = NULL, *_5 = NULL;
+ zval *translation = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 1, &translation_param, &placeholders);
+
+ if (unlikely(Z_TYPE_P(translation_param) != IS_STRING && Z_TYPE_P(translation_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'translation' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(translation_param) == IS_STRING)) {
+ zephir_get_strval(translation, translation_param);
+ } else {
+ ZEPHIR_INIT_VAR(translation);
+ ZVAL_EMPTY_STRING(translation);
+ }
+ if (!placeholders) {
+ placeholders = ZEPHIR_GLOBAL(global_null);
+ }
+
+
+ _0 = Z_TYPE_P(placeholders) == IS_ARRAY;
+ if (_0) {
+ _0 = (zephir_fast_count_int(placeholders TSRMLS_CC)) ? 1 : 0;
+ }
+ if (_0) {
+ zephir_is_iterable(placeholders, &_2, &_1, 0, 0, "phalcon/translate/interpolator/associativearray.zep", 38);
+ for (
+ ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
+ ; zephir_hash_move_forward_ex(_2, &_1)
+ ) {
+ ZEPHIR_GET_HMKEY(key, _2, _1);
+ ZEPHIR_GET_HVALUE(value, _3);
+ ZEPHIR_INIT_NVAR(_4);
+ ZEPHIR_INIT_LNVAR(_5);
+ ZEPHIR_CONCAT_SVS(_5, "%", key, "%");
+ zephir_fast_str_replace(&_4, _5, value, translation TSRMLS_CC);
+ zephir_get_strval(translation, _4);
+ }
+ }
+ RETURN_CTOR(translation);
+
+}
+
+
+
+
+#ifdef HAVE_CONFIG_H
+#endif
+
+#include
+
+#include
+#include
+#include
+
+
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_Interpolator_IndexedArray) {
+
+ ZEPHIR_REGISTER_CLASS(Phalcon\\Translate\\Interpolator, IndexedArray, phalcon, translate_interpolator_indexedarray, phalcon_translate_interpolator_indexedarray_method_entry, 0);
+
+ zend_class_implements(phalcon_translate_interpolator_indexedarray_ce TSRMLS_CC, 1, phalcon_translate_interpolatorinterface_ce);
+ return SUCCESS;
+
+}
+
+static PHP_METHOD(Phalcon_Translate_Interpolator_IndexedArray, replacePlaceholders) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zend_bool _0;
+ zval *translation_param = NULL, *placeholders = NULL, _1;
+ zval *translation = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 1, &translation_param, &placeholders);
+
+ if (unlikely(Z_TYPE_P(translation_param) != IS_STRING && Z_TYPE_P(translation_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'translation' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(translation_param) == IS_STRING)) {
+ zephir_get_strval(translation, translation_param);
+ } else {
+ ZEPHIR_INIT_VAR(translation);
+ ZVAL_EMPTY_STRING(translation);
+ }
+ if (!placeholders) {
+ placeholders = ZEPHIR_GLOBAL(global_null);
+ }
+
+
+ _0 = Z_TYPE_P(placeholders) == IS_ARRAY;
+ if (_0) {
+ _0 = (zephir_fast_count_int(placeholders TSRMLS_CC)) ? 1 : 0;
+ }
+ if (_0) {
+ Z_SET_ISREF_P(placeholders);
+ ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 386, placeholders, translation);
+ Z_UNSET_ISREF_P(placeholders);
+ zephir_check_call_status();
+ ZEPHIR_SINIT_VAR(_1);
+ ZVAL_STRING(&_1, "sprintf", 0);
+ ZEPHIR_CALL_USER_FUNC_ARRAY(return_value, &_1, placeholders);
+ zephir_check_call_status();
+ RETURN_MM();
+ }
+ RETURN_CTOR(translation);
+
+}
+
+
+
+
#ifdef HAVE_CONFIG_H
#endif
@@ -133839,7 +134552,7 @@ static PHP_METHOD(Phalcon_Validation_Message, __set_state) {
zephir_array_fetch_string(&_0, message, SL("_message"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC);
zephir_array_fetch_string(&_1, message, SL("_field"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC);
zephir_array_fetch_string(&_2, message, SL("_type"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 432, _0, _1, _2);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 436, _0, _1, _2);
zephir_check_call_status();
RETURN_MM();
@@ -133925,7 +134638,7 @@ static PHP_METHOD(Phalcon_Validation_Validator, __construct) {
_0 = Z_TYPE_P(options) != IS_NULL;
}
if (_0) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_validation_exception_ce, "Options must be an array", "phalcon/validation/validator.zep", 39);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_validation_exception_ce, "Options must be an array", "phalcon/validation/validator.zep", 40);
return;
} else {
zephir_update_property_this(this_ptr, SL("_options"), options TSRMLS_CC);
@@ -134453,7 +135166,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alnum, validate) {
if (_2) {
RETURN_MM_BOOL(1);
}
- ZEPHIR_CALL_FUNCTION(&_3, "ctype_alnum", NULL, 433, value);
+ ZEPHIR_CALL_FUNCTION(&_3, "ctype_alnum", NULL, 437, value);
zephir_check_call_status();
if (!(zephir_is_true(_3))) {
ZEPHIR_INIT_NVAR(_1);
@@ -134486,7 +135199,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alnum, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZVAL_STRING(_5, "Alnum", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _4, field, _5);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5);
zephir_check_temp_parameter(_5);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -134556,7 +135269,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alpha, validate) {
if (_2) {
RETURN_MM_BOOL(1);
}
- ZEPHIR_CALL_FUNCTION(&_3, "ctype_alpha", NULL, 434, value);
+ ZEPHIR_CALL_FUNCTION(&_3, "ctype_alpha", NULL, 438, value);
zephir_check_call_status();
if (!(zephir_is_true(_3))) {
ZEPHIR_INIT_NVAR(_1);
@@ -134589,7 +135302,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alpha, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZVAL_STRING(_5, "Alpha", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _4, field, _5);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5);
zephir_check_temp_parameter(_5);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -134706,7 +135419,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Between, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZVAL_STRING(_5, "Between", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 432, _4, field, _5);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _4, field, _5);
zephir_check_temp_parameter(_5);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -134770,7 +135483,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, validate) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&valueWith, validation, "getvalue", NULL, 0, fieldWith);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "compare", NULL, 435, value, valueWith);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "compare", NULL, 439, value, valueWith);
zephir_check_call_status();
if (!(zephir_is_true(_1))) {
ZEPHIR_INIT_NVAR(_0);
@@ -134813,7 +135526,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_3);
ZVAL_STRING(_3, "Confirmation", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 432, _2, field, _3);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _2, field, _3);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -134852,12 +135565,12 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, compare) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_STRING(&_3, "utf-8", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "mb_strtolower", &_5, 193, a, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "mb_strtolower", &_5, 194, a, &_3);
zephir_check_call_status();
zephir_get_strval(a, _4);
ZEPHIR_SINIT_NVAR(_3);
ZVAL_STRING(&_3, "utf-8", 0);
- ZEPHIR_CALL_FUNCTION(&_6, "mb_strtolower", &_5, 193, b, &_3);
+ ZEPHIR_CALL_FUNCTION(&_6, "mb_strtolower", &_5, 194, b, &_3);
zephir_check_call_status();
zephir_get_strval(b, _6);
}
@@ -134924,7 +135637,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Digit, validate) {
if (_2) {
RETURN_MM_BOOL(1);
}
- ZEPHIR_CALL_FUNCTION(&_3, "ctype_digit", NULL, 436, value);
+ ZEPHIR_CALL_FUNCTION(&_3, "ctype_digit", NULL, 440, value);
zephir_check_call_status();
if (!(zephir_is_true(_3))) {
ZEPHIR_INIT_NVAR(_1);
@@ -134957,7 +135670,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Digit, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZVAL_STRING(_5, "Digit", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _4, field, _5);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5);
zephir_check_temp_parameter(_5);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -135029,7 +135742,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Email, validate) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 274);
- ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 190, value, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_1);
@@ -135062,7 +135775,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Email, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_6);
ZVAL_STRING(_6, "Email", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _5, field, _6);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6);
zephir_check_temp_parameter(_6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -135138,7 +135851,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_ExclusionIn, validate) {
zephir_check_temp_parameter(_1);
zephir_check_call_status();
if (Z_TYPE_P(domain) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'domain' must be an array", "phalcon/validation/validator/exclusionin.zep", 59);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'domain' must be an array", "phalcon/validation/validator/exclusionin.zep", 62);
return;
}
if (zephir_fast_in_array(value, domain TSRMLS_CC)) {
@@ -135175,7 +135888,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_ExclusionIn, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_4);
ZVAL_STRING(_4, "ExclusionIn", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _3, field, _4);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _3, field, _4);
zephir_check_temp_parameter(_4);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -135246,7 +135959,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
ZEPHIR_CALL_METHOD(&label, validation, "getlabel", NULL, 0, field);
zephir_check_call_status();
}
- zephir_array_fetch_string(&_1, _SERVER, SL("REQUEST_METHOD"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 61 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, _SERVER, SL("REQUEST_METHOD"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 62 TSRMLS_CC);
_2 = ZEPHIR_IS_STRING(_1, "POST");
if (_2) {
_2 = ZEPHIR_IS_EMPTY(_POST);
@@ -135257,14 +135970,14 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
}
_4 = _3;
if (_4) {
- zephir_array_fetch_string(&_5, _SERVER, SL("CONTENT_LENGTH"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 61 TSRMLS_CC);
+ zephir_array_fetch_string(&_5, _SERVER, SL("CONTENT_LENGTH"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 62 TSRMLS_CC);
_4 = ZEPHIR_GT_LONG(_5, 0);
}
_6 = _4;
if (!(_6)) {
_7 = zephir_array_isset_string(value, SS("error"));
if (_7) {
- zephir_array_fetch_string(&_8, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 61 TSRMLS_CC);
+ zephir_array_fetch_string(&_8, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 62 TSRMLS_CC);
_7 = ZEPHIR_IS_LONG_IDENTICAL(_8, 1);
}
_6 = _7;
@@ -135291,7 +136004,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_11);
ZVAL_STRING(_11, "FileIniSize", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_12, 432, _9, field, _11);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_12, 436, _9, field, _11);
zephir_check_temp_parameter(_11);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -135309,7 +136022,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
if (!(_14)) {
_15 = zephir_array_isset_string(value, SS("error"));
if (_15) {
- zephir_array_fetch_string(&_16, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 73 TSRMLS_CC);
+ zephir_array_fetch_string(&_16, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 75 TSRMLS_CC);
_15 = ZEPHIR_IS_LONG_IDENTICAL(_16, 4);
}
_14 = _15;
@@ -135325,13 +136038,13 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
}
_18 = _17;
if (!(_18)) {
- zephir_array_fetch_string(&_19, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 77 TSRMLS_CC);
+ zephir_array_fetch_string(&_19, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 79 TSRMLS_CC);
_18 = !ZEPHIR_IS_LONG_IDENTICAL(_19, 0);
}
_20 = _18;
if (!(_20)) {
- zephir_array_fetch_string(&_21, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 77 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_9, "is_uploaded_file", NULL, 231, _21);
+ zephir_array_fetch_string(&_21, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 79 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&_9, "is_uploaded_file", NULL, 232, _21);
zephir_check_call_status();
_20 = !zephir_is_true(_9);
}
@@ -135357,7 +136070,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_23);
ZVAL_STRING(_23, "FileEmpty", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 432, _22, field, _23);
+ ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _22, field, _23);
zephir_check_temp_parameter(_23);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11);
@@ -135394,7 +136107,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_23);
ZVAL_STRING(_23, "FileValid", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 432, _9, field, _23);
+ ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _9, field, _23);
zephir_check_temp_parameter(_23);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11);
@@ -135437,22 +136150,22 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_preg_match(_11, _27, maxSize, matches, 0, 0 , 0 TSRMLS_CC);
if (zephir_array_isset_long(matches, 2)) {
ZEPHIR_OBS_NVAR(unit);
- zephir_array_fetch_long(&unit, matches, 2, PH_NOISY, "phalcon/validation/validator/file.zep", 110 TSRMLS_CC);
+ zephir_array_fetch_long(&unit, matches, 2, PH_NOISY, "phalcon/validation/validator/file.zep", 115 TSRMLS_CC);
}
- zephir_array_fetch_long(&_28, matches, 1, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 113 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 310, _28);
+ zephir_array_fetch_long(&_28, matches, 1, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 118 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 311, _28);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_30);
- zephir_array_fetch(&_31, byteUnits, unit, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 113 TSRMLS_CC);
+ zephir_array_fetch(&_31, byteUnits, unit, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 118 TSRMLS_CC);
ZEPHIR_SINIT_VAR(_32);
ZVAL_LONG(&_32, 2);
zephir_pow_function(_30, &_32, _31);
ZEPHIR_INIT_VAR(bytes);
mul_function(bytes, _22, _30 TSRMLS_CC);
- zephir_array_fetch_string(&_33, value, SL("size"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 115 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 310, _33);
+ zephir_array_fetch_string(&_33, value, SL("size"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 120 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 311, _33);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_34, "floatval", &_29, 310, bytes);
+ ZEPHIR_CALL_FUNCTION(&_34, "floatval", &_29, 311, bytes);
zephir_check_call_status();
if (ZEPHIR_GT(_22, _34)) {
ZEPHIR_INIT_NVAR(_30);
@@ -135477,7 +136190,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_36);
ZVAL_STRING(_36, "FileSize", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _30, "__construct", &_12, 432, _35, field, _36);
+ ZEPHIR_CALL_METHOD(NULL, _30, "__construct", &_12, 436, _35, field, _36);
zephir_check_temp_parameter(_36);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _30);
@@ -135497,22 +136210,22 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_temp_parameter(_11);
zephir_check_call_status();
if (Z_TYPE_P(types) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'allowedTypes' must be an array", "phalcon/validation/validator/file.zep", 132);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'allowedTypes' must be an array", "phalcon/validation/validator/file.zep", 138);
return;
}
if ((zephir_function_exists_ex(SS("finfo_open") TSRMLS_CC) == SUCCESS)) {
ZEPHIR_SINIT_NVAR(_32);
ZVAL_LONG(&_32, 16);
- ZEPHIR_CALL_FUNCTION(&tmp, "finfo_open", NULL, 228, &_32);
+ ZEPHIR_CALL_FUNCTION(&tmp, "finfo_open", NULL, 229, &_32);
zephir_check_call_status();
- zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 137 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 229, tmp, _28);
+ zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 143 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 230, tmp, _28);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 230, tmp);
+ ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 231, tmp);
zephir_check_call_status();
} else {
ZEPHIR_OBS_NVAR(mime);
- zephir_array_fetch_string(&mime, value, SL("type"), PH_NOISY, "phalcon/validation/validator/file.zep", 141 TSRMLS_CC);
+ zephir_array_fetch_string(&mime, value, SL("type"), PH_NOISY, "phalcon/validation/validator/file.zep", 147 TSRMLS_CC);
}
if (!(zephir_fast_in_array(mime, types TSRMLS_CC))) {
ZEPHIR_INIT_NVAR(_11);
@@ -135539,7 +136252,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_23);
ZVAL_STRING(_23, "FileType", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 432, _22, field, _23);
+ ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _22, field, _23);
zephir_check_temp_parameter(_23);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11);
@@ -135562,13 +136275,13 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
_37 = zephir_is_true(_22);
}
if (_37) {
- zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 158 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&tmp, "getimagesize", NULL, 248, _28);
+ zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 164 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&tmp, "getimagesize", NULL, 249, _28);
zephir_check_call_status();
ZEPHIR_OBS_VAR(width);
- zephir_array_fetch_long(&width, tmp, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 159 TSRMLS_CC);
+ zephir_array_fetch_long(&width, tmp, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 165 TSRMLS_CC);
ZEPHIR_OBS_VAR(height);
- zephir_array_fetch_long(&height, tmp, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 160 TSRMLS_CC);
+ zephir_array_fetch_long(&height, tmp, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 166 TSRMLS_CC);
ZEPHIR_INIT_NVAR(_11);
ZVAL_STRING(_11, "minResolution", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_CALL_METHOD(&_34, this_ptr, "issetoption", NULL, 0, _11);
@@ -135583,9 +136296,9 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
ZEPHIR_INIT_VAR(minResolution);
zephir_fast_explode_str(minResolution, SL("x"), _35, LONG_MAX TSRMLS_CC);
ZEPHIR_OBS_VAR(minWidth);
- zephir_array_fetch_long(&minWidth, minResolution, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 164 TSRMLS_CC);
+ zephir_array_fetch_long(&minWidth, minResolution, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 170 TSRMLS_CC);
ZEPHIR_OBS_VAR(minHeight);
- zephir_array_fetch_long(&minHeight, minResolution, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 165 TSRMLS_CC);
+ zephir_array_fetch_long(&minHeight, minResolution, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 171 TSRMLS_CC);
} else {
ZEPHIR_INIT_NVAR(minWidth);
ZVAL_LONG(minWidth, 1);
@@ -135624,7 +136337,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_23);
ZVAL_STRING(_23, "FileMinResolution", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 432, _35, field, _23);
+ ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _35, field, _23);
zephir_check_temp_parameter(_23);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11);
@@ -135645,9 +136358,9 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
ZEPHIR_INIT_VAR(maxResolution);
zephir_fast_explode_str(maxResolution, SL("x"), _39, LONG_MAX TSRMLS_CC);
ZEPHIR_OBS_VAR(maxWidth);
- zephir_array_fetch_long(&maxWidth, maxResolution, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 186 TSRMLS_CC);
+ zephir_array_fetch_long(&maxWidth, maxResolution, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 192 TSRMLS_CC);
ZEPHIR_OBS_VAR(maxHeight);
- zephir_array_fetch_long(&maxHeight, maxResolution, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 187 TSRMLS_CC);
+ zephir_array_fetch_long(&maxHeight, maxResolution, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 193 TSRMLS_CC);
_40 = ZEPHIR_GT(width, maxWidth);
if (!(_40)) {
_40 = ZEPHIR_GT(height, maxHeight);
@@ -135680,7 +136393,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_26);
ZVAL_STRING(_26, "FileMaxResolution", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _23, "__construct", &_12, 432, _41, field, _26);
+ ZEPHIR_CALL_METHOD(NULL, _23, "__construct", &_12, 436, _41, field, _26);
zephir_check_temp_parameter(_26);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _23);
@@ -135718,8 +136431,9 @@ ZEPHIR_INIT_CLASS(Phalcon_Validation_Validator_Identical) {
static PHP_METHOD(Phalcon_Validation_Validator_Identical, validate) {
int ZEPHIR_LAST_CALL_STATUS;
+ zend_bool valid;
zval *field = NULL;
- zval *validation, *field_param = NULL, *message = NULL, *label = NULL, *replacePairs, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4;
+ zval *validation, *field_param = NULL, *message = NULL, *label = NULL, *replacePairs, *value = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 0, &validation, &field_param);
@@ -135737,48 +136451,70 @@ static PHP_METHOD(Phalcon_Validation_Validator_Identical, validate) {
}
- ZEPHIR_CALL_METHOD(&_0, validation, "getvalue", NULL, 0, field);
+ ZEPHIR_CALL_METHOD(&value, validation, "getvalue", NULL, 0, field);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_2);
- ZVAL_STRING(_2, "accepted", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "getoption", NULL, 0, _2);
- zephir_check_temp_parameter(_2);
+ ZEPHIR_INIT_VAR(_1);
+ ZVAL_STRING(_1, "accepted", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "hasoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
zephir_check_call_status();
- if (!ZEPHIR_IS_EQUAL(_0, _1)) {
- ZEPHIR_INIT_NVAR(_2);
- ZVAL_STRING(_2, "label", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&label, this_ptr, "getoption", NULL, 0, _2);
- zephir_check_temp_parameter(_2);
+ if (zephir_is_true(_0)) {
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "accepted", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&_2, this_ptr, "getoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
+ zephir_check_call_status();
+ valid = ZEPHIR_IS_EQUAL(value, _2);
+ } else {
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "value", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&_2, this_ptr, "hasoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
+ zephir_check_call_status();
+ if (zephir_is_true(_2)) {
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "value", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "getoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
+ zephir_check_call_status();
+ valid = ZEPHIR_IS_EQUAL(value, _3);
+ }
+ }
+ if (!(valid)) {
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "label", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&label, this_ptr, "getoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
zephir_check_call_status();
if (ZEPHIR_IS_EMPTY(label)) {
ZEPHIR_CALL_METHOD(&label, validation, "getlabel", NULL, 0, field);
zephir_check_call_status();
}
- ZEPHIR_INIT_NVAR(_2);
- ZVAL_STRING(_2, "message", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&message, this_ptr, "getoption", NULL, 0, _2);
- zephir_check_temp_parameter(_2);
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "message", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&message, this_ptr, "getoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
zephir_check_call_status();
ZEPHIR_INIT_VAR(replacePairs);
zephir_create_array(replacePairs, 1, 0 TSRMLS_CC);
zephir_array_update_string(&replacePairs, SL(":field"), &label, PH_COPY | PH_SEPARATE);
if (ZEPHIR_IS_EMPTY(message)) {
- ZEPHIR_INIT_NVAR(_2);
- ZVAL_STRING(_2, "Identical", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&message, validation, "getdefaultmessage", NULL, 0, _2);
- zephir_check_temp_parameter(_2);
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "Identical", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&message, validation, "getdefaultmessage", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
zephir_check_call_status();
}
- ZEPHIR_INIT_NVAR(_2);
- object_init_ex(_2, phalcon_validation_message_ce);
- ZEPHIR_CALL_FUNCTION(&_3, "strtr", NULL, 53, message, replacePairs);
+ ZEPHIR_INIT_NVAR(_1);
+ object_init_ex(_1, phalcon_validation_message_ce);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, message, replacePairs);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_4);
ZVAL_STRING(_4, "Identical", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 432, _3, field, _4);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _2, field, _4);
zephir_check_temp_parameter(_4);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _2);
+ ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
zephir_check_call_status();
RETURN_MM_BOOL(0);
}
@@ -135851,7 +136587,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) {
zephir_check_temp_parameter(_1);
zephir_check_call_status();
if (Z_TYPE_P(domain) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'domain' must be an array", "phalcon/validation/validator/inclusionin.zep", 61);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'domain' must be an array", "phalcon/validation/validator/inclusionin.zep", 62);
return;
}
ZEPHIR_INIT_VAR(strict);
@@ -135863,7 +136599,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) {
zephir_check_call_status();
if (zephir_is_true(_3)) {
if (Z_TYPE_P(strict) != IS_BOOL) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'strict' must be a boolean", "phalcon/validation/validator/inclusionin.zep", 67);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'strict' must be a boolean", "phalcon/validation/validator/inclusionin.zep", 68);
return;
}
ZEPHIR_INIT_NVAR(_1);
@@ -135872,7 +136608,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) {
zephir_check_temp_parameter(_1);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_4, "in_array", NULL, 363, value, domain, strict);
+ ZEPHIR_CALL_FUNCTION(&_4, "in_array", NULL, 365, value, domain, strict);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_1);
@@ -135908,7 +136644,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_6);
ZVAL_STRING(_6, "InclusionIn", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _5, field, _6);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6);
zephir_check_temp_parameter(_6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -136014,7 +136750,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Numericality, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_7);
ZVAL_STRING(_7, "Numericality", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 432, _6, field, _7);
+ ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 436, _6, field, _7);
zephir_check_temp_parameter(_7);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _5);
@@ -136107,7 +136843,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_PresenceOf, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_3);
ZVAL_STRING(_3, "PresenceOf", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _2, field, _3);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _2, field, _3);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -136223,7 +136959,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Regex, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_7);
ZVAL_STRING(_7, "Regex", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 432, _6, field, _7);
+ ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 436, _6, field, _7);
zephir_check_temp_parameter(_7);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _4);
@@ -136322,7 +137058,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) {
zephir_check_call_status();
}
if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 364, value);
+ ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, value);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(length);
@@ -136357,7 +137093,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_6);
ZVAL_STRING(_6, "TooLong", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_7, 432, _4, field, _6);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_7, 436, _4, field, _6);
zephir_check_temp_parameter(_6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -136394,7 +137130,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_8);
ZVAL_STRING(_8, "TooShort", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_7, 432, _4, field, _8);
+ ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_7, 436, _4, field, _8);
zephir_check_temp_parameter(_8);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _6);
@@ -136480,7 +137216,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Uniqueness, validate) {
ZEPHIR_INIT_VAR(_1);
zephir_create_array(_1, 2, 0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_2);
- ZEPHIR_CONCAT_VSVS(_2, attribute, "=:value: AND ", attribute, "!= :except:");
+ ZEPHIR_CONCAT_VSVS(_2, attribute, " = :value: AND ", attribute, " != :except:");
zephir_array_fast_append(_1, _2);
ZEPHIR_INIT_VAR(_3);
zephir_create_array(_3, 2, 0 TSRMLS_CC);
@@ -136494,7 +137230,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Uniqueness, validate) {
ZEPHIR_INIT_NVAR(_1);
zephir_create_array(_1, 2, 0 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_2);
- ZEPHIR_CONCAT_VS(_2, attribute, "=:value:");
+ ZEPHIR_CONCAT_VS(_2, attribute, " = :value:");
zephir_array_fast_append(_1, _2);
ZEPHIR_INIT_NVAR(_3);
zephir_create_array(_3, 1, 0 TSRMLS_CC);
@@ -136535,7 +137271,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Uniqueness, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_7);
ZVAL_STRING(_7, "Uniqueness", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 432, _6, field, _7);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _6, field, _7);
zephir_check_temp_parameter(_7);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -136607,7 +137343,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Url, validate) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 273);
- ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 190, value, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_1);
@@ -136640,7 +137376,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Url, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_6);
ZVAL_STRING(_6, "Url", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _5, field, _6);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6);
zephir_check_temp_parameter(_6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -136680,8 +137416,8 @@ zend_class_entry *phalcon_forms_elementinterface_ce;
zend_class_entry *phalcon_validation_validatorinterface_ce;
zend_class_entry *phalcon_mvc_model_validatorinterface_ce;
zend_class_entry *phalcon_cache_backendinterface_ce;
-zend_class_entry *phalcon_cache_frontendinterface_ce;
zend_class_entry *phalcon_mvc_model_metadatainterface_ce;
+zend_class_entry *phalcon_cache_frontendinterface_ce;
zend_class_entry *phalcon_db_dialectinterface_ce;
zend_class_entry *phalcon_dispatcherinterface_ce;
zend_class_entry *phalcon_annotations_adapterinterface_ce;
@@ -136690,11 +137426,11 @@ zend_class_entry *phalcon_logger_adapterinterface_ce;
zend_class_entry *phalcon_logger_formatterinterface_ce;
zend_class_entry *phalcon_mvc_entityinterface_ce;
zend_class_entry *phalcon_mvc_model_resultsetinterface_ce;
+zend_class_entry *phalcon_session_adapterinterface_ce;
zend_class_entry *phalcon_assets_filterinterface_ce;
zend_class_entry *phalcon_diinterface_ce;
zend_class_entry *phalcon_mvc_viewbaseinterface_ce;
zend_class_entry *phalcon_paginator_adapterinterface_ce;
-zend_class_entry *phalcon_session_adapterinterface_ce;
zend_class_entry *phalcon_translate_adapterinterface_ce;
zend_class_entry *phalcon_acl_adapterinterface_ce;
zend_class_entry *phalcon_flashinterface_ce;
@@ -136705,6 +137441,7 @@ zend_class_entry *phalcon_mvc_model_metadata_strategyinterface_ce;
zend_class_entry *phalcon_mvc_model_resultinterface_ce;
zend_class_entry *phalcon_mvc_routerinterface_ce;
zend_class_entry *phalcon_mvc_view_engineinterface_ce;
+zend_class_entry *phalcon_translate_interpolatorinterface_ce;
zend_class_entry *phalcon_acl_roleinterface_ce;
zend_class_entry *phalcon_annotations_readerinterface_ce;
zend_class_entry *phalcon_cryptinterface_ce;
@@ -136760,9 +137497,9 @@ zend_class_entry *phalcon_db_adapter_pdo_ce;
zend_class_entry *phalcon_db_dialect_ce;
zend_class_entry *phalcon_logger_adapter_ce;
zend_class_entry *phalcon_logger_formatter_ce;
+zend_class_entry *phalcon_session_adapter_ce;
zend_class_entry *phalcon_mvc_model_exception_ce;
zend_class_entry *phalcon_paginator_adapter_ce;
-zend_class_entry *phalcon_session_adapter_ce;
zend_class_entry *phalcon_translate_adapter_ce;
zend_class_entry *phalcon_assets_inline_ce;
zend_class_entry *phalcon_assets_resource_ce;
@@ -136937,6 +137674,7 @@ zend_class_entry *phalcon_mvc_model_metadata_files_ce;
zend_class_entry *phalcon_mvc_model_metadata_libmemcached_ce;
zend_class_entry *phalcon_mvc_model_metadata_memcache_ce;
zend_class_entry *phalcon_mvc_model_metadata_memory_ce;
+zend_class_entry *phalcon_mvc_model_metadata_redis_ce;
zend_class_entry *phalcon_mvc_model_metadata_session_ce;
zend_class_entry *phalcon_mvc_model_metadata_strategy_annotations_ce;
zend_class_entry *phalcon_mvc_model_metadata_strategy_introspection_ce;
@@ -136990,6 +137728,7 @@ zend_class_entry *phalcon_security_exception_ce;
zend_class_entry *phalcon_session_adapter_files_ce;
zend_class_entry *phalcon_session_adapter_libmemcached_ce;
zend_class_entry *phalcon_session_adapter_memcache_ce;
+zend_class_entry *phalcon_session_adapter_redis_ce;
zend_class_entry *phalcon_session_bag_ce;
zend_class_entry *phalcon_session_ce;
zend_class_entry *phalcon_session_exception_ce;
@@ -137002,6 +137741,8 @@ zend_class_entry *phalcon_translate_adapter_gettext_ce;
zend_class_entry *phalcon_translate_adapter_nativearray_ce;
zend_class_entry *phalcon_translate_ce;
zend_class_entry *phalcon_translate_exception_ce;
+zend_class_entry *phalcon_translate_interpolator_associativearray_ce;
+zend_class_entry *phalcon_translate_interpolator_indexedarray_ce;
zend_class_entry *phalcon_validation_ce;
zend_class_entry *phalcon_validation_exception_ce;
zend_class_entry *phalcon_validation_message_ce;
@@ -137068,8 +137809,8 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Validation_ValidatorInterface);
ZEPHIR_INIT(Phalcon_Mvc_Model_ValidatorInterface);
ZEPHIR_INIT(Phalcon_Cache_BackendInterface);
- ZEPHIR_INIT(Phalcon_Cache_FrontendInterface);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaDataInterface);
+ ZEPHIR_INIT(Phalcon_Cache_FrontendInterface);
ZEPHIR_INIT(Phalcon_Db_DialectInterface);
ZEPHIR_INIT(Phalcon_DispatcherInterface);
ZEPHIR_INIT(Phalcon_Annotations_AdapterInterface);
@@ -137078,11 +137819,11 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Logger_FormatterInterface);
ZEPHIR_INIT(Phalcon_Mvc_EntityInterface);
ZEPHIR_INIT(Phalcon_Mvc_Model_ResultsetInterface);
+ ZEPHIR_INIT(Phalcon_Session_AdapterInterface);
ZEPHIR_INIT(Phalcon_Assets_FilterInterface);
ZEPHIR_INIT(Phalcon_DiInterface);
ZEPHIR_INIT(Phalcon_Mvc_ViewBaseInterface);
ZEPHIR_INIT(Phalcon_Paginator_AdapterInterface);
- ZEPHIR_INIT(Phalcon_Session_AdapterInterface);
ZEPHIR_INIT(Phalcon_Translate_AdapterInterface);
ZEPHIR_INIT(Phalcon_Acl_AdapterInterface);
ZEPHIR_INIT(Phalcon_FlashInterface);
@@ -137093,6 +137834,7 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Mvc_Model_ResultInterface);
ZEPHIR_INIT(Phalcon_Mvc_RouterInterface);
ZEPHIR_INIT(Phalcon_Mvc_View_EngineInterface);
+ ZEPHIR_INIT(Phalcon_Translate_InterpolatorInterface);
ZEPHIR_INIT(Phalcon_Acl_RoleInterface);
ZEPHIR_INIT(Phalcon_Annotations_ReaderInterface);
ZEPHIR_INIT(Phalcon_CryptInterface);
@@ -137148,9 +137890,9 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Db_Dialect);
ZEPHIR_INIT(Phalcon_Logger_Adapter);
ZEPHIR_INIT(Phalcon_Logger_Formatter);
+ ZEPHIR_INIT(Phalcon_Session_Adapter);
ZEPHIR_INIT(Phalcon_Mvc_Model_Exception);
ZEPHIR_INIT(Phalcon_Paginator_Adapter);
- ZEPHIR_INIT(Phalcon_Session_Adapter);
ZEPHIR_INIT(Phalcon_Translate_Adapter);
ZEPHIR_INIT(Phalcon_Assets_Inline);
ZEPHIR_INIT(Phalcon_Assets_Resource);
@@ -137324,6 +138066,7 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Libmemcached);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Memcache);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Memory);
+ ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Redis);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Session);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Strategy_Annotations);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Strategy_Introspection);
@@ -137378,6 +138121,7 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Session_Adapter_Files);
ZEPHIR_INIT(Phalcon_Session_Adapter_Libmemcached);
ZEPHIR_INIT(Phalcon_Session_Adapter_Memcache);
+ ZEPHIR_INIT(Phalcon_Session_Adapter_Redis);
ZEPHIR_INIT(Phalcon_Session_Bag);
ZEPHIR_INIT(Phalcon_Session_Exception);
ZEPHIR_INIT(Phalcon_Tag);
@@ -137389,6 +138133,8 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Translate_Adapter_Gettext);
ZEPHIR_INIT(Phalcon_Translate_Adapter_NativeArray);
ZEPHIR_INIT(Phalcon_Translate_Exception);
+ ZEPHIR_INIT(Phalcon_Translate_Interpolator_AssociativeArray);
+ ZEPHIR_INIT(Phalcon_Translate_Interpolator_IndexedArray);
ZEPHIR_INIT(Phalcon_Validation);
ZEPHIR_INIT(Phalcon_Validation_Exception);
ZEPHIR_INIT(Phalcon_Validation_Message);
diff --git a/build/64bits/phalcon.zep.h b/build/64bits/phalcon.zep.h
index 984ec057a1c..877bafc5931 100644
--- a/build/64bits/phalcon.zep.h
+++ b/build/64bits/phalcon.zep.h
@@ -593,29 +593,6 @@ ZEPHIR_INIT_FUNCS(phalcon_cache_backendinterface_method_entry) {
PHP_FE_END
};
-zend_class_entry *phalcon_cache_frontendinterface_ce;
-
-ZEPHIR_INIT_CLASS(Phalcon_Cache_FrontendInterface);
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_cache_frontendinterface_beforestore, 0, 0, 1)
- ZEND_ARG_INFO(0, data)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_cache_frontendinterface_afterretrieve, 0, 0, 1)
- ZEND_ARG_INFO(0, data)
-ZEND_END_ARG_INFO()
-
-ZEPHIR_INIT_FUNCS(phalcon_cache_frontendinterface_method_entry) {
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, getLifetime, NULL)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, isBuffering, NULL)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, start, NULL)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, getContent, NULL)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, stop, NULL)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, beforeStore, arginfo_phalcon_cache_frontendinterface_beforestore)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, afterRetrieve, arginfo_phalcon_cache_frontendinterface_afterretrieve)
- PHP_FE_END
-};
-
zend_class_entry *phalcon_mvc_model_metadata_ce;
ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_MetaData);
@@ -950,6 +927,29 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_model_metadatainterface_method_entry) {
PHP_FE_END
};
+zend_class_entry *phalcon_cache_frontendinterface_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Cache_FrontendInterface);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_cache_frontendinterface_beforestore, 0, 0, 1)
+ ZEND_ARG_INFO(0, data)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_cache_frontendinterface_afterretrieve, 0, 0, 1)
+ ZEND_ARG_INFO(0, data)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_cache_frontendinterface_method_entry) {
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, getLifetime, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, isBuffering, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, start, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, getContent, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, stop, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, beforeStore, arginfo_phalcon_cache_frontendinterface_beforestore)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, afterRetrieve, arginfo_phalcon_cache_frontendinterface_afterretrieve)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_db_adapter_ce;
ZEPHIR_INIT_CLASS(Phalcon_Db_Adapter);
@@ -2617,6 +2617,145 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_model_resultsetinterface_method_entry) {
PHP_FE_END
};
+zend_class_entry *phalcon_session_adapter_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Session_Adapter);
+
+static PHP_METHOD(Phalcon_Session_Adapter, __construct);
+static PHP_METHOD(Phalcon_Session_Adapter, start);
+static PHP_METHOD(Phalcon_Session_Adapter, setOptions);
+static PHP_METHOD(Phalcon_Session_Adapter, getOptions);
+static PHP_METHOD(Phalcon_Session_Adapter, setName);
+static PHP_METHOD(Phalcon_Session_Adapter, getName);
+static PHP_METHOD(Phalcon_Session_Adapter, get);
+static PHP_METHOD(Phalcon_Session_Adapter, set);
+static PHP_METHOD(Phalcon_Session_Adapter, has);
+static PHP_METHOD(Phalcon_Session_Adapter, remove);
+static PHP_METHOD(Phalcon_Session_Adapter, getId);
+static PHP_METHOD(Phalcon_Session_Adapter, setId);
+static PHP_METHOD(Phalcon_Session_Adapter, isStarted);
+static PHP_METHOD(Phalcon_Session_Adapter, destroy);
+static PHP_METHOD(Phalcon_Session_Adapter, status);
+static PHP_METHOD(Phalcon_Session_Adapter, __get);
+static PHP_METHOD(Phalcon_Session_Adapter, __set);
+static PHP_METHOD(Phalcon_Session_Adapter, __isset);
+static PHP_METHOD(Phalcon_Session_Adapter, __unset);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___construct, 0, 0, 0)
+ ZEND_ARG_INFO(0, options)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setoptions, 0, 0, 1)
+ ZEND_ARG_ARRAY_INFO(0, options, 0)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setname, 0, 0, 1)
+ ZEND_ARG_INFO(0, name)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_get, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ ZEND_ARG_INFO(0, defaultValue)
+ ZEND_ARG_INFO(0, remove)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_set, 0, 0, 2)
+ ZEND_ARG_INFO(0, index)
+ ZEND_ARG_INFO(0, value)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_has, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_remove, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setid, 0, 0, 1)
+ ZEND_ARG_INFO(0, id)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___get, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___set, 0, 0, 2)
+ ZEND_ARG_INFO(0, index)
+ ZEND_ARG_INFO(0, value)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___isset, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___unset, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_session_adapter_method_entry) {
+ PHP_ME(Phalcon_Session_Adapter, __construct, arginfo_phalcon_session_adapter___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Session_Adapter, start, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, setOptions, arginfo_phalcon_session_adapter_setoptions, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, getOptions, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, setName, arginfo_phalcon_session_adapter_setname, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, getName, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, get, arginfo_phalcon_session_adapter_get, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, set, arginfo_phalcon_session_adapter_set, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, has, arginfo_phalcon_session_adapter_has, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, remove, arginfo_phalcon_session_adapter_remove, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, getId, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, setId, arginfo_phalcon_session_adapter_setid, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, isStarted, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, destroy, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, status, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, __get, arginfo_phalcon_session_adapter___get, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, __set, arginfo_phalcon_session_adapter___set, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, __isset, arginfo_phalcon_session_adapter___isset, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, __unset, arginfo_phalcon_session_adapter___unset, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
+
+zend_class_entry *phalcon_session_adapterinterface_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Session_AdapterInterface);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_setoptions, 0, 0, 1)
+ ZEND_ARG_ARRAY_INFO(0, options, 0)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_get, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ ZEND_ARG_INFO(0, defaultValue)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_set, 0, 0, 2)
+ ZEND_ARG_INFO(0, index)
+ ZEND_ARG_INFO(0, value)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_has, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_remove, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_session_adapterinterface_method_entry) {
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, start, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, setOptions, arginfo_phalcon_session_adapterinterface_setoptions)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, getOptions, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, get, arginfo_phalcon_session_adapterinterface_get)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, set, arginfo_phalcon_session_adapterinterface_set)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, has, arginfo_phalcon_session_adapterinterface_has)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, remove, arginfo_phalcon_session_adapterinterface_remove)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, getId, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, isStarted, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, destroy, NULL)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_assets_filterinterface_ce;
ZEPHIR_INIT_CLASS(Phalcon_Assets_FilterInterface);
@@ -2803,149 +2942,12 @@ ZEPHIR_INIT_FUNCS(phalcon_paginator_adapterinterface_method_entry) {
PHP_FE_END
};
-zend_class_entry *phalcon_session_adapter_ce;
-
-ZEPHIR_INIT_CLASS(Phalcon_Session_Adapter);
-
-static PHP_METHOD(Phalcon_Session_Adapter, __construct);
-static PHP_METHOD(Phalcon_Session_Adapter, start);
-static PHP_METHOD(Phalcon_Session_Adapter, setOptions);
-static PHP_METHOD(Phalcon_Session_Adapter, getOptions);
-static PHP_METHOD(Phalcon_Session_Adapter, setName);
-static PHP_METHOD(Phalcon_Session_Adapter, getName);
-static PHP_METHOD(Phalcon_Session_Adapter, get);
-static PHP_METHOD(Phalcon_Session_Adapter, set);
-static PHP_METHOD(Phalcon_Session_Adapter, has);
-static PHP_METHOD(Phalcon_Session_Adapter, remove);
-static PHP_METHOD(Phalcon_Session_Adapter, getId);
-static PHP_METHOD(Phalcon_Session_Adapter, setId);
-static PHP_METHOD(Phalcon_Session_Adapter, isStarted);
-static PHP_METHOD(Phalcon_Session_Adapter, destroy);
-static PHP_METHOD(Phalcon_Session_Adapter, status);
-static PHP_METHOD(Phalcon_Session_Adapter, __get);
-static PHP_METHOD(Phalcon_Session_Adapter, __set);
-static PHP_METHOD(Phalcon_Session_Adapter, __isset);
-static PHP_METHOD(Phalcon_Session_Adapter, __unset);
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___construct, 0, 0, 0)
- ZEND_ARG_INFO(0, options)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setoptions, 0, 0, 1)
- ZEND_ARG_ARRAY_INFO(0, options, 0)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setname, 0, 0, 1)
- ZEND_ARG_INFO(0, name)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_get, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
- ZEND_ARG_INFO(0, defaultValue)
- ZEND_ARG_INFO(0, remove)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_set, 0, 0, 2)
- ZEND_ARG_INFO(0, index)
- ZEND_ARG_INFO(0, value)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_has, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_remove, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setid, 0, 0, 1)
- ZEND_ARG_INFO(0, id)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___get, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___set, 0, 0, 2)
- ZEND_ARG_INFO(0, index)
- ZEND_ARG_INFO(0, value)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___isset, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___unset, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEPHIR_INIT_FUNCS(phalcon_session_adapter_method_entry) {
- PHP_ME(Phalcon_Session_Adapter, __construct, arginfo_phalcon_session_adapter___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
- PHP_ME(Phalcon_Session_Adapter, start, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, setOptions, arginfo_phalcon_session_adapter_setoptions, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, getOptions, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, setName, arginfo_phalcon_session_adapter_setname, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, getName, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, get, arginfo_phalcon_session_adapter_get, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, set, arginfo_phalcon_session_adapter_set, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, has, arginfo_phalcon_session_adapter_has, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, remove, arginfo_phalcon_session_adapter_remove, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, getId, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, setId, arginfo_phalcon_session_adapter_setid, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, isStarted, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, destroy, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, status, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, __get, arginfo_phalcon_session_adapter___get, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, __set, arginfo_phalcon_session_adapter___set, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, __isset, arginfo_phalcon_session_adapter___isset, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, __unset, arginfo_phalcon_session_adapter___unset, ZEND_ACC_PUBLIC)
- PHP_FE_END
-};
-
-zend_class_entry *phalcon_session_adapterinterface_ce;
-
-ZEPHIR_INIT_CLASS(Phalcon_Session_AdapterInterface);
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_setoptions, 0, 0, 1)
- ZEND_ARG_ARRAY_INFO(0, options, 0)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_get, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
- ZEND_ARG_INFO(0, defaultValue)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_set, 0, 0, 2)
- ZEND_ARG_INFO(0, index)
- ZEND_ARG_INFO(0, value)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_has, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_remove, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEPHIR_INIT_FUNCS(phalcon_session_adapterinterface_method_entry) {
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, start, NULL)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, setOptions, arginfo_phalcon_session_adapterinterface_setoptions)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, getOptions, NULL)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, get, arginfo_phalcon_session_adapterinterface_get)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, set, arginfo_phalcon_session_adapterinterface_set)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, has, arginfo_phalcon_session_adapterinterface_has)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, remove, arginfo_phalcon_session_adapterinterface_remove)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, getId, NULL)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, isStarted, NULL)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, destroy, NULL)
- PHP_FE_END
-};
-
zend_class_entry *phalcon_translate_adapter_ce;
ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter);
+static PHP_METHOD(Phalcon_Translate_Adapter, __construct);
+static PHP_METHOD(Phalcon_Translate_Adapter, setInterpolator);
static PHP_METHOD(Phalcon_Translate_Adapter, t);
static PHP_METHOD(Phalcon_Translate_Adapter, _);
static PHP_METHOD(Phalcon_Translate_Adapter, offsetSet);
@@ -2954,6 +2956,14 @@ static PHP_METHOD(Phalcon_Translate_Adapter, offsetUnset);
static PHP_METHOD(Phalcon_Translate_Adapter, offsetGet);
static PHP_METHOD(Phalcon_Translate_Adapter, replacePlaceholders);
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter___construct, 0, 0, 1)
+ ZEND_ARG_ARRAY_INFO(0, options, 0)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_setinterpolator, 0, 0, 1)
+ ZEND_ARG_OBJ_INFO(0, interpolator, Phalcon\\Translate\\InterpolatorInterface, 0)
+ZEND_END_ARG_INFO()
+
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_t, 0, 0, 1)
ZEND_ARG_INFO(0, translateKey)
ZEND_ARG_INFO(0, placeholders)
@@ -2987,6 +2997,8 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_replaceplaceholders, 0,
ZEND_END_ARG_INFO()
ZEPHIR_INIT_FUNCS(phalcon_translate_adapter_method_entry) {
+ PHP_ME(Phalcon_Translate_Adapter, __construct, arginfo_phalcon_translate_adapter___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Translate_Adapter, setInterpolator, arginfo_phalcon_translate_adapter_setinterpolator, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Translate_Adapter, t, arginfo_phalcon_translate_adapter_t, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Translate_Adapter, _, arginfo_phalcon_translate_adapter__, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Translate_Adapter, offsetSet, arginfo_phalcon_translate_adapter_offsetset, ZEND_ACC_PUBLIC)
@@ -4259,6 +4271,20 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_view_engineinterface_method_entry) {
PHP_FE_END
};
+zend_class_entry *phalcon_translate_interpolatorinterface_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_InterpolatorInterface);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_interpolatorinterface_replaceplaceholders, 0, 0, 1)
+ ZEND_ARG_INFO(0, translation)
+ ZEND_ARG_INFO(0, placeholders)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_translate_interpolatorinterface_method_entry) {
+ PHP_ABSTRACT_ME(Phalcon_Translate_InterpolatorInterface, replacePlaceholders, arginfo_phalcon_translate_interpolatorinterface_replaceplaceholders)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_acl_adapter_ce;
ZEPHIR_INIT_CLASS(Phalcon_Acl_Adapter);
@@ -9050,6 +9076,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, describeReferences);
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, tableOptions);
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, supportsSavepoints);
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, supportsReleaseSavepoints);
+static PHP_METHOD(Phalcon_Db_Dialect_Oracle, prepareTable);
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_dialect_oracle_limit, 0, 0, 2)
ZEND_ARG_INFO(0, sqlQuery)
@@ -9176,6 +9203,13 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_dialect_oracle_tableoptions, 0, 0, 1)
ZEND_ARG_INFO(0, schema)
ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_dialect_oracle_preparetable, 0, 0, 1)
+ ZEND_ARG_INFO(0, table)
+ ZEND_ARG_INFO(0, schema)
+ ZEND_ARG_INFO(0, alias)
+ ZEND_ARG_INFO(0, escapeChar)
+ZEND_END_ARG_INFO()
+
ZEPHIR_INIT_FUNCS(phalcon_db_dialect_oracle_method_entry) {
PHP_ME(Phalcon_Db_Dialect_Oracle, limit, arginfo_phalcon_db_dialect_oracle_limit, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Db_Dialect_Oracle, getColumnDefinition, arginfo_phalcon_db_dialect_oracle_getcolumndefinition, ZEND_ACC_PUBLIC)
@@ -9202,6 +9236,7 @@ ZEPHIR_INIT_FUNCS(phalcon_db_dialect_oracle_method_entry) {
PHP_ME(Phalcon_Db_Dialect_Oracle, tableOptions, arginfo_phalcon_db_dialect_oracle_tableoptions, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Db_Dialect_Oracle, supportsSavepoints, NULL, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Db_Dialect_Oracle, supportsReleaseSavepoints, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Db_Dialect_Oracle, prepareTable, arginfo_phalcon_db_dialect_oracle_preparetable, ZEND_ACC_PROTECTED)
PHP_FE_END
};
@@ -11232,6 +11267,7 @@ static PHP_METHOD(Phalcon_Http_Response, setHeader);
static PHP_METHOD(Phalcon_Http_Response, setRawHeader);
static PHP_METHOD(Phalcon_Http_Response, resetHeaders);
static PHP_METHOD(Phalcon_Http_Response, setExpires);
+static PHP_METHOD(Phalcon_Http_Response, setCache);
static PHP_METHOD(Phalcon_Http_Response, setNotModified);
static PHP_METHOD(Phalcon_Http_Response, setContentType);
static PHP_METHOD(Phalcon_Http_Response, setEtag);
@@ -11282,6 +11318,10 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_response_setexpires, 0, 0, 1)
ZEND_ARG_OBJ_INFO(0, datetime, DateTime, 0)
ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_response_setcache, 0, 0, 1)
+ ZEND_ARG_INFO(0, minutes)
+ZEND_END_ARG_INFO()
+
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_response_setcontenttype, 0, 0, 1)
ZEND_ARG_INFO(0, contentType)
ZEND_ARG_INFO(0, charset)
@@ -11331,6 +11371,7 @@ ZEPHIR_INIT_FUNCS(phalcon_http_response_method_entry) {
PHP_ME(Phalcon_Http_Response, setRawHeader, arginfo_phalcon_http_response_setrawheader, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, resetHeaders, NULL, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, setExpires, arginfo_phalcon_http_response_setexpires, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Http_Response, setCache, arginfo_phalcon_http_response_setcache, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, setNotModified, NULL, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, setContentType, arginfo_phalcon_http_response_setcontenttype, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, setEtag, arginfo_phalcon_http_response_setetag, ZEND_ACC_PUBLIC)
@@ -14498,6 +14539,36 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_model_metadata_memory_method_entry) {
PHP_FE_END
};
+zend_class_entry *phalcon_mvc_model_metadata_redis_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_MetaData_Redis);
+
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, __construct);
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, read);
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, write);
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, reset);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_metadata_redis___construct, 0, 0, 0)
+ ZEND_ARG_INFO(0, options)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_metadata_redis_read, 0, 0, 1)
+ ZEND_ARG_INFO(0, key)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_metadata_redis_write, 0, 0, 2)
+ ZEND_ARG_INFO(0, key)
+ ZEND_ARG_INFO(0, data)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_mvc_model_metadata_redis_method_entry) {
+ PHP_ME(Phalcon_Mvc_Model_MetaData_Redis, __construct, arginfo_phalcon_mvc_model_metadata_redis___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Mvc_Model_MetaData_Redis, read, arginfo_phalcon_mvc_model_metadata_redis_read, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Mvc_Model_MetaData_Redis, write, arginfo_phalcon_mvc_model_metadata_redis_write, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Mvc_Model_MetaData_Redis, reset, NULL, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_mvc_model_metadata_session_ce;
ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_MetaData_Session);
@@ -16852,7 +16923,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, stats);
static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, __wakeup);
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_queue_beanstalk_job___construct, 0, 0, 3)
- ZEND_ARG_INFO(0, queue)
+ ZEND_ARG_OBJ_INFO(0, queue, Phalcon\\Queue\\Beanstalk, 0)
ZEND_ARG_INFO(0, id)
ZEND_ARG_INFO(0, body)
ZEND_END_ARG_INFO()
@@ -17157,6 +17228,50 @@ ZEPHIR_INIT_FUNCS(phalcon_session_adapter_memcache_method_entry) {
PHP_FE_END
};
+zend_class_entry *phalcon_session_adapter_redis_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Session_Adapter_Redis);
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, getRedis);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, getLifetime);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, __construct);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, open);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, close);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, read);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, write);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, destroy);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, gc);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_redis___construct, 0, 0, 0)
+ ZEND_ARG_ARRAY_INFO(0, options, 1)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_redis_read, 0, 0, 1)
+ ZEND_ARG_INFO(0, sessionId)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_redis_write, 0, 0, 2)
+ ZEND_ARG_INFO(0, sessionId)
+ ZEND_ARG_INFO(0, data)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_redis_destroy, 0, 0, 0)
+ ZEND_ARG_INFO(0, sessionId)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_session_adapter_redis_method_entry) {
+ PHP_ME(Phalcon_Session_Adapter_Redis, getRedis, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, getLifetime, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, __construct, arginfo_phalcon_session_adapter_redis___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Session_Adapter_Redis, open, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, close, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, read, arginfo_phalcon_session_adapter_redis_read, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, write, arginfo_phalcon_session_adapter_redis_write, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, destroy, arginfo_phalcon_session_adapter_redis_destroy, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, gc, NULL, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_session_bag_ce;
ZEPHIR_INIT_CLASS(Phalcon_Session_Bag);
@@ -17739,6 +17854,7 @@ zend_class_entry *phalcon_translate_adapter_csv_ce;
ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter_Csv);
static PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct);
+static PHP_METHOD(Phalcon_Translate_Adapter_Csv, _load);
static PHP_METHOD(Phalcon_Translate_Adapter_Csv, query);
static PHP_METHOD(Phalcon_Translate_Adapter_Csv, exists);
static zend_object_value zephir_init_properties_Phalcon_Translate_Adapter_Csv(zend_class_entry *class_type TSRMLS_DC);
@@ -17747,6 +17863,13 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_csv___construct, 0, 0,
ZEND_ARG_ARRAY_INFO(0, options, 0)
ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_csv__load, 0, 0, 4)
+ ZEND_ARG_INFO(0, file)
+ ZEND_ARG_INFO(0, length)
+ ZEND_ARG_INFO(0, delimiter)
+ ZEND_ARG_INFO(0, enclosure)
+ZEND_END_ARG_INFO()
+
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_csv_query, 0, 0, 1)
ZEND_ARG_INFO(0, index)
ZEND_ARG_INFO(0, placeholders)
@@ -17758,6 +17881,7 @@ ZEND_END_ARG_INFO()
ZEPHIR_INIT_FUNCS(phalcon_translate_adapter_csv_method_entry) {
PHP_ME(Phalcon_Translate_Adapter_Csv, __construct, arginfo_phalcon_translate_adapter_csv___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Translate_Adapter_Csv, _load, arginfo_phalcon_translate_adapter_csv__load, ZEND_ACC_PRIVATE)
PHP_ME(Phalcon_Translate_Adapter_Csv, query, arginfo_phalcon_translate_adapter_csv_query, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Translate_Adapter_Csv, exists, arginfo_phalcon_translate_adapter_csv_exists, ZEND_ACC_PUBLIC)
PHP_FE_END
@@ -17881,6 +18005,38 @@ zend_class_entry *phalcon_translate_exception_ce;
ZEPHIR_INIT_CLASS(Phalcon_Translate_Exception);
+zend_class_entry *phalcon_translate_interpolator_associativearray_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_Interpolator_AssociativeArray);
+
+static PHP_METHOD(Phalcon_Translate_Interpolator_AssociativeArray, replacePlaceholders);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_interpolator_associativearray_replaceplaceholders, 0, 0, 1)
+ ZEND_ARG_INFO(0, translation)
+ ZEND_ARG_INFO(0, placeholders)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_translate_interpolator_associativearray_method_entry) {
+ PHP_ME(Phalcon_Translate_Interpolator_AssociativeArray, replacePlaceholders, arginfo_phalcon_translate_interpolator_associativearray_replaceplaceholders, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
+
+zend_class_entry *phalcon_translate_interpolator_indexedarray_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_Interpolator_IndexedArray);
+
+static PHP_METHOD(Phalcon_Translate_Interpolator_IndexedArray, replacePlaceholders);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_interpolator_indexedarray_replaceplaceholders, 0, 0, 1)
+ ZEND_ARG_INFO(0, translation)
+ ZEND_ARG_INFO(0, placeholders)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_translate_interpolator_indexedarray_method_entry) {
+ PHP_ME(Phalcon_Translate_Interpolator_IndexedArray, replacePlaceholders, arginfo_phalcon_translate_interpolator_indexedarray_replaceplaceholders, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_validation_ce;
ZEPHIR_INIT_CLASS(Phalcon_Validation);
diff --git a/build/64bits/php_phalcon.h b/build/64bits/php_phalcon.h
index e67d31674a1..aed59e8482d 100644
--- a/build/64bits/php_phalcon.h
+++ b/build/64bits/php_phalcon.h
@@ -196,7 +196,7 @@ typedef zend_function zephir_fcall_cache_entry;
#define PHP_PHALCON_NAME "phalcon"
-#define PHP_PHALCON_VERSION "2.0.5"
+#define PHP_PHALCON_VERSION "2.0.6"
#define PHP_PHALCON_EXTNAME "phalcon"
#define PHP_PHALCON_AUTHOR "Phalcon Team and contributors"
#define PHP_PHALCON_ZEPVERSION "0.7.1b"
diff --git a/build/safe/phalcon.zep.c b/build/safe/phalcon.zep.c
index 889eaa24e83..f03e012a1f9 100644
--- a/build/safe/phalcon.zep.c
+++ b/build/safe/phalcon.zep.c
@@ -3605,6 +3605,11 @@ long zephir_safe_mod_double_zval(double op1, zval *op2 TSRMLS_DC);
#define ZEPHIR_SCONCAT_SVSVSVS(result, op1, op2, op3, op4, op5, op6, op7) \
zephir_concat_svsvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, 1 TSRMLS_CC);
+#define ZEPHIR_CONCAT_SVSVSVSSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9, op10, op11, op12) \
+ zephir_concat_svsvsvssvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, sizeof(op8)-1, op9, op10, sizeof(op10)-1, op11, op12, sizeof(op12)-1, 0 TSRMLS_CC);
+#define ZEPHIR_SCONCAT_SVSVSVSSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9, op10, op11, op12) \
+ zephir_concat_svsvsvssvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, sizeof(op8)-1, op9, op10, sizeof(op10)-1, op11, op12, sizeof(op12)-1, 1 TSRMLS_CC);
+
#define ZEPHIR_CONCAT_SVSVSVSV(result, op1, op2, op3, op4, op5, op6, op7, op8) \
zephir_concat_svsvsvsv(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, 0 TSRMLS_CC);
#define ZEPHIR_SCONCAT_SVSVSVSV(result, op1, op2, op3, op4, op5, op6, op7, op8) \
@@ -3615,6 +3620,11 @@ long zephir_safe_mod_double_zval(double op1, zval *op2 TSRMLS_DC);
#define ZEPHIR_SCONCAT_SVSVSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9) \
zephir_concat_svsvsvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, op9, sizeof(op9)-1, 1 TSRMLS_CC);
+#define ZEPHIR_CONCAT_SVSVSVSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9, op10, op11) \
+ zephir_concat_svsvsvsvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, op9, sizeof(op9)-1, op10, op11, sizeof(op11)-1, 0 TSRMLS_CC);
+#define ZEPHIR_SCONCAT_SVSVSVSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9, op10, op11) \
+ zephir_concat_svsvsvsvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, op9, sizeof(op9)-1, op10, op11, sizeof(op11)-1, 1 TSRMLS_CC);
+
#define ZEPHIR_CONCAT_SVSVV(result, op1, op2, op3, op4, op5) \
zephir_concat_svsvv(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, 0 TSRMLS_CC);
#define ZEPHIR_SCONCAT_SVSVV(result, op1, op2, op3, op4, op5) \
@@ -3718,8 +3728,10 @@ static void zephir_concat_svsvs(zval **result, const char *op1, zend_uint op1_le
static void zephir_concat_svsvssvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, const char *op6, zend_uint op6_len, zval *op7, const char *op8, zend_uint op8_len, zval *op9, const char *op10, zend_uint op10_len, int self_var TSRMLS_DC);
static void zephir_concat_svsvsv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, int self_var TSRMLS_DC);
static void zephir_concat_svsvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, int self_var TSRMLS_DC);
+static void zephir_concat_svsvsvssvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, const char *op8, zend_uint op8_len, zval *op9, const char *op10, zend_uint op10_len, zval *op11, const char *op12, zend_uint op12_len, int self_var TSRMLS_DC);
static void zephir_concat_svsvsvsv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, int self_var TSRMLS_DC);
static void zephir_concat_svsvsvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, const char *op9, zend_uint op9_len, int self_var TSRMLS_DC);
+static void zephir_concat_svsvsvsvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, const char *op9, zend_uint op9_len, zval *op10, const char *op11, zend_uint op11_len, int self_var TSRMLS_DC);
static void zephir_concat_svsvv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, zval *op5, int self_var TSRMLS_DC);
static void zephir_concat_svsvvsv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, zval *op5, const char *op6, zend_uint op6_len, zval *op7, int self_var TSRMLS_DC);
static void zephir_concat_svsvvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, zval *op5, const char *op6, zend_uint op6_len, zval *op7, const char *op8, zend_uint op8_len, int self_var TSRMLS_DC);
@@ -10022,7 +10034,7 @@ static void zephir_fast_join_str(zval *return_value, char *glue, unsigned int gl
static void zephir_camelize(zval *return_value, const zval *str) {
- int i, len;
+ int i, len, first = 0;
smart_str camelize_str = {0};
char *marker, ch;
@@ -10034,35 +10046,40 @@ static void zephir_camelize(zval *return_value, const zval *str) {
marker = Z_STRVAL_P(str);
len = Z_STRLEN_P(str);
- for (i = 0; i < len - 1; i++) {
- ch = *marker;
- if (i == 0 || ch == '-' || ch == '_') {
+ for (i = 0; i < len; i++) {
+
+ ch = marker[i];
+
+ if (first == 0) {
+
if (ch == '-' || ch == '_') {
- i++;
- marker++;
+ continue;
}
- smart_str_appendc(&camelize_str, toupper(*marker));
- }
- else {
- smart_str_appendc(&camelize_str, tolower(*marker));
+ first = 1;
+ smart_str_appendc(&camelize_str, toupper(ch));
+ continue;
}
- marker++;
- }
+ if (ch == '-' || ch == '_') {
+ if (i != (len - 1)) {
+ i++;
+ ch = marker[i];
+ smart_str_appendc(&camelize_str, toupper(ch));
+ }
+ continue;
+ }
- if (likely(i == len - 1)) {
- smart_str_appendc(&camelize_str, *marker);
+ smart_str_appendc(&camelize_str, tolower(ch));
}
smart_str_0(&camelize_str);
if (camelize_str.c) {
RETURN_STRINGL(camelize_str.c, camelize_str.len, 0);
- } else {
- RETURN_EMPTY_STRING();
}
+ RETURN_EMPTY_STRING();
}
static void zephir_uncamelize(zval *return_value, const zval *str) {
@@ -10078,10 +10095,13 @@ static void zephir_uncamelize(zval *return_value, const zval *str) {
marker = Z_STRVAL_P(str);
for (i = 0; i < Z_STRLEN_P(str); i++) {
+
ch = *marker;
+
if (ch == '\0') {
break;
}
+
if (ch >= 'A' && ch <= 'Z') {
if (i > 0) {
smart_str_appendc(&uncamelize_str, '_');
@@ -10090,6 +10110,7 @@ static void zephir_uncamelize(zval *return_value, const zval *str) {
} else {
smart_str_appendc(&uncamelize_str, (*marker));
}
+
marker++;
}
smart_str_0(&uncamelize_str);
@@ -10257,7 +10278,7 @@ static void zephir_fast_str_replace(zval **return_value_ptr, zval *search, zval
if (Z_TYPE_P(search) == IS_ARRAY) {
do {
- zval *params[] = { search, replace, subject };
+ zval *params[] = { search, replace, subject };
zval_ptr_dtor(return_value_ptr);
return_value_ptr = NULL;
zephir_call_func_aparams(return_value_ptr, "str_replace", sizeof("str_replace")-1, NULL, 0, 3, params TSRMLS_CC);
@@ -14452,6 +14473,107 @@ static void zephir_concat_svsvsvs(zval **result, const char *op1, zend_uint op1_
}
+static void zephir_concat_svsvsvssvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, const char *op8, zend_uint op8_len, zval *op9, const char *op10, zend_uint op10_len, zval *op11, const char *op12, zend_uint op12_len, int self_var TSRMLS_DC){
+
+ zval result_copy, op2_copy, op4_copy, op6_copy, op9_copy, op11_copy;
+ int use_copy = 0, use_copy2 = 0, use_copy4 = 0, use_copy6 = 0, use_copy9 = 0, use_copy11 = 0;
+ uint offset = 0, length;
+
+ if (Z_TYPE_P(op2) != IS_STRING) {
+ zend_make_printable_zval(op2, &op2_copy, &use_copy2);
+ if (use_copy2) {
+ op2 = &op2_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op4) != IS_STRING) {
+ zend_make_printable_zval(op4, &op4_copy, &use_copy4);
+ if (use_copy4) {
+ op4 = &op4_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op6) != IS_STRING) {
+ zend_make_printable_zval(op6, &op6_copy, &use_copy6);
+ if (use_copy6) {
+ op6 = &op6_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op9) != IS_STRING) {
+ zend_make_printable_zval(op9, &op9_copy, &use_copy9);
+ if (use_copy9) {
+ op9 = &op9_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op11) != IS_STRING) {
+ zend_make_printable_zval(op11, &op11_copy, &use_copy11);
+ if (use_copy11) {
+ op11 = &op11_copy;
+ }
+ }
+
+ length = op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len + Z_STRLEN_P(op9) + op10_len + Z_STRLEN_P(op11) + op12_len;
+ if (self_var) {
+
+ if (Z_TYPE_PP(result) != IS_STRING) {
+ zend_make_printable_zval(*result, &result_copy, &use_copy);
+ if (use_copy) {
+ ZEPHIR_CPY_WRT_CTOR(*result, (&result_copy));
+ }
+ }
+
+ offset = Z_STRLEN_PP(result);
+ length += offset;
+ Z_STRVAL_PP(result) = (char *) str_erealloc(Z_STRVAL_PP(result), length + 1);
+
+ } else {
+ Z_STRVAL_PP(result) = (char *) emalloc(length + 1);
+ }
+
+ memcpy(Z_STRVAL_PP(result) + offset, op1, op1_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len, Z_STRVAL_P(op2), Z_STRLEN_P(op2));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2), op3, op3_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len, Z_STRVAL_P(op4), Z_STRLEN_P(op4));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4), op5, op5_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len, Z_STRVAL_P(op6), Z_STRLEN_P(op6));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6), op7, op7_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len, op8, op8_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len, Z_STRVAL_P(op9), Z_STRLEN_P(op9));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len + Z_STRLEN_P(op9), op10, op10_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len + Z_STRLEN_P(op9) + op10_len, Z_STRVAL_P(op11), Z_STRLEN_P(op11));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len + Z_STRLEN_P(op9) + op10_len + Z_STRLEN_P(op11), op12, op12_len);
+ Z_STRVAL_PP(result)[length] = 0;
+ Z_TYPE_PP(result) = IS_STRING;
+ Z_STRLEN_PP(result) = length;
+
+ if (use_copy2) {
+ zval_dtor(op2);
+ }
+
+ if (use_copy4) {
+ zval_dtor(op4);
+ }
+
+ if (use_copy6) {
+ zval_dtor(op6);
+ }
+
+ if (use_copy9) {
+ zval_dtor(op9);
+ }
+
+ if (use_copy11) {
+ zval_dtor(op11);
+ }
+
+ if (use_copy) {
+ zval_dtor(&result_copy);
+ }
+
+}
+
static void zephir_concat_svsvsvsv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, int self_var TSRMLS_DC){
zval result_copy, op2_copy, op4_copy, op6_copy, op8_copy;
@@ -14625,6 +14747,106 @@ static void zephir_concat_svsvsvsvs(zval **result, const char *op1, zend_uint op
}
+static void zephir_concat_svsvsvsvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, const char *op9, zend_uint op9_len, zval *op10, const char *op11, zend_uint op11_len, int self_var TSRMLS_DC){
+
+ zval result_copy, op2_copy, op4_copy, op6_copy, op8_copy, op10_copy;
+ int use_copy = 0, use_copy2 = 0, use_copy4 = 0, use_copy6 = 0, use_copy8 = 0, use_copy10 = 0;
+ uint offset = 0, length;
+
+ if (Z_TYPE_P(op2) != IS_STRING) {
+ zend_make_printable_zval(op2, &op2_copy, &use_copy2);
+ if (use_copy2) {
+ op2 = &op2_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op4) != IS_STRING) {
+ zend_make_printable_zval(op4, &op4_copy, &use_copy4);
+ if (use_copy4) {
+ op4 = &op4_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op6) != IS_STRING) {
+ zend_make_printable_zval(op6, &op6_copy, &use_copy6);
+ if (use_copy6) {
+ op6 = &op6_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op8) != IS_STRING) {
+ zend_make_printable_zval(op8, &op8_copy, &use_copy8);
+ if (use_copy8) {
+ op8 = &op8_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op10) != IS_STRING) {
+ zend_make_printable_zval(op10, &op10_copy, &use_copy10);
+ if (use_copy10) {
+ op10 = &op10_copy;
+ }
+ }
+
+ length = op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + Z_STRLEN_P(op8) + op9_len + Z_STRLEN_P(op10) + op11_len;
+ if (self_var) {
+
+ if (Z_TYPE_PP(result) != IS_STRING) {
+ zend_make_printable_zval(*result, &result_copy, &use_copy);
+ if (use_copy) {
+ ZEPHIR_CPY_WRT_CTOR(*result, (&result_copy));
+ }
+ }
+
+ offset = Z_STRLEN_PP(result);
+ length += offset;
+ Z_STRVAL_PP(result) = (char *) str_erealloc(Z_STRVAL_PP(result), length + 1);
+
+ } else {
+ Z_STRVAL_PP(result) = (char *) emalloc(length + 1);
+ }
+
+ memcpy(Z_STRVAL_PP(result) + offset, op1, op1_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len, Z_STRVAL_P(op2), Z_STRLEN_P(op2));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2), op3, op3_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len, Z_STRVAL_P(op4), Z_STRLEN_P(op4));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4), op5, op5_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len, Z_STRVAL_P(op6), Z_STRLEN_P(op6));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6), op7, op7_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len, Z_STRVAL_P(op8), Z_STRLEN_P(op8));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + Z_STRLEN_P(op8), op9, op9_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + Z_STRLEN_P(op8) + op9_len, Z_STRVAL_P(op10), Z_STRLEN_P(op10));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + Z_STRLEN_P(op8) + op9_len + Z_STRLEN_P(op10), op11, op11_len);
+ Z_STRVAL_PP(result)[length] = 0;
+ Z_TYPE_PP(result) = IS_STRING;
+ Z_STRLEN_PP(result) = length;
+
+ if (use_copy2) {
+ zval_dtor(op2);
+ }
+
+ if (use_copy4) {
+ zval_dtor(op4);
+ }
+
+ if (use_copy6) {
+ zval_dtor(op6);
+ }
+
+ if (use_copy8) {
+ zval_dtor(op8);
+ }
+
+ if (use_copy10) {
+ zval_dtor(op10);
+ }
+
+ if (use_copy) {
+ zval_dtor(&result_copy);
+ }
+
+}
+
static void zephir_concat_svsvv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, zval *op5, int self_var TSRMLS_DC){
zval result_copy, op2_copy, op4_copy, op5_copy;
@@ -17401,12 +17623,12 @@ static PHP_METHOD(phalcon_0__closure, __invoke) {
- zephir_array_fetch_long(&_0, matches, 1, PH_NOISY | PH_READONLY, "phalcon/text.zep", 276 TSRMLS_CC);
+ zephir_array_fetch_long(&_0, matches, 1, PH_NOISY | PH_READONLY, "phalcon/text.zep", 272 TSRMLS_CC);
ZEPHIR_INIT_VAR(words);
zephir_fast_explode_str(words, SL("|"), _0, LONG_MAX TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_2, "array_rand", NULL, 438, words);
+ ZEPHIR_CALL_FUNCTION(&_2, "array_rand", NULL, 442, words);
zephir_check_call_status();
- zephir_array_fetch(&_1, words, _2, PH_NOISY | PH_READONLY, "phalcon/text.zep", 277 TSRMLS_CC);
+ zephir_array_fetch(&_1, words, _2, PH_NOISY | PH_READONLY, "phalcon/text.zep", 273 TSRMLS_CC);
RETURN_CTOR(_1);
}
@@ -17967,7 +18189,7 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) {
if (_0) {
paddingSize = (blockSize - (zephir_safe_mod_long_long(zephir_fast_strlen_ev(text), blockSize TSRMLS_CC)));
if (paddingSize >= 256) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Block size is bigger than 256", "phalcon/crypt.zep", 147);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Block size is bigger than 256", "phalcon/crypt.zep", 142);
return;
}
do {
@@ -18076,7 +18298,7 @@ static PHP_METHOD(Phalcon_Crypt, _cryptPadText) {
RETURN_CTOR(text);
}
if (paddingSize > blockSize) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Invalid padding size", "phalcon/crypt.zep", 191);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Invalid padding size", "phalcon/crypt.zep", 186);
return;
}
ZEPHIR_SINIT_NVAR(_1);
@@ -18352,7 +18574,7 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) {
if (!((zephir_function_exists_ex(SS("mcrypt_get_iv_size") TSRMLS_CC) == SUCCESS))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "mcrypt extension is required", "phalcon/crypt.zep", 307);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "mcrypt extension is required", "phalcon/crypt.zep", 302);
return;
}
if (ZEPHIR_IS_STRING_IDENTICAL(key, "")) {
@@ -18362,7 +18584,7 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) {
ZEPHIR_CPY_WRT(encryptKey, key);
}
if (ZEPHIR_IS_EMPTY(encryptKey)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Encryption key cannot be empty", "phalcon/crypt.zep", 317);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Encryption key cannot be empty", "phalcon/crypt.zep", 312);
return;
}
ZEPHIR_OBS_VAR(cipher);
@@ -18372,7 +18594,7 @@ static PHP_METHOD(Phalcon_Crypt, encrypt) {
ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 131, cipher, mode);
zephir_check_call_status();
if (ZEPHIR_LT_LONG(ivSize, zephir_fast_strlen_ev(encryptKey))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 325);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 320);
return;
}
ZEPHIR_SINIT_VAR(_0);
@@ -18441,7 +18663,7 @@ static PHP_METHOD(Phalcon_Crypt, decrypt) {
if (!((zephir_function_exists_ex(SS("mcrypt_get_iv_size") TSRMLS_CC) == SUCCESS))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "mcrypt extension is required", "phalcon/crypt.zep", 361);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "mcrypt extension is required", "phalcon/crypt.zep", 356);
return;
}
if (Z_TYPE_P(key) == IS_NULL) {
@@ -18451,7 +18673,7 @@ static PHP_METHOD(Phalcon_Crypt, decrypt) {
ZEPHIR_CPY_WRT(decryptKey, key);
}
if (ZEPHIR_IS_EMPTY(decryptKey)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Decryption key cannot be empty", "phalcon/crypt.zep", 371);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Decryption key cannot be empty", "phalcon/crypt.zep", 366);
return;
}
ZEPHIR_OBS_VAR(cipher);
@@ -18463,13 +18685,13 @@ static PHP_METHOD(Phalcon_Crypt, decrypt) {
ZEPHIR_INIT_VAR(keySize);
ZVAL_LONG(keySize, zephir_fast_strlen_ev(decryptKey));
if (ZEPHIR_GT(keySize, ivSize)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 380);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 375);
return;
}
ZEPHIR_INIT_VAR(length);
ZVAL_LONG(length, zephir_fast_strlen_ev(text));
if (ZEPHIR_GT(keySize, length)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of IV is larger than text to decrypt", "phalcon/crypt.zep", 385);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of IV is larger than text to decrypt", "phalcon/crypt.zep", 380);
return;
}
ZEPHIR_INIT_VAR(_0);
@@ -18917,7 +19139,7 @@ static PHP_METHOD(Phalcon_Debug, listenExceptions) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "onUncaughtException", 1);
zephir_array_fast_append(_0, _1);
- ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 147, _0);
+ ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 148, _0);
zephir_check_call_status();
RETURN_THIS();
@@ -18937,7 +19159,7 @@ static PHP_METHOD(Phalcon_Debug, listenLowSeverity) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "onUncaughtLowSeverity", 1);
zephir_array_fast_append(_0, _1);
- ZEPHIR_CALL_FUNCTION(NULL, "set_error_handler", NULL, 148, _0);
+ ZEPHIR_CALL_FUNCTION(NULL, "set_error_handler", NULL, 149, _0);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_2);
zephir_create_array(_2, 2, 0 TSRMLS_CC);
@@ -18945,7 +19167,7 @@ static PHP_METHOD(Phalcon_Debug, listenLowSeverity) {
ZEPHIR_INIT_NVAR(_1);
ZVAL_STRING(_1, "onUncaughtException", 1);
zephir_array_fast_append(_2, _1);
- ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 147, _2);
+ ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 148, _2);
zephir_check_call_status();
RETURN_THIS();
@@ -18980,7 +19202,7 @@ static PHP_METHOD(Phalcon_Debug, debugVar) {
ZEPHIR_INIT_VAR(_0);
zephir_create_array(_0, 3, 0 TSRMLS_CC);
zephir_array_fast_append(_0, varz);
- ZEPHIR_CALL_FUNCTION(&_1, "debug_backtrace", NULL, 149);
+ ZEPHIR_CALL_FUNCTION(&_1, "debug_backtrace", NULL, 150);
zephir_check_call_status();
zephir_array_fast_append(_0, _1);
ZEPHIR_INIT_VAR(_2);
@@ -19020,7 +19242,7 @@ static PHP_METHOD(Phalcon_Debug, _escapeString) {
ZVAL_LONG(&_3, 2);
ZEPHIR_SINIT_VAR(_4);
ZVAL_STRING(&_4, "utf-8", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("htmlentities", NULL, 150, _0, &_3, &_4);
+ ZEPHIR_RETURN_CALL_FUNCTION("htmlentities", NULL, 151, _0, &_3, &_4);
zephir_check_call_status();
RETURN_MM();
}
@@ -19071,7 +19293,7 @@ static PHP_METHOD(Phalcon_Debug, _getArrayDump) {
) {
ZEPHIR_GET_HMKEY(k, _2, _1);
ZEPHIR_GET_HVALUE(v, _3);
- ZEPHIR_CALL_FUNCTION(&_4, "is_scalar", &_5, 151, v);
+ ZEPHIR_CALL_FUNCTION(&_4, "is_scalar", &_5, 152, v);
zephir_check_call_status();
if (zephir_is_true(_4)) {
ZEPHIR_INIT_NVAR(varDump);
@@ -19088,7 +19310,7 @@ static PHP_METHOD(Phalcon_Debug, _getArrayDump) {
if (Z_TYPE_P(v) == IS_ARRAY) {
ZEPHIR_INIT_NVAR(_8);
ZVAL_LONG(_8, (zephir_get_numberval(n) + 1));
- ZEPHIR_CALL_METHOD(&_6, this_ptr, "_getarraydump", &_9, 152, v, _8);
+ ZEPHIR_CALL_METHOD(&_6, this_ptr, "_getarraydump", &_9, 153, v, _8);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_10);
ZEPHIR_CONCAT_SVSVS(_10, "[", k, "] => Array(", _6, ")");
@@ -19122,14 +19344,14 @@ static PHP_METHOD(Phalcon_Debug, _getVarDump) {
zephir_fcall_cache_entry *_2 = NULL;
int ZEPHIR_LAST_CALL_STATUS;
- zval *variable, *className, *dumpedObject = NULL, *dump, *_0 = NULL, *_1 = NULL;
+ zval *variable, *className, *dumpedObject = NULL, *_0 = NULL, *_1 = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 0, &variable);
- ZEPHIR_CALL_FUNCTION(&_0, "is_scalar", NULL, 151, variable);
+ ZEPHIR_CALL_FUNCTION(&_0, "is_scalar", NULL, 152, variable);
zephir_check_call_status();
if (zephir_is_true(_0)) {
if (Z_TYPE_P(variable) == IS_BOOL) {
@@ -19150,20 +19372,20 @@ static PHP_METHOD(Phalcon_Debug, _getVarDump) {
if (Z_TYPE_P(variable) == IS_OBJECT) {
ZEPHIR_INIT_VAR(className);
zephir_get_class(className, variable, 0 TSRMLS_CC);
- ZEPHIR_INIT_VAR(dump);
if ((zephir_method_exists_ex(variable, SS("dump") TSRMLS_CC) == SUCCESS)) {
ZEPHIR_CALL_METHOD(&dumpedObject, variable, "dump", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 0, dumpedObject);
zephir_check_call_status();
- ZEPHIR_CONCAT_SVSVS(dump, "Object(", className, ": ", _1, ")");
+ ZEPHIR_CONCAT_SVSVS(return_value, "Object(", className, ": ", _1, ")");
+ RETURN_MM();
} else {
- ZEPHIR_CONCAT_SVS(dump, "Object(", className, ")");
+ ZEPHIR_CONCAT_SVS(return_value, "Object(", className, ")");
+ RETURN_MM();
}
- RETURN_CCTOR(dump);
}
if (Z_TYPE_P(variable) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 152, variable);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 153, variable);
zephir_check_call_status();
ZEPHIR_CONCAT_SVS(return_value, "Array(", _1, ")");
RETURN_MM();
@@ -19184,11 +19406,11 @@ static PHP_METHOD(Phalcon_Debug, getMajorVersion) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_version_ce, "get", &_1, 153);
+ ZEPHIR_CALL_CE_STATIC(&_0, phalcon_version_ce, "get", &_1, 154);
zephir_check_call_status();
ZEPHIR_INIT_VAR(parts);
zephir_fast_explode_str(parts, SL(" "), _0, LONG_MAX TSRMLS_CC);
- zephir_array_fetch_long(&_2, parts, 0, PH_NOISY | PH_READONLY, "phalcon/debug.zep", 290 TSRMLS_CC);
+ zephir_array_fetch_long(&_2, parts, 0, PH_NOISY | PH_READONLY, "phalcon/debug.zep", 289 TSRMLS_CC);
RETURN_CTOR(_2);
}
@@ -19203,7 +19425,7 @@ static PHP_METHOD(Phalcon_Debug, getVersion) {
ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmajorversion", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_CE_STATIC(&_1, phalcon_version_ce, "get", &_2, 153);
+ ZEPHIR_CALL_CE_STATIC(&_1, phalcon_version_ce, "get", &_2, 154);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "");
RETURN_MM();
@@ -19253,12 +19475,13 @@ static PHP_METHOD(Phalcon_Debug, getJsSources) {
static PHP_METHOD(Phalcon_Debug, showTraceItem) {
- zephir_fcall_cache_entry *_15 = NULL, *_21 = NULL;
+ zend_bool _24;
+ zephir_fcall_cache_entry *_15 = NULL, *_26 = NULL;
HashTable *_13;
HashPosition _12;
zval *_1, *_17 = NULL;
zval *trace = NULL;
- zval *n_param = NULL, *trace_param = NULL, *space, *twoSpaces, *underscore, *minus, *className, *prepareInternalClass, *preparedFunctionName, *html = NULL, *classReflection, *prepareUriClass, *functionName, *functionReflection, *traceArgs, *arguments, *argument = NULL, *filez, *line = NULL, *showFiles, *lines = NULL, *numberLines, *showFileFragment, *beforeLine, *afterLine, *lastLine = NULL, *commentPattern, *utf8, *entCompat, *tab, *comment, linePosition = zval_used_for_init, *currentLine = NULL, _0, *_2, *_3 = NULL, _4 = zval_used_for_init, _5 = zval_used_for_init, _6 = zval_used_for_init, *_7 = NULL, *_8 = NULL, *_9 = NULL, *_10 = NULL, *_11, **_14, *_16, *_18, *_19 = NULL, *_20 = NULL;
+ zval *n_param = NULL, *trace_param = NULL, *className, *prepareInternalClass, *preparedFunctionName, *html = NULL, *classReflection, *prepareUriClass, *functionName, *functionReflection, *traceArgs, *arguments, *argument = NULL, *filez, *line = NULL, *showFiles, *lines = NULL, *numberLines, *showFileFragment, *beforeLine, *afterLine, *lastLine = NULL, linePosition = zval_used_for_init, *currentLine = NULL, _0, *_2, *_3 = NULL, _4 = zval_used_for_init, _5 = zval_used_for_init, _6 = zval_used_for_init, *_7 = NULL, *_8 = NULL, *_9 = NULL, *_10 = NULL, *_11, **_14, *_16, *_18, *_19 = NULL, _20 = zval_used_for_init, *_21 = NULL, _22 = zval_used_for_init, _23 = zval_used_for_init, _25 = zval_used_for_init;
int n, firstLine, i, ZEPHIR_LAST_CALL_STATUS;
ZEPHIR_MM_GROW();
@@ -19269,22 +19492,13 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
- ZEPHIR_INIT_VAR(space);
- ZVAL_STRING(space, " ", 1);
- ZEPHIR_INIT_VAR(twoSpaces);
- ZVAL_STRING(twoSpaces, " ", 1);
- ZEPHIR_INIT_VAR(underscore);
- ZVAL_STRING(underscore, "_", 1);
- ZEPHIR_INIT_VAR(minus);
- ZVAL_STRING(minus, "-", 1);
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, n);
ZEPHIR_INIT_VAR(_1);
ZEPHIR_CONCAT_SVS(_1, "#", &_0, " | ");
ZEPHIR_CPY_WRT(html, _1);
- if (zephir_array_isset_string(trace, SS("class"))) {
- ZEPHIR_OBS_VAR(className);
- zephir_array_fetch_string(&className, trace, SL("class"), PH_NOISY, "phalcon/debug.zep", 356 TSRMLS_CC);
+ ZEPHIR_OBS_VAR(className);
+ if (zephir_array_isset_string_fetch(&className, trace, SS("class"), 0 TSRMLS_CC)) {
ZEPHIR_INIT_VAR(_2);
ZEPHIR_INIT_VAR(_3);
ZEPHIR_SINIT_VAR(_4);
@@ -19305,13 +19519,17 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
object_init_ex(classReflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC));
ZEPHIR_CALL_METHOD(NULL, classReflection, "__construct", NULL, 62, className);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, classReflection, "isinternal", NULL, 154);
+ ZEPHIR_CALL_METHOD(&_8, classReflection, "isinternal", NULL, 155);
zephir_check_call_status();
if (zephir_is_true(_8)) {
ZEPHIR_INIT_VAR(_9);
zephir_fast_strtolower(_9, className);
+ ZEPHIR_SINIT_NVAR(_5);
+ ZVAL_STRING(&_5, "_", 0);
+ ZEPHIR_SINIT_NVAR(_6);
+ ZVAL_STRING(&_6, "-", 0);
ZEPHIR_INIT_VAR(prepareInternalClass);
- zephir_fast_str_replace(&prepareInternalClass, underscore, minus, _9 TSRMLS_CC);
+ zephir_fast_str_replace(&prepareInternalClass, &_5, &_6, _9 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVSVS(_7, "", className, "");
zephir_concat_self(&html, _7 TSRMLS_CC);
@@ -19321,11 +19539,11 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
zephir_concat_self(&html, _10 TSRMLS_CC);
}
}
- zephir_array_fetch_string(&_11, trace, SL("type"), PH_NOISY | PH_READONLY, "phalcon/debug.zep", 395 TSRMLS_CC);
+ zephir_array_fetch_string(&_11, trace, SL("type"), PH_NOISY | PH_READONLY, "phalcon/debug.zep", 385 TSRMLS_CC);
zephir_concat_self(&html, _11 TSRMLS_CC);
}
ZEPHIR_OBS_VAR(functionName);
- zephir_array_fetch_string(&functionName, trace, SL("function"), PH_NOISY, "phalcon/debug.zep", 401 TSRMLS_CC);
+ zephir_array_fetch_string(&functionName, trace, SL("function"), PH_NOISY, "phalcon/debug.zep", 391 TSRMLS_CC);
if (zephir_array_isset_string(trace, SS("class"))) {
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVS(_7, "", functionName, "");
@@ -19334,13 +19552,17 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
if ((zephir_function_exists(functionName TSRMLS_CC) == SUCCESS)) {
ZEPHIR_INIT_VAR(functionReflection);
object_init_ex(functionReflection, zephir_get_internal_ce(SS("reflectionfunction") TSRMLS_CC));
- ZEPHIR_CALL_METHOD(NULL, functionReflection, "__construct", NULL, 155, functionName);
+ ZEPHIR_CALL_METHOD(NULL, functionReflection, "__construct", NULL, 156, functionName);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, functionReflection, "isinternal", NULL, 156);
+ ZEPHIR_CALL_METHOD(&_8, functionReflection, "isinternal", NULL, 157);
zephir_check_call_status();
if (zephir_is_true(_8)) {
+ ZEPHIR_SINIT_NVAR(_4);
+ ZVAL_STRING(&_4, "_", 0);
+ ZEPHIR_SINIT_NVAR(_5);
+ ZVAL_STRING(&_5, "-", 0);
ZEPHIR_INIT_VAR(preparedFunctionName);
- zephir_fast_str_replace(&preparedFunctionName, underscore, minus, functionName TSRMLS_CC);
+ zephir_fast_str_replace(&preparedFunctionName, &_4, &_5, functionName TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_10);
ZEPHIR_CONCAT_SVSVS(_10, "", functionName, "");
zephir_concat_self(&html, _10 TSRMLS_CC);
@@ -19355,13 +19577,12 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
zephir_concat_self(&html, _7 TSRMLS_CC);
}
}
- if (zephir_array_isset_string(trace, SS("args"))) {
- ZEPHIR_OBS_VAR(traceArgs);
- zephir_array_fetch_string(&traceArgs, trace, SL("args"), PH_NOISY, "phalcon/debug.zep", 435 TSRMLS_CC);
+ ZEPHIR_OBS_VAR(traceArgs);
+ if (zephir_array_isset_string_fetch(&traceArgs, trace, SS("args"), 0 TSRMLS_CC)) {
if (zephir_fast_count_int(traceArgs TSRMLS_CC)) {
ZEPHIR_INIT_VAR(arguments);
array_init(arguments);
- zephir_is_iterable(traceArgs, &_13, &_12, 0, 0, "phalcon/debug.zep", 450);
+ zephir_is_iterable(traceArgs, &_13, &_12, 0, 0, "phalcon/debug.zep", 439);
for (
; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS
; zephir_hash_move_forward_ex(_13, &_12)
@@ -19371,7 +19592,7 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVS(_7, "", _8, "");
- zephir_array_append(&arguments, _7, PH_SEPARATE, "phalcon/debug.zep", 444);
+ zephir_array_append(&arguments, _7, PH_SEPARATE, "phalcon/debug.zep", 433);
}
ZEPHIR_INIT_NVAR(_3);
zephir_fast_join_str(_3, SL(", "), arguments TSRMLS_CC);
@@ -19385,7 +19606,7 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
ZEPHIR_OBS_VAR(filez);
if (zephir_array_isset_string_fetch(&filez, trace, SS("file"), 0 TSRMLS_CC)) {
ZEPHIR_OBS_VAR(_16);
- zephir_array_fetch_string(&_16, trace, SL("line"), PH_NOISY, "phalcon/debug.zep", 461 TSRMLS_CC);
+ zephir_array_fetch_string(&_16, trace, SL("line"), PH_NOISY, "phalcon/debug.zep", 450 TSRMLS_CC);
zephir_get_strval(_17, _16);
ZEPHIR_CPY_WRT(line, _17);
ZEPHIR_INIT_LNVAR(_7);
@@ -19394,7 +19615,7 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
ZEPHIR_OBS_VAR(showFiles);
zephir_read_property_this(&showFiles, this_ptr, SL("_showFiles"), PH_NOISY_CC);
if (zephir_is_true(showFiles)) {
- ZEPHIR_CALL_FUNCTION(&lines, "file", NULL, 157, filez);
+ ZEPHIR_CALL_FUNCTION(&lines, "file", NULL, 158, filez);
zephir_check_call_status();
ZEPHIR_INIT_VAR(numberLines);
ZVAL_LONG(numberLines, zephir_fast_count_int(lines TSRMLS_CC));
@@ -19431,16 +19652,6 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
ZEPHIR_CONCAT_SVSVS(_10, "");
zephir_concat_self(&html, _10 TSRMLS_CC);
}
- ZEPHIR_INIT_VAR(commentPattern);
- ZVAL_STRING(commentPattern, "#\\*\\/#", 1);
- ZEPHIR_INIT_VAR(utf8);
- ZVAL_STRING(utf8, "UTF-8", 1);
- ZEPHIR_INIT_VAR(entCompat);
- ZVAL_LONG(entCompat, 2);
- ZEPHIR_INIT_VAR(tab);
- ZVAL_STRING(tab, "\t", 1);
- ZEPHIR_INIT_VAR(comment);
- ZVAL_STRING(comment, "* /", 1);
i = firstLine;
while (1) {
if (!(ZEPHIR_GE_LONG(lastLine, i))) {
@@ -19449,33 +19660,47 @@ static PHP_METHOD(Phalcon_Debug, showTraceItem) {
ZEPHIR_SINIT_NVAR(linePosition);
ZVAL_LONG(&linePosition, (i - 1));
ZEPHIR_OBS_NVAR(currentLine);
- zephir_array_fetch(¤tLine, lines, &linePosition, PH_NOISY, "phalcon/debug.zep", 549 TSRMLS_CC);
+ zephir_array_fetch(¤tLine, lines, &linePosition, PH_NOISY, "phalcon/debug.zep", 523 TSRMLS_CC);
if (zephir_is_true(showFileFragment)) {
if (i == firstLine) {
ZEPHIR_INIT_NVAR(_19);
ZEPHIR_INIT_NVAR(_3);
ZEPHIR_INIT_NVAR(_9);
zephir_fast_trim(_9, currentLine, NULL , ZEPHIR_TRIM_RIGHT TSRMLS_CC);
- zephir_preg_match(_3, commentPattern, _9, _19, 0, 0 , 0 TSRMLS_CC);
+ ZEPHIR_SINIT_NVAR(_20);
+ ZVAL_STRING(&_20, "#\\*\\/#", 0);
+ zephir_preg_match(_3, &_20, _9, _19, 0, 0 , 0 TSRMLS_CC);
if (zephir_is_true(_3)) {
- ZEPHIR_INIT_NVAR(_20);
- zephir_fast_str_replace(&_20, comment, space, currentLine TSRMLS_CC);
- ZEPHIR_CPY_WRT(currentLine, _20);
+ ZEPHIR_INIT_NVAR(_21);
+ ZEPHIR_SINIT_NVAR(_22);
+ ZVAL_STRING(&_22, "* /", 0);
+ ZEPHIR_SINIT_NVAR(_23);
+ ZVAL_STRING(&_23, " ", 0);
+ zephir_fast_str_replace(&_21, &_22, &_23, currentLine TSRMLS_CC);
+ ZEPHIR_CPY_WRT(currentLine, _21);
}
}
}
- if (ZEPHIR_IS_STRING(currentLine, "\n")) {
+ _24 = ZEPHIR_IS_STRING(currentLine, "\n");
+ if (!(_24)) {
+ _24 = ZEPHIR_IS_STRING(currentLine, "\r\n");
+ }
+ if (_24) {
zephir_concat_self_str(&html, SL(" \n") TSRMLS_CC);
} else {
- if (ZEPHIR_IS_STRING(currentLine, "\r\n")) {
- zephir_concat_self_str(&html, SL(" \n") TSRMLS_CC);
- } else {
- ZEPHIR_INIT_NVAR(_20);
- zephir_fast_str_replace(&_20, tab, twoSpaces, currentLine TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_8, "htmlentities", &_21, 150, _20, entCompat, utf8);
- zephir_check_call_status();
- zephir_concat_self(&html, _8 TSRMLS_CC);
- }
+ ZEPHIR_INIT_NVAR(_21);
+ ZEPHIR_SINIT_NVAR(_20);
+ ZVAL_STRING(&_20, "\t", 0);
+ ZEPHIR_SINIT_NVAR(_22);
+ ZVAL_STRING(&_22, " ", 0);
+ zephir_fast_str_replace(&_21, &_20, &_22, currentLine TSRMLS_CC);
+ ZEPHIR_SINIT_NVAR(_23);
+ ZVAL_LONG(&_23, 2);
+ ZEPHIR_SINIT_NVAR(_25);
+ ZVAL_STRING(&_25, "UTF-8", 0);
+ ZEPHIR_CALL_FUNCTION(&_8, "htmlentities", &_26, 151, _21, &_23, &_25);
+ zephir_check_call_status();
+ zephir_concat_self(&html, _8 TSRMLS_CC);
}
i++;
}
@@ -19497,7 +19722,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtLowSeverity) {
- ZEPHIR_CALL_FUNCTION(&_0, "error_reporting", NULL, 158);
+ ZEPHIR_CALL_FUNCTION(&_0, "error_reporting", NULL, 159);
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_1);
zephir_bitwise_and_function(&_1, _0, severity TSRMLS_CC);
@@ -19506,9 +19731,9 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtLowSeverity) {
object_init_ex(_2, zephir_get_internal_ce(SS("errorexception") TSRMLS_CC));
ZEPHIR_INIT_VAR(_3);
ZVAL_LONG(_3, 0);
- ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 159, message, _3, severity, file, line);
+ ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 160, message, _3, severity, file, line);
zephir_check_call_status();
- zephir_throw_exception_debug(_2, "phalcon/debug.zep", 592 TSRMLS_CC);
+ zephir_throw_exception_debug(_2, "phalcon/debug.zep", 566 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -19531,7 +19756,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
- ZEPHIR_CALL_FUNCTION(&obLevel, "ob_get_level", NULL, 160);
+ ZEPHIR_CALL_FUNCTION(&obLevel, "ob_get_level", NULL, 161);
zephir_check_call_status();
if (ZEPHIR_GT_LONG(obLevel, 0)) {
ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118);
@@ -19591,21 +19816,21 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
ZEPHIR_CALL_METHOD(&_9, exception, "gettrace", NULL, 0);
zephir_check_call_status();
- zephir_is_iterable(_9, &_11, &_10, 0, 0, "phalcon/debug.zep", 686);
+ zephir_is_iterable(_9, &_11, &_10, 0, 0, "phalcon/debug.zep", 660);
for (
; zephir_hash_get_current_data_ex(_11, (void**) &_12, &_10) == SUCCESS
; zephir_hash_move_forward_ex(_11, &_10)
) {
ZEPHIR_GET_HMKEY(n, _11, _10);
ZEPHIR_GET_HVALUE(traceItem, _12);
- ZEPHIR_CALL_METHOD(&_13, this_ptr, "showtraceitem", &_14, 161, n, traceItem);
+ ZEPHIR_CALL_METHOD(&_13, this_ptr, "showtraceitem", &_14, 162, n, traceItem);
zephir_check_call_status();
zephir_concat_self(&html, _13 TSRMLS_CC);
}
zephir_concat_self_str(&html, SL(" ") TSRMLS_CC);
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
zephir_concat_self_str(&html, SL("Key | Value | ") TSRMLS_CC);
- zephir_is_iterable(_REQUEST, &_16, &_15, 0, 0, "phalcon/debug.zep", 700);
+ zephir_is_iterable(_REQUEST, &_16, &_15, 0, 0, "phalcon/debug.zep", 674);
for (
; zephir_hash_get_current_data_ex(_16, (void**) &_17, &_15) == SUCCESS
; zephir_hash_move_forward_ex(_16, &_15)
@@ -19617,7 +19842,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
ZEPHIR_CONCAT_SVSVS(_18, "", keyRequest, " | ", value, " | ");
zephir_concat_self(&html, _18 TSRMLS_CC);
} else {
- ZEPHIR_CALL_FUNCTION(&_13, "print_r", &_19, 162, value, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(&_13, "print_r", &_19, 163, value, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_18);
ZEPHIR_CONCAT_SVSVS(_18, "", keyRequest, " | ", _13, " | ");
@@ -19627,7 +19852,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
zephir_concat_self_str(&html, SL(" ") TSRMLS_CC);
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
zephir_concat_self_str(&html, SL("Key | Value | ") TSRMLS_CC);
- zephir_is_iterable(_SERVER, &_21, &_20, 0, 0, "phalcon/debug.zep", 710);
+ zephir_is_iterable(_SERVER, &_21, &_20, 0, 0, "phalcon/debug.zep", 684);
for (
; zephir_hash_get_current_data_ex(_21, (void**) &_22, &_20) == SUCCESS
; zephir_hash_move_forward_ex(_21, &_20)
@@ -19643,9 +19868,9 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
zephir_concat_self_str(&html, SL(" ") TSRMLS_CC);
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
zephir_concat_self_str(&html, SL("# | Path | ") TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_13, "get_included_files", NULL, 163);
+ ZEPHIR_CALL_FUNCTION(&_13, "get_included_files", NULL, 164);
zephir_check_call_status();
- zephir_is_iterable(_13, &_25, &_24, 0, 0, "phalcon/debug.zep", 720);
+ zephir_is_iterable(_13, &_25, &_24, 0, 0, "phalcon/debug.zep", 694);
for (
; zephir_hash_get_current_data_ex(_25, (void**) &_26, &_24) == SUCCESS
; zephir_hash_move_forward_ex(_25, &_24)
@@ -19658,7 +19883,7 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
}
zephir_concat_self_str(&html, SL(" ") TSRMLS_CC);
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_13, "memory_get_usage", NULL, 164, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(&_13, "memory_get_usage", NULL, 165, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_27);
ZEPHIR_CONCAT_SVS(_27, "Memory |
---|
Usage | ", _13, " | ");
@@ -19667,14 +19892,14 @@ static PHP_METHOD(Phalcon_Debug, onUncaughtException) {
if (Z_TYPE_P(dataVars) == IS_ARRAY) {
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
zephir_concat_self_str(&html, SL("Key | Value | ") TSRMLS_CC);
- zephir_is_iterable(dataVars, &_29, &_28, 0, 0, "phalcon/debug.zep", 738);
+ zephir_is_iterable(dataVars, &_29, &_28, 0, 0, "phalcon/debug.zep", 712);
for (
; zephir_hash_get_current_data_ex(_29, (void**) &_30, &_28) == SUCCESS
; zephir_hash_move_forward_ex(_29, &_28)
) {
ZEPHIR_GET_HMKEY(keyVar, _29, _28);
ZEPHIR_GET_HVALUE(dataVar, _30);
- zephir_array_fetch_long(&_32, dataVar, 0, PH_NOISY | PH_READONLY, "phalcon/debug.zep", 736 TSRMLS_CC);
+ zephir_array_fetch_long(&_32, dataVar, 0, PH_NOISY | PH_READONLY, "phalcon/debug.zep", 710 TSRMLS_CC);
ZEPHIR_CALL_METHOD(&_31, this_ptr, "_getvardump", &_23, 0, _32);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_33);
@@ -19835,7 +20060,7 @@ static PHP_METHOD(Phalcon_Di, setShared) {
static PHP_METHOD(Phalcon_Di, remove) {
- zval *name_param = NULL, *_0;
+ zval *name_param = NULL, *_0, *_1;
zval *name = NULL;
ZEPHIR_MM_GROW();
@@ -19856,6 +20081,8 @@ static PHP_METHOD(Phalcon_Di, remove) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_services"), PH_NOISY_CC);
zephir_array_unset(&_0, name, PH_SEPARATE);
+ _1 = zephir_fetch_nproperty_this(this_ptr, SL("_sharedInstances"), PH_NOISY_CC);
+ zephir_array_unset(&_1, name, PH_SEPARATE);
ZEPHIR_MM_RESTORE();
}
@@ -19963,7 +20190,7 @@ static PHP_METHOD(Phalcon_Di, getRaw) {
ZEPHIR_CONCAT_SVS(_2, "Service '", name, "' wasn't found in the dependency injection container");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/di.zep", 187 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/di.zep", 189 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -20002,7 +20229,7 @@ static PHP_METHOD(Phalcon_Di, getService) {
ZEPHIR_CONCAT_SVS(_2, "Service '", name, "' wasn't found in the dependency injection container");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/di.zep", 201 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/di.zep", 203 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -20060,7 +20287,7 @@ static PHP_METHOD(Phalcon_Di, get) {
ZEPHIR_CONCAT_SVS(_3, "Service '", name, "' wasn't found in the dependency injection container");
ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_2, "phalcon/di.zep", 227 TSRMLS_CC);
+ zephir_throw_exception_debug(_2, "phalcon/di.zep", 229 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -20383,7 +20610,7 @@ static PHP_METHOD(Phalcon_Di, __call) {
ZEPHIR_CONCAT_SVS(_5, "Call to undefined method or service '", method, "'");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _5);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/di.zep", 425 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/di.zep", 427 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -21419,13 +21646,13 @@ static PHP_METHOD(Phalcon_Escaper, detectEncoding) {
; zephir_hash_move_forward_ex(_3, &_2)
) {
ZEPHIR_GET_HVALUE(charset, _4);
- ZEPHIR_CALL_FUNCTION(&_5, "mb_detect_encoding", &_6, 177, str, charset, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(&_5, "mb_detect_encoding", &_6, 178, str, charset, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
if (zephir_is_true(_5)) {
RETURN_CCTOR(charset);
}
}
- ZEPHIR_RETURN_CALL_FUNCTION("mb_detect_encoding", &_6, 177, str);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_detect_encoding", &_6, 178, str);
zephir_check_call_status();
RETURN_MM();
@@ -21447,11 +21674,11 @@ static PHP_METHOD(Phalcon_Escaper, normalizeEncoding) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_escaper_exception_ce, "Extension 'mbstring' is required", "phalcon/escaper.zep", 128);
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "detectencoding", NULL, 178, str);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "detectencoding", NULL, 179, str);
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "UTF-32", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 179, str, &_1, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 180, str, &_1, _0);
zephir_check_call_status();
RETURN_MM();
@@ -21471,7 +21698,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeHtml) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_htmlQuoteType"), PH_NOISY_CC);
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_encoding"), PH_NOISY_CC);
- ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 180, text, _0, _1);
+ ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 181, text, _0, _1);
zephir_check_call_status();
RETURN_MM();
@@ -21492,7 +21719,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeHtmlAttr) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_encoding"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, 3);
- ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 180, attribute, &_1, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 181, attribute, &_1, _0);
zephir_check_call_status();
RETURN_MM();
@@ -21510,7 +21737,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeCss) {
zephir_get_strval(css, css_param);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 181, css);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 182, css);
zephir_check_call_status();
zephir_escape_css(return_value, _0);
RETURN_MM();
@@ -21529,7 +21756,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeJs) {
zephir_get_strval(js, js_param);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 181, js);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 182, js);
zephir_check_call_status();
zephir_escape_js(return_value, _0);
RETURN_MM();
@@ -21548,7 +21775,7 @@ static PHP_METHOD(Phalcon_Escaper, escapeUrl) {
zephir_get_strval(url, url_param);
- ZEPHIR_RETURN_CALL_FUNCTION("rawurlencode", NULL, 182, url);
+ ZEPHIR_RETURN_CALL_FUNCTION("rawurlencode", NULL, 183, url);
zephir_check_call_status();
RETURN_MM();
@@ -21827,16 +22054,16 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) {
if (ZEPHIR_IS_STRING(filter, "email")) {
ZEPHIR_SINIT_VAR(_3);
ZVAL_STRING(&_3, "FILTER_SANITIZE_EMAIL", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 189, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 190, &_3);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 190, value, _4);
+ ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, _4);
zephir_check_call_status();
RETURN_MM();
}
if (ZEPHIR_IS_STRING(filter, "int")) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 519);
- ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 190, value, &_3);
+ ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3);
zephir_check_call_status();
RETURN_MM();
}
@@ -21846,14 +22073,14 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) {
if (ZEPHIR_IS_STRING(filter, "absint")) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, zephir_get_intval(value));
- ZEPHIR_RETURN_CALL_FUNCTION("abs", NULL, 191, &_3);
+ ZEPHIR_RETURN_CALL_FUNCTION("abs", NULL, 192, &_3);
zephir_check_call_status();
RETURN_MM();
}
if (ZEPHIR_IS_STRING(filter, "string")) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 513);
- ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 190, value, &_3);
+ ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3);
zephir_check_call_status();
RETURN_MM();
}
@@ -21863,7 +22090,7 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) {
add_assoc_long_ex(_2, SS("flags"), 4096);
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 520);
- ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 190, value, &_3, _2);
+ ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3, _2);
zephir_check_call_status();
RETURN_MM();
}
@@ -21886,13 +22113,13 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) {
RETURN_MM();
}
if (ZEPHIR_IS_STRING(filter, "striptags")) {
- ZEPHIR_RETURN_CALL_FUNCTION("strip_tags", NULL, 192, value);
+ ZEPHIR_RETURN_CALL_FUNCTION("strip_tags", NULL, 193, value);
zephir_check_call_status();
RETURN_MM();
}
if (ZEPHIR_IS_STRING(filter, "lower")) {
if ((zephir_function_exists_ex(SS("mb_strtolower") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 193, value);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 194, value);
zephir_check_call_status();
RETURN_MM();
}
@@ -21901,7 +22128,7 @@ static PHP_METHOD(Phalcon_Filter, _sanitize) {
}
if (ZEPHIR_IS_STRING(filter, "upper")) {
if ((zephir_function_exists_ex(SS("mb_strtoupper") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 194, value);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 195, value);
zephir_check_call_status();
RETURN_MM();
}
@@ -22682,7 +22909,7 @@ static PHP_METHOD(Phalcon_Loader, register) {
ZEPHIR_INIT_VAR(_2);
ZVAL_STRING(_2, "autoLoad", 1);
zephir_array_fast_append(_1, _2);
- ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_register", NULL, 292, _1);
+ ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_register", NULL, 293, _1);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_registered"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
}
@@ -22706,7 +22933,7 @@ static PHP_METHOD(Phalcon_Loader, unregister) {
ZEPHIR_INIT_VAR(_2);
ZVAL_STRING(_2, "autoLoad", 1);
zephir_array_fast_append(_1, _2);
- ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_unregister", NULL, 293, _1);
+ ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_unregister", NULL, 294, _1);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_registered"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
}
@@ -22814,7 +23041,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) {
zephir_check_temp_parameter(_9);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 294, filePath);
+ ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath);
zephir_check_call_status();
if (zephir_is_true(_11)) {
if (Z_TYPE_P(eventsManager) == IS_OBJECT) {
@@ -22885,7 +23112,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) {
zephir_check_temp_parameter(_9);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 294, filePath);
+ ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath);
zephir_check_call_status();
if (zephir_is_true(_11)) {
if (Z_TYPE_P(eventsManager) == IS_OBJECT) {
@@ -22943,7 +23170,7 @@ static PHP_METHOD(Phalcon_Loader, autoLoad) {
zephir_check_temp_parameter(_9);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 294, filePath);
+ ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath);
zephir_check_call_status();
if (zephir_is_true(_11)) {
if (Z_TYPE_P(eventsManager) == IS_OBJECT) {
@@ -23196,7 +23423,7 @@ static PHP_METHOD(Phalcon_Registry, next) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_CALL_FUNCTION(NULL, "next", NULL, 397, _0);
+ ZEPHIR_CALL_FUNCTION(NULL, "next", NULL, 399, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -23212,7 +23439,7 @@ static PHP_METHOD(Phalcon_Registry, key) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_RETURN_CALL_FUNCTION("key", NULL, 398, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("key", NULL, 400, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
RETURN_MM();
@@ -23228,7 +23455,7 @@ static PHP_METHOD(Phalcon_Registry, rewind) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_CALL_FUNCTION(NULL, "reset", NULL, 399, _0);
+ ZEPHIR_CALL_FUNCTION(NULL, "reset", NULL, 401, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -23244,7 +23471,7 @@ static PHP_METHOD(Phalcon_Registry, valid) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_CALL_FUNCTION(&_1, "key", NULL, 398, _0);
+ ZEPHIR_CALL_FUNCTION(&_1, "key", NULL, 400, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
RETURN_MM_BOOL(Z_TYPE_P(_1) != IS_NULL);
@@ -23260,7 +23487,7 @@ static PHP_METHOD(Phalcon_Registry, current) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_RETURN_CALL_FUNCTION("current", NULL, 400, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("current", NULL, 402, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
RETURN_MM();
@@ -23289,7 +23516,7 @@ static PHP_METHOD(Phalcon_Registry, __set) {
}
- ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetset", NULL, 401, key, value);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetset", NULL, 403, key, value);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -23317,7 +23544,7 @@ static PHP_METHOD(Phalcon_Registry, __get) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetget", NULL, 402, key);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetget", NULL, 404, key);
zephir_check_call_status();
RETURN_MM();
@@ -23345,7 +23572,7 @@ static PHP_METHOD(Phalcon_Registry, __isset) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetexists", NULL, 403, key);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetexists", NULL, 405, key);
zephir_check_call_status();
RETURN_MM();
@@ -23373,7 +23600,7 @@ static PHP_METHOD(Phalcon_Registry, __unset) {
}
- ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetunset", NULL, 404, key);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetunset", NULL, 406, key);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -23529,7 +23756,7 @@ static PHP_METHOD(Phalcon_Security, getSaltBytes) {
ZEPHIR_INIT_NVAR(safeBytes);
ZEPHIR_INIT_NVAR(_1);
ZVAL_LONG(_1, numberBytes);
- ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", &_3, 405, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", &_3, 407, _1);
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&_4, "base64_encode", &_5, 112, _2);
zephir_check_call_status();
@@ -23621,7 +23848,7 @@ static PHP_METHOD(Phalcon_Security, hash) {
}
ZEPHIR_INIT_VAR(_3);
ZEPHIR_CONCAT_SVSV(_3, "$", variant, "$", saltBytes);
- ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 406, password, _3);
+ ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 408, password, _3);
zephir_check_call_status();
RETURN_MM();
}
@@ -23644,11 +23871,11 @@ static PHP_METHOD(Phalcon_Security, hash) {
ZVAL_STRING(&_5, "%02s", 0);
ZEPHIR_SINIT_VAR(_6);
ZVAL_LONG(&_6, workFactor);
- ZEPHIR_CALL_FUNCTION(&_7, "sprintf", NULL, 186, &_5, &_6);
+ ZEPHIR_CALL_FUNCTION(&_7, "sprintf", NULL, 187, &_5, &_6);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_3);
ZEPHIR_CONCAT_SVSVSV(_3, "$2", variant, "$", _7, "$", saltBytes);
- ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 406, password, _3);
+ ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 408, password, _3);
zephir_check_call_status();
RETURN_MM();
} while(0);
@@ -23688,7 +23915,7 @@ static PHP_METHOD(Phalcon_Security, checkHash) {
RETURN_MM_BOOL(0);
}
}
- ZEPHIR_CALL_FUNCTION(&_1, "crypt", NULL, 406, password, passwordHash);
+ ZEPHIR_CALL_FUNCTION(&_1, "crypt", NULL, 408, password, passwordHash);
zephir_check_call_status();
zephir_get_strval(_2, _1);
ZEPHIR_CPY_WRT(cryptedHash, _2);
@@ -23752,7 +23979,7 @@ static PHP_METHOD(Phalcon_Security, getTokenKey) {
ZEPHIR_INIT_VAR(safeBytes);
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, numberBytes);
- ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", NULL, 405, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", NULL, 407, _1);
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&_3, "base64_encode", NULL, 112, _2);
zephir_check_call_status();
@@ -23794,7 +24021,7 @@ static PHP_METHOD(Phalcon_Security, getToken) {
}
ZEPHIR_INIT_VAR(_0);
ZVAL_LONG(_0, numberBytes);
- ZEPHIR_CALL_FUNCTION(&token, "openssl_random_pseudo_bytes", NULL, 405, _0);
+ ZEPHIR_CALL_FUNCTION(&token, "openssl_random_pseudo_bytes", NULL, 407, _0);
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&_1, "base64_encode", NULL, 112, token);
zephir_check_call_status();
@@ -23967,7 +24194,7 @@ static PHP_METHOD(Phalcon_Security, computeHmac) {
}
- ZEPHIR_CALL_FUNCTION(&hmac, "hash_hmac", NULL, 407, algo, data, key, (raw ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_FUNCTION(&hmac, "hash_hmac", NULL, 409, algo, data, key, (raw ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
if (!(zephir_is_true(hmac))) {
ZEPHIR_INIT_VAR(_0);
@@ -24758,7 +24985,7 @@ static PHP_METHOD(Phalcon_Tag, colorField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "color", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24778,7 +25005,7 @@ static PHP_METHOD(Phalcon_Tag, textField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "text", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24798,7 +25025,7 @@ static PHP_METHOD(Phalcon_Tag, numericField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "number", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24818,7 +25045,7 @@ static PHP_METHOD(Phalcon_Tag, rangeField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "range", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24838,7 +25065,7 @@ static PHP_METHOD(Phalcon_Tag, emailField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "email", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24858,7 +25085,7 @@ static PHP_METHOD(Phalcon_Tag, dateField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "date", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24878,7 +25105,7 @@ static PHP_METHOD(Phalcon_Tag, dateTimeField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "datetime", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24898,7 +25125,7 @@ static PHP_METHOD(Phalcon_Tag, dateTimeLocalField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "datetime-local", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24918,7 +25145,7 @@ static PHP_METHOD(Phalcon_Tag, monthField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "month", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24938,7 +25165,7 @@ static PHP_METHOD(Phalcon_Tag, timeField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "time", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24958,7 +25185,7 @@ static PHP_METHOD(Phalcon_Tag, weekField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "week", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24978,7 +25205,7 @@ static PHP_METHOD(Phalcon_Tag, passwordField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "password", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -24998,7 +25225,7 @@ static PHP_METHOD(Phalcon_Tag, hiddenField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "hidden", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25018,7 +25245,7 @@ static PHP_METHOD(Phalcon_Tag, fileField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "file", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25038,7 +25265,7 @@ static PHP_METHOD(Phalcon_Tag, searchField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "search", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25058,7 +25285,7 @@ static PHP_METHOD(Phalcon_Tag, telField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "tel", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25078,7 +25305,7 @@ static PHP_METHOD(Phalcon_Tag, urlField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "url", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25098,7 +25325,7 @@ static PHP_METHOD(Phalcon_Tag, checkField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "checkbox", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 412, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 414, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25118,7 +25345,7 @@ static PHP_METHOD(Phalcon_Tag, radioField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "radio", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 412, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 414, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25140,7 +25367,7 @@ static PHP_METHOD(Phalcon_Tag, imageInput) {
ZVAL_STRING(_1, "image", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_2);
ZVAL_BOOL(_2, 1);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters, _2);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters, _2);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25162,7 +25389,7 @@ static PHP_METHOD(Phalcon_Tag, submitButton) {
ZVAL_STRING(_1, "submit", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_2);
ZVAL_BOOL(_2, 1);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters, _2);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters, _2);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -25183,7 +25410,7 @@ static PHP_METHOD(Phalcon_Tag, selectStatic) {
}
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 205, parameters, data);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, parameters, data);
zephir_check_call_status();
RETURN_MM();
@@ -25203,7 +25430,7 @@ static PHP_METHOD(Phalcon_Tag, select) {
}
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 205, parameters, data);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, parameters, data);
zephir_check_call_status();
RETURN_MM();
@@ -25714,13 +25941,13 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_VAR(_3);
ZVAL_STRING(&_3, "en_US.UTF-8", 0);
- ZEPHIR_CALL_FUNCTION(&locale, "setlocale", &_4, 413, &_0, &_3);
+ ZEPHIR_CALL_FUNCTION(&locale, "setlocale", &_4, 415, &_0, &_3);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "UTF-8", 0);
ZEPHIR_SINIT_NVAR(_3);
ZVAL_STRING(&_3, "ASCII//TRANSLIT", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "iconv", NULL, 376, &_0, &_3, text);
+ ZEPHIR_CALL_FUNCTION(&_5, "iconv", NULL, 378, &_0, &_3, text);
zephir_check_call_status();
zephir_get_strval(text, _5);
}
@@ -25783,7 +26010,7 @@ static PHP_METHOD(Phalcon_Tag, friendlyTitle) {
if (zephir_is_true(_5)) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 0);
- ZEPHIR_CALL_FUNCTION(NULL, "setlocale", &_4, 413, &_3, locale);
+ ZEPHIR_CALL_FUNCTION(NULL, "setlocale", &_4, 415, &_3, locale);
zephir_check_call_status();
}
RETURN_CCTOR(friendly);
@@ -26090,24 +26317,21 @@ static PHP_METHOD(Phalcon_Text, uncamelize) {
static PHP_METHOD(Phalcon_Text, increment) {
- zval *str_param = NULL, *separator = NULL, *parts, *number = NULL, *_0;
- zval *str = NULL;
+ zval *str_param = NULL, *separator_param = NULL, *parts, *number = NULL, *_0;
+ zval *str = NULL, *separator = NULL;
ZEPHIR_MM_GROW();
- zephir_fetch_params(1, 1, 1, &str_param, &separator);
+ zephir_fetch_params(1, 1, 1, &str_param, &separator_param);
zephir_get_strval(str, str_param);
- if (!separator) {
- ZEPHIR_CPY_WRT(separator, ZEPHIR_GLOBAL(global_null));
+ if (!separator_param) {
+ ZEPHIR_INIT_VAR(separator);
+ ZVAL_STRING(separator, "_", 1);
} else {
- ZEPHIR_SEPARATE_PARAM(separator);
+ zephir_get_strval(separator, separator_param);
}
- if (Z_TYPE_P(separator) == IS_NULL) {
- ZEPHIR_INIT_NVAR(separator);
- ZVAL_STRING(separator, "_", 1);
- }
ZEPHIR_INIT_VAR(parts);
zephir_fast_explode(parts, separator, str, LONG_MAX TSRMLS_CC);
ZEPHIR_OBS_VAR(number);
@@ -26118,7 +26342,7 @@ static PHP_METHOD(Phalcon_Text, increment) {
ZEPHIR_INIT_NVAR(number);
ZVAL_LONG(number, 1);
}
- zephir_array_fetch_long(&_0, parts, 0, PH_NOISY | PH_READONLY, "phalcon/text.zep", 88 TSRMLS_CC);
+ zephir_array_fetch_long(&_0, parts, 0, PH_NOISY | PH_READONLY, "phalcon/text.zep", 84 TSRMLS_CC);
ZEPHIR_CONCAT_VVV(return_value, _0, separator, number);
RETURN_MM();
@@ -26154,13 +26378,13 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_STRING(&_0, "a", 0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "z", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "A", 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "Z", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_INIT_VAR(pool);
zephir_fast_array_merge(pool, &(_2), &(_4) TSRMLS_CC);
@@ -26171,13 +26395,13 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 9);
- ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "a", 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "f", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(pool);
zephir_fast_array_merge(pool, &(_2), &(_4) TSRMLS_CC);
@@ -26188,7 +26412,7 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 9);
- ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
break;
}
@@ -26197,7 +26421,7 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 1);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 9);
- ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
break;
}
@@ -26205,21 +26429,21 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 9);
- ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "a", 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "z", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "A", 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "Z", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_5, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&pool, "array_merge", &_6, 417, _2, _4, _5);
+ ZEPHIR_CALL_FUNCTION(&pool, "array_merge", &_6, 419, _2, _4, _5);
zephir_check_call_status();
break;
} while(0);
@@ -26233,7 +26457,7 @@ static PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, end);
- zephir_array_fetch_long(&_7, pool, zephir_mt_rand(zephir_get_intval(&_0), zephir_get_intval(&_1) TSRMLS_CC), PH_NOISY | PH_READONLY, "phalcon/text.zep", 130 TSRMLS_CC);
+ zephir_array_fetch_long(&_7, pool, zephir_mt_rand(zephir_get_intval(&_0), zephir_get_intval(&_1) TSRMLS_CC), PH_NOISY | PH_READONLY, "phalcon/text.zep", 126 TSRMLS_CC);
zephir_concat_self(&str, _7 TSRMLS_CC);
}
RETURN_CCTOR(str);
@@ -26323,7 +26547,7 @@ static PHP_METHOD(Phalcon_Text, lower) {
if ((zephir_function_exists_ex(SS("mb_strtolower") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 193, str, encoding);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 194, str, encoding);
zephir_check_call_status();
RETURN_MM();
}
@@ -26371,7 +26595,7 @@ static PHP_METHOD(Phalcon_Text, upper) {
if ((zephir_function_exists_ex(SS("mb_strtoupper") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 194, str, encoding);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 195, str, encoding);
zephir_check_call_status();
RETURN_MM();
}
@@ -26416,26 +26640,26 @@ static PHP_METHOD(Phalcon_Text, concat) {
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, 0);
- ZEPHIR_CALL_FUNCTION(&separator, "func_get_arg", &_1, 418, &_0);
+ ZEPHIR_CALL_FUNCTION(&separator, "func_get_arg", &_1, 420, &_0);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, 1);
- ZEPHIR_CALL_FUNCTION(&a, "func_get_arg", &_1, 418, &_0);
+ ZEPHIR_CALL_FUNCTION(&a, "func_get_arg", &_1, 420, &_0);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, 2);
- ZEPHIR_CALL_FUNCTION(&b, "func_get_arg", &_1, 418, &_0);
+ ZEPHIR_CALL_FUNCTION(&b, "func_get_arg", &_1, 420, &_0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_2, "func_num_args", NULL, 419);
+ ZEPHIR_CALL_FUNCTION(&_2, "func_num_args", NULL, 421);
zephir_check_call_status();
if (ZEPHIR_GT_LONG(_2, 3)) {
- ZEPHIR_CALL_FUNCTION(&_3, "func_get_args", NULL, 165);
+ ZEPHIR_CALL_FUNCTION(&_3, "func_get_args", NULL, 166);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, 3);
- ZEPHIR_CALL_FUNCTION(&_4, "array_slice", NULL, 377, _3, &_0);
+ ZEPHIR_CALL_FUNCTION(&_4, "array_slice", NULL, 379, _3, &_0);
zephir_check_call_status();
- zephir_is_iterable(_4, &_6, &_5, 0, 0, "phalcon/text.zep", 246);
+ zephir_is_iterable(_4, &_6, &_5, 0, 0, "phalcon/text.zep", 242);
for (
; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS
; zephir_hash_move_forward_ex(_6, &_5)
@@ -26530,36 +26754,36 @@ static PHP_METHOD(Phalcon_Text, dynamic) {
}
- ZEPHIR_CALL_FUNCTION(&_0, "substr_count", &_1, 420, text, leftDelimiter);
+ ZEPHIR_CALL_FUNCTION(&_0, "substr_count", &_1, 422, text, leftDelimiter);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_2, "substr_count", &_1, 420, text, rightDelimiter);
+ ZEPHIR_CALL_FUNCTION(&_2, "substr_count", &_1, 422, text, rightDelimiter);
zephir_check_call_status();
if (!ZEPHIR_IS_IDENTICAL(_0, _2)) {
ZEPHIR_INIT_VAR(_3);
object_init_ex(_3, spl_ce_RuntimeException);
ZEPHIR_INIT_VAR(_4);
ZEPHIR_CONCAT_SVS(_4, "Syntax error in string \"", text, "\"");
- ZEPHIR_CALL_METHOD(NULL, _3, "__construct", NULL, 421, _4);
+ ZEPHIR_CALL_METHOD(NULL, _3, "__construct", NULL, 423, _4);
zephir_check_call_status();
- zephir_throw_exception_debug(_3, "phalcon/text.zep", 265 TSRMLS_CC);
+ zephir_throw_exception_debug(_3, "phalcon/text.zep", 261 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_CALL_FUNCTION(&ld_s, "preg_quote", &_5, 422, leftDelimiter);
+ ZEPHIR_CALL_FUNCTION(&ld_s, "preg_quote", &_5, 424, leftDelimiter);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&rd_s, "preg_quote", &_5, 422, rightDelimiter);
+ ZEPHIR_CALL_FUNCTION(&rd_s, "preg_quote", &_5, 424, rightDelimiter);
zephir_check_call_status();
ZEPHIR_INIT_VAR(pattern);
ZEPHIR_CONCAT_SVSVVSVS(pattern, "/", ld_s, "([^", ld_s, rd_s, "]+)", rd_s, "/");
ZEPHIR_CPY_WRT(result, text);
while (1) {
- if (!(zephir_memnstr(result, leftDelimiter, "phalcon/text.zep", 273))) {
+ if (!(zephir_memnstr(result, leftDelimiter, "phalcon/text.zep", 269))) {
break;
}
ZEPHIR_INIT_NVAR(_3);
ZEPHIR_INIT_NVAR(_3);
zephir_create_closure_ex(_3, NULL, phalcon_0__closure_ce, SS("__invoke") TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_6, "preg_replace_callback", &_7, 423, pattern, _3, result);
+ ZEPHIR_CALL_FUNCTION(&_6, "preg_replace_callback", &_7, 425, pattern, _3, result);
zephir_check_call_status();
ZEPHIR_CPY_WRT(result, _6);
}
@@ -27223,7 +27447,7 @@ static PHP_METHOD(Phalcon_Version, _getVersion) {
ZVAL_LONG(_0, 0);
zephir_array_fast_append(return_value, _0);
ZEPHIR_INIT_NVAR(_0);
- ZVAL_LONG(_0, 5);
+ ZVAL_LONG(_0, 6);
zephir_array_fast_append(return_value, _0);
ZEPHIR_INIT_NVAR(_0);
ZVAL_LONG(_0, 4);
@@ -27292,7 +27516,7 @@ static PHP_METHOD(Phalcon_Version, get) {
zephir_array_fetch_long(&specialNumber, version, 4, PH_NOISY, "phalcon/version.zep", 128 TSRMLS_CC);
ZEPHIR_INIT_VAR(result);
ZEPHIR_CONCAT_VSVSVS(result, major, ".", medium, ".", minor, " ");
- ZEPHIR_CALL_STATIC(&suffix, "_getspecial", &_0, 437, special);
+ ZEPHIR_CALL_STATIC(&suffix, "_getspecial", &_0, 441, special);
zephir_check_call_status();
if (!ZEPHIR_IS_STRING(suffix, "")) {
ZEPHIR_INIT_VAR(_1);
@@ -27326,11 +27550,11 @@ static PHP_METHOD(Phalcon_Version, getId) {
zephir_array_fetch_long(&specialNumber, version, 4, PH_NOISY, "phalcon/version.zep", 158 TSRMLS_CC);
ZEPHIR_SINIT_VAR(_0);
ZVAL_STRING(&_0, "%02s", 0);
- ZEPHIR_CALL_FUNCTION(&_1, "sprintf", &_2, 186, &_0, medium);
+ ZEPHIR_CALL_FUNCTION(&_1, "sprintf", &_2, 187, &_0, medium);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "%02s", 0);
- ZEPHIR_CALL_FUNCTION(&_3, "sprintf", &_2, 186, &_0, minor);
+ ZEPHIR_CALL_FUNCTION(&_3, "sprintf", &_2, 187, &_0, minor);
zephir_check_call_status();
ZEPHIR_CONCAT_VVVVV(return_value, major, _1, _3, special, specialNumber);
RETURN_MM();
@@ -27359,7 +27583,7 @@ static PHP_METHOD(Phalcon_Version, getPart) {
}
if (part == 3) {
zephir_array_fetch_long(&_1, version, 3, PH_NOISY | PH_READONLY, "phalcon/version.zep", 187 TSRMLS_CC);
- ZEPHIR_CALL_STATIC(&result, "_getspecial", &_0, 437, _1);
+ ZEPHIR_CALL_STATIC(&result, "_getspecial", &_0, 441, _1);
zephir_check_call_status();
break;
}
@@ -36858,7 +37082,7 @@ static PHP_METHOD(Phalcon_Cache_Backend_Libmemcached, save) {
int ZEPHIR_LAST_CALL_STATUS;
zend_bool stopBuffer;
- zval *keyName = NULL, *content = NULL, *lifetime = NULL, *stopBuffer_param = NULL, *lastKey = NULL, *frontend, *memcache = NULL, *cachedContent = NULL, *preparedContent = NULL, *tmp, *tt1 = NULL, *success = NULL, *options, *specialKey, *keys = NULL, *isBuffering = NULL, *_0;
+ zval *keyName = NULL, *content = NULL, *lifetime = NULL, *stopBuffer_param = NULL, *lastKey = NULL, *frontend, *memcache = NULL, *cachedContent = NULL, *preparedContent = NULL, *tmp, *tt1 = NULL, *success = NULL, *options, *specialKey, *keys = NULL, *isBuffering = NULL, *_0, *_1, *_2 = NULL, *_3;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 0, 4, &keyName, &content, &lifetime, &stopBuffer_param);
@@ -36931,7 +37155,16 @@ static PHP_METHOD(Phalcon_Cache_Backend_Libmemcached, save) {
zephir_check_call_status();
}
if (!(zephir_is_true(success))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "Failed storing data in memcached", "phalcon/cache/backend/libmemcached.zep", 223);
+ ZEPHIR_INIT_VAR(_1);
+ object_init_ex(_1, phalcon_cache_exception_ce);
+ ZEPHIR_CALL_METHOD(&_2, memcache, "getresultcode", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_INIT_VAR(_3);
+ ZEPHIR_CONCAT_SV(_3, "Failed storing data in memcached, error code: ", _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3);
+ zephir_check_call_status();
+ zephir_throw_exception_debug(_1, "phalcon/cache/backend/libmemcached.zep", 223 TSRMLS_CC);
+ ZEPHIR_MM_RESTORE();
return;
}
ZEPHIR_OBS_VAR(options);
@@ -43122,7 +43355,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, fetchAll) {
if (!(zephir_is_true(row))) {
break;
}
- zephir_array_append(&results, row, PH_SEPARATE, "phalcon/db/adapter.zep", 249);
+ zephir_array_append(&results, row, PH_SEPARATE, "phalcon/db/adapter.zep", 243);
}
}
RETURN_CCTOR(results);
@@ -43192,7 +43425,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, insert) {
ZEPHIR_CONCAT_SVS(_1, "Unable to insert into ", table, " without data");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _1);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/db/adapter.zep", 317 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/db/adapter.zep", 312 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -43202,7 +43435,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, insert) {
array_init(insertValues);
ZEPHIR_INIT_VAR(bindDataTypes);
array_init(bindDataTypes);
- zephir_is_iterable(values, &_3, &_2, 0, 0, "phalcon/db/adapter.zep", 347);
+ zephir_is_iterable(values, &_3, &_2, 0, 0, "phalcon/db/adapter.zep", 342);
for (
; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS
; zephir_hash_move_forward_ex(_3, &_2)
@@ -43211,24 +43444,24 @@ static PHP_METHOD(Phalcon_Db_Adapter, insert) {
ZEPHIR_GET_HVALUE(value, _4);
if (Z_TYPE_P(value) == IS_OBJECT) {
zephir_get_strval(_5, value);
- zephir_array_append(&placeholders, _5, PH_SEPARATE, "phalcon/db/adapter.zep", 330);
+ zephir_array_append(&placeholders, _5, PH_SEPARATE, "phalcon/db/adapter.zep", 325);
} else {
if (Z_TYPE_P(value) == IS_NULL) {
ZEPHIR_INIT_NVAR(_0);
ZVAL_STRING(_0, "null", 1);
- zephir_array_append(&placeholders, _0, PH_SEPARATE, "phalcon/db/adapter.zep", 333);
+ zephir_array_append(&placeholders, _0, PH_SEPARATE, "phalcon/db/adapter.zep", 328);
} else {
ZEPHIR_INIT_NVAR(_0);
ZVAL_STRING(_0, "?", 1);
- zephir_array_append(&placeholders, _0, PH_SEPARATE, "phalcon/db/adapter.zep", 335);
- zephir_array_append(&insertValues, value, PH_SEPARATE, "phalcon/db/adapter.zep", 336);
+ zephir_array_append(&placeholders, _0, PH_SEPARATE, "phalcon/db/adapter.zep", 330);
+ zephir_array_append(&insertValues, value, PH_SEPARATE, "phalcon/db/adapter.zep", 331);
if (Z_TYPE_P(dataTypes) == IS_ARRAY) {
ZEPHIR_OBS_NVAR(bindType);
if (!(zephir_array_isset_fetch(&bindType, dataTypes, position, 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Incomplete number of bind types", "phalcon/db/adapter.zep", 339);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Incomplete number of bind types", "phalcon/db/adapter.zep", 334);
return;
}
- zephir_array_append(&bindDataTypes, bindType, PH_SEPARATE, "phalcon/db/adapter.zep", 341);
+ zephir_array_append(&bindDataTypes, bindType, PH_SEPARATE, "phalcon/db/adapter.zep", 336);
}
}
}
@@ -43246,7 +43479,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, insert) {
if (ZEPHIR_GLOBAL(db).escape_identifiers) {
ZEPHIR_INIT_VAR(escapedFields);
array_init(escapedFields);
- zephir_is_iterable(fields, &_7, &_6, 0, 0, "phalcon/db/adapter.zep", 364);
+ zephir_is_iterable(fields, &_7, &_6, 0, 0, "phalcon/db/adapter.zep", 359);
for (
; zephir_hash_get_current_data_ex(_7, (void**) &_8, &_6) == SUCCESS
; zephir_hash_move_forward_ex(_7, &_6)
@@ -43254,7 +43487,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, insert) {
ZEPHIR_GET_HVALUE(field, _8);
ZEPHIR_CALL_METHOD(&_9, this_ptr, "escapeidentifier", &_10, 0, field);
zephir_check_call_status();
- zephir_array_append(&escapedFields, _9, PH_SEPARATE, "phalcon/db/adapter.zep", 362);
+ zephir_array_append(&escapedFields, _9, PH_SEPARATE, "phalcon/db/adapter.zep", 357);
}
} else {
ZEPHIR_CPY_WRT(escapedFields, fields);
@@ -43303,15 +43536,15 @@ static PHP_METHOD(Phalcon_Db_Adapter, insertAsDict) {
if (_0) {
RETURN_MM_BOOL(0);
}
- zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/db/adapter.zep", 419);
+ zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/db/adapter.zep", 414);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
) {
ZEPHIR_GET_HMKEY(field, _2, _1);
ZEPHIR_GET_HVALUE(value, _3);
- zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/db/adapter.zep", 415);
- zephir_array_append(&values, value, PH_SEPARATE, "phalcon/db/adapter.zep", 416);
+ zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/db/adapter.zep", 410);
+ zephir_array_append(&values, value, PH_SEPARATE, "phalcon/db/adapter.zep", 411);
}
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "insert", NULL, 0, table, values, fields, dataTypes);
zephir_check_call_status();
@@ -43344,7 +43577,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, update) {
array_init(updateValues);
ZEPHIR_INIT_VAR(bindDataTypes);
array_init(bindDataTypes);
- zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/db/adapter.zep", 505);
+ zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/db/adapter.zep", 500);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -43353,7 +43586,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, update) {
ZEPHIR_GET_HVALUE(value, _2);
ZEPHIR_OBS_NVAR(field);
if (!(zephir_array_isset_fetch(&field, fields, position, 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The number of values in the update is not the same as fields", "phalcon/db/adapter.zep", 478);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The number of values in the update is not the same as fields", "phalcon/db/adapter.zep", 473);
return;
}
if (ZEPHIR_GLOBAL(db).escape_identifiers) {
@@ -43365,25 +43598,25 @@ static PHP_METHOD(Phalcon_Db_Adapter, update) {
if (Z_TYPE_P(value) == IS_OBJECT) {
ZEPHIR_INIT_LNVAR(_4);
ZEPHIR_CONCAT_VSV(_4, escapedField, " = ", value);
- zephir_array_append(&placeholders, _4, PH_SEPARATE, "phalcon/db/adapter.zep", 488);
+ zephir_array_append(&placeholders, _4, PH_SEPARATE, "phalcon/db/adapter.zep", 483);
} else {
if (Z_TYPE_P(value) == IS_NULL) {
ZEPHIR_INIT_LNVAR(_4);
ZEPHIR_CONCAT_VS(_4, escapedField, " = null");
- zephir_array_append(&placeholders, _4, PH_SEPARATE, "phalcon/db/adapter.zep", 491);
+ zephir_array_append(&placeholders, _4, PH_SEPARATE, "phalcon/db/adapter.zep", 486);
} else {
- zephir_array_append(&updateValues, value, PH_SEPARATE, "phalcon/db/adapter.zep", 493);
+ zephir_array_append(&updateValues, value, PH_SEPARATE, "phalcon/db/adapter.zep", 488);
if (Z_TYPE_P(dataTypes) == IS_ARRAY) {
ZEPHIR_OBS_NVAR(bindType);
if (!(zephir_array_isset_fetch(&bindType, dataTypes, position, 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Incomplete number of bind types", "phalcon/db/adapter.zep", 496);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Incomplete number of bind types", "phalcon/db/adapter.zep", 491);
return;
}
- zephir_array_append(&bindDataTypes, bindType, PH_SEPARATE, "phalcon/db/adapter.zep", 498);
+ zephir_array_append(&bindDataTypes, bindType, PH_SEPARATE, "phalcon/db/adapter.zep", 493);
}
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_VS(_5, escapedField, " = ?");
- zephir_array_append(&placeholders, _5, PH_SEPARATE, "phalcon/db/adapter.zep", 500);
+ zephir_array_append(&placeholders, _5, PH_SEPARATE, "phalcon/db/adapter.zep", 495);
}
}
}
@@ -43402,7 +43635,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, update) {
zephir_concat_self(&updateSql, whereCondition TSRMLS_CC);
} else {
if (Z_TYPE_P(whereCondition) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Invalid WHERE clause conditions", "phalcon/db/adapter.zep", 528);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Invalid WHERE clause conditions", "phalcon/db/adapter.zep", 523);
return;
}
ZEPHIR_OBS_VAR(conditions);
@@ -43462,15 +43695,15 @@ static PHP_METHOD(Phalcon_Db_Adapter, updateAsDict) {
if (_0) {
RETURN_MM_BOOL(0);
}
- zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/db/adapter.zep", 604);
+ zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/db/adapter.zep", 599);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
) {
ZEPHIR_GET_HMKEY(field, _2, _1);
ZEPHIR_GET_HVALUE(value, _3);
- zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/db/adapter.zep", 600);
- zephir_array_append(&values, value, PH_SEPARATE, "phalcon/db/adapter.zep", 601);
+ zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/db/adapter.zep", 595);
+ zephir_array_append(&values, value, PH_SEPARATE, "phalcon/db/adapter.zep", 596);
}
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "update", NULL, 0, table, fields, values, whereCondition, dataTypes);
zephir_check_call_status();
@@ -43609,7 +43842,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, tableExists) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchone", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_array_fetch_long(&_4, _0, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 681 TSRMLS_CC);
+ zephir_array_fetch_long(&_4, _0, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 676 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_GT_LONG(_4, 0));
}
@@ -43659,7 +43892,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, viewExists) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchone", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_array_fetch_long(&_4, _0, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 693 TSRMLS_CC);
+ zephir_array_fetch_long(&_4, _0, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 688 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_GT_LONG(_4, 0));
}
@@ -43760,11 +43993,11 @@ static PHP_METHOD(Phalcon_Db_Adapter, createTable) {
ZEPHIR_OBS_VAR(columns);
if (!(zephir_array_isset_string_fetch(&columns, definition, SS("columns"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 720);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 715);
return;
}
if (!(zephir_fast_count_int(columns TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 724);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 719);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dialect"), PH_NOISY_CC);
@@ -43858,7 +44091,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, createView) {
if (!(zephir_array_isset_string(definition, SS("sql")))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 749);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 739);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dialect"), PH_NOISY_CC);
@@ -44371,14 +44604,14 @@ static PHP_METHOD(Phalcon_Db_Adapter, listTables) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchall", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 858);
+ zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 848);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
) {
ZEPHIR_GET_HVALUE(table, _6);
- zephir_array_fetch_long(&_7, table, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 856 TSRMLS_CC);
- zephir_array_append(&allTables, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 856);
+ zephir_array_fetch_long(&_7, table, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 846 TSRMLS_CC);
+ zephir_array_append(&allTables, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 846);
}
RETURN_CCTOR(allTables);
@@ -44422,14 +44655,14 @@ static PHP_METHOD(Phalcon_Db_Adapter, listViews) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchall", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 876);
+ zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 866);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
) {
ZEPHIR_GET_HVALUE(table, _6);
- zephir_array_fetch_long(&_7, table, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 874 TSRMLS_CC);
- zephir_array_append(&allTables, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 874);
+ zephir_array_fetch_long(&_7, table, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 864 TSRMLS_CC);
+ zephir_array_append(&allTables, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 864);
}
RETURN_CCTOR(allTables);
@@ -44472,27 +44705,27 @@ static PHP_METHOD(Phalcon_Db_Adapter, describeIndexes) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchall", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 908);
+ zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 898);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
) {
ZEPHIR_GET_HVALUE(index, _6);
- zephir_array_fetch_long(&keyName, index, 2, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 897 TSRMLS_CC);
+ zephir_array_fetch_long(&keyName, index, 2, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 887 TSRMLS_CC);
if (!(zephir_array_isset(indexes, keyName))) {
ZEPHIR_INIT_NVAR(columns);
array_init(columns);
} else {
ZEPHIR_OBS_NVAR(columns);
- zephir_array_fetch(&columns, indexes, keyName, PH_NOISY, "phalcon/db/adapter.zep", 901 TSRMLS_CC);
+ zephir_array_fetch(&columns, indexes, keyName, PH_NOISY, "phalcon/db/adapter.zep", 891 TSRMLS_CC);
}
- zephir_array_fetch_long(&_7, index, 4, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 904 TSRMLS_CC);
- zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 904);
+ zephir_array_fetch_long(&_7, index, 4, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 894 TSRMLS_CC);
+ zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 894);
zephir_array_update_zval(&indexes, keyName, &columns, PH_COPY | PH_SEPARATE);
}
ZEPHIR_INIT_VAR(indexObjects);
array_init(indexObjects);
- zephir_is_iterable(indexes, &_9, &_8, 0, 0, "phalcon/db/adapter.zep", 917);
+ zephir_is_iterable(indexes, &_9, &_8, 0, 0, "phalcon/db/adapter.zep", 907);
for (
; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS
; zephir_hash_move_forward_ex(_9, &_8)
@@ -44560,40 +44793,40 @@ static PHP_METHOD(Phalcon_Db_Adapter, describeReferences) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchall", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 961);
+ zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 951);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
) {
ZEPHIR_GET_HVALUE(reference, _6);
- zephir_array_fetch_long(&constraintName, reference, 2, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 937 TSRMLS_CC);
+ zephir_array_fetch_long(&constraintName, reference, 2, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 927 TSRMLS_CC);
if (!(zephir_array_isset(references, constraintName))) {
ZEPHIR_OBS_NVAR(referencedSchema);
- zephir_array_fetch_long(&referencedSchema, reference, 3, PH_NOISY, "phalcon/db/adapter.zep", 939 TSRMLS_CC);
+ zephir_array_fetch_long(&referencedSchema, reference, 3, PH_NOISY, "phalcon/db/adapter.zep", 929 TSRMLS_CC);
ZEPHIR_OBS_NVAR(referencedTable);
- zephir_array_fetch_long(&referencedTable, reference, 4, PH_NOISY, "phalcon/db/adapter.zep", 940 TSRMLS_CC);
+ zephir_array_fetch_long(&referencedTable, reference, 4, PH_NOISY, "phalcon/db/adapter.zep", 930 TSRMLS_CC);
ZEPHIR_INIT_NVAR(columns);
array_init(columns);
ZEPHIR_INIT_NVAR(referencedColumns);
array_init(referencedColumns);
} else {
- zephir_array_fetch(&_7, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 944 TSRMLS_CC);
+ zephir_array_fetch(&_7, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 934 TSRMLS_CC);
ZEPHIR_OBS_NVAR(referencedSchema);
- zephir_array_fetch_string(&referencedSchema, _7, SL("referencedSchema"), PH_NOISY, "phalcon/db/adapter.zep", 944 TSRMLS_CC);
- zephir_array_fetch(&_8, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 945 TSRMLS_CC);
+ zephir_array_fetch_string(&referencedSchema, _7, SL("referencedSchema"), PH_NOISY, "phalcon/db/adapter.zep", 934 TSRMLS_CC);
+ zephir_array_fetch(&_8, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 935 TSRMLS_CC);
ZEPHIR_OBS_NVAR(referencedTable);
- zephir_array_fetch_string(&referencedTable, _8, SL("referencedTable"), PH_NOISY, "phalcon/db/adapter.zep", 945 TSRMLS_CC);
- zephir_array_fetch(&_9, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 946 TSRMLS_CC);
+ zephir_array_fetch_string(&referencedTable, _8, SL("referencedTable"), PH_NOISY, "phalcon/db/adapter.zep", 935 TSRMLS_CC);
+ zephir_array_fetch(&_9, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 936 TSRMLS_CC);
ZEPHIR_OBS_NVAR(columns);
- zephir_array_fetch_string(&columns, _9, SL("columns"), PH_NOISY, "phalcon/db/adapter.zep", 946 TSRMLS_CC);
- zephir_array_fetch(&_10, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 947 TSRMLS_CC);
+ zephir_array_fetch_string(&columns, _9, SL("columns"), PH_NOISY, "phalcon/db/adapter.zep", 936 TSRMLS_CC);
+ zephir_array_fetch(&_10, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 937 TSRMLS_CC);
ZEPHIR_OBS_NVAR(referencedColumns);
- zephir_array_fetch_string(&referencedColumns, _10, SL("referencedColumns"), PH_NOISY, "phalcon/db/adapter.zep", 947 TSRMLS_CC);
+ zephir_array_fetch_string(&referencedColumns, _10, SL("referencedColumns"), PH_NOISY, "phalcon/db/adapter.zep", 937 TSRMLS_CC);
}
- zephir_array_fetch_long(&_7, reference, 1, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 950 TSRMLS_CC);
- zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 950);
- zephir_array_fetch_long(&_8, reference, 5, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 951 TSRMLS_CC);
- zephir_array_append(&referencedColumns, _8, PH_SEPARATE, "phalcon/db/adapter.zep", 951);
+ zephir_array_fetch_long(&_7, reference, 1, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 940 TSRMLS_CC);
+ zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 940);
+ zephir_array_fetch_long(&_8, reference, 5, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 941 TSRMLS_CC);
+ zephir_array_append(&referencedColumns, _8, PH_SEPARATE, "phalcon/db/adapter.zep", 941);
ZEPHIR_INIT_NVAR(_11);
zephir_create_array(_11, 4, 0 TSRMLS_CC);
zephir_array_update_string(&_11, SL("referencedSchema"), &referencedSchema, PH_COPY | PH_SEPARATE);
@@ -44604,7 +44837,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, describeReferences) {
}
ZEPHIR_INIT_VAR(referenceObjects);
array_init(referenceObjects);
- zephir_is_iterable(references, &_13, &_12, 0, 0, "phalcon/db/adapter.zep", 971);
+ zephir_is_iterable(references, &_13, &_12, 0, 0, "phalcon/db/adapter.zep", 961);
for (
; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS
; zephir_hash_move_forward_ex(_13, &_12)
@@ -44616,16 +44849,16 @@ static PHP_METHOD(Phalcon_Db_Adapter, describeReferences) {
ZEPHIR_INIT_NVAR(_11);
zephir_create_array(_11, 4, 0 TSRMLS_CC);
ZEPHIR_OBS_NVAR(_15);
- zephir_array_fetch_string(&_15, arrayReference, SL("referencedSchema"), PH_NOISY, "phalcon/db/adapter.zep", 964 TSRMLS_CC);
+ zephir_array_fetch_string(&_15, arrayReference, SL("referencedSchema"), PH_NOISY, "phalcon/db/adapter.zep", 954 TSRMLS_CC);
zephir_array_update_string(&_11, SL("referencedSchema"), &_15, PH_COPY | PH_SEPARATE);
ZEPHIR_OBS_NVAR(_15);
- zephir_array_fetch_string(&_15, arrayReference, SL("referencedTable"), PH_NOISY, "phalcon/db/adapter.zep", 965 TSRMLS_CC);
+ zephir_array_fetch_string(&_15, arrayReference, SL("referencedTable"), PH_NOISY, "phalcon/db/adapter.zep", 955 TSRMLS_CC);
zephir_array_update_string(&_11, SL("referencedTable"), &_15, PH_COPY | PH_SEPARATE);
ZEPHIR_OBS_NVAR(_15);
- zephir_array_fetch_string(&_15, arrayReference, SL("columns"), PH_NOISY, "phalcon/db/adapter.zep", 966 TSRMLS_CC);
+ zephir_array_fetch_string(&_15, arrayReference, SL("columns"), PH_NOISY, "phalcon/db/adapter.zep", 956 TSRMLS_CC);
zephir_array_update_string(&_11, SL("columns"), &_15, PH_COPY | PH_SEPARATE);
ZEPHIR_OBS_NVAR(_15);
- zephir_array_fetch_string(&_15, arrayReference, SL("referencedColumns"), PH_NOISY, "phalcon/db/adapter.zep", 968 TSRMLS_CC);
+ zephir_array_fetch_string(&_15, arrayReference, SL("referencedColumns"), PH_NOISY, "phalcon/db/adapter.zep", 958 TSRMLS_CC);
zephir_array_update_string(&_11, SL("referencedColumns"), &_15, PH_COPY | PH_SEPARATE);
ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_16, 16, name, _11);
zephir_check_call_status();
@@ -44671,7 +44904,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, tableOptions) {
ZVAL_LONG(_2, 2);
ZEPHIR_CALL_METHOD(&_1, this_ptr, "fetchall", NULL, 0, sql, _2);
zephir_check_call_status();
- zephir_array_fetch_long(&_3, _1, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 987 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, _1, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 977 TSRMLS_CC);
RETURN_CTOR(_3);
}
array_init(return_value);
@@ -44706,7 +44939,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, createSavepoint) {
ZEPHIR_CALL_METHOD(&_0, dialect, "supportssavepoints", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_0))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter.", "phalcon/db/adapter.zep", 1002);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter.", "phalcon/db/adapter.zep", 992);
return;
}
ZEPHIR_CALL_METHOD(&_1, dialect, "createsavepoint", NULL, 0, name);
@@ -44744,7 +44977,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, releaseSavepoint) {
ZEPHIR_CALL_METHOD(&_0, dialect, "supportssavepoints", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_0))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1018);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1008);
return;
}
ZEPHIR_CALL_METHOD(&_1, dialect, "supportsreleasesavepoints", NULL, 0);
@@ -44787,7 +45020,7 @@ static PHP_METHOD(Phalcon_Db_Adapter, rollbackSavepoint) {
ZEPHIR_CALL_METHOD(&_0, dialect, "supportssavepoints", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_0))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1038);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1028);
return;
}
ZEPHIR_CALL_METHOD(&_1, dialect, "rollbacksavepoint", NULL, 0, name);
@@ -44812,14 +45045,14 @@ static PHP_METHOD(Phalcon_Db_Adapter, setNestedTransactionsWithSavepoints) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_transactionLevel"), PH_NOISY_CC);
if (ZEPHIR_GT_LONG(_0, 0)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Nested transaction with savepoints behavior cannot be changed while a transaction is open", "phalcon/db/adapter.zep", 1051);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Nested transaction with savepoints behavior cannot be changed while a transaction is open", "phalcon/db/adapter.zep", 1041);
return;
}
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_dialect"), PH_NOISY_CC);
ZEPHIR_CALL_METHOD(&_2, _1, "supportssavepoints", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_2))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1055);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1045);
return;
}
zephir_update_property_this(this_ptr, SL("_transactionsWithSavepoints"), nestedTransactionsWithSavepoints ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
@@ -47020,11 +47253,10 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionGroupBy) {
if (unlikely(Z_TYPE_P(filed) != IS_ARRAY)) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Invalid SQL-GROUP-BY expression", "phalcon/db/dialect.zep", 829);
return;
- } else {
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqlexpression", &_4, 0, filed, escapeChar, bindCounts);
- zephir_check_call_status();
- zephir_array_append(&fields, _3, PH_SEPARATE, "phalcon/db/dialect.zep", 831);
}
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqlexpression", &_4, 0, filed, escapeChar, bindCounts);
+ zephir_check_call_status();
+ zephir_array_append(&fields, _3, PH_SEPARATE, "phalcon/db/dialect.zep", 832);
}
ZEPHIR_INIT_VAR(_5);
zephir_fast_join_str(_5, SL(", "), fields TSRMLS_CC);
@@ -47106,11 +47338,10 @@ static PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionOrderBy) {
if (unlikely(Z_TYPE_P(filed) != IS_ARRAY)) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Invalid SQL-ORDER-BY expression", "phalcon/db/dialect.zep", 870);
return;
- } else {
- zephir_array_fetch_long(&_3, filed, 0, PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 872 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&fieldSql, this_ptr, "getsqlexpression", &_4, 0, _3, escapeChar, bindCounts);
- zephir_check_call_status();
}
+ zephir_array_fetch_long(&_3, filed, 0, PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 873 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&fieldSql, this_ptr, "getsqlexpression", &_4, 0, _3, escapeChar, bindCounts);
+ zephir_check_call_status();
ZEPHIR_OBS_NVAR(type);
_5 = zephir_array_isset_long_fetch(&type, filed, 1, 0 TSRMLS_CC);
if (_5) {
@@ -47659,19 +47890,19 @@ static PHP_METHOD(Phalcon_Db_Profiler, startProfile) {
ZEPHIR_CALL_METHOD(NULL, activeProfile, "__construct", NULL, 0);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlstatement", NULL, 143, sqlStatement);
+ ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlstatement", NULL, 144, sqlStatement);
zephir_check_call_status();
if (Z_TYPE_P(sqlVariables) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlvariables", NULL, 144, sqlVariables);
+ ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlvariables", NULL, 145, sqlVariables);
zephir_check_call_status();
}
if (Z_TYPE_P(sqlBindTypes) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlbindtypes", NULL, 145, sqlBindTypes);
+ ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlbindtypes", NULL, 146, sqlBindTypes);
zephir_check_call_status();
}
ZEPHIR_INIT_VAR(_0);
zephir_microtime(_0, ZEPHIR_GLOBAL(global_true) TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, activeProfile, "setinitialtime", NULL, 146, _0);
+ ZEPHIR_CALL_METHOD(NULL, activeProfile, "setinitialtime", NULL, 147, _0);
zephir_check_call_status();
if ((zephir_method_exists_ex(this_ptr, SS("beforestartprofile") TSRMLS_CC) == SUCCESS)) {
ZEPHIR_CALL_METHOD(NULL, this_ptr, "beforestartprofile", NULL, 0, activeProfile);
@@ -50756,15 +50987,14 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) {
if (zephir_is_true(size)) {
ZEPHIR_CALL_METHOD(&scale, column, "getscale", NULL, 0);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_1);
- ZEPHIR_CONCAT_SV(_1, "(", size);
- zephir_concat_self(&columnSql, _1 TSRMLS_CC);
if (zephir_is_true(scale)) {
+ ZEPHIR_INIT_LNVAR(_1);
+ ZEPHIR_CONCAT_SVSVS(_1, "(", size, ",", scale, ")");
+ zephir_concat_self(&columnSql, _1 TSRMLS_CC);
+ } else {
ZEPHIR_INIT_VAR(_4);
- ZEPHIR_CONCAT_SVS(_4, ",", scale, ")");
+ ZEPHIR_CONCAT_SVS(_4, "(", size, ")");
zephir_concat_self(&columnSql, _4 TSRMLS_CC);
- } else {
- zephir_concat_self_str(&columnSql, SL(")") TSRMLS_CC);
}
}
ZEPHIR_CALL_METHOD(&_0, column, "isunsigned", NULL, 0);
@@ -50846,7 +51076,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) {
break;
}
if (ZEPHIR_IS_EMPTY(columnSql)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Unrecognized MySQL data type", "phalcon/db/dialect/mysql.zep", 192);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Unrecognized MySQL data type", "phalcon/db/dialect/mysql.zep", 191);
return;
}
ZEPHIR_CALL_METHOD(&typeValues, column, "gettypevalues", NULL, 0);
@@ -50855,7 +51085,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) {
if (Z_TYPE_P(typeValues) == IS_ARRAY) {
ZEPHIR_INIT_VAR(valueSql);
ZVAL_STRING(valueSql, "", 1);
- zephir_is_iterable(typeValues, &_6, &_5, 0, 0, "phalcon/db/dialect/mysql.zep", 203);
+ zephir_is_iterable(typeValues, &_6, &_5, 0, 0, "phalcon/db/dialect/mysql.zep", 202);
for (
; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS
; zephir_hash_move_forward_ex(_6, &_5)
@@ -50897,8 +51127,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addColumn) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *afterPosition = NULL, *sql = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *afterPosition = NULL, *sql, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, _3, *_4 = NULL, *_5 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &column);
@@ -50927,50 +51157,41 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addColumn) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` ADD ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` ADD ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumndefinition", NULL, 0, column);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVSV(_3, "`", _1, "` ", _2);
- zephir_concat_self(&sql, _3 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(sql);
+ ZEPHIR_CONCAT_SVSVSV(sql, "ALTER TABLE ", _0, " ADD `", _1, "` ", _2);
ZEPHIR_CALL_METHOD(&defaultValue, column, "getdefault", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(defaultValue))) {
- ZEPHIR_SINIT_VAR(_4);
- ZVAL_STRING(&_4, "\"", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 141, defaultValue, &_4);
+ ZEPHIR_SINIT_VAR(_3);
+ ZVAL_STRING(&_3, "\"", 0);
+ ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 141, defaultValue, &_3);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_6);
- ZEPHIR_CONCAT_SVS(_6, " DEFAULT \"", _5, "\"");
- zephir_concat_self(&sql, _6 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_5);
+ ZEPHIR_CONCAT_SVS(_5, " DEFAULT \"", _4, "\"");
+ zephir_concat_self(&sql, _5 TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_5, column, "isnotnull", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, column, "isnotnull", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_5)) {
+ if (zephir_is_true(_4)) {
zephir_concat_self_str(&sql, SL(" NOT NULL") TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_5, column, "isfirst", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, column, "isfirst", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_5)) {
+ if (zephir_is_true(_4)) {
zephir_concat_self_str(&sql, SL(" FIRST") TSRMLS_CC);
} else {
ZEPHIR_CALL_METHOD(&afterPosition, column, "getafterposition", NULL, 0);
zephir_check_call_status();
if (zephir_is_true(afterPosition)) {
- ZEPHIR_INIT_LNVAR(_6);
- ZEPHIR_CONCAT_SV(_6, " AFTER ", afterPosition);
- zephir_concat_self(&sql, _6 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_5);
+ ZEPHIR_CONCAT_SV(_5, " AFTER ", afterPosition);
+ zephir_concat_self(&sql, _5 TSRMLS_CC);
}
}
RETURN_CCTOR(sql);
@@ -50980,8 +51201,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addColumn) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, modifyColumn) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *currentColumn = NULL, *sql = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *currentColumn = NULL, *sql, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, _3, *_4 = NULL, *_5;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 1, &tableName_param, &schemaName_param, &column, ¤tColumn);
@@ -51013,37 +51234,28 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, modifyColumn) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` MODIFY ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` MODIFY ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumndefinition", NULL, 0, column);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVSV(_3, "`", _1, "` ", _2);
- zephir_concat_self(&sql, _3 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(sql);
+ ZEPHIR_CONCAT_SVSVSV(sql, "ALTER TABLE ", _0, " MODIFY `", _1, "` ", _2);
ZEPHIR_CALL_METHOD(&defaultValue, column, "getdefault", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(defaultValue))) {
- ZEPHIR_SINIT_VAR(_4);
- ZVAL_STRING(&_4, "\"", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 141, defaultValue, &_4);
+ ZEPHIR_SINIT_VAR(_3);
+ ZVAL_STRING(&_3, "\"", 0);
+ ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 141, defaultValue, &_3);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_6);
- ZEPHIR_CONCAT_SVS(_6, " DEFAULT \"", _5, "\"");
- zephir_concat_self(&sql, _6 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_5);
+ ZEPHIR_CONCAT_SVS(_5, " DEFAULT \"", _4, "\"");
+ zephir_concat_self(&sql, _5 TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_5, column, "isnotnull", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, column, "isnotnull", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_5)) {
+ if (zephir_is_true(_4)) {
zephir_concat_self_str(&sql, SL(" NOT NULL") TSRMLS_CC);
}
RETURN_CCTOR(sql);
@@ -51052,8 +51264,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, modifyColumn) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropColumn) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *columnName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *columnName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *columnName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *columnName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &columnName_param);
@@ -51093,28 +51306,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropColumn) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` DROP COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` DROP COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", columnName, "`");
- zephir_concat_self(&sql, _0 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP COLUMN `", columnName, "`");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addIndex) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql = NULL, *indexType = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql, *indexType = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
@@ -51143,24 +51346,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addIndex) {
}
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSV(_0, "ALTER TABLE `", schemaName, "`.`", tableName);
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SV(_0, "ALTER TABLE `", tableName);
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CONCAT_SV(sql, "ALTER TABLE ", _0);
ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(indexType))) {
ZEPHIR_INIT_VAR(_1);
- ZEPHIR_CONCAT_SVS(_1, "` ADD ", indexType, " INDEX ");
+ ZEPHIR_CONCAT_SVS(_1, " ADD ", indexType, " INDEX ");
zephir_concat_self(&sql, _1 TSRMLS_CC);
} else {
- zephir_concat_self_str(&sql, SL("` ADD INDEX ") TSRMLS_CC);
+ zephir_concat_self_str(&sql, SL(" ADD INDEX ") TSRMLS_CC);
}
ZEPHIR_CALL_METHOD(&_2, index, "getname", NULL, 0);
zephir_check_call_status();
@@ -51177,8 +51374,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addIndex) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropIndex) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *indexName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *indexName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *indexName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *indexName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &indexName_param);
@@ -51218,28 +51416,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropIndex) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` DROP INDEX ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` DROP INDEX ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", indexName, "`");
- zephir_concat_self(&sql, _0 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP INDEX `", indexName, "`");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addPrimaryKey) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql = NULL, *_1 = NULL, *_2 = NULL, *_3;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *index, *_0 = NULL, *_1 = NULL, *_2 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
@@ -51268,31 +51456,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addPrimaryKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` ADD PRIMARY KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` ADD PRIMARY KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 43, _2);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVS(_3, "(", _1, ")");
- zephir_concat_self(&sql, _3 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " ADD PRIMARY KEY (", _1, ")");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropPrimaryKey) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 0, &tableName_param, &schemaName_param);
@@ -51321,25 +51500,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropPrimaryKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` DROP PRIMARY KEY");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` DROP PRIMARY KEY");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVS(return_value, "ALTER TABLE ", _0, " DROP PRIMARY KEY");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *reference, *sql = NULL, *referencedSchema = NULL, *onDelete = NULL, *onUpdate = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *reference, *sql, *onDelete = NULL, *onUpdate = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &reference);
@@ -51368,41 +51540,26 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` ADD FOREIGN KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` ADD FOREIGN KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, reference, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_3, reference, "getcolumns", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 43, _3);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_4);
- ZEPHIR_CONCAT_SVSVS(_4, "`", _1, "`(", _2, ") REFERENCES ");
- zephir_concat_self(&sql, _4 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&referencedSchema, reference, "getreferencedschema", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_5, reference, "getreferencedtable", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(referencedSchema)) {
- ZEPHIR_INIT_VAR(_5);
- ZEPHIR_CONCAT_SVS(_5, "`", referencedSchema, "`.");
- zephir_concat_self(&sql, _5 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_6, reference, "getreferencedtable", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_6, reference, "getreferencedschema", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "preparetable", NULL, 0, _5, _6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_8, reference, "getreferencedcolumns", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", NULL, 43, _8);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_5);
- ZEPHIR_CONCAT_SVSVS(_5, "`", _6, "`(", _7, ")");
- zephir_concat_self(&sql, _5 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(sql);
+ ZEPHIR_CONCAT_SVSVSVSVSVS(sql, "ALTER TABLE ", _0, " ADD FOREIGN KEY `", _1, "`(", _2, ") REFERENCES ", _4, "(", _7, ")");
ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onDelete))) {
@@ -51413,9 +51570,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) {
ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onUpdate))) {
- ZEPHIR_INIT_LNVAR(_5);
- ZEPHIR_CONCAT_SV(_5, " ON UPDATE ", onUpdate);
- zephir_concat_self(&sql, _5 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SV(_9, " ON UPDATE ", onUpdate);
+ zephir_concat_self(&sql, _9 TSRMLS_CC);
}
RETURN_CCTOR(sql);
@@ -51423,8 +51580,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropForeignKey) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *referenceName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *referenceName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *referenceName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *referenceName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &referenceName_param);
@@ -51464,30 +51622,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropForeignKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` DROP FOREIGN KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` DROP FOREIGN KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_CONCAT_VSVS(return_value, sql, "`", referenceName, "`");
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP FOREIGN KEY `", referenceName, "`");
RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) {
- zephir_fcall_cache_entry *_6 = NULL, *_9 = NULL, *_14 = NULL;
+ zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_13 = NULL;
+ HashTable *_1, *_11, *_17;
+ HashPosition _0, _10, _16;
int ZEPHIR_LAST_CALL_STATUS;
- HashTable *_2, *_12, *_18;
- HashPosition _1, _11, _17;
zval *definition = NULL;
- zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, **_3, *_4 = NULL, *_5 = NULL, _7 = zval_used_for_init, *_8 = NULL, *_10 = NULL, **_13, *_15 = NULL, *_16 = NULL, **_19, *_20 = NULL, *_21 = NULL, *_22;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, **_2, *_3 = NULL, *_4 = NULL, _6 = zval_used_for_init, *_7 = NULL, *_9 = NULL, **_12, *_14 = NULL, *_15 = NULL, **_18, *_19 = NULL, *_20 = NULL, *_21;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &definition_param);
@@ -51520,19 +51670,11 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) {
ZEPHIR_OBS_VAR(columns);
if (!(zephir_array_isset_string_fetch(&columns, definition, SS("columns"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'columns' is required in the definition array", "phalcon/db/dialect/mysql.zep", 424);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'columns' is required in the definition array", "phalcon/db/dialect/mysql.zep", 354);
return;
}
- ZEPHIR_INIT_VAR(table);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "`", schemaName, "`.`", tableName, "`");
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", tableName, "`");
- ZEPHIR_CPY_WRT(table, _0);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(temporary);
ZVAL_BOOL(temporary, 0);
ZEPHIR_OBS_VAR(options);
@@ -51548,134 +51690,134 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) {
}
ZEPHIR_INIT_VAR(createLines);
array_init(createLines);
- zephir_is_iterable(columns, &_2, &_1, 0, 0, "phalcon/db/dialect/mysql.zep", 487);
+ zephir_is_iterable(columns, &_1, &_0, 0, 0, "phalcon/db/dialect/mysql.zep", 413);
for (
- ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
- ; zephir_hash_move_forward_ex(_2, &_1)
+ ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
+ ; zephir_hash_move_forward_ex(_1, &_0)
) {
- ZEPHIR_GET_HVALUE(column, _3);
- ZEPHIR_CALL_METHOD(&_4, column, "getname", NULL, 0);
+ ZEPHIR_GET_HVALUE(column, _2);
+ ZEPHIR_CALL_METHOD(&_3, column, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumndefinition", &_6, 0, column);
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumndefinition", &_5, 0, column);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(columnLine);
- ZEPHIR_CONCAT_SVSV(columnLine, "`", _4, "` ", _5);
+ ZEPHIR_CONCAT_SVSV(columnLine, "`", _3, "` ", _4);
ZEPHIR_CALL_METHOD(&defaultValue, column, "getdefault", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(defaultValue))) {
- ZEPHIR_SINIT_NVAR(_7);
- ZVAL_STRING(&_7, "\"", 0);
- ZEPHIR_CALL_FUNCTION(&_8, "addcslashes", &_9, 141, defaultValue, &_7);
+ ZEPHIR_SINIT_NVAR(_6);
+ ZVAL_STRING(&_6, "\"", 0);
+ ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 141, defaultValue, &_6);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SVS(_10, " DEFAULT \"", _8, "\"");
- zephir_concat_self(&columnLine, _10 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, " DEFAULT \"", _7, "\"");
+ zephir_concat_self(&columnLine, _9 TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isnotnull", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isnotnull", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
zephir_concat_self_str(&columnLine, SL(" NOT NULL") TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isautoincrement", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isautoincrement", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
zephir_concat_self_str(&columnLine, SL(" AUTO_INCREMENT") TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isprimary", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isprimary", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
zephir_concat_self_str(&columnLine, SL(" PRIMARY KEY") TSRMLS_CC);
}
- zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 481);
+ zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 407);
}
ZEPHIR_OBS_VAR(indexes);
if (zephir_array_isset_string_fetch(&indexes, definition, SS("indexes"), 0 TSRMLS_CC)) {
- zephir_is_iterable(indexes, &_12, &_11, 0, 0, "phalcon/db/dialect/mysql.zep", 509);
+ zephir_is_iterable(indexes, &_11, &_10, 0, 0, "phalcon/db/dialect/mysql.zep", 435);
for (
- ; zephir_hash_get_current_data_ex(_12, (void**) &_13, &_11) == SUCCESS
- ; zephir_hash_move_forward_ex(_12, &_11)
+ ; zephir_hash_get_current_data_ex(_11, (void**) &_12, &_10) == SUCCESS
+ ; zephir_hash_move_forward_ex(_11, &_10)
) {
- ZEPHIR_GET_HVALUE(index, _13);
+ ZEPHIR_GET_HVALUE(index, _12);
ZEPHIR_CALL_METHOD(&indexName, index, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
zephir_check_call_status();
if (ZEPHIR_IS_STRING(indexName, "PRIMARY")) {
- ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_14, 43, _5);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_13, 43, _4);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(indexSql);
- ZEPHIR_CONCAT_SVS(indexSql, "PRIMARY KEY (", _4, ")");
+ ZEPHIR_CONCAT_SVS(indexSql, "PRIMARY KEY (", _3, ")");
} else {
ZEPHIR_INIT_NVAR(indexSql);
if (!(ZEPHIR_IS_EMPTY(indexType))) {
- ZEPHIR_CALL_METHOD(&_15, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_14, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, this_ptr, "getcolumnlist", &_14, 43, _15);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_13, 43, _14);
zephir_check_call_status();
- ZEPHIR_CONCAT_VSVSVS(indexSql, indexType, " KEY `", indexName, "` (", _8, ")");
+ ZEPHIR_CONCAT_VSVSVS(indexSql, indexType, " KEY `", indexName, "` (", _7, ")");
} else {
- ZEPHIR_CALL_METHOD(&_16, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_15, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", &_14, 43, _16);
+ ZEPHIR_CALL_METHOD(&_14, this_ptr, "getcolumnlist", &_13, 43, _15);
zephir_check_call_status();
- ZEPHIR_CONCAT_SVSVS(indexSql, "KEY `", indexName, "` (", _15, ")");
+ ZEPHIR_CONCAT_SVSVS(indexSql, "KEY `", indexName, "` (", _14, ")");
}
}
- zephir_array_append(&createLines, indexSql, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 507);
+ zephir_array_append(&createLines, indexSql, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 433);
}
}
ZEPHIR_OBS_VAR(references);
if (zephir_array_isset_string_fetch(&references, definition, SS("references"), 0 TSRMLS_CC)) {
- zephir_is_iterable(references, &_18, &_17, 0, 0, "phalcon/db/dialect/mysql.zep", 531);
+ zephir_is_iterable(references, &_17, &_16, 0, 0, "phalcon/db/dialect/mysql.zep", 457);
for (
- ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS
- ; zephir_hash_move_forward_ex(_18, &_17)
+ ; zephir_hash_get_current_data_ex(_17, (void**) &_18, &_16) == SUCCESS
+ ; zephir_hash_move_forward_ex(_17, &_16)
) {
- ZEPHIR_GET_HVALUE(reference, _19);
- ZEPHIR_CALL_METHOD(&_4, reference, "getname", NULL, 0);
+ ZEPHIR_GET_HVALUE(reference, _18);
+ ZEPHIR_CALL_METHOD(&_3, reference, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, reference, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, reference, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", &_14, 43, _8);
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_13, 43, _7);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_15, reference, "getreferencedtable", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_14, reference, "getreferencedtable", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_20, reference, "getreferencedcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_19, reference, "getreferencedcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_16, this_ptr, "getcolumnlist", &_14, 43, _20);
+ ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", &_13, 43, _19);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(referenceSql);
- ZEPHIR_CONCAT_SVSVSSVSVS(referenceSql, "CONSTRAINT `", _4, "` FOREIGN KEY (", _5, ")", " REFERENCES `", _15, "`(", _16, ")");
+ ZEPHIR_CONCAT_SVSVSSVSVS(referenceSql, "CONSTRAINT `", _3, "` FOREIGN KEY (", _4, ")", " REFERENCES `", _14, "`(", _15, ")");
ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onDelete))) {
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SV(_10, " ON DELETE ", onDelete);
- zephir_concat_self(&referenceSql, _10 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SV(_9, " ON DELETE ", onDelete);
+ zephir_concat_self(&referenceSql, _9 TSRMLS_CC);
}
ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onUpdate))) {
- ZEPHIR_INIT_LNVAR(_21);
- ZEPHIR_CONCAT_SV(_21, " ON UPDATE ", onUpdate);
- zephir_concat_self(&referenceSql, _21 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_20);
+ ZEPHIR_CONCAT_SV(_20, " ON UPDATE ", onUpdate);
+ zephir_concat_self(&referenceSql, _20 TSRMLS_CC);
}
- zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 529);
+ zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 455);
}
}
- ZEPHIR_INIT_VAR(_22);
- zephir_fast_join_str(_22, SL(",\n\t"), createLines TSRMLS_CC);
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_VS(_10, _22, "\n)");
- zephir_concat_self(&sql, _10 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_21);
+ zephir_fast_join_str(_21, SL(",\n\t"), createLines TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_VS(_9, _21, "\n)");
+ zephir_concat_self(&sql, _9 TSRMLS_CC);
if (zephir_array_isset_string(definition, SS("options"))) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "_gettableoptions", NULL, 0, definition);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_gettableoptions", NULL, 0, definition);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_21);
- ZEPHIR_CONCAT_SV(_21, " ", _4);
- zephir_concat_self(&sql, _21 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_20);
+ ZEPHIR_CONCAT_SV(_20, " ", _3);
+ zephir_concat_self(&sql, _20 TSRMLS_CC);
}
RETURN_CCTOR(sql);
@@ -51683,9 +51825,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropTable) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *sql, *table = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &tableName_param, &schemaName_param, &ifExists_param);
@@ -51719,16 +51862,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropTable) {
}
- ZEPHIR_INIT_VAR(table);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "`", schemaName, "`.`", tableName, "`");
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", tableName, "`");
- ZEPHIR_CPY_WRT(table, _0);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
ZEPHIR_CONCAT_SV(sql, "DROP TABLE IF EXISTS ", table);
@@ -51741,9 +51876,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropTable) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zval *definition = NULL;
- zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *view = NULL, *viewSql;
- zval *viewName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *_0 = NULL;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 1, &viewName_param, &definition_param, &schemaName_param);
@@ -51771,29 +51907,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, createView) {
ZEPHIR_OBS_VAR(viewSql);
if (!(zephir_array_isset_string_fetch(&viewSql, definition, SS("sql"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/mysql.zep", 571);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/mysql.zep", 493);
return;
}
- ZEPHIR_INIT_VAR(view);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "`", schemaName, "`.`", viewName, "`");
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", viewName, "`");
- ZEPHIR_CPY_WRT(view, _0);
- }
- ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", view, " AS ", viewSql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", _0, " AS ", viewSql);
RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *sql, *view = NULL;
- zval *viewName = NULL, *schemaName = NULL, *_0;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &viewName_param, &schemaName_param, &ifExists_param);
@@ -51827,13 +51956,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropView) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_VSV(_0, schemaName, ".", viewName);
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_CPY_WRT(view, viewName);
- }
+ ZEPHIR_CALL_METHOD(&view, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
ZEPHIR_CONCAT_SV(sql, "DROP VIEW IF EXISTS ", view);
@@ -51918,7 +52042,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, viewExists) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, describeColumns) {
- zval *table_param = NULL, *schema_param = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *table_param = NULL, *schema_param = NULL, *_0 = NULL;
zval *table = NULL, *schema = NULL;
ZEPHIR_MM_GROW();
@@ -51943,11 +52068,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, describeColumns) {
}
- if (schema && Z_STRLEN_P(schema)) {
- ZEPHIR_CONCAT_SVSVS(return_value, "DESCRIBE `", schema, "`.`", table, "`");
- RETURN_MM();
- }
- ZEPHIR_CONCAT_SVS(return_value, "DESCRIBE `", table, "`");
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, table, schema);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SV(return_value, "DESCRIBE ", _0);
RETURN_MM();
}
@@ -52012,7 +52135,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, listViews) {
static PHP_METHOD(Phalcon_Db_Dialect_MySQL, describeIndexes) {
- zval *table_param = NULL, *schema_param = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *table_param = NULL, *schema_param = NULL, *_0 = NULL;
zval *table = NULL, *schema = NULL;
ZEPHIR_MM_GROW();
@@ -52037,11 +52161,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, describeIndexes) {
}
- if (schema && Z_STRLEN_P(schema)) {
- ZEPHIR_CONCAT_SVSVS(return_value, "SHOW INDEXES FROM `", schema, "`.`", table, "`");
- RETURN_MM();
- }
- ZEPHIR_CONCAT_SVS(return_value, "SHOW INDEXES FROM `", table, "`");
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, table, schema);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SV(return_value, "SHOW INDEXES FROM ", _0);
RETURN_MM();
}
@@ -52147,7 +52269,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, _getTableOptions) {
if (zephir_is_true(engine)) {
ZEPHIR_INIT_VAR(_0);
ZEPHIR_CONCAT_SV(_0, "ENGINE=", engine);
- zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 727);
+ zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 633);
}
}
ZEPHIR_OBS_VAR(autoIncrement);
@@ -52155,7 +52277,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, _getTableOptions) {
if (zephir_is_true(autoIncrement)) {
ZEPHIR_INIT_LNVAR(_0);
ZEPHIR_CONCAT_SV(_0, "AUTO_INCREMENT=", autoIncrement);
- zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 736);
+ zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 642);
}
}
ZEPHIR_OBS_VAR(tableCollation);
@@ -52163,13 +52285,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_MySQL, _getTableOptions) {
if (zephir_is_true(tableCollation)) {
ZEPHIR_INIT_VAR(collationParts);
zephir_fast_explode_str(collationParts, SL("_"), tableCollation, LONG_MAX TSRMLS_CC);
- zephir_array_fetch_long(&_1, collationParts, 0, PH_NOISY | PH_READONLY, "phalcon/db/dialect/mysql.zep", 746 TSRMLS_CC);
+ zephir_array_fetch_long(&_1, collationParts, 0, PH_NOISY | PH_READONLY, "phalcon/db/dialect/mysql.zep", 652 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_0);
ZEPHIR_CONCAT_SV(_0, "DEFAULT CHARSET=", _1);
- zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 746);
+ zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 652);
ZEPHIR_INIT_VAR(_2);
ZEPHIR_CONCAT_SV(_2, "COLLATE=", tableCollation);
- zephir_array_append(&tableOptions, _2, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 747);
+ zephir_array_append(&tableOptions, _2, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 653);
}
}
if (zephir_fast_count_int(tableOptions TSRMLS_CC)) {
@@ -52719,9 +52841,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, createTable) {
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropTable) {
int ZEPHIR_LAST_CALL_STATUS;
- zephir_fcall_cache_entry *_2 = NULL;
zend_bool ifExists;
- zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *table = NULL, *_0 = NULL, *_1 = NULL, *_3 = NULL, *_4 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *table = NULL;
zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
@@ -52761,23 +52882,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropTable) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_CALL_CE_STATIC(&_1, phalcon_text_ce, "upper", &_2, 142, schemaName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", NULL, 42, _1);
- zephir_check_call_status();
- ZEPHIR_CALL_CE_STATIC(&_4, phalcon_text_ce, "upper", &_2, 142, tableName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "escape", NULL, 42, _4);
- zephir_check_call_status();
- ZEPHIR_INIT_VAR(table);
- ZEPHIR_CONCAT_VSV(table, _0, ".", _3);
- } else {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_2, 142, tableName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&table, this_ptr, "escape", NULL, 42, _0);
- zephir_check_call_status();
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
if (ifExists) {
ZEPHIR_CONCAT_SV(return_value, "DROP TABLE IF EXISTS ", table);
RETURN_MM();
@@ -52790,9 +52896,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropTable) {
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, createView) {
int ZEPHIR_LAST_CALL_STATUS;
- zephir_fcall_cache_entry *_1 = NULL;
zval *definition = NULL;
- zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *view = NULL, *viewSql, *_0 = NULL, *_2 = NULL, *_3;
+ zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *_0 = NULL;
zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
@@ -52821,25 +52926,12 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, createView) {
ZEPHIR_OBS_VAR(viewSql);
if (!(zephir_array_isset_string_fetch(&viewSql, definition, SS("sql"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/oracle.zep", 234);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/oracle.zep", 230);
return;
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schemaName);
- zephir_check_call_status();
- ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, viewName);
- zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_VSV(_3, _0, ".", _2);
- ZEPHIR_CALL_METHOD(&view, this_ptr, "escape", NULL, 42, _3);
- zephir_check_call_status();
- } else {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, viewName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&view, this_ptr, "escape", NULL, 42, _0);
- zephir_check_call_status();
- }
- ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", view, " AS ", viewSql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", _0, " AS ", viewSql);
RETURN_MM();
}
@@ -52847,9 +52939,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, createView) {
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropView) {
int ZEPHIR_LAST_CALL_STATUS;
- zephir_fcall_cache_entry *_1 = NULL;
zend_bool ifExists;
- zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *view = NULL, *_0 = NULL, *_2 = NULL, *_3;
+ zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *view = NULL;
zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
@@ -52884,21 +52975,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropView) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schemaName);
- zephir_check_call_status();
- ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, viewName);
- zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_VSV(_3, _0, ".", _2);
- ZEPHIR_CALL_METHOD(&view, this_ptr, "escape", NULL, 42, _3);
- zephir_check_call_status();
- } else {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, viewName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&view, this_ptr, "escape", NULL, 42, _0);
- zephir_check_call_status();
- }
+ ZEPHIR_CALL_METHOD(&view, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
if (ifExists) {
ZEPHIR_CONCAT_SV(return_value, "DROP VIEW IF EXISTS ", view);
RETURN_MM();
@@ -53235,6 +53313,57 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, supportsReleaseSavepoints) {
}
+static PHP_METHOD(Phalcon_Db_Dialect_Oracle, prepareTable) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zephir_fcall_cache_entry *_0 = NULL, *_2 = NULL;
+ zval *table_param = NULL, *schema_param = NULL, *alias_param = NULL, *escapeChar_param = NULL, *_1 = NULL, *_3 = NULL;
+ zval *table = NULL, *schema = NULL, *alias = NULL, *escapeChar = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 3, &table_param, &schema_param, &alias_param, &escapeChar_param);
+
+ if (unlikely(Z_TYPE_P(table_param) != IS_STRING && Z_TYPE_P(table_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'table' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(table_param) == IS_STRING)) {
+ zephir_get_strval(table, table_param);
+ } else {
+ ZEPHIR_INIT_VAR(table);
+ ZVAL_EMPTY_STRING(table);
+ }
+ if (!schema_param) {
+ ZEPHIR_INIT_VAR(schema);
+ ZVAL_EMPTY_STRING(schema);
+ } else {
+ zephir_get_strval(schema, schema_param);
+ }
+ if (!alias_param) {
+ ZEPHIR_INIT_VAR(alias);
+ ZVAL_EMPTY_STRING(alias);
+ } else {
+ zephir_get_strval(alias, alias_param);
+ }
+ if (!escapeChar_param) {
+ ZEPHIR_INIT_VAR(escapeChar);
+ ZVAL_EMPTY_STRING(escapeChar);
+ } else {
+ zephir_get_strval(escapeChar, escapeChar_param);
+ }
+
+
+ ZEPHIR_CALL_CE_STATIC(&_1, phalcon_text_ce, "upper", &_2, 142, table);
+ zephir_check_call_status();
+ ZEPHIR_CALL_CE_STATIC(&_3, phalcon_text_ce, "upper", &_2, 142, schema);
+ zephir_check_call_status();
+ ZEPHIR_RETURN_CALL_PARENT(phalcon_db_dialect_oracle_ce, this_ptr, "preparetable", &_0, 143, _1, _3, alias, escapeChar);
+ zephir_check_call_status();
+ RETURN_MM();
+
+}
+
@@ -53432,8 +53561,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, getColumnDefinition) {
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addColumn) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *sql = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *sql, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &column);
@@ -53462,16 +53591,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addColumn) {
}
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\" ADD COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\" ADD COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CONCAT_SVS(sql, "ALTER TABLE ", _0, " ADD COLUMN ");
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumndefinition", NULL, 0, column);
@@ -53503,8 +53626,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, modifyColumn) {
zend_bool _10;
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *currentColumn = NULL, *sql, *sqlAlterTable = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9 = NULL, _11, *_12 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *currentColumn = NULL, *sql, *sqlAlterTable, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9 = NULL, _11, *_12 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 1, &tableName_param, &schemaName_param, &column, ¤tColumn);
@@ -53538,16 +53661,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, modifyColumn) {
ZVAL_STRING(sql, "", 1);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sqlAlterTable);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(sqlAlterTable, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\"");
- ZEPHIR_CPY_WRT(sqlAlterTable, _0);
- }
+ ZEPHIR_CONCAT_SV(sqlAlterTable, "ALTER TABLE ", _0);
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, currentColumn, "getname", NULL, 0);
@@ -53635,8 +53752,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, modifyColumn) {
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropColumn) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *columnName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *columnName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *columnName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *columnName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &columnName_param);
@@ -53676,150 +53794,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropColumn) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\" ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\" ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, " DROP COLUMN \"", columnName, "\"");
- zephir_concat_self(&sql, _0 TSRMLS_CC);
- RETURN_CCTOR(sql);
-
-}
-
-static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addIndex) {
-
- int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql, *indexType = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_4 = NULL, *_5 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_3 = NULL;
-
- ZEPHIR_MM_GROW();
- zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
-
- if (unlikely(Z_TYPE_P(tableName_param) != IS_STRING && Z_TYPE_P(tableName_param) != IS_NULL)) {
- zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'tableName' must be a string") TSRMLS_CC);
- RETURN_MM_NULL();
- }
-
- if (likely(Z_TYPE_P(tableName_param) == IS_STRING)) {
- zephir_get_strval(tableName, tableName_param);
- } else {
- ZEPHIR_INIT_VAR(tableName);
- ZVAL_EMPTY_STRING(tableName);
- }
- if (unlikely(Z_TYPE_P(schemaName_param) != IS_STRING && Z_TYPE_P(schemaName_param) != IS_NULL)) {
- zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'schemaName' must be a string") TSRMLS_CC);
- RETURN_MM_NULL();
- }
-
- if (likely(Z_TYPE_P(schemaName_param) == IS_STRING)) {
- zephir_get_strval(schemaName, schemaName_param);
- } else {
- ZEPHIR_INIT_VAR(schemaName);
- ZVAL_EMPTY_STRING(schemaName);
- }
-
-
- ZEPHIR_CALL_METHOD(&_0, index, "getname", NULL, 0);
- zephir_check_call_status();
- if (ZEPHIR_IS_STRING_IDENTICAL(_0, "PRIMARY")) {
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "addprimarykey", NULL, 0, tableName, schemaName, index);
- zephir_check_call_status();
- RETURN_MM();
- }
- ZEPHIR_INIT_VAR(sql);
- ZVAL_STRING(sql, "CREATE", 1);
- ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
- zephir_check_call_status();
- if (!(ZEPHIR_IS_EMPTY(indexType))) {
- ZEPHIR_INIT_VAR(_1);
- ZEPHIR_CONCAT_SV(_1, " ", indexType);
- zephir_concat_self(&sql, _1 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_2, index, "getname", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_1);
- ZEPHIR_CONCAT_SVS(_1, " INDEX \"", _2, "\" ON");
- zephir_concat_self(&sql, _1 TSRMLS_CC);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVSVS(_3, " \"", schemaName, "\".\"", tableName, "\"");
- zephir_concat_self(&sql, _3 TSRMLS_CC);
- } else {
- ZEPHIR_INIT_LNVAR(_3);
- ZEPHIR_CONCAT_SVS(_3, " \"", tableName, "\"");
- zephir_concat_self(&sql, _3 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 43, _5);
- zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_1);
- ZEPHIR_CONCAT_SVS(_1, " (", _4, ")");
- zephir_concat_self(&sql, _1 TSRMLS_CC);
- RETURN_CCTOR(sql);
-
-}
-
-static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropIndex) {
-
- zval *tableName_param = NULL, *schemaName_param = NULL, *indexName_param = NULL;
- zval *tableName = NULL, *schemaName = NULL, *indexName = NULL;
-
- ZEPHIR_MM_GROW();
- zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &indexName_param);
-
- if (unlikely(Z_TYPE_P(tableName_param) != IS_STRING && Z_TYPE_P(tableName_param) != IS_NULL)) {
- zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'tableName' must be a string") TSRMLS_CC);
- RETURN_MM_NULL();
- }
-
- if (likely(Z_TYPE_P(tableName_param) == IS_STRING)) {
- zephir_get_strval(tableName, tableName_param);
- } else {
- ZEPHIR_INIT_VAR(tableName);
- ZVAL_EMPTY_STRING(tableName);
- }
- if (unlikely(Z_TYPE_P(schemaName_param) != IS_STRING && Z_TYPE_P(schemaName_param) != IS_NULL)) {
- zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'schemaName' must be a string") TSRMLS_CC);
- RETURN_MM_NULL();
- }
-
- if (likely(Z_TYPE_P(schemaName_param) == IS_STRING)) {
- zephir_get_strval(schemaName, schemaName_param);
- } else {
- ZEPHIR_INIT_VAR(schemaName);
- ZVAL_EMPTY_STRING(schemaName);
- }
- if (unlikely(Z_TYPE_P(indexName_param) != IS_STRING && Z_TYPE_P(indexName_param) != IS_NULL)) {
- zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'indexName' must be a string") TSRMLS_CC);
- RETURN_MM_NULL();
- }
-
- if (likely(Z_TYPE_P(indexName_param) == IS_STRING)) {
- zephir_get_strval(indexName, indexName_param);
- } else {
- ZEPHIR_INIT_VAR(indexName);
- ZVAL_EMPTY_STRING(indexName);
- }
-
-
- ZEPHIR_CONCAT_SVS(return_value, "DROP INDEX \"", indexName, "\"");
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP COLUMN \"", columnName, "\"");
RETURN_MM();
}
-static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addPrimaryKey) {
+static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addIndex) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql = NULL, *_1 = NULL, *_2 = NULL, *_3;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql, *indexType = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
@@ -53848,31 +53834,137 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addPrimaryKey) {
}
+ ZEPHIR_CALL_METHOD(&_0, index, "getname", NULL, 0);
+ zephir_check_call_status();
+ if (ZEPHIR_IS_STRING_IDENTICAL(_0, "PRIMARY")) {
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "addprimarykey", NULL, 0, tableName, schemaName, index);
+ zephir_check_call_status();
+ RETURN_MM();
+ }
ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
+ ZVAL_STRING(sql, "CREATE", 1);
+ ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
+ zephir_check_call_status();
+ if (!(ZEPHIR_IS_EMPTY(indexType))) {
+ ZEPHIR_INIT_VAR(_1);
+ ZEPHIR_CONCAT_SV(_1, " ", indexType);
+ zephir_concat_self(&sql, _1 TSRMLS_CC);
+ }
+ ZEPHIR_CALL_METHOD(&_2, index, "getname", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_INIT_LNVAR(_1);
+ ZEPHIR_CONCAT_SVSV(_1, " INDEX \"", _2, "\" ON ", _3);
+ zephir_concat_self(&sql, _1 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 43, _5);
+ zephir_check_call_status();
+ ZEPHIR_INIT_VAR(_6);
+ ZEPHIR_CONCAT_SVS(_6, " (", _4, ")");
+ zephir_concat_self(&sql, _6 TSRMLS_CC);
+ RETURN_CCTOR(sql);
+
+}
+
+static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropIndex) {
+
+ zval *tableName_param = NULL, *schemaName_param = NULL, *indexName_param = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *indexName = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &indexName_param);
+
+ if (unlikely(Z_TYPE_P(tableName_param) != IS_STRING && Z_TYPE_P(tableName_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'tableName' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(tableName_param) == IS_STRING)) {
+ zephir_get_strval(tableName, tableName_param);
} else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
+ ZEPHIR_INIT_VAR(tableName);
+ ZVAL_EMPTY_STRING(tableName);
}
+ if (unlikely(Z_TYPE_P(schemaName_param) != IS_STRING && Z_TYPE_P(schemaName_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'schemaName' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(schemaName_param) == IS_STRING)) {
+ zephir_get_strval(schemaName, schemaName_param);
+ } else {
+ ZEPHIR_INIT_VAR(schemaName);
+ ZVAL_EMPTY_STRING(schemaName);
+ }
+ if (unlikely(Z_TYPE_P(indexName_param) != IS_STRING && Z_TYPE_P(indexName_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'indexName' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(indexName_param) == IS_STRING)) {
+ zephir_get_strval(indexName, indexName_param);
+ } else {
+ ZEPHIR_INIT_VAR(indexName);
+ ZVAL_EMPTY_STRING(indexName);
+ }
+
+
+ ZEPHIR_CONCAT_SVS(return_value, "DROP INDEX \"", indexName, "\"");
+ RETURN_MM();
+
+}
+
+static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addPrimaryKey) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *index, *_0 = NULL, *_1 = NULL, *_2 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
+
+ if (unlikely(Z_TYPE_P(tableName_param) != IS_STRING && Z_TYPE_P(tableName_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'tableName' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(tableName_param) == IS_STRING)) {
+ zephir_get_strval(tableName, tableName_param);
+ } else {
+ ZEPHIR_INIT_VAR(tableName);
+ ZVAL_EMPTY_STRING(tableName);
+ }
+ if (unlikely(Z_TYPE_P(schemaName_param) != IS_STRING && Z_TYPE_P(schemaName_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'schemaName' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(schemaName_param) == IS_STRING)) {
+ zephir_get_strval(schemaName, schemaName_param);
+ } else {
+ ZEPHIR_INIT_VAR(schemaName);
+ ZVAL_EMPTY_STRING(schemaName);
+ }
+
+
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 43, _2);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVS(_3, " ADD CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _1, ")");
- zephir_concat_self(&sql, _3 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " ADD CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _1, ")");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropPrimaryKey) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 0, &tableName_param, &schemaName_param);
@@ -53901,26 +53993,18 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropPrimaryKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- zephir_concat_self_str(&sql, SL(" DROP CONSTRAINT \"PRIMARY\"") TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVS(return_value, "ALTER TABLE ", _0, " DROP CONSTRAINT \"PRIMARY\"");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *reference, *sql = NULL, *onDelete = NULL, *onUpdate = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7, *_8 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *reference, *sql, *onDelete = NULL, *onUpdate = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &reference);
@@ -53949,16 +54033,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\" ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\" ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, reference, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_3, reference, "getcolumns", NULL, 0);
@@ -53971,22 +54047,21 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", NULL, 43, _6);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_7);
- ZEPHIR_CONCAT_SVSVSSVSVS(_7, "ADD CONSTRAINT \"", _1, "\" FOREIGN KEY (", _2, ")", " REFERENCES \"", _4, "\" (", _5, ")");
- zephir_concat_self(&sql, _7 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(sql);
+ ZEPHIR_CONCAT_SVSVSVSSVSVS(sql, "ALTER TABLE ", _0, " ADD CONSTRAINT \"", _1, "\" FOREIGN KEY (", _2, ")", " REFERENCES \"", _4, "\" (", _5, ")");
ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onDelete))) {
- ZEPHIR_INIT_VAR(_8);
- ZEPHIR_CONCAT_SV(_8, " ON DELETE ", onDelete);
- zephir_concat_self(&sql, _8 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_7);
+ ZEPHIR_CONCAT_SV(_7, " ON DELETE ", onDelete);
+ zephir_concat_self(&sql, _7 TSRMLS_CC);
}
ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onUpdate))) {
- ZEPHIR_INIT_LNVAR(_8);
- ZEPHIR_CONCAT_SV(_8, " ON UPDATE ", onUpdate);
- zephir_concat_self(&sql, _8 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_7);
+ ZEPHIR_CONCAT_SV(_7, " ON UPDATE ", onUpdate);
+ zephir_concat_self(&sql, _7 TSRMLS_CC);
}
RETURN_CCTOR(sql);
@@ -53994,8 +54069,9 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) {
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropForeignKey) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *referenceName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *referenceName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *referenceName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *referenceName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &referenceName_param);
@@ -54035,32 +54111,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropForeignKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, " DROP CONSTRAINT \"", referenceName, "\"");
- zephir_concat_self(&sql, _0 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP CONSTRAINT \"", referenceName, "\"");
+ RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) {
- zephir_fcall_cache_entry *_6 = NULL, *_9 = NULL, *_17 = NULL;
+ zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_16 = NULL;
+ HashTable *_1, *_14, *_23;
+ HashPosition _0, _13, _22;
int ZEPHIR_LAST_CALL_STATUS;
- HashTable *_2, *_15, *_24;
- HashPosition _1, _14, _23;
zval *definition = NULL;
- zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *indexSqlAfterCreate, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, *primaryColumns, **_3, *_4 = NULL, *_5 = NULL, _7 = zval_used_for_init, *_8 = NULL, *_10 = NULL, *_11 = NULL, *_12 = NULL, *_13 = NULL, **_16, *_18 = NULL, *_20 = NULL, *_21 = NULL, *_22 = NULL, **_25, *_26 = NULL, *_27;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL, *_19 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *indexSqlAfterCreate, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, *primaryColumns, **_2, *_3 = NULL, *_4 = NULL, _6 = zval_used_for_init, *_7 = NULL, *_9 = NULL, *_10 = NULL, *_11 = NULL, *_12 = NULL, **_15, *_17 = NULL, *_18 = NULL, *_19 = NULL, *_20 = NULL, *_21 = NULL, **_24, *_25 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &definition_param);
@@ -54093,19 +54159,11 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) {
ZEPHIR_OBS_VAR(columns);
if (!(zephir_array_isset_string_fetch(&columns, definition, SS("columns"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'columns' is required in the definition array", "phalcon/db/dialect/postgresql.zep", 383);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'columns' is required in the definition array", "phalcon/db/dialect/postgresql.zep", 327);
return;
}
- ZEPHIR_INIT_VAR(table);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "\"", tableName, "\"");
- ZEPHIR_CPY_WRT(table, _0);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(temporary);
ZVAL_BOOL(temporary, 0);
ZEPHIR_OBS_VAR(options);
@@ -54123,64 +54181,64 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) {
array_init(createLines);
ZEPHIR_INIT_VAR(primaryColumns);
array_init(primaryColumns);
- zephir_is_iterable(columns, &_2, &_1, 0, 0, "phalcon/db/dialect/postgresql.zep", 443);
+ zephir_is_iterable(columns, &_1, &_0, 0, 0, "phalcon/db/dialect/postgresql.zep", 383);
for (
- ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
- ; zephir_hash_move_forward_ex(_2, &_1)
+ ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
+ ; zephir_hash_move_forward_ex(_1, &_0)
) {
- ZEPHIR_GET_HVALUE(column, _3);
- ZEPHIR_CALL_METHOD(&_4, column, "getname", NULL, 0);
+ ZEPHIR_GET_HVALUE(column, _2);
+ ZEPHIR_CALL_METHOD(&_3, column, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumndefinition", &_6, 0, column);
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumndefinition", &_5, 0, column);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(columnLine);
- ZEPHIR_CONCAT_SVSV(columnLine, "\"", _4, "\" ", _5);
+ ZEPHIR_CONCAT_SVSV(columnLine, "\"", _3, "\" ", _4);
ZEPHIR_CALL_METHOD(&defaultValue, column, "getdefault", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(defaultValue))) {
- ZEPHIR_SINIT_NVAR(_7);
- ZVAL_STRING(&_7, "\"", 0);
- ZEPHIR_CALL_FUNCTION(&_8, "addcslashes", &_9, 141, defaultValue, &_7);
+ ZEPHIR_SINIT_NVAR(_6);
+ ZVAL_STRING(&_6, "\"", 0);
+ ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 141, defaultValue, &_6);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SVS(_10, " DEFAULT \"", _8, "\"");
- zephir_concat_self(&columnLine, _10 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, " DEFAULT \"", _7, "\"");
+ zephir_concat_self(&columnLine, _9 TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isnotnull", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isnotnull", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
zephir_concat_self_str(&columnLine, SL(" NOT NULL") TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isautoincrement", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isautoincrement", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
}
- ZEPHIR_CALL_METHOD(&_11, column, "isprimary", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_10, column, "isprimary", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_11)) {
- ZEPHIR_CALL_METHOD(&_12, column, "getname", NULL, 0);
+ if (zephir_is_true(_10)) {
+ ZEPHIR_CALL_METHOD(&_11, column, "getname", NULL, 0);
zephir_check_call_status();
- zephir_array_append(&primaryColumns, _12, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 438);
+ zephir_array_append(&primaryColumns, _11, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 378);
}
- zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 441);
+ zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 381);
}
if (!(ZEPHIR_IS_EMPTY(primaryColumns))) {
- ZEPHIR_INIT_VAR(_13);
- zephir_fast_join_str(_13, SL(","), primaryColumns TSRMLS_CC);
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SVS(_10, "PRIMARY KEY (", _13, ")");
- zephir_array_append(&createLines, _10, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 444);
+ ZEPHIR_INIT_VAR(_12);
+ zephir_fast_join_str(_12, SL(","), primaryColumns TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, "PRIMARY KEY (", _12, ")");
+ zephir_array_append(&createLines, _9, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 384);
}
ZEPHIR_INIT_VAR(indexSqlAfterCreate);
ZVAL_STRING(indexSqlAfterCreate, "", 1);
ZEPHIR_OBS_VAR(indexes);
if (zephir_array_isset_string_fetch(&indexes, definition, SS("indexes"), 0 TSRMLS_CC)) {
- zephir_is_iterable(indexes, &_15, &_14, 0, 0, "phalcon/db/dialect/postgresql.zep", 484);
+ zephir_is_iterable(indexes, &_14, &_13, 0, 0, "phalcon/db/dialect/postgresql.zep", 418);
for (
- ; zephir_hash_get_current_data_ex(_15, (void**) &_16, &_14) == SUCCESS
- ; zephir_hash_move_forward_ex(_15, &_14)
+ ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS
+ ; zephir_hash_move_forward_ex(_14, &_13)
) {
- ZEPHIR_GET_HVALUE(index, _16);
+ ZEPHIR_GET_HVALUE(index, _15);
ZEPHIR_CALL_METHOD(&indexName, index, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
@@ -54188,126 +54246,112 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) {
ZEPHIR_INIT_NVAR(indexSql);
ZVAL_STRING(indexSql, "", 1);
if (ZEPHIR_IS_STRING(indexName, "PRIMARY")) {
- ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_17, 43, _5);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_16, 43, _4);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(indexSql);
- ZEPHIR_CONCAT_SVS(indexSql, "CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _4, ")");
+ ZEPHIR_CONCAT_SVS(indexSql, "CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _3, ")");
} else {
if (!(ZEPHIR_IS_EMPTY(indexType))) {
- ZEPHIR_CALL_METHOD(&_11, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_10, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, this_ptr, "getcolumnlist", &_17, 43, _11);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_16, 43, _10);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(indexSql);
- ZEPHIR_CONCAT_SVSVSVS(indexSql, "CONSTRAINT \"", indexName, "\" ", indexType, " (", _8, ")");
+ ZEPHIR_CONCAT_SVSVSVS(indexSql, "CONSTRAINT \"", indexName, "\" ", indexType, " (", _7, ")");
} else {
- ZEPHIR_CALL_METHOD(&_12, index, "getname", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_11, index, "getname", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_17, this_ptr, "preparetable", NULL, 143, tableName, schemaName);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_18);
- ZEPHIR_CONCAT_SVS(_18, "CREATE INDEX \"", _12, "\" ON ");
+ ZEPHIR_CONCAT_SVSV(_18, "CREATE INDEX \"", _11, "\" ON ", _17);
zephir_concat_self(&indexSqlAfterCreate, _18 TSRMLS_CC);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", tableName, "\"");
- zephir_concat_self(&indexSqlAfterCreate, _0 TSRMLS_CC);
- } else {
- ZEPHIR_INIT_LNVAR(_19);
- ZEPHIR_CONCAT_SVS(_19, "\"", tableName, "\"");
- zephir_concat_self(&indexSqlAfterCreate, _19 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_21, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_20, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_20, this_ptr, "getcolumnlist", &_17, 43, _21);
+ ZEPHIR_CALL_METHOD(&_19, this_ptr, "getcolumnlist", &_16, 43, _20);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_22);
- ZEPHIR_CONCAT_SVS(_22, " (", _20, ");");
- zephir_concat_self(&indexSqlAfterCreate, _22 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_21);
+ ZEPHIR_CONCAT_SVS(_21, " (", _19, ");");
+ zephir_concat_self(&indexSqlAfterCreate, _21 TSRMLS_CC);
}
}
if (!(ZEPHIR_IS_EMPTY(indexSql))) {
- zephir_array_append(&createLines, indexSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 481);
+ zephir_array_append(&createLines, indexSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 415);
}
}
}
ZEPHIR_OBS_VAR(references);
if (zephir_array_isset_string_fetch(&references, definition, SS("references"), 0 TSRMLS_CC)) {
- zephir_is_iterable(references, &_24, &_23, 0, 0, "phalcon/db/dialect/postgresql.zep", 513);
+ zephir_is_iterable(references, &_23, &_22, 0, 0, "phalcon/db/dialect/postgresql.zep", 443);
for (
- ; zephir_hash_get_current_data_ex(_24, (void**) &_25, &_23) == SUCCESS
- ; zephir_hash_move_forward_ex(_24, &_23)
+ ; zephir_hash_get_current_data_ex(_23, (void**) &_24, &_22) == SUCCESS
+ ; zephir_hash_move_forward_ex(_23, &_22)
) {
- ZEPHIR_GET_HVALUE(reference, _25);
- ZEPHIR_CALL_METHOD(&_4, reference, "getname", NULL, 0);
+ ZEPHIR_GET_HVALUE(reference, _24);
+ ZEPHIR_CALL_METHOD(&_3, reference, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, reference, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, reference, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", &_17, 43, _8);
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_16, 43, _7);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(referenceSql);
- ZEPHIR_CONCAT_SVSVS(referenceSql, "CONSTRAINT \"", _4, "\" FOREIGN KEY (", _5, ") REFERENCES ");
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_CALL_METHOD(&_11, reference, "getreferencedtable", NULL, 0);
- zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SVSVS(_10, "\"", schemaName, "\".\"", _11, "\" ");
- zephir_concat_self(&referenceSql, _10 TSRMLS_CC);
- } else {
- ZEPHIR_CALL_METHOD(&_12, reference, "getreferencedtable", NULL, 0);
- zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_18);
- ZEPHIR_CONCAT_SVS(_18, "\"", _12, "\" ");
- zephir_concat_self(&referenceSql, _18 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_21, reference, "getreferencedcolumns", NULL, 0);
+ ZEPHIR_CONCAT_SVSVS(referenceSql, "CONSTRAINT \"", _3, "\" FOREIGN KEY (", _4, ") REFERENCES ");
+ ZEPHIR_CALL_METHOD(&_11, reference, "getreferencedtable", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_10, this_ptr, "preparetable", NULL, 143, _11, schemaName);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_20, this_ptr, "getcolumnlist", &_17, 43, _21);
+ zephir_concat_self(&referenceSql, _10 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_19, reference, "getreferencedcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_22);
- ZEPHIR_CONCAT_SVS(_22, "(", _20, ")");
- zephir_concat_self(&referenceSql, _22 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_17, this_ptr, "getcolumnlist", &_16, 43, _19);
+ zephir_check_call_status();
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, " (", _17, ")");
+ zephir_concat_self(&referenceSql, _9 TSRMLS_CC);
ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onDelete))) {
- ZEPHIR_INIT_LNVAR(_26);
- ZEPHIR_CONCAT_SV(_26, " ON DELETE ", onDelete);
- zephir_concat_self(&referenceSql, _26 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_18);
+ ZEPHIR_CONCAT_SV(_18, " ON DELETE ", onDelete);
+ zephir_concat_self(&referenceSql, _18 TSRMLS_CC);
}
ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onUpdate))) {
- ZEPHIR_INIT_LNVAR(_26);
- ZEPHIR_CONCAT_SV(_26, " ON UPDATE ", onUpdate);
- zephir_concat_self(&referenceSql, _26 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_21);
+ ZEPHIR_CONCAT_SV(_21, " ON UPDATE ", onUpdate);
+ zephir_concat_self(&referenceSql, _21 TSRMLS_CC);
}
- zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 511);
+ zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 441);
}
}
- ZEPHIR_INIT_NVAR(_13);
- zephir_fast_join_str(_13, SL(",\n\t"), createLines TSRMLS_CC);
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_VS(_10, _13, "\n)");
- zephir_concat_self(&sql, _10 TSRMLS_CC);
+ ZEPHIR_INIT_NVAR(_12);
+ zephir_fast_join_str(_12, SL(",\n\t"), createLines TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_VS(_9, _12, "\n)");
+ zephir_concat_self(&sql, _9 TSRMLS_CC);
if (zephir_array_isset_string(definition, SS("options"))) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "_gettableoptions", NULL, 0, definition);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_gettableoptions", NULL, 0, definition);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_26);
- ZEPHIR_CONCAT_SV(_26, " ", _4);
- zephir_concat_self(&sql, _26 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_25);
+ ZEPHIR_CONCAT_SV(_25, " ", _3);
+ zephir_concat_self(&sql, _25 TSRMLS_CC);
}
- ZEPHIR_INIT_VAR(_27);
- ZEPHIR_CONCAT_SV(_27, ";", indexSqlAfterCreate);
- zephir_concat_self(&sql, _27 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_25);
+ ZEPHIR_CONCAT_SV(_25, ";", indexSqlAfterCreate);
+ zephir_concat_self(&sql, _25 TSRMLS_CC);
RETURN_CCTOR(sql);
}
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropTable) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *table = NULL, *sql;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &tableName_param, &schemaName_param, &ifExists_param);
@@ -54341,21 +54385,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropTable) {
}
- ZEPHIR_INIT_VAR(table);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "\"", tableName, "\"");
- ZEPHIR_CPY_WRT(table, _0);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
- ZEPHIR_CONCAT_SVS(sql, "DROP TABLE IF EXISTS \"", table, "\"");
+ ZEPHIR_CONCAT_SV(sql, "DROP TABLE IF EXISTS ", table);
} else {
- ZEPHIR_CONCAT_SVS(sql, "DROP TABLE \"", table, "\"");
+ ZEPHIR_CONCAT_SV(sql, "DROP TABLE ", table);
}
RETURN_CCTOR(sql);
@@ -54363,9 +54399,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropTable) {
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zval *definition = NULL;
- zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *view = NULL;
- zval *viewName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *_0 = NULL;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 1, &viewName_param, &definition_param, &schemaName_param);
@@ -54393,29 +54430,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createView) {
ZEPHIR_OBS_VAR(viewSql);
if (!(zephir_array_isset_string_fetch(&viewSql, definition, SS("sql"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/postgresql.zep", 554);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/postgresql.zep", 480);
return;
}
- ZEPHIR_INIT_VAR(view);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", viewName, "\"");
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "\"", viewName, "\"");
- ZEPHIR_CPY_WRT(view, _0);
- }
- ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", view, " AS ", viewSql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", _0, " AS ", viewSql);
RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *view = NULL, *sql;
- zval *viewName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &viewName_param, &schemaName_param, &ifExists_param);
@@ -54449,21 +54479,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropView) {
}
- ZEPHIR_INIT_VAR(view);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", viewName, "\"");
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "\"", viewName, "\"");
- ZEPHIR_CPY_WRT(view, _0);
- }
+ ZEPHIR_CALL_METHOD(&view, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
- ZEPHIR_CONCAT_SVS(sql, "DROP VIEW IF EXISTS ", view, "");
+ ZEPHIR_CONCAT_SV(sql, "DROP VIEW IF EXISTS ", view);
} else {
- ZEPHIR_CONCAT_SVS(sql, "DROP VIEW ", view, "");
+ ZEPHIR_CONCAT_SV(sql, "DROP VIEW ", view);
}
RETURN_CCTOR(sql);
@@ -54904,8 +54926,8 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, getColumnDefinition) {
static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addColumn) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *sql = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *sql, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &column);
@@ -54934,16 +54956,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addColumn) {
}
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\" ADD COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\" ADD COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CONCAT_SVS(sql, "ALTER TABLE ", _0, " ADD COLUMN ");
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumndefinition", NULL, 0, column);
@@ -55011,7 +55027,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, modifyColumn) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Altering a DB column is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 169);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Altering a DB column is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 165);
return;
}
@@ -55059,7 +55075,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropColumn) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Dropping DB column is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 177);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Dropping DB column is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 173);
return;
}
@@ -55213,7 +55229,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addPrimaryKey) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Adding a primary key after table has been created is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 221);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Adding a primary key after table has been created is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 217);
return;
}
@@ -55250,7 +55266,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropPrimaryKey) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Removing a primary key after table has been created is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 229);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Removing a primary key after table has been created is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 225);
return;
}
@@ -55287,7 +55303,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addForeignKey) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Adding a foreign key constraint to an existing table is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 237);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Adding a foreign key constraint to an existing table is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 233);
return;
}
@@ -55335,7 +55351,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropForeignKey) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Dropping a foreign key constraint is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 245);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Dropping a foreign key constraint is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 241);
return;
}
@@ -55375,16 +55391,17 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, createTable) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Not implemented yet", "phalcon/db/dialect/sqlite.zep", 253);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Not implemented yet", "phalcon/db/dialect/sqlite.zep", 249);
return;
}
static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropTable) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *sql, *table = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &tableName_param, &schemaName_param, &ifExists_param);
@@ -55418,18 +55435,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropTable) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_VSV(_0, schemaName, "\".\"", tableName);
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_CPY_WRT(table, tableName);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
- ZEPHIR_CONCAT_SVS(sql, "DROP TABLE IF EXISTS \"", table, "\"");
+ ZEPHIR_CONCAT_SV(sql, "DROP TABLE IF EXISTS ", table);
} else {
- ZEPHIR_CONCAT_SVS(sql, "DROP TABLE \"", table, "\"");
+ ZEPHIR_CONCAT_SV(sql, "DROP TABLE ", table);
}
RETURN_CCTOR(sql);
@@ -55437,9 +55449,10 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropTable) {
static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, createView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zval *definition = NULL;
- zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *view = NULL, *viewSql;
- zval *viewName = NULL, *schemaName = NULL, *_0;
+ zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *_0 = NULL;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 1, &viewName_param, &definition_param, &schemaName_param);
@@ -55467,26 +55480,22 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, createView) {
ZEPHIR_OBS_VAR(viewSql);
if (!(zephir_array_isset_string_fetch(&viewSql, definition, SS("sql"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/sqlite.zep", 286);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/sqlite.zep", 278);
return;
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_VSV(_0, schemaName, "\".\"", viewName);
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_CPY_WRT(view, viewName);
- }
- ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW \"", view, "\" AS ", viewSql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", _0, " AS ", viewSql);
RETURN_MM();
}
static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *view = NULL;
- zval *viewName = NULL, *schemaName = NULL, *_0;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &viewName_param, &schemaName_param, &ifExists_param);
@@ -55520,18 +55529,13 @@ static PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropView) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_VSV(_0, schemaName, "\".\"", viewName);
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_CPY_WRT(view, viewName);
- }
+ ZEPHIR_CALL_METHOD(&view, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
if (ifExists) {
- ZEPHIR_CONCAT_SVS(return_value, "DROP VIEW IF EXISTS \"", view, "\"");
+ ZEPHIR_CONCAT_SV(return_value, "DROP VIEW IF EXISTS ", view);
RETURN_MM();
}
- ZEPHIR_CONCAT_SVS(return_value, "DROP VIEW \"", view, "\"");
+ ZEPHIR_CONCAT_SV(return_value, "DROP VIEW ", view);
RETURN_MM();
}
@@ -56421,7 +56425,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, all) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "variables", 1);
zephir_array_fast_append(_0, _1);
- ZEPHIR_CALL_FUNCTION(&_2, "func_get_args", NULL, 165);
+ ZEPHIR_CALL_FUNCTION(&_2, "func_get_args", NULL, 166);
zephir_check_call_status();
ZEPHIR_CALL_USER_FUNC_ARRAY(return_value, _0, _2);
zephir_check_call_status();
@@ -56621,7 +56625,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, (tab + 1));
- ZEPHIR_CALL_METHOD(&_18, this_ptr, "output", &_19, 166, value, _3, &_5);
+ ZEPHIR_CALL_METHOD(&_18, this_ptr, "output", &_19, 167, value, _3, &_5);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_20);
@@ -56653,7 +56657,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
zephir_concat_self(&output, _2 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_13, "get_parent_class", &_21, 167, variable);
+ ZEPHIR_CALL_FUNCTION(&_13, "get_parent_class", &_21, 168, variable);
zephir_check_call_status();
if (zephir_is_true(_13)) {
ZEPHIR_INIT_NVAR(_12);
@@ -56664,7 +56668,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_check_temp_parameter(_3);
zephir_check_call_status();
zephir_array_update_string(&_12, SL(":style"), &_18, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_FUNCTION(&_18, "get_parent_class", &_21, 167, variable);
+ ZEPHIR_CALL_FUNCTION(&_18, "get_parent_class", &_21, 168, variable);
zephir_check_call_status();
zephir_array_update_string(&_12, SL(":parent"), &_18, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
@@ -56710,7 +56714,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, (tab + 1));
- ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 166, value, _3, &_5);
+ ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 167, value, _3, &_5);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_20);
@@ -56720,7 +56724,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
} else {
do {
Z_SET_ISREF_P(variable);
- ZEPHIR_CALL_FUNCTION(&attr, "each", &_28, 168, variable);
+ ZEPHIR_CALL_FUNCTION(&attr, "each", &_28, 169, variable);
Z_UNSET_ISREF_P(variable);
zephir_check_call_status();
if (!(zephir_is_true(attr))) {
@@ -56766,7 +56770,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_check_call_status();
zephir_array_update_string(&_12, SL(":style"), &_26, PH_COPY | PH_SEPARATE);
Z_SET_ISREF_P(key);
- ZEPHIR_CALL_FUNCTION(&_26, "end", &_32, 169, key);
+ ZEPHIR_CALL_FUNCTION(&_26, "end", &_32, 170, key);
Z_UNSET_ISREF_P(key);
zephir_check_call_status();
zephir_array_update_string(&_12, SL(":key"), &_26, PH_COPY | PH_SEPARATE);
@@ -56782,7 +56786,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, (tab + 1));
- ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 166, value, _3, &_5);
+ ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 167, value, _3, &_5);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_20);
@@ -56790,7 +56794,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_concat_self(&output, _20 TSRMLS_CC);
} while (zephir_is_true(attr));
}
- ZEPHIR_CALL_FUNCTION(&attr, "get_class_methods", NULL, 170, variable);
+ ZEPHIR_CALL_FUNCTION(&attr, "get_class_methods", NULL, 171, variable);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, tab);
@@ -56907,11 +56911,12 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Integer (:var)", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
- ZEPHIR_CALL_FUNCTION(&_2, "is_float", NULL, 171, variable);
+ ZEPHIR_CALL_FUNCTION(&_2, "is_float", NULL, 172, variable);
zephir_check_call_status();
if (zephir_is_true(_2)) {
ZEPHIR_INIT_NVAR(_1);
@@ -56925,8 +56930,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Float (:var)", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _13);
RETURN_MM();
}
if (zephir_is_numeric(variable)) {
@@ -56942,8 +56948,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Numeric string (:length) \":var\"", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
if (Z_TYPE_P(variable) == IS_STRING) {
@@ -56960,15 +56967,16 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
ZVAL_LONG(&_5, 4);
ZEPHIR_SINIT_VAR(_40);
ZVAL_STRING(&_40, "utf-8", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "htmlentities", NULL, 150, variable, &_5, &_40);
+ ZEPHIR_CALL_FUNCTION(&_2, "htmlentities", NULL, 151, variable, &_5, &_40);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_13, "nl2br", NULL, 172, _2);
+ ZEPHIR_CALL_FUNCTION(&_26, "nl2br", NULL, 173, _2);
zephir_check_call_status();
- zephir_array_update_string(&_1, SL(":var"), &_13, PH_COPY | PH_SEPARATE);
+ zephir_array_update_string(&_1, SL(":var"), &_26, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "String (:length) \":var\"", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _26);
RETURN_MM();
}
if (Z_TYPE_P(variable) == IS_BOOL) {
@@ -56991,8 +56999,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &_14, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Boolean (:var)", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
if (Z_TYPE_P(variable) == IS_NULL) {
@@ -57006,8 +57015,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":style"), &_2, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "NULL", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
ZEPHIR_INIT_NVAR(_1);
@@ -57021,8 +57031,9 @@ static PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "(:var)", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
@@ -57076,7 +57087,7 @@ static PHP_METHOD(Phalcon_Debug_Dump, variables) {
ZEPHIR_INIT_VAR(output);
ZVAL_STRING(output, "", 1);
- ZEPHIR_CALL_FUNCTION(&_0, "func_get_args", NULL, 165);
+ ZEPHIR_CALL_FUNCTION(&_0, "func_get_args", NULL, 166);
zephir_check_call_status();
zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/debug/dump.zep", 290);
for (
@@ -57835,7 +57846,7 @@ static PHP_METHOD(Phalcon_Di_Service, resolve) {
ZEPHIR_CALL_METHOD(NULL, builder, "__construct", NULL, 0);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&instance, builder, "build", NULL, 174, dependencyInjector, definition, parameters);
+ ZEPHIR_CALL_METHOD(&instance, builder, "build", NULL, 175, dependencyInjector, definition, parameters);
zephir_check_call_status();
} else {
found = 0;
@@ -58031,7 +58042,7 @@ static PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_cli_ce, this_ptr, "__construct", &_0, 173);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_cli_ce, this_ptr, "__construct", &_0, 174);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_1);
zephir_create_array(_1, 10, 0 TSRMLS_CC);
@@ -58333,7 +58344,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, _buildParameters) {
) {
ZEPHIR_GET_HMKEY(position, _1, _0);
ZEPHIR_GET_HVALUE(argument, _2);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_buildparameter", &_4, 175, dependencyInjector, position, argument);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_buildparameter", &_4, 176, dependencyInjector, position, argument);
zephir_check_call_status();
zephir_array_append(&buildArguments, _3, PH_SEPARATE, "phalcon/di/service/builder.zep", 117);
}
@@ -58378,7 +58389,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) {
} else {
ZEPHIR_OBS_VAR(arguments);
if (zephir_array_isset_string_fetch(&arguments, definition, SS("arguments"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 176, dependencyInjector, arguments);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 177, dependencyInjector, arguments);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(instance);
ZEPHIR_LAST_CALL_STATUS = zephir_create_instance_params(instance, className, _0 TSRMLS_CC);
@@ -58448,7 +58459,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) {
}
if (zephir_fast_count_int(arguments TSRMLS_CC)) {
ZEPHIR_INIT_NVAR(_5);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 176, dependencyInjector, arguments);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 177, dependencyInjector, arguments);
zephir_check_call_status();
ZEPHIR_CALL_USER_FUNC_ARRAY(_5, methodCall, _0);
zephir_check_call_status();
@@ -58512,7 +58523,7 @@ static PHP_METHOD(Phalcon_Di_Service_Builder, build) {
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameter", &_12, 175, dependencyInjector, propertyPosition, propertyValue);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameter", &_12, 176, dependencyInjector, propertyPosition, propertyValue);
zephir_check_call_status();
zephir_update_property_zval_zval(instance, propertyName, _0 TSRMLS_CC);
}
@@ -58816,7 +58827,7 @@ static PHP_METHOD(Phalcon_Events_Manager, attach) {
}
ZEPHIR_INIT_VAR(_2);
ZVAL_LONG(_2, 1);
- ZEPHIR_CALL_METHOD(NULL, priorityQueue, "setextractflags", NULL, 183, _2);
+ ZEPHIR_CALL_METHOD(NULL, priorityQueue, "setextractflags", NULL, 184, _2);
zephir_check_call_status();
zephir_update_property_array(this_ptr, SL("_events"), eventType, priorityQueue TSRMLS_CC);
} else {
@@ -58826,7 +58837,7 @@ static PHP_METHOD(Phalcon_Events_Manager, attach) {
if (Z_TYPE_P(priorityQueue) == IS_OBJECT) {
ZEPHIR_INIT_NVAR(_2);
ZVAL_LONG(_2, priority);
- ZEPHIR_CALL_METHOD(NULL, priorityQueue, "insert", NULL, 184, handler, _2);
+ ZEPHIR_CALL_METHOD(NULL, priorityQueue, "insert", NULL, 185, handler, _2);
zephir_check_call_status();
} else {
zephir_array_append(&priorityQueue, handler, PH_SEPARATE, "phalcon/events/manager.zep", 82);
@@ -58875,7 +58886,7 @@ static PHP_METHOD(Phalcon_Events_Manager, detach) {
}
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, 1);
- ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "setextractflags", NULL, 183, _1);
+ ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "setextractflags", NULL, 184, _1);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_1);
ZVAL_LONG(_1, 3);
@@ -58897,13 +58908,13 @@ static PHP_METHOD(Phalcon_Events_Manager, detach) {
if (!ZEPHIR_IS_IDENTICAL(_5, handler)) {
zephir_array_fetch_string(&_6, data, SL("data"), PH_NOISY | PH_READONLY, "phalcon/events/manager.zep", 117 TSRMLS_CC);
zephir_array_fetch_string(&_7, data, SL("priority"), PH_NOISY | PH_READONLY, "phalcon/events/manager.zep", 117 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "insert", &_8, 184, _6, _7);
+ ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "insert", &_8, 185, _6, _7);
zephir_check_call_status();
}
}
zephir_update_property_array(this_ptr, SL("_events"), eventType, newPriorityQueue TSRMLS_CC);
} else {
- ZEPHIR_CALL_FUNCTION(&key, "array_search", NULL, 185, handler, priorityQueue, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(&key, "array_search", NULL, 186, handler, priorityQueue, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
if (!ZEPHIR_IS_FALSE_IDENTICAL(key)) {
zephir_array_unset(&priorityQueue, key, PH_SEPARATE);
@@ -59059,7 +59070,7 @@ static PHP_METHOD(Phalcon_Events_Manager, fireQueue) {
zephir_get_class(_1, queue, 0 TSRMLS_CC);
ZEPHIR_SINIT_VAR(_2);
ZVAL_STRING(&_2, "Unexpected value type: expected object of type SplPriorityQueue, %s given", 0);
- ZEPHIR_CALL_FUNCTION(&_3, "sprintf", NULL, 186, &_2, _1);
+ ZEPHIR_CALL_FUNCTION(&_3, "sprintf", NULL, 187, &_2, _1);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3);
zephir_check_call_status();
@@ -59272,9 +59283,9 @@ static PHP_METHOD(Phalcon_Events_Manager, fire) {
if (_3) {
ZEPHIR_INIT_NVAR(event);
object_init_ex(event, phalcon_events_event_ce);
- ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 187, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 188, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 188, fireEvents, event);
+ ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 189, fireEvents, event);
zephir_check_call_status();
}
}
@@ -59288,10 +59299,10 @@ static PHP_METHOD(Phalcon_Events_Manager, fire) {
if (Z_TYPE_P(event) == IS_NULL) {
ZEPHIR_INIT_NVAR(event);
object_init_ex(event, phalcon_events_event_ce);
- ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 187, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 188, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 188, fireEvents, event);
+ ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 189, fireEvents, event);
zephir_check_call_status();
}
}
@@ -59504,7 +59515,7 @@ static PHP_METHOD(Phalcon_Flash_Direct, output) {
}
}
if (remove) {
- ZEPHIR_CALL_PARENT(NULL, phalcon_flash_direct_ce, this_ptr, "clear", &_3, 195);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_flash_direct_ce, this_ptr, "clear", &_3, 196);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -59777,7 +59788,7 @@ static PHP_METHOD(Phalcon_Flash_Session, output) {
zephir_check_call_status();
}
}
- ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_4, 195);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_4, 196);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -59795,7 +59806,7 @@ static PHP_METHOD(Phalcon_Flash_Session, clear) {
ZVAL_BOOL(_0, 1);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "_getsessionmessages", NULL, 0, _0);
zephir_check_call_status();
- ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_1, 195);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_1, 196);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -60921,7 +60932,7 @@ static PHP_METHOD(Phalcon_Forms_Form, isValid) {
} else {
ZEPHIR_INIT_NVAR(validation);
object_init_ex(validation, phalcon_validation_ce);
- ZEPHIR_CALL_METHOD(NULL, validation, "__construct", &_11, 209, preparedValidators);
+ ZEPHIR_CALL_METHOD(NULL, validation, "__construct", &_11, 210, preparedValidators);
zephir_check_call_status();
}
ZEPHIR_CALL_METHOD(&filters, element, "getfilters", NULL, 0);
@@ -60929,10 +60940,10 @@ static PHP_METHOD(Phalcon_Forms_Form, isValid) {
if (Z_TYPE_P(filters) == IS_ARRAY) {
ZEPHIR_CALL_METHOD(&_2, element, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, validation, "setfilters", &_12, 210, _2, filters);
+ ZEPHIR_CALL_METHOD(NULL, validation, "setfilters", &_12, 211, _2, filters);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&elementMessages, validation, "validate", &_13, 211, data, entity);
+ ZEPHIR_CALL_METHOD(&elementMessages, validation, "validate", &_13, 212, data, entity);
zephir_check_call_status();
if (zephir_fast_count_int(elementMessages TSRMLS_CC)) {
ZEPHIR_CALL_METHOD(&_14, element, "getname", NULL, 0);
@@ -60995,7 +61006,7 @@ static PHP_METHOD(Phalcon_Forms_Form, getMessages) {
; zephir_hash_move_forward_ex(_2, &_1)
) {
ZEPHIR_GET_HVALUE(elementMessages, _3);
- ZEPHIR_CALL_METHOD(NULL, group, "appendmessages", &_4, 212, elementMessages);
+ ZEPHIR_CALL_METHOD(NULL, group, "appendmessages", &_4, 213, elementMessages);
zephir_check_call_status();
}
}
@@ -61465,7 +61476,7 @@ static PHP_METHOD(Phalcon_Forms_Form, rewind) {
ZVAL_LONG(_0, 0);
zephir_update_property_this(this_ptr, SL("_position"), _0 TSRMLS_CC);
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_elements"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_1, "array_values", NULL, 213, _0);
+ ZEPHIR_CALL_FUNCTION(&_1, "array_values", NULL, 214, _0);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_elementsIndexed"), _1 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -61557,7 +61568,7 @@ static PHP_METHOD(Phalcon_Forms_Manager, create) {
}
ZEPHIR_INIT_VAR(form);
object_init_ex(form, phalcon_forms_form_ce);
- ZEPHIR_CALL_METHOD(NULL, form, "__construct", NULL, 214, entity);
+ ZEPHIR_CALL_METHOD(NULL, form, "__construct", NULL, 215, entity);
zephir_check_call_status();
zephir_update_property_array(this_ptr, SL("_forms"), name, form TSRMLS_CC);
RETURN_CCTOR(form);
@@ -61666,7 +61677,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Check, render) {
ZVAL_BOOL(_2, 1);
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes, _2);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "checkfield", &_0, 196, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "checkfield", &_0, 197, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61711,7 +61722,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Date, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "datefield", &_0, 197, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "datefield", &_0, 198, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61756,7 +61767,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Email, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "emailfield", &_0, 198, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "emailfield", &_0, 199, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61801,7 +61812,7 @@ static PHP_METHOD(Phalcon_Forms_Element_File, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "filefield", &_0, 199, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "filefield", &_0, 200, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61846,7 +61857,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Hidden, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "hiddenfield", &_0, 200, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "hiddenfield", &_0, 201, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61891,7 +61902,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Numeric, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "numericfield", &_0, 201, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "numericfield", &_0, 202, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61936,7 +61947,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Password, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "passwordfield", &_0, 202, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "passwordfield", &_0, 203, _1);
zephir_check_call_status();
RETURN_MM();
@@ -61983,7 +61994,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Radio, render) {
ZVAL_BOOL(_2, 1);
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes, _2);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "radiofield", &_0, 203, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "radiofield", &_0, 204, _1);
zephir_check_call_status();
RETURN_MM();
@@ -62034,7 +62045,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Select, __construct) {
zephir_update_property_this(this_ptr, SL("_optionsValues"), options TSRMLS_CC);
- ZEPHIR_CALL_PARENT(NULL, phalcon_forms_element_select_ce, this_ptr, "__construct", &_0, 204, name, attributes);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_forms_element_select_ce, this_ptr, "__construct", &_0, 205, name, attributes);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -62090,7 +62101,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Select, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
_2 = zephir_fetch_nproperty_this(this_ptr, SL("_optionsValues"), PH_NOISY_CC);
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 205, _1, _2);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, _1, _2);
zephir_check_call_status();
RETURN_MM();
@@ -62135,7 +62146,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Submit, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "submitbutton", &_0, 206, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "submitbutton", &_0, 207, _1);
zephir_check_call_status();
RETURN_MM();
@@ -62180,7 +62191,7 @@ static PHP_METHOD(Phalcon_Forms_Element_Text, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textfield", &_0, 207, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textfield", &_0, 208, _1);
zephir_check_call_status();
RETURN_MM();
@@ -62225,7 +62236,7 @@ static PHP_METHOD(Phalcon_Forms_Element_TextArea, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textarea", &_0, 208, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textarea", &_0, 209, _1);
zephir_check_call_status();
RETURN_MM();
@@ -62532,7 +62543,7 @@ static PHP_METHOD(Phalcon_Http_Cookie, send) {
} else {
ZEPHIR_CPY_WRT(encryptValue, value);
}
- ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 215, name, encryptValue, expire, path, domain, secure, httpOnly);
+ ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 216, name, encryptValue, expire, path, domain, secure, httpOnly);
zephir_check_call_status();
RETURN_THIS();
@@ -62620,7 +62631,7 @@ static PHP_METHOD(Phalcon_Http_Cookie, delete) {
zephir_time(_2);
ZEPHIR_SINIT_VAR(_4);
ZVAL_LONG(&_4, (zephir_get_numberval(_2) - 691200));
- ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 215, name, ZEPHIR_GLOBAL(global_null), &_4, path, domain, secure, httpOnly);
+ ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 216, name, ZEPHIR_GLOBAL(global_null), &_4, path, domain, secure, httpOnly);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -62977,7 +62988,7 @@ static PHP_METHOD(Phalcon_Http_Request, get) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 216, _REQUEST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _REQUEST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -63028,7 +63039,7 @@ static PHP_METHOD(Phalcon_Http_Request, getPost) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 216, _POST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _POST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -63038,7 +63049,7 @@ static PHP_METHOD(Phalcon_Http_Request, getPut) {
int ZEPHIR_LAST_CALL_STATUS;
zend_bool notAllowEmpty, noRecursive;
- zval *name_param = NULL, *filters = NULL, *defaultValue = NULL, *notAllowEmpty_param = NULL, *noRecursive_param = NULL, *put = NULL, *_0, _1;
+ zval *name_param = NULL, *filters = NULL, *defaultValue = NULL, *notAllowEmpty_param = NULL, *noRecursive_param = NULL, *put = NULL, *_0 = NULL;
zval *name = NULL;
ZEPHIR_MM_GROW();
@@ -63083,17 +63094,15 @@ static PHP_METHOD(Phalcon_Http_Request, getPut) {
if (Z_TYPE_P(put) != IS_ARRAY) {
ZEPHIR_INIT_NVAR(put);
array_init(put);
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_SINIT_VAR(_1);
- ZVAL_STRING(&_1, "php://input", 0);
- zephir_file_get_contents(_0, &_1 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getrawbody", NULL, 0);
+ zephir_check_call_status();
Z_SET_ISREF_P(put);
- ZEPHIR_CALL_FUNCTION(NULL, "parse_str", NULL, 217, _0, put);
+ ZEPHIR_CALL_FUNCTION(NULL, "parse_str", NULL, 218, _0, put);
Z_UNSET_ISREF_P(put);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_putCache"), put TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 216, put, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, put, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -63144,7 +63153,7 @@ static PHP_METHOD(Phalcon_Http_Request, getQuery) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 216, _GET, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _GET, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -63581,7 +63590,7 @@ static PHP_METHOD(Phalcon_Http_Request, getServerAddress) {
}
ZEPHIR_SINIT_VAR(_0);
ZVAL_STRING(&_0, "localhost", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("gethostbyname", NULL, 218, &_0);
+ ZEPHIR_RETURN_CALL_FUNCTION("gethostbyname", NULL, 219, &_0);
zephir_check_call_status();
RETURN_MM();
@@ -63772,7 +63781,7 @@ static PHP_METHOD(Phalcon_Http_Request, isMethod) {
}
- ZEPHIR_CALL_METHOD(&httpMethod, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&httpMethod, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
if (Z_TYPE_P(methods) == IS_STRING) {
_0 = strict;
@@ -63844,7 +63853,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPost) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "POST"));
@@ -63857,7 +63866,7 @@ static PHP_METHOD(Phalcon_Http_Request, isGet) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "GET"));
@@ -63870,7 +63879,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPut) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "PUT"));
@@ -63883,7 +63892,7 @@ static PHP_METHOD(Phalcon_Http_Request, isPatch) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "PATCH"));
@@ -63896,7 +63905,7 @@ static PHP_METHOD(Phalcon_Http_Request, isHead) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "HEAD"));
@@ -63909,7 +63918,7 @@ static PHP_METHOD(Phalcon_Http_Request, isDelete) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "DELETE"));
@@ -63922,7 +63931,7 @@ static PHP_METHOD(Phalcon_Http_Request, isOptions) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "OPTIONS"));
@@ -63970,7 +63979,7 @@ static PHP_METHOD(Phalcon_Http_Request, hasFiles) {
}
}
if (Z_TYPE_P(error) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 220, error, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 221, error, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
numberFiles += zephir_get_numberval(_4);
}
@@ -64014,7 +64023,7 @@ static PHP_METHOD(Phalcon_Http_Request, hasFileHelper) {
}
}
if (Z_TYPE_P(value) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 220, value, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 221, value, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
numberFiles += zephir_get_numberval(_4);
}
@@ -64063,7 +64072,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) {
zephir_array_fetch_string(&_6, input, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC);
zephir_array_fetch_string(&_7, input, SL("size"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC);
zephir_array_fetch_string(&_8, input, SL("error"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&smoothInput, this_ptr, "smoothfiles", &_9, 221, _4, _5, _6, _7, _8, prefix);
+ ZEPHIR_CALL_METHOD(&smoothInput, this_ptr, "smoothfiles", &_9, 222, _4, _5, _6, _7, _8, prefix);
zephir_check_call_status();
zephir_is_iterable(smoothInput, &_11, &_10, 0, 0, "phalcon/http/request.zep", 714);
for (
@@ -64097,7 +64106,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) {
ZEPHIR_INIT_NVAR(_16);
object_init_ex(_16, phalcon_http_request_file_ce);
zephir_array_fetch_string(&_17, file, SL("key"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 711 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 222, dataFile, _17);
+ ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 223, dataFile, _17);
zephir_check_call_status();
zephir_array_append(&files, _16, PH_SEPARATE, "phalcon/http/request.zep", 711);
}
@@ -64111,7 +64120,7 @@ static PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) {
if (_13) {
ZEPHIR_INIT_NVAR(_16);
object_init_ex(_16, phalcon_http_request_file_ce);
- ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 222, input, prefix);
+ ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 223, input, prefix);
zephir_check_call_status();
zephir_array_append(&files, _16, PH_SEPARATE, "phalcon/http/request.zep", 716);
}
@@ -64184,7 +64193,7 @@ static PHP_METHOD(Phalcon_Http_Request, smoothFiles) {
zephir_array_fetch(&_7, tmp_names, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC);
zephir_array_fetch(&_8, sizes, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC);
zephir_array_fetch(&_9, errors, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&parentFiles, this_ptr, "smoothfiles", &_10, 221, _5, _6, _7, _8, _9, p);
+ ZEPHIR_CALL_METHOD(&parentFiles, this_ptr, "smoothfiles", &_10, 222, _5, _6, _7, _8, _9, p);
zephir_check_call_status();
zephir_is_iterable(parentFiles, &_12, &_11, 0, 0, "phalcon/http/request.zep", 755);
for (
@@ -64238,7 +64247,7 @@ static PHP_METHOD(Phalcon_Http_Request, getHeaders) {
ZVAL_STRING(&_8, " ", 0);
zephir_fast_str_replace(&_4, &_7, &_8, _6 TSRMLS_CC);
zephir_fast_strtolower(_3, _4);
- ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 223, _3);
+ ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 224, _3);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_10);
ZEPHIR_SINIT_NVAR(_11);
@@ -64257,7 +64266,7 @@ static PHP_METHOD(Phalcon_Http_Request, getHeaders) {
ZVAL_STRING(&_7, " ", 0);
zephir_fast_str_replace(&_4, &_5, &_7, name TSRMLS_CC);
zephir_fast_strtolower(_3, _4);
- ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 223, _3);
+ ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 224, _3);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_6);
ZEPHIR_SINIT_NVAR(_8);
@@ -64332,7 +64341,7 @@ static PHP_METHOD(Phalcon_Http_Request, _getQualityHeader) {
ZVAL_LONG(&_2, -1);
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 1);
- ZEPHIR_CALL_FUNCTION(&_4, "preg_split", &_5, 224, &_1, _0, &_2, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "preg_split", &_5, 225, &_1, _0, &_2, &_3);
zephir_check_call_status();
zephir_is_iterable(_4, &_7, &_6, 0, 0, "phalcon/http/request.zep", 827);
for (
@@ -64350,7 +64359,7 @@ static PHP_METHOD(Phalcon_Http_Request, _getQualityHeader) {
ZVAL_LONG(&_2, -1);
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 1);
- ZEPHIR_CALL_FUNCTION(&_10, "preg_split", &_5, 224, &_1, _9, &_2, &_3);
+ ZEPHIR_CALL_FUNCTION(&_10, "preg_split", &_5, 225, &_1, _9, &_2, &_3);
zephir_check_call_status();
zephir_is_iterable(_10, &_12, &_11, 0, 0, "phalcon/http/request.zep", 824);
for (
@@ -64481,7 +64490,7 @@ static PHP_METHOD(Phalcon_Http_Request, getAcceptableContent) {
ZVAL_STRING(_0, "HTTP_ACCEPT", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "accept", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 225, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1);
zephir_check_temp_parameter(_0);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
@@ -64500,7 +64509,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestAccept) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "accept", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 226, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -64518,7 +64527,7 @@ static PHP_METHOD(Phalcon_Http_Request, getClientCharsets) {
ZVAL_STRING(_0, "HTTP_ACCEPT_CHARSET", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "charset", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 225, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1);
zephir_check_temp_parameter(_0);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
@@ -64537,7 +64546,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestCharset) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "charset", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 226, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -64555,7 +64564,7 @@ static PHP_METHOD(Phalcon_Http_Request, getLanguages) {
ZVAL_STRING(_0, "HTTP_ACCEPT_LANGUAGE", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "language", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 225, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1);
zephir_check_temp_parameter(_0);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
@@ -64574,7 +64583,7 @@ static PHP_METHOD(Phalcon_Http_Request, getBestLanguage) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "language", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 226, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -64894,7 +64903,7 @@ static PHP_METHOD(Phalcon_Http_Response, setStatusCode) {
if (_4) {
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "HTTP/", 0);
- ZEPHIR_CALL_FUNCTION(&_6, "strstr", &_7, 233, key, &_5);
+ ZEPHIR_CALL_FUNCTION(&_6, "strstr", &_7, 234, key, &_5);
zephir_check_call_status();
_4 = zephir_is_true(_6);
}
@@ -65165,6 +65174,48 @@ static PHP_METHOD(Phalcon_Http_Response, setExpires) {
}
+static PHP_METHOD(Phalcon_Http_Response, setCache) {
+
+ zval *_1, *_3;
+ zval *minutes_param = NULL, *date, _0, _2, *_4;
+ int minutes, ZEPHIR_LAST_CALL_STATUS;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 0, &minutes_param);
+
+ if (unlikely(Z_TYPE_P(minutes_param) != IS_LONG)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'minutes' must be a long/integer") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ minutes = Z_LVAL_P(minutes_param);
+
+
+ ZEPHIR_INIT_VAR(date);
+ object_init_ex(date, php_date_get_date_ce());
+ ZEPHIR_CALL_METHOD(NULL, date, "__construct", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_SINIT_VAR(_0);
+ ZVAL_LONG(&_0, minutes);
+ ZEPHIR_INIT_VAR(_1);
+ ZEPHIR_CONCAT_SVS(_1, "+", &_0, " minutes");
+ ZEPHIR_CALL_METHOD(NULL, date, "modify", NULL, 0, _1);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "setexpires", NULL, 0, date);
+ zephir_check_call_status();
+ ZEPHIR_SINIT_VAR(_2);
+ ZVAL_LONG(&_2, ((minutes * 60)));
+ ZEPHIR_INIT_VAR(_3);
+ ZEPHIR_CONCAT_SV(_3, "max-age=", &_2);
+ ZEPHIR_INIT_VAR(_4);
+ ZVAL_STRING(_4, "Cache-Control", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "setheader", NULL, 0, _4, _3);
+ zephir_check_temp_parameter(_4);
+ zephir_check_call_status();
+ RETURN_THIS();
+
+}
+
static PHP_METHOD(Phalcon_Http_Response, setNotModified) {
int ZEPHIR_LAST_CALL_STATUS;
@@ -65279,7 +65330,7 @@ static PHP_METHOD(Phalcon_Http_Response, redirect) {
if (_0) {
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "://", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "strstr", NULL, 233, location, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strstr", NULL, 234, location, &_1);
zephir_check_call_status();
_0 = zephir_is_true(_2);
}
@@ -65336,7 +65387,7 @@ static PHP_METHOD(Phalcon_Http_Response, redirect) {
statusCode = 302;
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_statusCodes"), PH_NOISY_CC);
ZEPHIR_OBS_VAR(message);
- zephir_array_fetch_long(&message, _5, 302, PH_NOISY, "phalcon/http/response.zep", 461 TSRMLS_CC);
+ zephir_array_fetch_long(&message, _5, 302, PH_NOISY, "phalcon/http/response.zep", 481 TSRMLS_CC);
} else {
ZEPHIR_OBS_NVAR(message);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_statusCodes"), PH_NOISY_CC);
@@ -65472,7 +65523,7 @@ static PHP_METHOD(Phalcon_Http_Response, send) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_sent"), PH_NOISY_CC);
if (zephir_is_true(_0)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_response_exception_ce, "Response was already sent", "phalcon/http/response.zep", 568);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_response_exception_ce, "Response was already sent", "phalcon/http/response.zep", 588);
return;
}
ZEPHIR_OBS_VAR(headers);
@@ -65499,7 +65550,7 @@ static PHP_METHOD(Phalcon_Http_Response, send) {
_1 = (zephir_fast_strlen_ev(file)) ? 1 : 0;
}
if (_1) {
- ZEPHIR_CALL_FUNCTION(NULL, "readfile", NULL, 234, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "readfile", NULL, 235, file);
zephir_check_call_status();
}
}
@@ -65739,7 +65790,7 @@ static PHP_METHOD(Phalcon_Http_Request_File, __construct) {
zephir_update_property_this(this_ptr, SL("_name"), name TSRMLS_CC);
ZEPHIR_SINIT_VAR(_0);
ZVAL_STRING(&_0, "PATHINFO_EXTENSION", 0);
- ZEPHIR_CALL_FUNCTION(&_1, "defined", NULL, 227, &_0);
+ ZEPHIR_CALL_FUNCTION(&_1, "defined", NULL, 228, &_0);
zephir_check_call_status();
if (zephir_is_true(_1)) {
ZEPHIR_SINIT_NVAR(_0);
@@ -65805,15 +65856,15 @@ static PHP_METHOD(Phalcon_Http_Request_File, getRealType) {
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, 16);
- ZEPHIR_CALL_FUNCTION(&finfo, "finfo_open", NULL, 228, &_0);
+ ZEPHIR_CALL_FUNCTION(&finfo, "finfo_open", NULL, 229, &_0);
zephir_check_call_status();
if (Z_TYPE_P(finfo) != IS_RESOURCE) {
RETURN_MM_STRING("", 1);
}
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_tmp"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 229, finfo, _1);
+ ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 230, finfo, _1);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 230, finfo);
+ ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 231, finfo);
zephir_check_call_status();
RETURN_CCTOR(mime);
@@ -65831,7 +65882,7 @@ static PHP_METHOD(Phalcon_Http_Request_File, isUploadedFile) {
zephir_check_call_status();
_0 = Z_TYPE_P(tmp) == IS_STRING;
if (_0) {
- ZEPHIR_CALL_FUNCTION(&_1, "is_uploaded_file", NULL, 231, tmp);
+ ZEPHIR_CALL_FUNCTION(&_1, "is_uploaded_file", NULL, 232, tmp);
zephir_check_call_status();
_0 = zephir_is_true(_1);
}
@@ -65862,7 +65913,7 @@ static PHP_METHOD(Phalcon_Http_Request_File, moveTo) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_tmp"), PH_NOISY_CC);
- ZEPHIR_RETURN_CALL_FUNCTION("move_uploaded_file", NULL, 232, _0, destination);
+ ZEPHIR_RETURN_CALL_FUNCTION("move_uploaded_file", NULL, 233, _0, destination);
zephir_check_call_status();
RETURN_MM();
@@ -66042,30 +66093,30 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, set) {
object_init_ex(cookie, phalcon_http_cookie_ce);
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, expire);
- ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 235, name, value, _1, path, secure, domain, httpOnly);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 236, name, value, _1, path, secure, domain, httpOnly);
zephir_check_call_status();
_2 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 236, _2);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 237, _2);
zephir_check_call_status();
if (zephir_is_true(encryption)) {
- ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 237, encryption);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 238, encryption);
zephir_check_call_status();
}
zephir_update_property_array(this_ptr, SL("_cookies"), name, cookie TSRMLS_CC);
} else {
- ZEPHIR_CALL_METHOD(NULL, cookie, "setvalue", NULL, 238, value);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setvalue", NULL, 239, value);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_1);
ZVAL_LONG(_1, expire);
- ZEPHIR_CALL_METHOD(NULL, cookie, "setexpiration", NULL, 239, _1);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setexpiration", NULL, 240, _1);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, cookie, "setpath", NULL, 240, path);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setpath", NULL, 241, path);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, cookie, "setsecure", NULL, 241, secure);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setsecure", NULL, 242, secure);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, cookie, "setdomain", NULL, 242, domain);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setdomain", NULL, 243, domain);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, cookie, "sethttponly", NULL, 243, httpOnly);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "sethttponly", NULL, 244, httpOnly);
zephir_check_call_status();
}
_2 = zephir_fetch_nproperty_this(this_ptr, SL("_registered"), PH_NOISY_CC);
@@ -66117,17 +66168,17 @@ static PHP_METHOD(Phalcon_Http_Response_Cookies, get) {
}
ZEPHIR_INIT_NVAR(cookie);
object_init_ex(cookie, phalcon_http_cookie_ce);
- ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 235, name);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 236, name);
zephir_check_call_status();
ZEPHIR_OBS_VAR(dependencyInjector);
zephir_read_property_this(&dependencyInjector, this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
if (Z_TYPE_P(dependencyInjector) == IS_OBJECT) {
- ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 236, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 237, dependencyInjector);
zephir_check_call_status();
ZEPHIR_OBS_VAR(encryption);
zephir_read_property_this(&encryption, this_ptr, SL("_useEncryption"), PH_NOISY_CC);
if (zephir_is_true(encryption)) {
- ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 237, encryption);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 238, encryption);
zephir_check_call_status();
}
}
@@ -66411,10 +66462,10 @@ static PHP_METHOD(Phalcon_Http_Response_Headers, send) {
if (!(ZEPHIR_IS_EMPTY(value))) {
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_VSV(_5, header, ": ", value);
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 244, _5, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 245, _5, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
} else {
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 244, header, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 245, header, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
}
}
@@ -66475,7 +66526,7 @@ static PHP_METHOD(Phalcon_Http_Response_Headers, __set_state) {
) {
ZEPHIR_GET_HMKEY(key, _1, _0);
ZEPHIR_GET_HVALUE(value, _2);
- ZEPHIR_CALL_METHOD(NULL, headers, "set", &_3, 245, key, value);
+ ZEPHIR_CALL_METHOD(NULL, headers, "set", &_3, 246, key, value);
zephir_check_call_status();
}
}
@@ -67529,13 +67580,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, check) {
ZVAL_NULL(version);
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "GD_VERSION", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "defined", NULL, 227, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "defined", NULL, 228, &_1);
zephir_check_call_status();
if (zephir_is_true(_2)) {
ZEPHIR_INIT_NVAR(version);
ZEPHIR_GET_CONSTANT(version, "GD_VERSION");
} else {
- ZEPHIR_CALL_FUNCTION(&info, "gd_info", NULL, 246);
+ ZEPHIR_CALL_FUNCTION(&info, "gd_info", NULL, 247);
zephir_check_call_status();
ZEPHIR_INIT_VAR(matches);
ZVAL_NULL(matches);
@@ -67553,7 +67604,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, check) {
ZVAL_STRING(&_5, "2.0.1", 0);
ZEPHIR_SINIT_VAR(_6);
ZVAL_STRING(&_6, ">=", 0);
- ZEPHIR_CALL_FUNCTION(&_7, "version_compare", NULL, 247, version, &_5, &_6);
+ ZEPHIR_CALL_FUNCTION(&_7, "version_compare", NULL, 248, version, &_5, &_6);
zephir_check_call_status();
if (!(zephir_is_true(_7))) {
ZEPHIR_INIT_NVAR(_3);
@@ -67619,7 +67670,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) {
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_realpath"), _3 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&imageinfo, "getimagesize", NULL, 248, _4);
+ ZEPHIR_CALL_FUNCTION(&imageinfo, "getimagesize", NULL, 249, _4);
zephir_check_call_status();
if (zephir_is_true(imageinfo)) {
zephir_array_fetch_long(&_5, imageinfo, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter/gd.zep", 77 TSRMLS_CC);
@@ -67635,35 +67686,35 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) {
do {
if (ZEPHIR_IS_LONG(_9, 1)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromgif", NULL, 249, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromgif", NULL, 250, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(_9, 2)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromjpeg", NULL, 250, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromjpeg", NULL, 251, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(_9, 3)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefrompng", NULL, 251, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefrompng", NULL, 252, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(_9, 15)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromwbmp", NULL, 252, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromwbmp", NULL, 253, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(_9, 16)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromxbm", NULL, 253, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromxbm", NULL, 254, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
@@ -67688,7 +67739,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) {
} while(0);
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 254, _10, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 255, _10, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
} else {
_16 = !width;
@@ -67711,14 +67762,14 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) {
ZVAL_LONG(&_17, width);
ZEPHIR_SINIT_VAR(_18);
ZVAL_LONG(&_18, height);
- ZEPHIR_CALL_FUNCTION(&_3, "imagecreatetruecolor", NULL, 255, &_17, &_18);
+ ZEPHIR_CALL_FUNCTION(&_3, "imagecreatetruecolor", NULL, 256, &_17, &_18);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _3 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 256, _4, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, _4, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 254, _9, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 255, _9, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
zephir_update_property_this(this_ptr, SL("_realpath"), _10 TSRMLS_CC);
@@ -67757,7 +67808,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) {
ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION");
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "5.5.0", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 247, _0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1);
zephir_check_call_status();
if (ZEPHIR_LT_LONG(_2, 0)) {
ZEPHIR_OBS_VAR(pre_width);
@@ -67805,11 +67856,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) {
ZVAL_LONG(&_14, 0);
ZEPHIR_SINIT_VAR(_15);
ZVAL_LONG(&_15, 0);
- ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresized", NULL, 257, image, _9, &_12, &_13, &_14, &_15, pre_width, pre_height, _10, _11);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresized", NULL, 258, image, _9, &_12, &_13, &_14, &_15, pre_width, pre_height, _10, _11);
zephir_check_call_status();
if (zephir_is_true(_16)) {
_17 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 258, _17);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _17);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
}
@@ -67833,17 +67884,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) {
ZVAL_LONG(&_15, width);
ZEPHIR_SINIT_VAR(_21);
ZVAL_LONG(&_21, height);
- ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresampled", NULL, 259, image, _9, &_6, &_12, &_13, &_14, &_15, &_21, pre_width, pre_height);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresampled", NULL, 260, image, _9, &_6, &_12, &_13, &_14, &_15, &_21, pre_width, pre_height);
zephir_check_call_status();
if (zephir_is_true(_16)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 258, _10);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_22, "imagesx", &_23, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_22, "imagesx", &_23, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _22 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_24, "imagesy", &_25, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_24, "imagesy", &_25, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _24 TSRMLS_CC);
}
@@ -67853,16 +67904,16 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) {
ZVAL_LONG(&_6, width);
ZEPHIR_SINIT_NVAR(_12);
ZVAL_LONG(&_12, height);
- ZEPHIR_CALL_FUNCTION(&image, "imagescale", NULL, 262, _3, &_6, &_12);
+ ZEPHIR_CALL_FUNCTION(&image, "imagescale", NULL, 263, _3, &_6, &_12);
zephir_check_call_status();
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 258, _5);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _5);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_23, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_23, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _16 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_22, "imagesy", &_25, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_22, "imagesy", &_25, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _22 TSRMLS_CC);
}
@@ -67889,7 +67940,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) {
ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION");
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "5.5.0", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 247, _0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1);
zephir_check_call_status();
if (ZEPHIR_LT_LONG(_2, 0)) {
ZEPHIR_INIT_VAR(_3);
@@ -67915,17 +67966,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) {
ZVAL_LONG(&_11, width);
ZEPHIR_SINIT_VAR(_12);
ZVAL_LONG(&_12, height);
- ZEPHIR_CALL_FUNCTION(&_13, "imagecopyresampled", NULL, 259, image, _5, &_1, &_6, &_7, &_8, &_9, &_10, &_11, &_12);
+ ZEPHIR_CALL_FUNCTION(&_13, "imagecopyresampled", NULL, 260, image, _5, &_1, &_6, &_7, &_8, &_9, &_10, &_11, &_12);
zephir_check_call_status();
if (zephir_is_true(_13)) {
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 258, _14);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 259, _14);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_17, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_17, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _16 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_18, "imagesy", &_19, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_18, "imagesy", &_19, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _18 TSRMLS_CC);
}
@@ -67945,16 +67996,16 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) {
ZVAL_LONG(_3, height);
zephir_array_update_string(&rect, SL("height"), &_3, PH_COPY | PH_SEPARATE);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&image, "imagecrop", NULL, 263, _5, rect);
+ ZEPHIR_CALL_FUNCTION(&image, "imagecrop", NULL, 264, _5, rect);
zephir_check_call_status();
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 258, _14);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 259, _14);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_13, "imagesx", &_17, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_13, "imagesx", &_17, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _13 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_16, "imagesy", &_19, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagesy", &_19, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _16 TSRMLS_CC);
}
@@ -67982,20 +68033,20 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _rotate) {
ZVAL_LONG(&_3, 0);
ZEPHIR_SINIT_VAR(_4);
ZVAL_LONG(&_4, 127);
- ZEPHIR_CALL_FUNCTION(&transparent, "imagecolorallocatealpha", NULL, 264, _0, &_1, &_2, &_3, &_4);
+ ZEPHIR_CALL_FUNCTION(&transparent, "imagecolorallocatealpha", NULL, 265, _0, &_1, &_2, &_3, &_4);
zephir_check_call_status();
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, (360 - degrees));
ZEPHIR_SINIT_NVAR(_2);
ZVAL_LONG(&_2, 1);
- ZEPHIR_CALL_FUNCTION(&image, "imagerotate", NULL, 265, _5, &_1, transparent, &_2);
+ ZEPHIR_CALL_FUNCTION(&image, "imagerotate", NULL, 266, _5, &_1, transparent, &_2);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 254, image, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, image, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&width, "imagesx", NULL, 260, image);
+ ZEPHIR_CALL_FUNCTION(&width, "imagesx", NULL, 261, image);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&height, "imagesy", NULL, 261, image);
+ ZEPHIR_CALL_FUNCTION(&height, "imagesy", NULL, 262, image);
zephir_check_call_status();
_6 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
@@ -68008,11 +68059,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _rotate) {
ZVAL_LONG(&_4, 0);
ZEPHIR_SINIT_VAR(_7);
ZVAL_LONG(&_7, 100);
- ZEPHIR_CALL_FUNCTION(&_8, "imagecopymerge", NULL, 266, _6, image, &_1, &_2, &_3, &_4, width, height, &_7);
+ ZEPHIR_CALL_FUNCTION(&_8, "imagecopymerge", NULL, 267, _6, image, &_1, &_2, &_3, &_4, width, height, &_7);
zephir_check_call_status();
if (zephir_is_true(_8)) {
_9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, _9);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _9);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_width"), width TSRMLS_CC);
@@ -68038,7 +68089,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) {
ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION");
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "5.5.0", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 247, _0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1);
zephir_check_call_status();
if (ZEPHIR_LT_LONG(_2, 0)) {
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
@@ -68066,7 +68117,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) {
ZVAL_LONG(&_11, 0);
ZEPHIR_SINIT_NVAR(_12);
ZVAL_LONG(&_12, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, image, _6, &_1, &_9, &_10, &_11, &_12, _8);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, image, _6, &_1, &_9, &_10, &_11, &_12, _8);
zephir_check_call_status();
}
} else {
@@ -68090,18 +68141,18 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) {
ZVAL_LONG(&_11, ((zephir_get_numberval(_7) - x) - 1));
ZEPHIR_SINIT_NVAR(_12);
ZVAL_LONG(&_12, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, image, _6, &_1, &_9, &_10, &_11, _8, &_12);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, image, _6, &_1, &_9, &_10, &_11, _8, &_12);
zephir_check_call_status();
}
}
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, _5);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _5);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_14, "imagesx", NULL, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_14, "imagesx", NULL, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _14 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_15, "imagesy", NULL, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_15, "imagesy", NULL, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _15 TSRMLS_CC);
} else {
@@ -68109,13 +68160,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) {
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 268, _3, &_1);
+ ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 269, _3, &_1);
zephir_check_call_status();
} else {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 2);
- ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 268, _4, &_1);
+ ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 269, _4, &_1);
zephir_check_call_status();
}
}
@@ -68138,7 +68189,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _sharpen) {
ZEPHIR_INIT_VAR(_0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, (-18 + ((amount * 0.08))));
- ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 192, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 2);
@@ -68187,15 +68238,15 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _sharpen) {
ZVAL_LONG(&_6, (amount - 8));
ZEPHIR_SINIT_VAR(_7);
ZVAL_LONG(&_7, 0);
- ZEPHIR_CALL_FUNCTION(&_8, "imageconvolution", NULL, 269, _5, matrix, &_6, &_7);
+ ZEPHIR_CALL_FUNCTION(&_8, "imageconvolution", NULL, 270, _5, matrix, &_6, &_7);
zephir_check_call_status();
if (zephir_is_true(_8)) {
_9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "imagesx", NULL, 260, _9);
+ ZEPHIR_CALL_FUNCTION(&_10, "imagesx", NULL, 261, _9);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _10 TSRMLS_CC);
_11 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_12, "imagesy", NULL, 261, _11);
+ ZEPHIR_CALL_FUNCTION(&_12, "imagesy", NULL, 262, _11);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _12 TSRMLS_CC);
}
@@ -68221,7 +68272,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZEPHIR_INIT_VAR(_0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_DOUBLE(&_1, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127)));
- ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 192, &_1);
zephir_check_call_status();
zephir_round(_0, _2, NULL, NULL TSRMLS_CC);
opacity = zephir_get_intval(_0);
@@ -68247,7 +68298,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZVAL_LONG(&_11, 0);
ZEPHIR_SINIT_VAR(_12);
ZVAL_LONG(&_12, 0);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, reflection, _7, &_1, &_10, &_11, &_12, _8, _9);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, reflection, _7, &_1, &_10, &_11, &_12, _8, _9);
zephir_check_call_status();
offset = 0;
while (1) {
@@ -68288,7 +68339,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZVAL_LONG(&_21, src_y);
ZEPHIR_SINIT_NVAR(_22);
ZVAL_LONG(&_22, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, line, _18, &_11, &_12, &_20, &_21, _19, &_22);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, line, _18, &_11, &_12, &_20, &_21, _19, &_22);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_11);
ZVAL_LONG(&_11, 4);
@@ -68300,7 +68351,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZVAL_LONG(&_21, 0);
ZEPHIR_SINIT_NVAR(_22);
ZVAL_LONG(&_22, dst_opacity);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_23, 270, line, &_11, &_12, &_20, &_21, &_22);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_23, 271, line, &_11, &_12, &_20, &_21, &_22);
zephir_check_call_status();
_24 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_11);
@@ -68313,18 +68364,18 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZVAL_LONG(&_21, 0);
ZEPHIR_SINIT_NVAR(_22);
ZVAL_LONG(&_22, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, reflection, line, &_11, &_12, &_20, &_21, _24, &_22);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, reflection, line, &_11, &_12, &_20, &_21, _24, &_22);
zephir_check_call_status();
offset++;
}
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, _14);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _14);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), reflection TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_25, "imagesx", NULL, 260, reflection);
+ ZEPHIR_CALL_FUNCTION(&_25, "imagesx", NULL, 261, reflection);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _25 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_26, "imagesy", NULL, 261, reflection);
+ ZEPHIR_CALL_FUNCTION(&_26, "imagesy", NULL, 262, reflection);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _26 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -68346,21 +68397,21 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) {
ZEPHIR_CALL_METHOD(&_0, watermark, "render", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&overlay, "imagecreatefromstring", NULL, 271, _0);
+ ZEPHIR_CALL_FUNCTION(&overlay, "imagecreatefromstring", NULL, 272, _0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 254, overlay, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, overlay, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 260, overlay);
+ ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 261, overlay);
zephir_check_call_status();
width = zephir_get_intval(_1);
- ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 261, overlay);
+ ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 262, overlay);
zephir_check_call_status();
height = zephir_get_intval(_2);
if (opacity < 100) {
ZEPHIR_INIT_VAR(_3);
ZEPHIR_SINIT_VAR(_4);
ZVAL_DOUBLE(&_4, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127)));
- ZEPHIR_CALL_FUNCTION(&_5, "abs", NULL, 191, &_4);
+ ZEPHIR_CALL_FUNCTION(&_5, "abs", NULL, 192, &_4);
zephir_check_call_status();
zephir_round(_3, _5, NULL, NULL TSRMLS_CC);
opacity = zephir_get_intval(_3);
@@ -68372,11 +68423,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) {
ZVAL_LONG(&_7, 127);
ZEPHIR_SINIT_VAR(_8);
ZVAL_LONG(&_8, opacity);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 264, overlay, &_4, &_6, &_7, &_8);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 265, overlay, &_4, &_6, &_7, &_8);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_4);
ZVAL_LONG(&_4, 3);
- ZEPHIR_CALL_FUNCTION(NULL, "imagelayereffect", NULL, 272, overlay, &_4);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagelayereffect", NULL, 273, overlay, &_4);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_4);
ZVAL_LONG(&_4, 0);
@@ -68386,11 +68437,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) {
ZVAL_LONG(&_7, width);
ZEPHIR_SINIT_NVAR(_8);
ZVAL_LONG(&_8, height);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", NULL, 273, overlay, &_4, &_6, &_7, &_8, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", NULL, 274, overlay, &_4, &_6, &_7, &_8, color);
zephir_check_call_status();
}
_9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 256, _9, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, _9, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_4);
@@ -68405,10 +68456,10 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) {
ZVAL_LONG(&_11, width);
ZEPHIR_SINIT_VAR(_12);
ZVAL_LONG(&_12, height);
- ZEPHIR_CALL_FUNCTION(&_5, "imagecopy", NULL, 267, _10, overlay, &_4, &_6, &_7, &_8, &_11, &_12);
+ ZEPHIR_CALL_FUNCTION(&_5, "imagecopy", NULL, 268, _10, overlay, &_4, &_6, &_7, &_8, &_11, &_12);
zephir_check_call_status();
if (zephir_is_true(_5)) {
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, overlay);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, overlay);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -68440,7 +68491,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZEPHIR_INIT_VAR(_0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_DOUBLE(&_1, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127)));
- ZEPHIR_CALL_FUNCTION(&_2, "abs", &_3, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "abs", &_3, 192, &_1);
zephir_check_call_status();
zephir_round(_0, _2, NULL, NULL TSRMLS_CC);
opacity = zephir_get_intval(_0);
@@ -68449,7 +68500,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_1, size);
ZEPHIR_SINIT_VAR(_4);
ZVAL_LONG(&_4, 0);
- ZEPHIR_CALL_FUNCTION(&space, "imagettfbbox", NULL, 274, &_1, &_4, fontfile, text);
+ ZEPHIR_CALL_FUNCTION(&space, "imagettfbbox", NULL, 275, &_1, &_4, fontfile, text);
zephir_check_call_status();
if (zephir_array_isset_long(space, 0)) {
ZEPHIR_OBS_VAR(_5);
@@ -68483,12 +68534,12 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, (s4 - s0));
- ZEPHIR_CALL_FUNCTION(&_12, "abs", &_3, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_12, "abs", &_3, 192, &_1);
zephir_check_call_status();
width = (zephir_get_numberval(_12) + 10);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, (s5 - s1));
- ZEPHIR_CALL_FUNCTION(&_13, "abs", &_3, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_13, "abs", &_3, 192, &_1);
zephir_check_call_status();
height = (zephir_get_numberval(_13) + 10);
if (offsetX < 0) {
@@ -68508,7 +68559,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_15, b);
ZEPHIR_SINIT_VAR(_16);
ZVAL_LONG(&_16, opacity);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 264, _14, &_1, &_4, &_15, &_16);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 265, _14, &_1, &_4, &_15, &_16);
zephir_check_call_status();
angle = 0;
_18 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
@@ -68520,17 +68571,17 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_15, offsetX);
ZEPHIR_SINIT_NVAR(_16);
ZVAL_LONG(&_16, offsetY);
- ZEPHIR_CALL_FUNCTION(NULL, "imagettftext", NULL, 275, _18, &_1, &_4, &_15, &_16, color, fontfile, text);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagettftext", NULL, 276, _18, &_1, &_4, &_15, &_16, color, fontfile, text);
zephir_check_call_status();
} else {
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, size);
- ZEPHIR_CALL_FUNCTION(&_12, "imagefontwidth", NULL, 276, &_1);
+ ZEPHIR_CALL_FUNCTION(&_12, "imagefontwidth", NULL, 277, &_1);
zephir_check_call_status();
width = (zephir_get_intval(_12) * zephir_fast_strlen_ev(text));
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, size);
- ZEPHIR_CALL_FUNCTION(&_13, "imagefontheight", NULL, 277, &_1);
+ ZEPHIR_CALL_FUNCTION(&_13, "imagefontheight", NULL, 278, &_1);
zephir_check_call_status();
height = zephir_get_intval(_13);
if (offsetX < 0) {
@@ -68550,7 +68601,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_15, b);
ZEPHIR_SINIT_NVAR(_16);
ZVAL_LONG(&_16, opacity);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 264, _14, &_1, &_4, &_15, &_16);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 265, _14, &_1, &_4, &_15, &_16);
zephir_check_call_status();
_19 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
@@ -68559,7 +68610,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_4, offsetX);
ZEPHIR_SINIT_NVAR(_15);
ZVAL_LONG(&_15, offsetY);
- ZEPHIR_CALL_FUNCTION(NULL, "imagestring", NULL, 278, _19, &_1, &_4, &_15, text, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagestring", NULL, 279, _19, &_1, &_4, &_15, text, color);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -68580,22 +68631,22 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZEPHIR_CALL_METHOD(&_0, mask, "render", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&maskImage, "imagecreatefromstring", NULL, 271, _0);
+ ZEPHIR_CALL_FUNCTION(&maskImage, "imagecreatefromstring", NULL, 272, _0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 260, maskImage);
+ ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 261, maskImage);
zephir_check_call_status();
mask_width = zephir_get_intval(_1);
- ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 261, maskImage);
+ ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 262, maskImage);
zephir_check_call_status();
mask_height = zephir_get_intval(_2);
alpha = 127;
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 254, maskImage, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 255, maskImage, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC);
ZEPHIR_CALL_METHOD(&newimage, this_ptr, "_create", NULL, 0, _4, _5);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 254, newimage, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 255, newimage, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_6);
ZVAL_LONG(&_6, 0);
@@ -68605,13 +68656,13 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZVAL_LONG(&_8, 0);
ZEPHIR_SINIT_VAR(_9);
ZVAL_LONG(&_9, alpha);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 264, newimage, &_6, &_7, &_8, &_9);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 265, newimage, &_6, &_7, &_8, &_9);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_6);
ZVAL_LONG(&_6, 0);
ZEPHIR_SINIT_NVAR(_7);
ZVAL_LONG(&_7, 0);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefill", NULL, 279, newimage, &_6, &_7, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefill", NULL, 280, newimage, &_6, &_7, color);
zephir_check_call_status();
_11 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
_12 = !ZEPHIR_IS_LONG(_11, mask_width);
@@ -68622,7 +68673,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
if (_12) {
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
_15 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&tempImage, "imagecreatetruecolor", NULL, 255, _14, _15);
+ ZEPHIR_CALL_FUNCTION(&tempImage, "imagecreatetruecolor", NULL, 256, _14, _15);
zephir_check_call_status();
_16 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
_17 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC);
@@ -68638,9 +68689,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZVAL_LONG(&_18, mask_width);
ZEPHIR_SINIT_VAR(_19);
ZVAL_LONG(&_19, mask_height);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopyresampled", NULL, 259, tempImage, maskImage, &_6, &_7, &_8, &_9, _16, _17, &_18, &_19);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopyresampled", NULL, 260, tempImage, maskImage, &_6, &_7, &_8, &_9, _16, _17, &_18, &_19);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 258, maskImage);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, maskImage);
zephir_check_call_status();
ZEPHIR_CPY_WRT(maskImage, tempImage);
}
@@ -68660,9 +68711,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZVAL_LONG(&_6, x);
ZEPHIR_SINIT_NVAR(_7);
ZVAL_LONG(&_7, y);
- ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 280, maskImage, &_6, &_7);
+ ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 281, maskImage, &_6, &_7);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 281, maskImage, index);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 282, maskImage, index);
zephir_check_call_status();
if (zephir_array_isset_string(color, SS("red"))) {
zephir_array_fetch_string(&_23, color, SL("red"), PH_NOISY | PH_READONLY, "phalcon/image/adapter/gd.zep", 431 TSRMLS_CC);
@@ -68675,10 +68726,10 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZVAL_LONG(&_7, x);
ZEPHIR_SINIT_NVAR(_8);
ZVAL_LONG(&_8, y);
- ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 280, _16, &_7, &_8);
+ ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 281, _16, &_7, &_8);
zephir_check_call_status();
_17 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 281, _17, index);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 282, _17, index);
zephir_check_call_status();
ZEPHIR_OBS_NVAR(r);
zephir_array_fetch_string(&r, color, SL("red"), PH_NOISY, "phalcon/image/adapter/gd.zep", 436 TSRMLS_CC);
@@ -68688,22 +68739,22 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
zephir_array_fetch_string(&b, color, SL("blue"), PH_NOISY, "phalcon/image/adapter/gd.zep", 436 TSRMLS_CC);
ZEPHIR_SINIT_NVAR(_7);
ZVAL_LONG(&_7, alpha);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 264, newimage, r, g, b, &_7);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 265, newimage, r, g, b, &_7);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_7);
ZVAL_LONG(&_7, x);
ZEPHIR_SINIT_NVAR(_8);
ZVAL_LONG(&_8, y);
- ZEPHIR_CALL_FUNCTION(NULL, "imagesetpixel", &_24, 282, newimage, &_7, &_8, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesetpixel", &_24, 283, newimage, &_7, &_8, color);
zephir_check_call_status();
y++;
}
x++;
}
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 258, _14);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, _14);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 258, maskImage);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, maskImage);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), newimage TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -68737,9 +68788,9 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _background) {
ZVAL_LONG(&_4, b);
ZEPHIR_SINIT_VAR(_5);
ZVAL_LONG(&_5, opacity);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 264, background, &_2, &_3, &_4, &_5);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 265, background, &_2, &_3, &_4, &_5);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 256, background, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, background, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_6 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
@@ -68752,11 +68803,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _background) {
ZVAL_LONG(&_4, 0);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, 0);
- ZEPHIR_CALL_FUNCTION(&_9, "imagecopy", NULL, 267, background, _6, &_2, &_3, &_4, &_5, _7, _8);
+ ZEPHIR_CALL_FUNCTION(&_9, "imagecopy", NULL, 268, background, _6, &_2, &_3, &_4, &_5, _7, _8);
zephir_check_call_status();
if (zephir_is_true(_9)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, _10);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), background TSRMLS_CC);
}
@@ -68784,7 +68835,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _blur) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 7);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_2, 270, _0, &_1);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_2, 271, _0, &_1);
zephir_check_call_status();
i++;
}
@@ -68823,7 +68874,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) {
ZVAL_LONG(&_3, x1);
ZEPHIR_SINIT_NVAR(_4);
ZVAL_LONG(&_4, y1);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorat", &_5, 280, _2, &_3, &_4);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorat", &_5, 281, _2, &_3, &_4);
zephir_check_call_status();
x2 = (x + amount);
y2 = (y + amount);
@@ -68836,7 +68887,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) {
ZVAL_LONG(&_7, x2);
ZEPHIR_SINIT_NVAR(_8);
ZVAL_LONG(&_8, y2);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", &_9, 273, _6, &_3, &_4, &_7, &_8, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", &_9, 274, _6, &_3, &_4, &_7, &_8, color);
zephir_check_call_status();
y += amount;
}
@@ -68869,30 +68920,30 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _save) {
zephir_fast_strtolower(ext, _1);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "gif", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_2, 0)) {
ZEPHIR_INIT_ZVAL_NREF(_4);
ZVAL_LONG(_4, 1);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_5, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_5, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _5 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 285, _7, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 286, _7, file);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "jpg", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
_8 = ZEPHIR_IS_LONG(_5, 0);
if (!(_8)) {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "jpeg", 0);
- ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
_8 = ZEPHIR_IS_LONG(_9, 0);
}
@@ -68901,64 +68952,64 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _save) {
ZVAL_LONG(_4, 2);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, quality);
- ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 286, _7, file, &_0);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 287, _7, file, &_0);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "png", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_5, 0)) {
ZEPHIR_INIT_ZVAL_NREF(_4);
ZVAL_LONG(_4, 3);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 287, _7, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 288, _7, file);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "wbmp", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_5, 0)) {
ZEPHIR_INIT_ZVAL_NREF(_4);
ZVAL_LONG(_4, 15);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 288, _7, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 289, _7, file);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "xbm", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_5, 0)) {
ZEPHIR_INIT_ZVAL_NREF(_4);
ZVAL_LONG(_4, 16);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 289, _7, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 290, _7, file);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
@@ -68996,25 +69047,25 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) {
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "gif", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_2, 0)) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 285, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 286, _4);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "jpg", 0);
- ZEPHIR_CALL_FUNCTION(&_6, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_6, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
_7 = ZEPHIR_IS_LONG(_6, 0);
if (!(_7)) {
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "jpeg", 0);
- ZEPHIR_CALL_FUNCTION(&_8, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_8, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
_7 = ZEPHIR_IS_LONG(_8, 0);
}
@@ -69022,45 +69073,45 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, quality);
- ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 286, _4, ZEPHIR_GLOBAL(global_null), &_1);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 287, _4, ZEPHIR_GLOBAL(global_null), &_1);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "png", 0);
- ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_9, 0)) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 287, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 288, _4);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "wbmp", 0);
- ZEPHIR_CALL_FUNCTION(&_10, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_10, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_10, 0)) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 288, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 289, _4);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "xbm", 0);
- ZEPHIR_CALL_FUNCTION(&_11, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_11, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_11, 0)) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 289, _4, ZEPHIR_GLOBAL(global_null));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 290, _4, ZEPHIR_GLOBAL(global_null));
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
@@ -69092,11 +69143,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, _create) {
ZVAL_LONG(&_0, width);
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, height);
- ZEPHIR_CALL_FUNCTION(&image, "imagecreatetruecolor", NULL, 255, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&image, "imagecreatetruecolor", NULL, 256, &_0, &_1);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 256, image, ZEPHIR_GLOBAL(global_false));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, image, ZEPHIR_GLOBAL(global_false));
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 254, image, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, image, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
RETURN_CCTOR(image);
@@ -69112,7 +69163,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Gd, __destruct) {
ZEPHIR_OBS_VAR(image);
zephir_read_property_this(&image, this_ptr, SL("_image"), PH_NOISY_CC);
if (Z_TYPE_P(image) == IS_RESOURCE) {
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, image);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, image);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -69165,12 +69216,12 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, check) {
}
ZEPHIR_SINIT_VAR(_2);
ZVAL_STRING(&_2, "Imagick::IMAGICK_EXTNUM", 0);
- ZEPHIR_CALL_FUNCTION(&_3, "defined", NULL, 227, &_2);
+ ZEPHIR_CALL_FUNCTION(&_3, "defined", NULL, 228, &_2);
zephir_check_call_status();
if (zephir_is_true(_3)) {
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "Imagick::IMAGICK_EXTNUM", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 189, &_2);
+ ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 190, &_2);
zephir_check_call_status();
zephir_update_static_property_ce(phalcon_image_adapter_imagick_ce, SL("_version"), &_4 TSRMLS_CC);
}
@@ -69255,7 +69306,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, __construct) {
_12 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_13);
ZVAL_STRING(&_13, "Imagick::ALPHACHANNEL_SET", 0);
- ZEPHIR_CALL_FUNCTION(&_14, "constant", NULL, 189, &_13);
+ ZEPHIR_CALL_FUNCTION(&_14, "constant", NULL, 190, &_13);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, _12, "setimagealphachannel", NULL, 0, _14);
zephir_check_call_status();
@@ -69727,7 +69778,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
while (1) {
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::COMPOSITE_DSTOUT", 0);
- ZEPHIR_CALL_FUNCTION(&_12, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_12, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_3);
ZVAL_LONG(_3, 0);
@@ -69741,11 +69792,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
}
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::EVALUATE_MULTIPLY", 0);
- ZEPHIR_CALL_FUNCTION(&_17, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_17, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::CHANNEL_ALPHA", 0);
- ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_3);
ZVAL_LONG(_3, opacity);
@@ -69788,7 +69839,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::ALPHACHANNEL_SET", 0);
- ZEPHIR_CALL_FUNCTION(&_9, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_9, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, image, "setimagealphachannel", &_25, 0, _9);
zephir_check_call_status();
@@ -69805,7 +69856,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
_30 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::COMPOSITE_SRC", 0);
- ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_3);
ZVAL_LONG(_3, 0);
@@ -69835,7 +69886,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
while (1) {
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::COMPOSITE_OVER", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_2, "constant", &_15, 190, &_14);
zephir_check_call_status();
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC);
ZEPHIR_INIT_NVAR(_3);
@@ -69917,7 +69968,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _watermark) {
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_4);
ZVAL_STRING(&_4, "Imagick::COMPOSITE_OVER", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "constant", &_6, 189, &_4);
+ ZEPHIR_CALL_FUNCTION(&_5, "constant", &_6, 190, &_4);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_1);
ZVAL_LONG(_1, offsetX);
@@ -69980,7 +70031,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _text) {
ZVAL_LONG(&_2, g);
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, b);
- ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 186, &_0, &_1, &_2, &_3);
+ ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 187, &_0, &_1, &_2, &_3);
zephir_check_call_status();
ZEPHIR_INIT_VAR(pixel);
object_init_ex(pixel, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC));
@@ -70009,23 +70060,23 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _text) {
if (offsetX < 0) {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, offsetX);
- ZEPHIR_CALL_FUNCTION(&_5, "abs", &_6, 191, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "abs", &_6, 192, &_0);
zephir_check_call_status();
offsetX = zephir_get_numberval(_5);
if (offsetY < 0) {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, offsetY);
- ZEPHIR_CALL_FUNCTION(&_7, "abs", &_6, 191, &_0);
+ ZEPHIR_CALL_FUNCTION(&_7, "abs", &_6, 192, &_0);
zephir_check_call_status();
offsetY = zephir_get_numberval(_7);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0);
- ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 190, &_0);
zephir_check_call_status();
} else {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHEAST", 0);
- ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 190, &_0);
zephir_check_call_status();
}
}
@@ -70094,7 +70145,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _mask) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Imagick::COMPOSITE_DSTIN", 0);
- ZEPHIR_CALL_FUNCTION(&_6, "constant", &_7, 189, &_5);
+ ZEPHIR_CALL_FUNCTION(&_6, "constant", &_7, 190, &_5);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_2);
ZVAL_LONG(_2, 0);
@@ -70144,7 +70195,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) {
ZVAL_LONG(&_2, g);
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, b);
- ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 186, &_0, &_1, &_2, &_3);
+ ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 187, &_0, &_1, &_2, &_3);
zephir_check_call_status();
ZEPHIR_INIT_VAR(pixel1);
object_init_ex(pixel1, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC));
@@ -70183,7 +70234,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) {
if (!(zephir_is_true(_9))) {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::ALPHACHANNEL_SET", 0);
- ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 190, &_0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, background, "setimagealphachannel", &_13, 0, _11);
zephir_check_call_status();
@@ -70192,11 +70243,11 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) {
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::EVALUATE_MULTIPLY", 0);
- ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 190, &_0);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::CHANNEL_ALPHA", 0);
- ZEPHIR_CALL_FUNCTION(&_15, "constant", &_12, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_15, "constant", &_12, 190, &_0);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_4);
ZVAL_LONG(_4, opacity);
@@ -70210,7 +70261,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) {
_20 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::COMPOSITE_DISSOLVE", 0);
- ZEPHIR_CALL_FUNCTION(&_21, "constant", &_12, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_21, "constant", &_12, 190, &_0);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_4);
ZVAL_LONG(_4, 0);
@@ -70364,7 +70415,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) {
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "w", 0);
- ZEPHIR_CALL_FUNCTION(&fp, "fopen", NULL, 291, file, &_0);
+ ZEPHIR_CALL_FUNCTION(&fp, "fopen", NULL, 292, file, &_0);
zephir_check_call_status();
_11 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_CALL_METHOD(NULL, _11, "writeimagesfile", NULL, 0, fp);
@@ -70388,7 +70439,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::COMPRESSION_JPEG", 0);
- ZEPHIR_CALL_FUNCTION(&_15, "constant", NULL, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_15, "constant", NULL, 190, &_0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, _10, "setimagecompression", NULL, 0, _15);
zephir_check_call_status();
@@ -70460,7 +70511,7 @@ static PHP_METHOD(Phalcon_Image_Adapter_Imagick, _render) {
if (_7) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_STRING(&_3, "Imagick::COMPRESSION_JPEG", 0);
- ZEPHIR_CALL_FUNCTION(&_9, "constant", NULL, 189, &_3);
+ ZEPHIR_CALL_FUNCTION(&_9, "constant", NULL, 190, &_3);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, image, "setimagecompression", NULL, 0, _9);
zephir_check_call_status();
@@ -71859,7 +71910,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, __construct) {
ZEPHIR_INIT_NVAR(mode);
ZVAL_STRING(mode, "ab", 1);
}
- ZEPHIR_CALL_FUNCTION(&handler, "fopen", NULL, 291, name, mode);
+ ZEPHIR_CALL_FUNCTION(&handler, "fopen", NULL, 292, name, mode);
zephir_check_call_status();
if (Z_TYPE_P(handler) != IS_RESOURCE) {
ZEPHIR_INIT_VAR(_0);
@@ -71891,7 +71942,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, getFormatter) {
if (Z_TYPE_P(_0) != IS_OBJECT) {
ZEPHIR_INIT_VAR(_1);
object_init_ex(_1, phalcon_logger_formatter_line_ce);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 295);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 296);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_formatter"), _1 TSRMLS_CC);
}
@@ -71903,7 +71954,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, logInternal) {
zval *context = NULL;
int type, time, ZEPHIR_LAST_CALL_STATUS;
- zval *message_param = NULL, *type_param = NULL, *time_param = NULL, *context_param = NULL, *fileHandler, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3, *_4;
+ zval *message_param = NULL, *type_param = NULL, *time_param = NULL, *context_param = NULL, *fileHandler, *_0 = NULL, *_1 = NULL, *_2, *_3;
zval *message = NULL;
ZEPHIR_MM_GROW();
@@ -71929,11 +71980,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, logInternal) {
ZVAL_LONG(_3, time);
ZEPHIR_CALL_METHOD(&_1, _0, "format", NULL, 0, message, _2, _3, context);
zephir_check_call_status();
- ZEPHIR_INIT_NVAR(_2);
- ZEPHIR_GET_CONSTANT(_2, "PHP_EOL");
- ZEPHIR_INIT_VAR(_4);
- ZEPHIR_CONCAT_VV(_4, _1, _2);
- zephir_fwrite(NULL, fileHandler, _4 TSRMLS_CC);
+ zephir_fwrite(NULL, fileHandler, _1 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
}
@@ -71975,7 +72022,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_File, __wakeup) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_logger_exception_ce, "Logger must be opened in append or write mode", "phalcon/logger/adapter/file.zep", 152);
return;
}
- ZEPHIR_CALL_FUNCTION(&_1, "fopen", NULL, 291, path, mode);
+ ZEPHIR_CALL_FUNCTION(&_1, "fopen", NULL, 292, path, mode);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_fileHandler"), _1 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -72060,15 +72107,15 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) {
if (!ZEPHIR_IS_TRUE_IDENTICAL(_1)) {
ZEPHIR_SINIT_VAR(_2);
ZVAL_STRING(&_2, "X-Wf-Protocol-1: http://meta.wildfirehq.org/Protocol/JsonStream/0.2", 0);
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 244, &_2);
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "X-Wf-1-Plugin-1: http://meta.firephp.org/Wildfire/Plugin/FirePHP/Library-FirePHPCore/0.3", 0);
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 244, &_2);
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "X-Wf-Structure-1: http://meta.firephp.org/Wildfire/Structure/FirePHP/FirebugConsole/0.1", 0);
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 244, &_2);
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2);
zephir_check_call_status();
zephir_update_static_property_ce(phalcon_logger_adapter_firephp_ce, SL("_initialized"), &(ZEPHIR_GLOBAL(global_true)) TSRMLS_CC);
}
@@ -72098,7 +72145,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) {
if (zephir_array_isset_long(chunk, (zephir_get_numberval(key) + 1))) {
zephir_concat_self_str(&content, SL("|\\") TSRMLS_CC);
}
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 244, content);
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, content);
zephir_check_call_status();
_10 = zephir_fetch_static_property_ce(phalcon_logger_adapter_firephp_ce, SL("_index") TSRMLS_CC);
ZEPHIR_INIT_ZVAL_NREF(_11);
@@ -72176,7 +72223,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Stream, __construct) {
ZEPHIR_INIT_NVAR(mode);
ZVAL_STRING(mode, "ab", 1);
}
- ZEPHIR_CALL_FUNCTION(&stream, "fopen", NULL, 291, name, mode);
+ ZEPHIR_CALL_FUNCTION(&stream, "fopen", NULL, 292, name, mode);
zephir_check_call_status();
if (!(zephir_is_true(stream))) {
ZEPHIR_INIT_VAR(_0);
@@ -72206,7 +72253,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Stream, getFormatter) {
if (Z_TYPE_P(_0) != IS_OBJECT) {
ZEPHIR_INIT_VAR(_1);
object_init_ex(_1, phalcon_logger_formatter_line_ce);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 295);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 296);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_formatter"), _1 TSRMLS_CC);
}
@@ -72308,7 +72355,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, __construct) {
ZEPHIR_INIT_NVAR(facility);
ZVAL_LONG(facility, 8);
}
- ZEPHIR_CALL_FUNCTION(NULL, "openlog", NULL, 296, name, option, facility);
+ ZEPHIR_CALL_FUNCTION(NULL, "openlog", NULL, 297, name, option, facility);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_opened"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
}
@@ -72368,7 +72415,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, logInternal) {
}
zephir_array_fetch_long(&_3, appliedFormat, 0, PH_NOISY | PH_READONLY, "phalcon/logger/adapter/syslog.zep", 102 TSRMLS_CC);
zephir_array_fetch_long(&_4, appliedFormat, 1, PH_NOISY | PH_READONLY, "phalcon/logger/adapter/syslog.zep", 102 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "syslog", NULL, 297, _3, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "syslog", NULL, 298, _3, _4);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -72383,7 +72430,7 @@ static PHP_METHOD(Phalcon_Logger_Adapter_Syslog, close) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_opened"), PH_NOISY_CC);
if (zephir_is_true(_0)) {
- ZEPHIR_CALL_FUNCTION(NULL, "closelog", NULL, 298);
+ ZEPHIR_CALL_FUNCTION(NULL, "closelog", NULL, 299);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -72540,15 +72587,15 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Firephp, format) {
ZVAL_STRING(&_3, "5.3.6", 0);
ZEPHIR_SINIT_VAR(_4);
ZVAL_STRING(&_4, "<", 0);
- ZEPHIR_CALL_FUNCTION(&_0, "version_compare", NULL, 247, _1, &_3, &_4);
+ ZEPHIR_CALL_FUNCTION(&_0, "version_compare", NULL, 248, _1, &_3, &_4);
zephir_check_call_status();
if (!(zephir_is_true(_0))) {
param = (2) ? 1 : 0;
}
- ZEPHIR_CALL_FUNCTION(&backtrace, "debug_backtrace", NULL, 149, (param ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_FUNCTION(&backtrace, "debug_backtrace", NULL, 150, (param ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
Z_SET_ISREF_P(backtrace);
- ZEPHIR_CALL_FUNCTION(&lastTrace, "end", NULL, 169, backtrace);
+ ZEPHIR_CALL_FUNCTION(&lastTrace, "end", NULL, 170, backtrace);
Z_UNSET_ISREF_P(backtrace);
zephir_check_call_status();
if (zephir_array_isset_string(lastTrace, SS("file"))) {
@@ -72642,9 +72689,9 @@ ZEPHIR_INIT_CLASS(Phalcon_Logger_Formatter_Json) {
static PHP_METHOD(Phalcon_Logger_Formatter_Json, format) {
- zval *_1;
+ zval *_2;
int type, timestamp, ZEPHIR_LAST_CALL_STATUS;
- zval *message_param = NULL, *type_param = NULL, *timestamp_param = NULL, *context = NULL, *_0 = NULL, *_2 = NULL;
+ zval *message_param = NULL, *type_param = NULL, *timestamp_param = NULL, *context = NULL, *_0 = NULL, *_1, *_3 = NULL;
zval *message = NULL;
ZEPHIR_MM_GROW();
@@ -72664,17 +72711,21 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Json, format) {
zephir_get_strval(message, _0);
}
ZEPHIR_INIT_VAR(_1);
- zephir_create_array(_1, 3, 0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_2);
- ZVAL_LONG(_2, type);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "gettypestring", NULL, 0, _2);
+ zephir_create_array(_2, 3, 0 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_3);
+ ZVAL_LONG(_3, type);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "gettypestring", NULL, 0, _3);
zephir_check_call_status();
- zephir_array_update_string(&_1, SL("type"), &_0, PH_COPY | PH_SEPARATE);
- zephir_array_update_string(&_1, SL("message"), &message, PH_COPY | PH_SEPARATE);
- ZEPHIR_INIT_NVAR(_2);
- ZVAL_LONG(_2, timestamp);
- zephir_array_update_string(&_1, SL("timestamp"), &_2, PH_COPY | PH_SEPARATE);
- zephir_json_encode(return_value, &(return_value), _1, 0 TSRMLS_CC);
+ zephir_array_update_string(&_2, SL("type"), &_0, PH_COPY | PH_SEPARATE);
+ zephir_array_update_string(&_2, SL("message"), &message, PH_COPY | PH_SEPARATE);
+ ZEPHIR_INIT_NVAR(_3);
+ ZVAL_LONG(_3, timestamp);
+ zephir_array_update_string(&_2, SL("timestamp"), &_3, PH_COPY | PH_SEPARATE);
+ zephir_json_encode(_1, &(_1), _2, 0 TSRMLS_CC);
+ ZEPHIR_INIT_NVAR(_3);
+ ZEPHIR_GET_CONSTANT(_3, "PHP_EOL");
+ ZEPHIR_CONCAT_VV(return_value, _1, _3);
RETURN_MM();
}
@@ -72770,7 +72821,7 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, __construct) {
static PHP_METHOD(Phalcon_Logger_Formatter_Line, format) {
int type, timestamp, ZEPHIR_LAST_CALL_STATUS;
- zval *message_param = NULL, *type_param = NULL, *timestamp_param = NULL, *context = NULL, *format = NULL, *_0 = NULL, *_1, _2 = zval_used_for_init, *_3 = NULL, *_4;
+ zval *message_param = NULL, *type_param = NULL, *timestamp_param = NULL, *context = NULL, *format = NULL, *_0 = NULL, *_1, _2 = zval_used_for_init, *_3 = NULL, *_4 = NULL, *_5;
zval *message = NULL;
ZEPHIR_MM_GROW();
@@ -72791,7 +72842,7 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, format) {
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_dateFormat"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_2);
ZVAL_LONG(&_2, timestamp);
- ZEPHIR_CALL_FUNCTION(&_3, "date", NULL, 299, _1, &_2);
+ ZEPHIR_CALL_FUNCTION(&_3, "date", NULL, 300, _1, &_2);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "%date%", 0);
@@ -72813,7 +72864,11 @@ static PHP_METHOD(Phalcon_Logger_Formatter_Line, format) {
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "%message%", 0);
zephir_fast_str_replace(&_0, &_2, message, format TSRMLS_CC);
- ZEPHIR_CPY_WRT(format, _0);
+ ZEPHIR_INIT_NVAR(_4);
+ ZEPHIR_GET_CONSTANT(_4, "PHP_EOL");
+ ZEPHIR_INIT_VAR(_5);
+ ZEPHIR_CONCAT_VV(_5, _0, _4);
+ ZEPHIR_CPY_WRT(format, _5);
if (Z_TYPE_P(context) == IS_ARRAY) {
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "interpolate", NULL, 0, format, context);
zephir_check_call_status();
@@ -73841,7 +73896,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, _getResultset) {
}
ZEPHIR_INIT_VAR(collections);
array_init(collections);
- ZEPHIR_CALL_FUNCTION(&_0, "iterator_to_array", NULL, 300, documentsCursor);
+ ZEPHIR_CALL_FUNCTION(&_0, "iterator_to_array", NULL, 301, documentsCursor);
zephir_check_call_status();
zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/collection.zep", 440);
for (
@@ -74304,7 +74359,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, save) {
zephir_update_property_this(this_ptr, SL("_errorMessages"), _1 TSRMLS_CC);
ZEPHIR_OBS_VAR(disableEvents);
zephir_read_static_property_ce(&disableEvents, phalcon_mvc_collection_ce, SL("_disableEvents") TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_2, this_ptr, "_presave", NULL, 301, dependencyInjector, disableEvents, exists);
+ ZEPHIR_CALL_METHOD(&_2, this_ptr, "_presave", NULL, 302, dependencyInjector, disableEvents, exists);
zephir_check_call_status();
if (ZEPHIR_IS_FALSE_IDENTICAL(_2)) {
RETURN_MM_BOOL(0);
@@ -74333,7 +74388,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection, save) {
} else {
success = 0;
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_postsave", NULL, 302, disableEvents, (success ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), exists);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_postsave", NULL, 303, disableEvents, (success ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), exists);
zephir_check_call_status();
RETURN_MM();
@@ -75662,7 +75717,7 @@ static PHP_METHOD(Phalcon_Mvc_Micro, mount) {
if (zephir_is_true(_0)) {
ZEPHIR_INIT_VAR(lazyHandler);
object_init_ex(lazyHandler, phalcon_mvc_micro_lazyloader_ce);
- ZEPHIR_CALL_METHOD(NULL, lazyHandler, "__construct", NULL, 303, mainHandler);
+ ZEPHIR_CALL_METHOD(NULL, lazyHandler, "__construct", NULL, 304, mainHandler);
zephir_check_call_status();
} else {
ZEPHIR_CPY_WRT(lazyHandler, mainHandler);
@@ -75811,11 +75866,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, setService) {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
ZEPHIR_INIT_NVAR(dependencyInjector);
object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce);
- ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 173);
+ ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "set", NULL, 304, serviceName, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "set", NULL, 305, serviceName, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -75848,11 +75903,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, hasService) {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
ZEPHIR_INIT_NVAR(dependencyInjector);
object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce);
- ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 173);
+ ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "has", NULL, 305, serviceName);
+ ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "has", NULL, 306, serviceName);
zephir_check_call_status();
RETURN_MM();
@@ -75885,11 +75940,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, getService) {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
ZEPHIR_INIT_NVAR(dependencyInjector);
object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce);
- ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 173);
+ ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "get", NULL, 306, serviceName);
+ ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "get", NULL, 307, serviceName);
zephir_check_call_status();
RETURN_MM();
@@ -75910,11 +75965,11 @@ static PHP_METHOD(Phalcon_Mvc_Micro, getSharedService) {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
ZEPHIR_INIT_NVAR(dependencyInjector);
object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce);
- ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 173);
+ ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "getshared", NULL, 307, serviceName);
+ ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "getshared", NULL, 308, serviceName);
zephir_check_call_status();
RETURN_MM();
@@ -77404,12 +77459,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, query) {
ZEPHIR_CALL_METHOD(NULL, criteria, "__construct", NULL, 0);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(NULL, criteria, "setdi", NULL, 308, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "setdi", NULL, 309, dependencyInjector);
zephir_check_call_status();
}
ZEPHIR_INIT_NVAR(_2);
zephir_get_called_class(_2 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 309, _2);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 310, _2);
zephir_check_call_status();
RETURN_CCTOR(criteria);
@@ -78964,9 +79019,9 @@ static PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) {
break;
}
if (ZEPHIR_IS_LONG(bindType, 3) || ZEPHIR_IS_LONG(bindType, 7)) {
- ZEPHIR_CALL_FUNCTION(&_1, "floatval", &_8, 310, snapshotValue);
+ ZEPHIR_CALL_FUNCTION(&_1, "floatval", &_8, 311, snapshotValue);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_9, "floatval", &_8, 310, value);
+ ZEPHIR_CALL_FUNCTION(&_9, "floatval", &_8, 311, value);
zephir_check_call_status();
changed = !ZEPHIR_IS_IDENTICAL(_1, _9);
break;
@@ -79403,7 +79458,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, save) {
ZEPHIR_INIT_NVAR(_4);
object_init_ex(_4, phalcon_mvc_model_validationfailed_ce);
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_errorMessages"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 311, this_ptr, _3);
+ ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 312, this_ptr, _3);
zephir_check_call_status();
zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 2877 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -80191,7 +80246,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) {
int ZEPHIR_LAST_CALL_STATUS;
HashTable *_1;
HashPosition _0;
- zval *data_param = NULL, *columnMap = NULL, *key = NULL, *value = NULL, *snapshot, *attribute = NULL, **_2, *_3 = NULL, *_4 = NULL, *_6 = NULL;
+ zval *data_param = NULL, *columnMap = NULL, *key = NULL, *value = NULL, *snapshot, *attribute = NULL, **_2, *_3 = NULL, *_4 = NULL;
zval *data = NULL;
ZEPHIR_MM_GROW();
@@ -80207,7 +80262,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) {
if (Z_TYPE_P(columnMap) == IS_ARRAY) {
ZEPHIR_INIT_VAR(snapshot);
array_init(snapshot);
- zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3606);
+ zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3605);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -80250,12 +80305,8 @@ static PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) {
continue;
}
}
- ZEPHIR_OBS_NVAR(_6);
- zephir_array_fetch_long(&_6, attribute, 0, PH_NOISY, "phalcon/mvc/model.zep", 3600 TSRMLS_CC);
- zephir_array_update_zval(&snapshot, _6, &value, PH_COPY | PH_SEPARATE);
- } else {
- zephir_array_update_zval(&snapshot, attribute, &value, PH_COPY | PH_SEPARATE);
}
+ zephir_array_update_zval(&snapshot, attribute, &value, PH_COPY | PH_SEPARATE);
}
zephir_update_property_this(this_ptr, SL("_snapshot"), snapshot TSRMLS_CC);
RETURN_MM_NULL();
@@ -80300,12 +80351,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_OBS_VAR(snapshot);
zephir_read_property_this(&snapshot, this_ptr, SL("_snapshot"), PH_NOISY_CC);
if (Z_TYPE_P(snapshot) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3645);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3644);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC);
if (!ZEPHIR_IS_LONG(_0, 0)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3652);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3651);
return;
}
ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0);
@@ -80327,7 +80378,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not part of the model");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3684 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3683 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80339,7 +80390,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not part of the model");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3688 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3687 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80352,7 +80403,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not defined on the model");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3696 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3695 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80364,14 +80415,14 @@ static PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_CONCAT_SVS(_3, "The field '", fieldName, "' was not found in the snapshot");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3703 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3702 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
RETURN_MM_BOOL(!ZEPHIR_IS_EQUAL(value, originalValue));
}
ZEPHIR_INIT_NVAR(_1);
- zephir_is_iterable(allAttributes, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 3739);
+ zephir_is_iterable(allAttributes, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 3738);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
@@ -80406,12 +80457,12 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) {
ZEPHIR_OBS_VAR(snapshot);
zephir_read_property_this(&snapshot, this_ptr, SL("_snapshot"), PH_NOISY_CC);
if (Z_TYPE_P(snapshot) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3752);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3751);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC);
if (!ZEPHIR_IS_LONG(_0, 0)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3759);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3758);
return;
}
ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0);
@@ -80427,7 +80478,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) {
ZEPHIR_INIT_VAR(changed);
array_init(changed);
ZEPHIR_INIT_VAR(_1);
- zephir_is_iterable(allAttributes, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3813);
+ zephir_is_iterable(allAttributes, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3812);
for (
; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS
; zephir_hash_move_forward_ex(_3, &_2)
@@ -80435,17 +80486,17 @@ static PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) {
ZEPHIR_GET_HMKEY(name, _3, _2);
ZEPHIR_GET_HVALUE(_1, _4);
if (!(zephir_array_isset(snapshot, name))) {
- zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3792);
+ zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3791);
continue;
}
ZEPHIR_OBS_NVAR(value);
if (!(zephir_fetch_property_zval(&value, this_ptr, name, PH_SILENT_CC))) {
- zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3800);
+ zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3799);
continue;
}
- zephir_array_fetch(&_5, snapshot, name, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 3807 TSRMLS_CC);
+ zephir_array_fetch(&_5, snapshot, name, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 3806 TSRMLS_CC);
if (!ZEPHIR_IS_EQUAL(value, _5)) {
- zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3808);
+ zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3807);
continue;
}
}
@@ -80502,7 +80553,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, getRelated) {
ZEPHIR_CONCAT_SVSVS(_3, "There is no defined relations for the model '", className, "' using alias '", alias, "'");
ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_2, "phalcon/mvc/model.zep", 3855 TSRMLS_CC);
+ zephir_throw_exception_debug(_2, "phalcon/mvc/model.zep", 3854 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80640,7 +80691,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __call) {
ZEPHIR_CONCAT_SVSVS(_2, "The method '", method, "' doesn't exist on model '", modelName, "'");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3947 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3946 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -80702,7 +80753,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) {
ZEPHIR_CONCAT_SVSVS(_2, "The static method '", method, "' doesn't exist on model '", modelName, "'");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3998 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3997 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80714,7 +80765,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) {
ZEPHIR_CONCAT_SVS(_3, "The static method '", method, "' requires one argument");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4002 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4001 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80751,7 +80802,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __callStatic) {
ZEPHIR_CONCAT_SVS(_2, "Cannot resolve attribute '", extraMethod, "' in the model");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4036 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4035 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -80810,7 +80861,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __set) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(related);
array_init(related);
- zephir_is_iterable(value, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4100);
+ zephir_is_iterable(value, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4099);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -80819,7 +80870,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, __set) {
ZEPHIR_GET_HVALUE(item, _3);
if (Z_TYPE_P(item) == IS_OBJECT) {
if (zephir_instance_of_ev(item, phalcon_mvc_modelinterface_ce TSRMLS_CC)) {
- zephir_array_append(&related, item, PH_SEPARATE, "phalcon/mvc/model.zep", 4087);
+ zephir_array_append(&related, item, PH_SEPARATE, "phalcon/mvc/model.zep", 4086);
}
} else {
ZEPHIR_INIT_NVAR(lowerKey);
@@ -81006,7 +81057,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, unserialize) {
ZEPHIR_CALL_CE_STATIC(&dependencyInjector, phalcon_di_ce, "getdefault", &_0, 1);
zephir_check_call_status();
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 4224);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 4223);
return;
}
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
@@ -81017,13 +81068,13 @@ static PHP_METHOD(Phalcon_Mvc_Model, unserialize) {
zephir_check_call_status();
ZEPHIR_CPY_WRT(manager, _1);
if (Z_TYPE_P(manager) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 4237);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 4236);
return;
}
zephir_update_property_this(this_ptr, SL("_modelsManager"), manager TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, manager, "initialize", NULL, 0, this_ptr);
zephir_check_call_status();
- zephir_is_iterable(attributes, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 4256);
+ zephir_is_iterable(attributes, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 4255);
for (
; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS
; zephir_hash_move_forward_ex(_4, &_3)
@@ -81073,7 +81124,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, toArray) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_0, metaData, "getattributes", NULL, 0, this_ptr);
zephir_check_call_status();
- zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4320);
+ zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4319);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -81089,7 +81140,7 @@ static PHP_METHOD(Phalcon_Mvc_Model, toArray) {
ZEPHIR_CONCAT_SVS(_5, "Column '", attribute, "' doesn't make part of the column map");
ZEPHIR_CALL_METHOD(NULL, _4, "__construct", &_6, 9, _5);
zephir_check_call_status();
- zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 4298 TSRMLS_CC);
+ zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 4297 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
} else {
@@ -82839,9 +82890,11 @@ static PHP_METHOD(Phalcon_Mvc_Url, getBasePath) {
static PHP_METHOD(Phalcon_Mvc_Url, get) {
+ unsigned char _10, _12;
int ZEPHIR_LAST_CALL_STATUS;
- zend_bool _0, _1;
- zval *uri = NULL, *args = NULL, *local = NULL, *baseUri = NULL, *router = NULL, *dependencyInjector = NULL, *routeName, *route = NULL, *queryString = NULL, *_2, *_3 = NULL, _4 = zval_used_for_init, *_5, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9;
+ zend_bool _0, _1, _11;
+ zval *strUri = NULL, *_9 = NULL;
+ zval *uri = NULL, *args = NULL, *local = NULL, *baseUri = NULL, *router = NULL, *dependencyInjector = NULL, *routeName, *route = NULL, *queryString = NULL, *_2, *_3 = NULL, _4 = zval_used_for_init, *_5, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_13;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 0, 4, &uri, &args, &local, &baseUri);
@@ -82869,9 +82922,9 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
if (Z_TYPE_P(local) == IS_NULL) {
_0 = Z_TYPE_P(uri) == IS_STRING;
if (_0) {
- _1 = zephir_memnstr_str(uri, SL("//"), "phalcon/mvc/url.zep", 178);
+ _1 = zephir_memnstr_str(uri, SL("//"), "phalcon/mvc/url.zep", 181);
if (!(_1)) {
- _1 = zephir_memnstr_str(uri, SL(":"), "phalcon/mvc/url.zep", 178);
+ _1 = zephir_memnstr_str(uri, SL(":"), "phalcon/mvc/url.zep", 181);
}
_0 = _1;
}
@@ -82899,7 +82952,7 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
if (Z_TYPE_P(uri) == IS_ARRAY) {
ZEPHIR_OBS_VAR(routeName);
if (!(zephir_array_isset_string_fetch(&routeName, uri, SS("for"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_url_exception_ce, "It's necessary to define the route name with the parameter 'for'", "phalcon/mvc/url.zep", 196);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_url_exception_ce, "It's necessary to define the route name with the parameter 'for'", "phalcon/mvc/url.zep", 199);
return;
}
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_router"), PH_NOISY_CC);
@@ -82908,7 +82961,7 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
ZEPHIR_CPY_WRT(dependencyInjector, _5);
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_url_exception_ce, "A dependency injector container is required to obtain the 'router' service", "phalcon/mvc/url.zep", 208);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_url_exception_ce, "A dependency injector container is required to obtain the 'router' service", "phalcon/mvc/url.zep", 211);
return;
}
ZEPHIR_INIT_NVAR(_3);
@@ -82929,7 +82982,7 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
ZEPHIR_CONCAT_SVS(_7, "Cannot obtain a route using the name '", routeName, "'");
ZEPHIR_CALL_METHOD(NULL, _3, "__construct", NULL, 9, _7);
zephir_check_call_status();
- zephir_throw_exception_debug(_3, "phalcon/mvc/url.zep", 220 TSRMLS_CC);
+ zephir_throw_exception_debug(_3, "phalcon/mvc/url.zep", 223 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -82942,12 +82995,35 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
ZEPHIR_CPY_WRT(uri, _3);
}
if (zephir_is_true(local)) {
- ZEPHIR_INIT_LNVAR(_7);
- ZEPHIR_CONCAT_VV(_7, baseUri, uri);
- ZEPHIR_CPY_WRT(uri, _7);
+ zephir_get_strval(_9, uri);
+ ZEPHIR_CPY_WRT(strUri, _9);
+ _0 = ZEPHIR_IS_STRING(baseUri, "/");
+ if (_0) {
+ _0 = zephir_fast_strlen_ev(strUri) > 2;
+ }
+ _1 = _0;
+ if (_1) {
+ _10 = ZEPHIR_STRING_OFFSET(strUri, 0);
+ _1 = _10 == '/';
+ }
+ _11 = _1;
+ if (_11) {
+ _12 = ZEPHIR_STRING_OFFSET(strUri, 1);
+ _11 = _12 != '/';
+ }
+ ZEPHIR_INIT_NVAR(uri);
+ if (_11) {
+ ZEPHIR_SINIT_NVAR(_4);
+ ZVAL_LONG(&_4, 1);
+ ZEPHIR_INIT_NVAR(_3);
+ zephir_substr(_3, strUri, 1 , 0, ZEPHIR_SUBSTR_NO_LENGTH);
+ ZEPHIR_CONCAT_VV(uri, baseUri, _3);
+ } else {
+ ZEPHIR_CONCAT_VV(uri, baseUri, strUri);
+ }
}
if (zephir_is_true(args)) {
- ZEPHIR_CALL_FUNCTION(&queryString, "http_build_query", NULL, 367, args);
+ ZEPHIR_CALL_FUNCTION(&queryString, "http_build_query", NULL, 369, args);
zephir_check_call_status();
_0 = Z_TYPE_P(queryString) == IS_STRING;
if (_0) {
@@ -82963,9 +83039,9 @@ static PHP_METHOD(Phalcon_Mvc_Url, get) {
ZEPHIR_CONCAT_SV(_7, "&", queryString);
zephir_concat_self(&uri, _7 TSRMLS_CC);
} else {
- ZEPHIR_INIT_VAR(_9);
- ZEPHIR_CONCAT_SV(_9, "?", queryString);
- zephir_concat_self(&uri, _9 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_13);
+ ZEPHIR_CONCAT_SV(_13, "?", queryString);
+ zephir_concat_self(&uri, _13 TSRMLS_CC);
}
}
}
@@ -83598,19 +83674,19 @@ static PHP_METHOD(Phalcon_Mvc_View, _loadTemplateEngines) {
if (Z_TYPE_P(registeredEngines) != IS_ARRAY) {
ZEPHIR_INIT_VAR(_1);
object_init_ex(_1, phalcon_mvc_view_engine_php_ce);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 368, this_ptr, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 370, this_ptr, dependencyInjector);
zephir_check_call_status();
zephir_array_update_string(&engines, SL(".phtml"), &_1, PH_COPY | PH_SEPARATE);
} else {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "A dependency injector container is required to obtain the application services", "phalcon/mvc/view.zep", 524);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "A dependency injector container is required to obtain the application services", "phalcon/mvc/view.zep", 526);
return;
}
ZEPHIR_INIT_VAR(arguments);
zephir_create_array(arguments, 2, 0 TSRMLS_CC);
zephir_array_fast_append(arguments, this_ptr);
zephir_array_fast_append(arguments, dependencyInjector);
- zephir_is_iterable(registeredEngines, &_3, &_2, 0, 0, "phalcon/mvc/view.zep", 553);
+ zephir_is_iterable(registeredEngines, &_3, &_2, 0, 0, "phalcon/mvc/view.zep", 555);
for (
; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS
; zephir_hash_move_forward_ex(_3, &_2)
@@ -83634,7 +83710,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _loadTemplateEngines) {
ZEPHIR_CONCAT_SV(_6, "Invalid template engine registration for extension: ", extension);
ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6);
zephir_check_call_status();
- zephir_throw_exception_debug(_5, "phalcon/mvc/view.zep", 547 TSRMLS_CC);
+ zephir_throw_exception_debug(_5, "phalcon/mvc/view.zep", 549 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -83728,7 +83804,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _engineRender) {
zephir_read_property_this(&viewParams, this_ptr, SL("_viewParams"), PH_NOISY_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_eventsManager"), PH_NOISY_CC);
ZEPHIR_CPY_WRT(eventsManager, _4);
- zephir_is_iterable(engines, &_6, &_5, 0, 0, "phalcon/mvc/view.zep", 671);
+ zephir_is_iterable(engines, &_6, &_5, 0, 0, "phalcon/mvc/view.zep", 673);
for (
; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS
; zephir_hash_move_forward_ex(_6, &_5)
@@ -83778,7 +83854,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _engineRender) {
ZEPHIR_CONCAT_SVS(_11, "View '", viewsDirPath, "' was not found in the views directory");
ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _11);
zephir_check_call_status();
- zephir_throw_exception_debug(_8, "phalcon/mvc/view.zep", 682 TSRMLS_CC);
+ zephir_throw_exception_debug(_8, "phalcon/mvc/view.zep", 684 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -83843,7 +83919,7 @@ static PHP_METHOD(Phalcon_Mvc_View, exists) {
}
exists = 0;
ZEPHIR_INIT_NVAR(_0);
- zephir_is_iterable(engines, &_2, &_1, 0, 0, "phalcon/mvc/view.zep", 730);
+ zephir_is_iterable(engines, &_2, &_1, 0, 0, "phalcon/mvc/view.zep", 732);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -83937,7 +84013,7 @@ static PHP_METHOD(Phalcon_Mvc_View, render) {
ZEPHIR_CPY_WRT(renderView, _3);
} else {
ZEPHIR_OBS_NVAR(renderView);
- zephir_array_fetch_long(&renderView, pickView, 0, PH_NOISY, "phalcon/mvc/view.zep", 803 TSRMLS_CC);
+ zephir_array_fetch_long(&renderView, pickView, 0, PH_NOISY, "phalcon/mvc/view.zep", 805 TSRMLS_CC);
ZEPHIR_OBS_VAR(pickViewAction);
if (zephir_array_isset_long_fetch(&pickViewAction, pickView, 1, 0 TSRMLS_CC)) {
ZEPHIR_CPY_WRT(layoutName, pickViewAction);
@@ -83995,7 +84071,7 @@ static PHP_METHOD(Phalcon_Mvc_View, render) {
zephir_read_property_this(&templatesBefore, this_ptr, SL("_templatesBefore"), PH_NOISY_CC);
if (Z_TYPE_P(templatesBefore) == IS_ARRAY) {
silence = 0;
- zephir_is_iterable(templatesBefore, &_11, &_10, 0, 0, "phalcon/mvc/view.zep", 879);
+ zephir_is_iterable(templatesBefore, &_11, &_10, 0, 0, "phalcon/mvc/view.zep", 881);
for (
; zephir_hash_get_current_data_ex(_11, (void**) &_12, &_10) == SUCCESS
; zephir_hash_move_forward_ex(_11, &_10)
@@ -84030,7 +84106,7 @@ static PHP_METHOD(Phalcon_Mvc_View, render) {
zephir_read_property_this(&templatesAfter, this_ptr, SL("_templatesAfter"), PH_NOISY_CC);
if (Z_TYPE_P(templatesAfter) == IS_ARRAY) {
silence = 0;
- zephir_is_iterable(templatesAfter, &_15, &_14, 0, 0, "phalcon/mvc/view.zep", 910);
+ zephir_is_iterable(templatesAfter, &_15, &_14, 0, 0, "phalcon/mvc/view.zep", 912);
for (
; zephir_hash_get_current_data_ex(_15, (void**) &_16, &_14) == SUCCESS
; zephir_hash_move_forward_ex(_15, &_14)
@@ -84102,17 +84178,17 @@ static PHP_METHOD(Phalcon_Mvc_View, pick) {
} else {
ZEPHIR_INIT_VAR(layout);
ZVAL_NULL(layout);
- if (zephir_memnstr_str(renderView, SL("/"), "phalcon/mvc/view.zep", 983)) {
+ if (zephir_memnstr_str(renderView, SL("/"), "phalcon/mvc/view.zep", 985)) {
ZEPHIR_INIT_VAR(parts);
zephir_fast_explode_str(parts, SL("/"), renderView, LONG_MAX TSRMLS_CC);
ZEPHIR_OBS_NVAR(layout);
- zephir_array_fetch_long(&layout, parts, 0, PH_NOISY, "phalcon/mvc/view.zep", 984 TSRMLS_CC);
+ zephir_array_fetch_long(&layout, parts, 0, PH_NOISY, "phalcon/mvc/view.zep", 986 TSRMLS_CC);
}
ZEPHIR_INIT_NVAR(pickView);
zephir_create_array(pickView, 1, 0 TSRMLS_CC);
zephir_array_fast_append(pickView, renderView);
if (Z_TYPE_P(layout) != IS_NULL) {
- zephir_array_append(&pickView, layout, PH_SEPARATE, "phalcon/mvc/view.zep", 989);
+ zephir_array_append(&pickView, layout, PH_SEPARATE, "phalcon/mvc/view.zep", 991);
}
}
zephir_update_property_this(this_ptr, SL("_pickView"), pickView TSRMLS_CC);
@@ -84149,7 +84225,7 @@ static PHP_METHOD(Phalcon_Mvc_View, getPartial) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, this_ptr, "partial", NULL, 0, partialPath, params);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", NULL, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", NULL, 291);
zephir_check_call_status();
RETURN_MM();
@@ -84304,7 +84380,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _createCache) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
ZEPHIR_CPY_WRT(dependencyInjector, _0);
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "A dependency injector container is required to obtain the view cache services", "phalcon/mvc/view.zep", 1163);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "A dependency injector container is required to obtain the view cache services", "phalcon/mvc/view.zep", 1165);
return;
}
ZEPHIR_INIT_VAR(cacheService);
@@ -84316,7 +84392,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _createCache) {
if (zephir_array_isset_string_fetch(&cacheOptions, viewOptions, SS("cache"), 0 TSRMLS_CC)) {
if (zephir_array_isset_string(cacheOptions, SS("service"))) {
ZEPHIR_OBS_NVAR(cacheService);
- zephir_array_fetch_string(&cacheService, cacheOptions, SL("service"), PH_NOISY, "phalcon/mvc/view.zep", 1172 TSRMLS_CC);
+ zephir_array_fetch_string(&cacheService, cacheOptions, SL("service"), PH_NOISY, "phalcon/mvc/view.zep", 1174 TSRMLS_CC);
}
}
}
@@ -84324,7 +84400,7 @@ static PHP_METHOD(Phalcon_Mvc_View, _createCache) {
zephir_check_call_status();
ZEPHIR_CPY_WRT(viewCache, _1);
if (Z_TYPE_P(viewCache) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "The injected caching service is invalid", "phalcon/mvc/view.zep", 1182);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "The injected caching service is invalid", "phalcon/mvc/view.zep", 1184);
return;
}
RETURN_CCTOR(viewCache);
@@ -84392,7 +84468,7 @@ static PHP_METHOD(Phalcon_Mvc_View, cache) {
ZEPHIR_INIT_NVAR(cacheOptions);
array_init(cacheOptions);
}
- zephir_is_iterable(options, &_1, &_0, 0, 0, "phalcon/mvc/view.zep", 1250);
+ zephir_is_iterable(options, &_1, &_0, 0, 0, "phalcon/mvc/view.zep", 1252);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -85730,7 +85806,7 @@ static PHP_METHOD(Phalcon_Mvc_Collection_Behavior_Timestampable, notify) {
ZVAL_NULL(timestamp);
ZEPHIR_OBS_VAR(format);
if (zephir_array_isset_string_fetch(&format, options, SS("format"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 299, format);
+ ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 300, format);
zephir_check_call_status();
} else {
ZEPHIR_OBS_VAR(generator);
@@ -87271,7 +87347,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, inWhere) {
array_init(bindParams);
ZEPHIR_INIT_VAR(bindKeys);
array_init(bindKeys);
- zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 450);
+ zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 451);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -87281,7 +87357,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, inWhere) {
ZEPHIR_CONCAT_SV(key, "AP", hiddenParam);
ZEPHIR_INIT_NVAR(queryKey);
ZEPHIR_CONCAT_SVS(queryKey, ":", key, ":");
- zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 441);
+ zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 442);
zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE);
ZEPHIR_SEPARATE(hiddenParam);
zephir_increment(hiddenParam);
@@ -87330,7 +87406,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, notInWhere) {
array_init(bindParams);
ZEPHIR_INIT_VAR(bindKeys);
array_init(bindKeys);
- zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 487);
+ zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 488);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -87340,7 +87416,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, notInWhere) {
ZEPHIR_CONCAT_SV(key, "AP", hiddenParam);
ZEPHIR_INIT_LNVAR(_3);
ZEPHIR_CONCAT_SVS(_3, ":", key, ":");
- zephir_array_append(&bindKeys, _3, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 477);
+ zephir_array_append(&bindKeys, _3, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 478);
zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE);
ZEPHIR_SEPARATE(hiddenParam);
zephir_increment(hiddenParam);
@@ -87669,14 +87745,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, getParams) {
static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) {
- zend_bool _6;
+ zend_bool _6, _7;
HashTable *_4;
HashPosition _3;
zend_class_entry *_2;
int ZEPHIR_LAST_CALL_STATUS;
zval *data = NULL;
zval *modelName = NULL;
- zval *dependencyInjector, *modelName_param = NULL, *data_param = NULL, *conditions, *field = NULL, *value = NULL, *type = NULL, *metaData = NULL, *model, *dataTypes = NULL, *bind, *criteria, *_0 = NULL, *_1 = NULL, **_5, *_7 = NULL, *_8 = NULL;
+ zval *dependencyInjector, *modelName_param = NULL, *data_param = NULL, *attribute = NULL, *conditions, *field = NULL, *value = NULL, *type = NULL, *metaData = NULL, *model, *dataTypes = NULL, *bind, *criteria, *columnMap = NULL, *_0 = NULL, *_1 = NULL, **_5, *_8 = NULL, *_9 = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &dependencyInjector, &modelName_param, &data_param);
@@ -87714,35 +87790,47 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) {
}
ZEPHIR_CALL_METHOD(&dataTypes, metaData, "getdatatypes", NULL, 0, model);
zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&columnMap, metaData, "getreversecolumnmap", NULL, 0, model);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(bind);
array_init(bind);
- zephir_is_iterable(data, &_4, &_3, 0, 0, "phalcon/mvc/model/criteria.zep", 720);
+ zephir_is_iterable(data, &_4, &_3, 0, 0, "phalcon/mvc/model/criteria.zep", 732);
for (
; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS
; zephir_hash_move_forward_ex(_4, &_3)
) {
ZEPHIR_GET_HMKEY(field, _4, _3);
ZEPHIR_GET_HVALUE(value, _5);
+ _6 = Z_TYPE_P(columnMap) == IS_ARRAY;
+ if (_6) {
+ _6 = (zephir_fast_count_int(columnMap TSRMLS_CC)) ? 1 : 0;
+ }
+ if (_6) {
+ ZEPHIR_OBS_NVAR(attribute);
+ zephir_array_fetch(&attribute, columnMap, field, PH_NOISY, "phalcon/mvc/model/criteria.zep", 709 TSRMLS_CC);
+ } else {
+ ZEPHIR_CPY_WRT(attribute, field);
+ }
ZEPHIR_OBS_NVAR(type);
- if (zephir_array_isset_fetch(&type, dataTypes, field, 0 TSRMLS_CC)) {
- _6 = Z_TYPE_P(value) != IS_NULL;
- if (_6) {
- _6 = !ZEPHIR_IS_STRING_IDENTICAL(value, "");
+ if (zephir_array_isset_fetch(&type, dataTypes, attribute, 0 TSRMLS_CC)) {
+ _7 = Z_TYPE_P(value) != IS_NULL;
+ if (_7) {
+ _7 = !ZEPHIR_IS_STRING_IDENTICAL(value, "");
}
- if (_6) {
+ if (_7) {
if (ZEPHIR_IS_LONG(type, 2)) {
- ZEPHIR_INIT_LNVAR(_7);
- ZEPHIR_CONCAT_VSVS(_7, field, " LIKE :", field, ":");
- zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 710);
ZEPHIR_INIT_LNVAR(_8);
- ZEPHIR_CONCAT_SVS(_8, "%", value, "%");
- zephir_array_update_zval(&bind, field, &_8, PH_COPY | PH_SEPARATE);
- } else {
- ZEPHIR_INIT_LNVAR(_7);
- ZEPHIR_CONCAT_VSVS(_7, field, " = :", field, ":");
- zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 715);
- zephir_array_update_zval(&bind, field, &value, PH_COPY | PH_SEPARATE);
+ ZEPHIR_CONCAT_SVSVS(_8, "[", field, "] LIKE :", field, ":");
+ zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 721);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, "%", value, "%");
+ zephir_array_update_zval(&bind, field, &_9, PH_COPY | PH_SEPARATE);
+ continue;
}
+ ZEPHIR_INIT_LNVAR(_8);
+ ZEPHIR_CONCAT_SVSVS(_8, "[", field, "] = :", field, ":");
+ zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 728);
+ zephir_array_update_zval(&bind, field, &value, PH_COPY | PH_SEPARATE);
}
}
}
@@ -87756,12 +87844,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) {
if (zephir_fast_count_int(conditions TSRMLS_CC)) {
ZEPHIR_INIT_NVAR(_0);
zephir_fast_join_str(_0, SL(" AND "), conditions TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, criteria, "where", NULL, 312, _0);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "where", NULL, 313, _0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, criteria, "bind", NULL, 313, bind);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "bind", NULL, 314, bind);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 309, modelName);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 310, modelName);
zephir_check_call_status();
RETURN_CCTOR(criteria);
@@ -87778,7 +87866,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Criteria, execute) {
ZEPHIR_CALL_METHOD(&model, this_ptr, "getmodelname", NULL, 0);
zephir_check_call_status();
if (Z_TYPE_P(model) != IS_STRING) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Model name must be string", "phalcon/mvc/model/criteria.zep", 744);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Model name must be string", "phalcon/mvc/model/criteria.zep", 756);
return;
}
ZEPHIR_CALL_METHOD(&_0, this_ptr, "getparams", NULL, 0);
@@ -88783,7 +88871,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasOne) {
object_init_ex(relation, phalcon_mvc_model_relation_ce);
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, 1);
- ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 314, _1, referencedModel, fields, referencedFields, options);
+ ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _1, referencedModel, fields, referencedFields, options);
zephir_check_call_status();
ZEPHIR_OBS_VAR(alias);
if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) {
@@ -88860,7 +88948,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addBelongsTo) {
object_init_ex(relation, phalcon_mvc_model_relation_ce);
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, 0);
- ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 314, _1, referencedModel, fields, referencedFields, options);
+ ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _1, referencedModel, fields, referencedFields, options);
zephir_check_call_status();
ZEPHIR_OBS_VAR(alias);
if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) {
@@ -88938,7 +89026,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasMany) {
object_init_ex(relation, phalcon_mvc_model_relation_ce);
ZEPHIR_INIT_VAR(_0);
ZVAL_LONG(_0, 2);
- ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 314, _0, referencedModel, fields, referencedFields, options);
+ ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _0, referencedModel, fields, referencedFields, options);
zephir_check_call_status();
ZEPHIR_OBS_VAR(alias);
if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) {
@@ -89035,9 +89123,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasManyToMany) {
object_init_ex(relation, phalcon_mvc_model_relation_ce);
ZEPHIR_INIT_VAR(_0);
ZVAL_LONG(_0, 4);
- ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 314, _0, referencedModel, fields, referencedFields, options);
+ ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _0, referencedModel, fields, referencedFields, options);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, relation, "setintermediaterelation", NULL, 315, intermediateFields, intermediateModel, intermediateReferencedFields);
+ ZEPHIR_CALL_METHOD(NULL, relation, "setintermediaterelation", NULL, 316, intermediateFields, intermediateModel, intermediateReferencedFields);
zephir_check_call_status();
ZEPHIR_OBS_VAR(alias);
if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) {
@@ -89498,7 +89586,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1245);
return;
}
- ZEPHIR_CALL_METHOD(&_2, this_ptr, "_mergefindparameters", &_3, 316, extraParameters, parameters);
+ ZEPHIR_CALL_METHOD(&_2, this_ptr, "_mergefindparameters", &_3, 317, extraParameters, parameters);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&builder, this_ptr, "createbuilder", NULL, 0, _2);
zephir_check_call_status();
@@ -89563,10 +89651,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) {
ZEPHIR_CALL_METHOD(&_2, record, "getdi", NULL, 0);
zephir_check_call_status();
zephir_array_update_string(&findParams, SL("di"), &_2, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&findArguments, this_ptr, "_mergefindparameters", &_3, 316, findParams, parameters);
+ ZEPHIR_CALL_METHOD(&findArguments, this_ptr, "_mergefindparameters", &_3, 317, findParams, parameters);
zephir_check_call_status();
if (Z_TYPE_P(extraParameters) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&findParams, this_ptr, "_mergefindparameters", &_3, 316, findArguments, extraParameters);
+ ZEPHIR_CALL_METHOD(&findParams, this_ptr, "_mergefindparameters", &_3, 317, findArguments, extraParameters);
zephir_check_call_status();
} else {
ZEPHIR_CPY_WRT(findParams, findArguments);
@@ -91989,7 +92077,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCallArgument) {
add_assoc_stringl_ex(return_value, SS("type"), SL("all"), 1);
RETURN_MM();
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getexpression", NULL, 321, argument);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getexpression", NULL, 323, argument);
zephir_check_call_status();
RETURN_MM();
@@ -92025,11 +92113,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) {
zephir_create_array(_4, 3, 0 TSRMLS_CC);
add_assoc_stringl_ex(_4, SS("type"), SL("when"), 1);
zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 344 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 321, _6);
+ ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6);
zephir_check_call_status();
zephir_array_update_string(&_4, SL("expr"), &_5, PH_COPY | PH_SEPARATE);
zephir_array_fetch_string(&_8, whenExpr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 345 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 321, _8);
+ ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _8);
zephir_check_call_status();
zephir_array_update_string(&_4, SL("then"), &_5, PH_COPY | PH_SEPARATE);
zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 346);
@@ -92038,7 +92126,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) {
zephir_create_array(_4, 2, 0 TSRMLS_CC);
add_assoc_stringl_ex(_4, SS("type"), SL("else"), 1);
zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 350 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 321, _6);
+ ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6);
zephir_check_call_status();
zephir_array_update_string(&_4, SL("expr"), &_5, PH_COPY | PH_SEPARATE);
zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 351);
@@ -92047,7 +92135,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) {
zephir_create_array(return_value, 3, 0 TSRMLS_CC);
add_assoc_stringl_ex(return_value, SS("type"), SL("case"), 1);
zephir_array_fetch_string(&_6, expr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 357 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 321, _6);
+ ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6);
zephir_check_call_status();
zephir_array_update_string(&return_value, SL("expr"), &_5, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&return_value, SL("when-clauses"), &whenClauses, PH_COPY | PH_SEPARATE);
@@ -92087,13 +92175,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) {
; zephir_hash_move_forward_ex(_1, &_0)
) {
ZEPHIR_GET_HVALUE(argument, _2);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 322, argument);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 324, argument);
zephir_check_call_status();
zephir_array_append(&functionArgs, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 381);
}
} else {
zephir_create_array(functionArgs, 1, 0 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 322, arguments);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 324, arguments);
zephir_check_call_status();
zephir_array_fast_append(functionArgs, _3);
}
@@ -92156,12 +92244,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
if (!ZEPHIR_IS_LONG(exprType, 409)) {
ZEPHIR_OBS_VAR(exprLeft);
if (zephir_array_isset_string_fetch(&exprLeft, expr, SS("left"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&left, this_ptr, "_getexpression", &_0, 321, exprLeft, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&left, this_ptr, "_getexpression", &_0, 323, exprLeft, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
}
ZEPHIR_OBS_VAR(exprRight);
if (zephir_array_isset_string_fetch(&exprRight, expr, SS("right"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&right, this_ptr, "_getexpression", &_0, 321, exprRight, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&right, this_ptr, "_getexpression", &_0, 323, exprRight, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
}
}
@@ -92239,7 +92327,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
break;
}
if (ZEPHIR_IS_LONG(exprType, 355)) {
- ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getqualified", &_1, 323, expr);
+ ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getqualified", &_1, 325, expr);
zephir_check_call_status();
break;
}
@@ -92684,12 +92772,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
break;
}
if (ZEPHIR_IS_LONG(exprType, 350)) {
- ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getfunctioncall", NULL, 324, expr);
+ ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getfunctioncall", NULL, 326, expr);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(exprType, 409)) {
- ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getcaseexpression", NULL, 325, expr);
+ ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getcaseexpression", NULL, 327, expr);
zephir_check_call_status();
break;
}
@@ -92699,7 +92787,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
add_assoc_stringl_ex(exprReturn, SS("type"), SL("select"), 1);
ZEPHIR_INIT_NVAR(_3);
ZVAL_BOOL(_3, 1);
- ZEPHIR_CALL_METHOD(&_12, this_ptr, "_prepareselect", NULL, 326, expr, _3);
+ ZEPHIR_CALL_METHOD(&_12, this_ptr, "_prepareselect", NULL, 328, expr, _3);
zephir_check_call_status();
zephir_array_update_string(&exprReturn, SL("value"), &_12, PH_COPY | PH_SEPARATE);
break;
@@ -92718,7 +92806,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
RETURN_CCTOR(exprReturn);
}
if (zephir_array_isset_string(expr, SS("domain"))) {
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualified", &_1, 323, expr);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualified", &_1, 325, expr);
zephir_check_call_status();
RETURN_MM();
}
@@ -92731,7 +92819,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
; zephir_hash_move_forward_ex(_14, &_13)
) {
ZEPHIR_GET_HVALUE(exprListItem, _15);
- ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_0, 321, exprListItem);
+ ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_0, 323, exprListItem);
zephir_check_call_status();
zephir_array_append(&listItems, _12, PH_SEPARATE, "phalcon/mvc/model/query.zep", 735);
}
@@ -92833,7 +92921,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSelectColumn) {
add_assoc_stringl_ex(sqlColumn, SS("type"), SL("scalar"), 1);
ZEPHIR_OBS_VAR(columnData);
zephir_array_fetch_string(&columnData, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 838 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&sqlExprColumn, this_ptr, "_getexpression", NULL, 321, columnData);
+ ZEPHIR_CALL_METHOD(&sqlExprColumn, this_ptr, "_getexpression", NULL, 323, columnData);
zephir_check_call_status();
ZEPHIR_OBS_VAR(balias);
if (zephir_array_isset_string_fetch(&balias, sqlExprColumn, SS("balias"), 0 TSRMLS_CC)) {
@@ -93026,7 +93114,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) {
add_assoc_long_ex(_2, SS("type"), 355);
zephir_array_update_string(&_2, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_2, SL("name"), &fields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 323, _2);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _2);
zephir_check_call_status();
zephir_array_update_string(&_0, SL("left"), &_1, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_VAR(_4);
@@ -93034,7 +93122,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) {
add_assoc_stringl_ex(_4, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_4, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 323, _4);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _4);
zephir_check_call_status();
zephir_array_update_string(&_0, SL("right"), &_1, PH_COPY | PH_SEPARATE);
zephir_array_fast_append(sqlJoinConditions, _0);
@@ -93070,7 +93158,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) {
add_assoc_long_ex(_2, SS("type"), 355);
zephir_array_update_string(&_2, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_2, SL("name"), &field, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 323, _2);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _2);
zephir_check_call_status();
zephir_array_update_string(&_0, SL("left"), &_1, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_NVAR(_4);
@@ -93078,7 +93166,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) {
add_assoc_stringl_ex(_4, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_4, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("name"), &referencedField, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 323, _4);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _4);
zephir_check_call_status();
zephir_array_update_string(&_0, SL("right"), &_1, PH_COPY | PH_SEPARATE);
zephir_array_append(&sqlJoinPartialConditions, _0, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1041);
@@ -93161,7 +93249,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_long_ex(_8, SS("type"), 355);
zephir_array_update_string(&_8, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_8, SL("name"), &field, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _8);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _8);
zephir_check_call_status();
zephir_array_update_string(&sqlEqualsJoinCondition, SL("left"), &_7, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_NVAR(_10);
@@ -93169,7 +93257,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_stringl_ex(_10, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_10, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_10, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _10);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _10);
zephir_check_call_status();
zephir_array_update_string(&sqlEqualsJoinCondition, SL("right"), &_7, PH_COPY | PH_SEPARATE);
}
@@ -93191,7 +93279,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_long_ex(_12, SS("type"), 355);
zephir_array_update_string(&_12, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_12, SL("name"), &fields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _12);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _12);
zephir_check_call_status();
zephir_array_update_string(&_11, SL("left"), &_7, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_VAR(_13);
@@ -93199,7 +93287,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_stringl_ex(_13, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_13, SL("domain"), &intermediateModelName, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_13, SL("name"), &intermediateFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _13);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _13);
zephir_check_call_status();
zephir_array_update_string(&_11, SL("right"), &_7, PH_COPY | PH_SEPARATE);
zephir_array_fast_append(_10, _11);
@@ -93220,7 +93308,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_long_ex(_14, SS("type"), 355);
zephir_array_update_string(&_14, SL("domain"), &intermediateModelName, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_14, SL("name"), &intermediateReferencedFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _14);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _14);
zephir_check_call_status();
zephir_array_update_string(&_11, SL("left"), &_7, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_VAR(_15);
@@ -93228,7 +93316,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_stringl_ex(_15, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_15, SL("domain"), &referencedModelName, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_15, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _15);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _15);
zephir_check_call_status();
zephir_array_update_string(&_11, SL("right"), &_7, PH_COPY | PH_SEPARATE);
zephir_array_fast_append(_10, _11);
@@ -93295,7 +93383,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) {
; zephir_hash_move_forward_ex(_1, &_0)
) {
ZEPHIR_GET_HVALUE(joinItem, _2);
- ZEPHIR_CALL_METHOD(&joinData, this_ptr, "_getjoin", &_3, 327, manager, joinItem);
+ ZEPHIR_CALL_METHOD(&joinData, this_ptr, "_getjoin", &_3, 329, manager, joinItem);
zephir_check_call_status();
ZEPHIR_OBS_NVAR(source);
zephir_array_fetch_string(&source, joinData, SL("source"), PH_NOISY, "phalcon/mvc/model/query.zep", 1273 TSRMLS_CC);
@@ -93309,7 +93397,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) {
zephir_create_array(completeSource, 2, 0 TSRMLS_CC);
zephir_array_fast_append(completeSource, source);
zephir_array_fast_append(completeSource, schema);
- ZEPHIR_CALL_METHOD(&joinType, this_ptr, "_getjointype", &_4, 328, joinItem);
+ ZEPHIR_CALL_METHOD(&joinType, this_ptr, "_getjointype", &_4, 330, joinItem);
zephir_check_call_status();
ZEPHIR_OBS_NVAR(aliasExpr);
if (zephir_array_isset_string_fetch(&aliasExpr, joinItem, SS("alias"), 0 TSRMLS_CC)) {
@@ -93377,7 +93465,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) {
ZEPHIR_GET_HVALUE(joinItem, _11);
ZEPHIR_OBS_NVAR(joinExpr);
if (zephir_array_isset_string_fetch(&joinExpr, joinItem, SS("conditions"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_13, 321, joinExpr);
+ ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_13, 323, joinExpr);
zephir_check_call_status();
zephir_array_update_zval(&joinPreCondition, joinAliasName, &_12, PH_COPY | PH_SEPARATE);
}
@@ -93435,10 +93523,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) {
ZEPHIR_CALL_METHOD(&_12, relation, "isthrough", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_12))) {
- ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getsinglejoin", &_23, 329, joinType, joinSource, modelAlias, joinAlias, relation);
+ ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getsinglejoin", &_23, 331, joinType, joinSource, modelAlias, joinAlias, relation);
zephir_check_call_status();
} else {
- ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getmultijoin", &_24, 330, joinType, joinSource, modelAlias, joinAlias, relation);
+ ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getmultijoin", &_24, 332, joinType, joinSource, modelAlias, joinAlias, relation);
zephir_check_call_status();
}
if (zephir_array_isset_long(sqlJoin, 0)) {
@@ -93509,7 +93597,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getOrderClause) {
) {
ZEPHIR_GET_HVALUE(orderItem, _2);
zephir_array_fetch_string(&_3, orderItem, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1560 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&orderPartExpr, this_ptr, "_getexpression", &_4, 321, _3);
+ ZEPHIR_CALL_METHOD(&orderPartExpr, this_ptr, "_getexpression", &_4, 323, _3);
zephir_check_call_status();
if (zephir_array_isset_string_fetch(&orderSort, orderItem, SS("sort"), 1 TSRMLS_CC)) {
ZEPHIR_INIT_NVAR(orderPartSort);
@@ -93562,13 +93650,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getGroupClause) {
; zephir_hash_move_forward_ex(_1, &_0)
) {
ZEPHIR_GET_HVALUE(groupItem, _2);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 321, groupItem);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 323, groupItem);
zephir_check_call_status();
zephir_array_append(&groupParts, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1594);
}
} else {
zephir_create_array(groupParts, 1, 0 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 321, group);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 323, group);
zephir_check_call_status();
zephir_array_fast_append(groupParts, _3);
}
@@ -93594,13 +93682,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getLimitClause) {
ZEPHIR_OBS_VAR(number);
if (zephir_array_isset_string_fetch(&number, limitClause, SS("number"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 321, number);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 323, number);
zephir_check_call_status();
zephir_array_update_string(&limit, SL("number"), &_0, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(offset);
if (zephir_array_isset_string_fetch(&offset, limitClause, SS("offset"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 321, offset);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 323, offset);
zephir_check_call_status();
zephir_array_update_string(&limit, SL("offset"), &_0, PH_COPY | PH_SEPARATE);
}
@@ -93804,7 +93892,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) {
ZEPHIR_OBS_VAR(joins);
if (zephir_array_isset_string_fetch(&joins, select, SS("joins"), 0 TSRMLS_CC)) {
if (zephir_fast_count_int(joins TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", NULL, 331, select);
+ ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", NULL, 333, select);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(sqlJoins);
@@ -93830,7 +93918,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) {
; zephir_hash_move_forward_ex(_23, &_22)
) {
ZEPHIR_GET_HVALUE(column, _24);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getselectcolumn", &_25, 332, column);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getselectcolumn", &_25, 334, column);
zephir_check_call_status();
zephir_is_iterable(_3, &_27, &_26, 0, 0, "phalcon/mvc/model/query.zep", 1856);
for (
@@ -93879,31 +93967,31 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) {
}
ZEPHIR_OBS_VAR(where);
if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_31, 321, where);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_31, 323, where);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("where"), &_3, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(groupBy);
if (zephir_array_isset_string_fetch(&groupBy, ast, SS("groupBy"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getgroupclause", NULL, 333, groupBy);
+ ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getgroupclause", NULL, 335, groupBy);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("group"), &_32, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(having);
if (zephir_array_isset_string_fetch(&having, ast, SS("having"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getexpression", &_31, 321, having);
+ ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getexpression", &_31, 323, having);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("having"), &_32, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(order);
if (zephir_array_isset_string_fetch(&order, ast, SS("orderBy"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getorderclause", NULL, 334, order);
+ ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getorderclause", NULL, 336, order);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("order"), &_32, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(limit);
if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getlimitclause", NULL, 335, limit);
+ ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getlimitclause", NULL, 337, limit);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("limit"), &_32, PH_COPY | PH_SEPARATE);
}
@@ -93987,7 +94075,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) {
ZEPHIR_OBS_NVAR(_8);
zephir_array_fetch_string(&_8, exprValue, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 1960 TSRMLS_CC);
zephir_array_update_string(&_7, SL("type"), &_8, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_9, 321, exprValue, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_9, 323, exprValue, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_array_update_string(&_7, SL("value"), &_0, PH_COPY | PH_SEPARATE);
zephir_array_append(&exprValues, _7, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1962);
@@ -94162,7 +94250,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) {
) {
ZEPHIR_GET_HVALUE(updateValue, _11);
zephir_array_fetch_string(&_4, updateValue, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2110 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_12, 321, _4, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_12, 323, _4, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_array_append(&sqlFields, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2110);
ZEPHIR_OBS_NVAR(exprColumn);
@@ -94172,7 +94260,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) {
ZEPHIR_OBS_NVAR(_14);
zephir_array_fetch_string(&_14, exprColumn, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 2113 TSRMLS_CC);
zephir_array_update_string(&_13, SL("type"), &_14, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 321, exprColumn, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 323, exprColumn, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_array_update_string(&_13, SL("value"), &_15, PH_COPY | PH_SEPARATE);
zephir_array_append(&sqlValues, _13, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2115);
@@ -94187,13 +94275,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) {
if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) {
ZEPHIR_SINIT_VAR(_16);
ZVAL_BOOL(&_16, 1);
- ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 321, where, &_16);
+ ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 323, where, &_16);
zephir_check_call_status();
zephir_array_update_string(&sqlUpdate, SL("where"), &_15, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(limit);
if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getlimitclause", NULL, 335, limit);
+ ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getlimitclause", NULL, 337, limit);
zephir_check_call_status();
zephir_array_update_string(&sqlUpdate, SL("limit"), &_15, PH_COPY | PH_SEPARATE);
}
@@ -94312,13 +94400,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) {
if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) {
ZEPHIR_SINIT_VAR(_9);
ZVAL_BOOL(&_9, 1);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", NULL, 321, where, &_9);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", NULL, 323, where, &_9);
zephir_check_call_status();
zephir_array_update_string(&sqlDelete, SL("where"), &_3, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(limit);
if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_10, this_ptr, "_getlimitclause", NULL, 335, limit);
+ ZEPHIR_CALL_METHOD(&_10, this_ptr, "_getlimitclause", NULL, 337, limit);
zephir_check_call_status();
zephir_array_update_string(&sqlDelete, SL("limit"), &_10, PH_COPY | PH_SEPARATE);
}
@@ -94366,22 +94454,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, parse) {
zephir_update_property_this(this_ptr, SL("_type"), type TSRMLS_CC);
do {
if (ZEPHIR_IS_LONG(type, 309)) {
- ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareselect", NULL, 326);
+ ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareselect", NULL, 328);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 306)) {
- ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareinsert", NULL, 336);
+ ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareinsert", NULL, 338);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 300)) {
- ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareupdate", NULL, 337);
+ ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareupdate", NULL, 339);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 303)) {
- ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_preparedelete", NULL, 338);
+ ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_preparedelete", NULL, 340);
zephir_check_call_status();
break;
}
@@ -94768,12 +94856,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) {
isKeepingSnapshots = zephir_get_boolval(_40);
}
object_init_ex(return_value, phalcon_mvc_model_resultset_simple_ce);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 339, simpleColumnMap, resultObject, resultData, cache, (isKeepingSnapshots ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 341, simpleColumnMap, resultObject, resultData, cache, (isKeepingSnapshots ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
}
object_init_ex(return_value, phalcon_mvc_model_resultset_complex_ce);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 340, columns1, resultData, cache);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 342, columns1, resultData, cache);
zephir_check_call_status();
RETURN_MM();
@@ -94933,7 +95021,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_CALL_METHOD(&_15, insertModel, "create", NULL, 0, insertValues);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 341, _15, insertModel);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 343, _15, insertModel);
zephir_check_call_status();
RETURN_MM();
@@ -95064,13 +95152,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) {
zephir_array_update_zval(&updateValues, fieldName, &updateValue, PH_COPY | PH_SEPARATE);
}
- ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 342, model, intermediate, selectBindParams, selectBindTypes);
+ ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 344, model, intermediate, selectBindParams, selectBindTypes);
zephir_check_call_status();
if (!(zephir_fast_count_int(records TSRMLS_CC))) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_11);
ZVAL_BOOL(_11, 1);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 341, _11);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11);
zephir_check_call_status();
RETURN_MM();
}
@@ -95103,7 +95191,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_11);
ZVAL_BOOL(_11, 0);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 341, _11, record);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11, record);
zephir_check_call_status();
RETURN_MM();
}
@@ -95114,7 +95202,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_11);
ZVAL_BOOL(_11, 1);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 341, _11);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11);
zephir_check_call_status();
RETURN_MM();
@@ -95147,13 +95235,13 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) {
ZEPHIR_CALL_METHOD(&model, _1, "load", NULL, 0, modelName);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 342, model, intermediate, bindParams, bindTypes);
+ ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 344, model, intermediate, bindParams, bindTypes);
zephir_check_call_status();
if (!(zephir_fast_count_int(records TSRMLS_CC))) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_VAR(_2);
ZVAL_BOOL(_2, 1);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 341, _2);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2);
zephir_check_call_status();
RETURN_MM();
}
@@ -95186,7 +95274,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_2);
ZVAL_BOOL(_2, 0);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 341, _2, record);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2, record);
zephir_check_call_status();
RETURN_MM();
}
@@ -95197,7 +95285,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_2);
ZVAL_BOOL(_2, 1);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 341, _2);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2);
zephir_check_call_status();
RETURN_MM();
@@ -95245,18 +95333,18 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, _getRelatedRecords) {
}
ZEPHIR_INIT_VAR(query);
object_init_ex(query, phalcon_mvc_model_query_ce);
- ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 343);
+ ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 345);
zephir_check_call_status();
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, query, "setdi", NULL, 344, _5);
+ ZEPHIR_CALL_METHOD(NULL, query, "setdi", NULL, 346, _5);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_2);
ZVAL_LONG(_2, 309);
- ZEPHIR_CALL_METHOD(NULL, query, "settype", NULL, 345, _2);
+ ZEPHIR_CALL_METHOD(NULL, query, "settype", NULL, 347, _2);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, query, "setintermediate", NULL, 346, selectIr);
+ ZEPHIR_CALL_METHOD(NULL, query, "setintermediate", NULL, 348, selectIr);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_METHOD(query, "execute", NULL, 347, bindParams, bindTypes);
+ ZEPHIR_RETURN_CALL_METHOD(query, "execute", NULL, 349, bindParams, bindTypes);
zephir_check_call_status();
RETURN_MM();
@@ -95377,22 +95465,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, execute) {
zephir_read_property_this(&type, this_ptr, SL("_type"), PH_NOISY_CC);
do {
if (ZEPHIR_IS_LONG(type, 309)) {
- ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeselect", NULL, 348, intermediate, mergedParams, mergedTypes);
+ ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeselect", NULL, 350, intermediate, mergedParams, mergedTypes);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 306)) {
- ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeinsert", NULL, 349, intermediate, mergedParams, mergedTypes);
+ ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeinsert", NULL, 351, intermediate, mergedParams, mergedTypes);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 300)) {
- ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeupdate", NULL, 350, intermediate, mergedParams, mergedTypes);
+ ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeupdate", NULL, 352, intermediate, mergedParams, mergedTypes);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 303)) {
- ZEPHIR_CALL_METHOD(&result, this_ptr, "_executedelete", NULL, 351, intermediate, mergedParams, mergedTypes);
+ ZEPHIR_CALL_METHOD(&result, this_ptr, "_executedelete", NULL, 353, intermediate, mergedParams, mergedTypes);
zephir_check_call_status();
break;
}
@@ -95447,7 +95535,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, getSingleResult) {
zephir_check_call_status();
RETURN_MM();
}
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "execute", NULL, 347, bindParams, bindTypes);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "execute", NULL, 349, bindParams, bindTypes);
zephir_check_call_status();
ZEPHIR_RETURN_CALL_METHOD(_1, "getfirst", NULL, 0);
zephir_check_call_status();
@@ -95619,7 +95707,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query, getSql) {
_2 = zephir_fetch_nproperty_this(this_ptr, SL("_bindTypes"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_3);
ZVAL_BOOL(&_3, 1);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_executeselect", NULL, 348, intermediate, _1, _2, &_3);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_executeselect", NULL, 350, intermediate, _1, _2, &_3);
zephir_check_call_status();
RETURN_MM();
}
@@ -96572,6 +96660,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, delete) {
static PHP_METHOD(Phalcon_Mvc_Model_Resultset, filter) {
+ zend_bool _1;
int ZEPHIR_LAST_CALL_STATUS;
zend_object_iterator *_0;
zval *filter, *records, *record = NULL, *parameters, *processedRecord = NULL;
@@ -96597,12 +96686,14 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset, filter) {
ZEPHIR_INIT_NVAR(processedRecord);
ZEPHIR_CALL_USER_FUNC_ARRAY(processedRecord, filter, parameters);
zephir_check_call_status();
- if (Z_TYPE_P(processedRecord) != IS_OBJECT) {
- if (Z_TYPE_P(processedRecord) != IS_ARRAY) {
- continue;
- }
+ _1 = Z_TYPE_P(processedRecord) != IS_OBJECT;
+ if (_1) {
+ _1 = Z_TYPE_P(processedRecord) != IS_ARRAY;
+ }
+ if (_1) {
+ continue;
}
- zephir_array_append(&records, processedRecord, PH_SEPARATE, "phalcon/mvc/model/resultset.zep", 558);
+ zephir_array_append(&records, processedRecord, PH_SEPARATE, "phalcon/mvc/model/resultset.zep", 556);
}
_0->funcs->dtor(_0 TSRMLS_CC);
RETURN_CCTOR(records);
@@ -96977,7 +97068,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction, rollback) {
ZEPHIR_INIT_NVAR(_0);
object_init_ex(_0, phalcon_mvc_model_transaction_failed_ce);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_rollbackRecord"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 358, rollbackMessage, _5);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 360, rollbackMessage, _5);
zephir_check_call_status();
zephir_throw_exception_debug(_0, "phalcon/mvc/model/transaction.zep", 160 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -96996,7 +97087,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction, getConnection) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_rollbackOnAbort"), PH_NOISY_CC);
if (zephir_is_true(_0)) {
- ZEPHIR_CALL_FUNCTION(&_1, "connection_aborted", NULL, 359);
+ ZEPHIR_CALL_FUNCTION(&_1, "connection_aborted", NULL, 361);
zephir_check_call_status();
if (zephir_is_true(_1)) {
ZEPHIR_INIT_VAR(_2);
@@ -97566,7 +97657,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Behavior_Timestampable, notify) {
ZVAL_NULL(timestamp);
ZEPHIR_OBS_VAR(format);
if (zephir_array_isset_string_fetch(&format, options, SS("format"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 299, format);
+ ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 300, format);
zephir_check_call_status();
} else {
ZEPHIR_OBS_VAR(generator);
@@ -97922,9 +98013,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Libmemcached, __construct) {
ZEPHIR_OBS_VAR(_3);
zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC);
zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 317, _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 318, _1, options);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 319, _1, options);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_4);
@@ -98023,7 +98114,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Libmemcached, reset) {
zephir_check_call_status();
}
}
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_libmemcached_ce, this_ptr, "reset", &_5, 319);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_libmemcached_ce, this_ptr, "reset", &_5, 320);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -98108,9 +98199,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memcache, __construct) {
ZEPHIR_OBS_VAR(_3);
zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC);
zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 317, _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 320, _1, options);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 321, _1, options);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_4);
@@ -98209,7 +98300,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memcache, reset) {
zephir_check_call_status();
}
}
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_memcache_ce, this_ptr, "reset", &_5, 319);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_memcache_ce, this_ptr, "reset", &_5, 320);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -98310,6 +98401,192 @@ static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memory, write) {
+#ifdef HAVE_CONFIG_H
+#endif
+
+#include
+
+#include
+#include
+#include
+
+
+
+ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_MetaData_Redis) {
+
+ ZEPHIR_REGISTER_CLASS_EX(Phalcon\\Mvc\\Model\\MetaData, Redis, phalcon, mvc_model_metadata_redis, phalcon_mvc_model_metadata_ce, phalcon_mvc_model_metadata_redis_method_entry, 0);
+
+ zend_declare_property_long(phalcon_mvc_model_metadata_redis_ce, SL("_ttl"), 172800, ZEND_ACC_PROTECTED TSRMLS_CC);
+
+ zend_declare_property_null(phalcon_mvc_model_metadata_redis_ce, SL("_redis"), ZEND_ACC_PROTECTED TSRMLS_CC);
+
+ zend_class_implements(phalcon_mvc_model_metadata_redis_ce TSRMLS_CC, 1, phalcon_mvc_model_metadatainterface_ce);
+ return SUCCESS;
+
+}
+
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, __construct) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *_2;
+ zval *options = NULL, *ttl, *_0 = NULL, *_1, *_3, *_4;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 0, 1, &options);
+
+ if (!options) {
+ ZEPHIR_CPY_WRT(options, ZEPHIR_GLOBAL(global_null));
+ } else {
+ ZEPHIR_SEPARATE_PARAM(options);
+ }
+
+
+ if (Z_TYPE_P(options) != IS_ARRAY) {
+ ZEPHIR_INIT_NVAR(options);
+ array_init(options);
+ }
+ if (!(zephir_array_isset_string(options, SS("host")))) {
+ ZEPHIR_INIT_VAR(_0);
+ ZVAL_STRING(_0, "127.0.0.1", 1);
+ zephir_array_update_string(&options, SL("host"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("port")))) {
+ ZEPHIR_INIT_NVAR(_0);
+ ZVAL_LONG(_0, 6379);
+ zephir_array_update_string(&options, SL("port"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("persistent")))) {
+ ZEPHIR_INIT_NVAR(_0);
+ ZVAL_LONG(_0, 0);
+ zephir_array_update_string(&options, SL("persistent"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("statsKey")))) {
+ ZEPHIR_INIT_NVAR(_0);
+ ZVAL_STRING(_0, "_PHCM_MM", 1);
+ zephir_array_update_string(&options, SL("statsKey"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (zephir_array_isset_string_fetch(&ttl, options, SS("lifetime"), 1 TSRMLS_CC)) {
+ zephir_update_property_this(this_ptr, SL("_ttl"), ttl TSRMLS_CC);
+ }
+ ZEPHIR_INIT_NVAR(_0);
+ object_init_ex(_0, phalcon_cache_backend_redis_ce);
+ ZEPHIR_INIT_VAR(_1);
+ object_init_ex(_1, phalcon_cache_frontend_data_ce);
+ ZEPHIR_INIT_VAR(_2);
+ zephir_create_array(_2, 1, 0 TSRMLS_CC);
+ ZEPHIR_OBS_VAR(_3);
+ zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC);
+ zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 322, _1, options);
+ zephir_check_call_status();
+ zephir_update_property_this(this_ptr, SL("_redis"), _0 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_4);
+ array_init(_4);
+ zephir_update_property_this(this_ptr, SL("_metaData"), _4 TSRMLS_CC);
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, read) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *key_param = NULL, *data = NULL, *_0;
+ zval *key = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 0, &key_param);
+
+ if (unlikely(Z_TYPE_P(key_param) != IS_STRING && Z_TYPE_P(key_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'key' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(key_param) == IS_STRING)) {
+ zephir_get_strval(key, key_param);
+ } else {
+ ZEPHIR_INIT_VAR(key);
+ ZVAL_EMPTY_STRING(key);
+ }
+
+
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ ZEPHIR_CALL_METHOD(&data, _0, "get", NULL, 0, key);
+ zephir_check_call_status();
+ if (Z_TYPE_P(data) == IS_ARRAY) {
+ RETURN_CCTOR(data);
+ }
+ RETURN_MM_NULL();
+
+}
+
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, write) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *key_param = NULL, *data, *_0;
+ zval *key = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 2, 0, &key_param, &data);
+
+ if (unlikely(Z_TYPE_P(key_param) != IS_STRING && Z_TYPE_P(key_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'key' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(key_param) == IS_STRING)) {
+ zephir_get_strval(key, key_param);
+ } else {
+ ZEPHIR_INIT_VAR(key);
+ ZVAL_EMPTY_STRING(key);
+ }
+
+
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ ZEPHIR_CALL_METHOD(NULL, _0, "save", NULL, 0, key, data);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, reset) {
+
+ zephir_fcall_cache_entry *_5 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ HashTable *_2;
+ HashPosition _1;
+ zval *meta, *key = NULL, *realKey = NULL, *_0 = NULL, **_3, *_4;
+
+ ZEPHIR_MM_GROW();
+
+ ZEPHIR_OBS_VAR(meta);
+ zephir_read_property_this(&meta, this_ptr, SL("_metaData"), PH_NOISY_CC);
+ if (Z_TYPE_P(meta) == IS_ARRAY) {
+ ZEPHIR_INIT_VAR(_0);
+ zephir_is_iterable(meta, &_2, &_1, 0, 0, "phalcon/mvc/model/metadata/redis.zep", 131);
+ for (
+ ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
+ ; zephir_hash_move_forward_ex(_2, &_1)
+ ) {
+ ZEPHIR_GET_HMKEY(key, _2, _1);
+ ZEPHIR_GET_HVALUE(_0, _3);
+ ZEPHIR_INIT_NVAR(realKey);
+ ZEPHIR_CONCAT_SV(realKey, "meta-", key);
+ _4 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ ZEPHIR_CALL_METHOD(NULL, _4, "delete", NULL, 0, realKey);
+ zephir_check_call_status();
+ }
+ }
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_redis_ce, this_ptr, "reset", &_5, 320);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+
+
+
#ifdef HAVE_CONFIG_H
#endif
@@ -100603,7 +100880,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) {
}
}
}
- if (zephir_is_numeric(limit)) {
+ if (zephir_is_numeric(number)) {
ZEPHIR_OBS_VAR(hiddenParam);
zephir_read_property_this(&hiddenParam, this_ptr, SL("_hiddenParamNumber"), PH_NOISY_CC);
ZEPHIR_INIT_LNVAR(_4);
@@ -100664,21 +100941,21 @@ static PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getQuery) {
ZEPHIR_INIT_VAR(query);
object_init_ex(query, phalcon_mvc_model_query_ce);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getphql", NULL, 352);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getphql", NULL, 354);
zephir_check_call_status();
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 343, _0, _1);
+ ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 345, _0, _1);
zephir_check_call_status();
ZEPHIR_OBS_VAR(bindParams);
zephir_read_property_this(&bindParams, this_ptr, SL("_bindParams"), PH_NOISY_CC);
if (Z_TYPE_P(bindParams) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, query, "setbindparams", NULL, 353, bindParams);
+ ZEPHIR_CALL_METHOD(NULL, query, "setbindparams", NULL, 355, bindParams);
zephir_check_call_status();
}
ZEPHIR_OBS_VAR(bindTypes);
zephir_read_property_this(&bindTypes, this_ptr, SL("_bindTypes"), PH_NOISY_CC);
if (Z_TYPE_P(bindTypes) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, query, "setbindtypes", NULL, 354, bindTypes);
+ ZEPHIR_CALL_METHOD(NULL, query, "setbindtypes", NULL, 356, bindTypes);
zephir_check_call_status();
}
RETURN_CCTOR(query);
@@ -110560,7 +110837,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, __construct) {
zephir_update_property_this(this_ptr, SL("_columnTypes"), columnTypes TSRMLS_CC);
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_complex_ce, this_ptr, "__construct", &_0, 355, result, cache);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_complex_ce, this_ptr, "__construct", &_0, 357, result, cache);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -110877,7 +111154,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, __construct) {
zephir_update_property_this(this_ptr, SL("_model"), model TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_columnMap"), columnMap TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_keepSnapshots"), keepSnapshots TSRMLS_CC);
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_simple_ce, this_ptr, "__construct", &_0, 355, result, cache);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_simple_ce, this_ptr, "__construct", &_0, 357, result, cache);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -110932,12 +111209,12 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, current) {
_6 = zephir_fetch_nproperty_this(this_ptr, SL("_keepSnapshots"), PH_NOISY_CC);
ZEPHIR_INIT_NVAR(_3);
ZVAL_LONG(_3, 0);
- ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmap", &_5, 356, _2, row, columnMap, _3, _6);
+ ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmap", &_5, 358, _2, row, columnMap, _3, _6);
zephir_check_call_status();
}
break;
}
- ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_7, 357, row, columnMap, hydrateMode);
+ ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_7, 359, row, columnMap, hydrateMode);
zephir_check_call_status();
break;
} while(0);
@@ -110953,7 +111230,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, toArray) {
HashTable *_2, *_5;
HashPosition _1, _4;
int ZEPHIR_LAST_CALL_STATUS;
- zval *renameColumns_param = NULL, *result, *records = NULL, *record = NULL, *renamed = NULL, *renamedKey = NULL, *key = NULL, *value = NULL, *renamedRecords, *columnMap, *_0, **_3, **_6, *_7 = NULL, *_8 = NULL, *_10 = NULL;
+ zval *renameColumns_param = NULL, *result, *records = NULL, *record = NULL, *renamed = NULL, *renamedKey = NULL, *key = NULL, *value = NULL, *renamedRecords, *columnMap, *_0, **_3, **_6, *_7 = NULL, *_8 = NULL;
zend_bool renameColumns;
ZEPHIR_MM_GROW();
@@ -110990,7 +111267,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, toArray) {
ZEPHIR_INIT_VAR(renamedRecords);
array_init(renamedRecords);
if (Z_TYPE_P(records) == IS_ARRAY) {
- zephir_is_iterable(records, &_2, &_1, 0, 0, "phalcon/mvc/model/resultset/simple.zep", 220);
+ zephir_is_iterable(records, &_2, &_1, 0, 0, "phalcon/mvc/model/resultset/simple.zep", 218);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -110998,7 +111275,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, toArray) {
ZEPHIR_GET_HVALUE(record, _3);
ZEPHIR_INIT_NVAR(renamed);
array_init(renamed);
- zephir_is_iterable(record, &_5, &_4, 0, 0, "phalcon/mvc/model/resultset/simple.zep", 218);
+ zephir_is_iterable(record, &_5, &_4, 0, 0, "phalcon/mvc/model/resultset/simple.zep", 216);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
@@ -111030,14 +111307,10 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, toArray) {
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_OBS_NVAR(_10);
- zephir_array_fetch_long(&_10, renamedKey, 0, PH_NOISY, "phalcon/mvc/model/resultset/simple.zep", 209 TSRMLS_CC);
- zephir_array_update_zval(&renamed, _10, &value, PH_COPY | PH_SEPARATE);
- } else {
- zephir_array_update_zval(&renamed, renamedKey, &value, PH_COPY | PH_SEPARATE);
}
+ zephir_array_update_zval(&renamed, renamedKey, &value, PH_COPY | PH_SEPARATE);
}
- zephir_array_append(&renamedRecords, renamed, PH_SEPARATE, "phalcon/mvc/model/resultset/simple.zep", 218);
+ zephir_array_append(&renamedRecords, renamed, PH_SEPARATE, "phalcon/mvc/model/resultset/simple.zep", 216);
}
}
RETURN_CCTOR(renamedRecords);
@@ -111104,22 +111377,22 @@ static PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, unserialize) {
ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 72, data);
zephir_check_call_status();
if (Z_TYPE_P(resultset) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/simple.zep", 254);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/simple.zep", 252);
return;
}
- zephir_array_fetch_string(&_0, resultset, SL("model"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 257 TSRMLS_CC);
+ zephir_array_fetch_string(&_0, resultset, SL("model"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 255 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_model"), _0 TSRMLS_CC);
- zephir_array_fetch_string(&_1, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 258 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 256 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_rows"), _1 TSRMLS_CC);
- zephir_array_fetch_string(&_2, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 259 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 257 TSRMLS_CC);
ZEPHIR_INIT_ZVAL_NREF(_3);
ZVAL_LONG(_3, zephir_fast_count_int(_2 TSRMLS_CC));
zephir_update_property_this(this_ptr, SL("_count"), _3 TSRMLS_CC);
- zephir_array_fetch_string(&_4, resultset, SL("cache"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 260 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, resultset, SL("cache"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 258 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_cache"), _4 TSRMLS_CC);
- zephir_array_fetch_string(&_5, resultset, SL("columnMap"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 261 TSRMLS_CC);
+ zephir_array_fetch_string(&_5, resultset, SL("columnMap"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 259 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_columnMap"), _5 TSRMLS_CC);
- zephir_array_fetch_string(&_6, resultset, SL("hydrateMode"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 262 TSRMLS_CC);
+ zephir_array_fetch_string(&_6, resultset, SL("hydrateMode"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 260 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_hydrateMode"), _6 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -111408,7 +111681,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction_Manager, get) {
ZEPHIR_INIT_VAR(_3);
ZVAL_STRING(_3, "rollbackPendent", 1);
zephir_array_fast_append(_2, _3);
- ZEPHIR_CALL_FUNCTION(NULL, "register_shutdown_function", NULL, 360, _2);
+ ZEPHIR_CALL_FUNCTION(NULL, "register_shutdown_function", NULL, 362, _2);
zephir_check_call_status();
}
zephir_update_property_this(this_ptr, SL("_initialized"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
@@ -111467,9 +111740,9 @@ static PHP_METHOD(Phalcon_Mvc_Model_Transaction_Manager, getOrCreateTransaction)
ZEPHIR_INIT_VAR(transaction);
object_init_ex(transaction, phalcon_mvc_model_transaction_ce);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_service"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, transaction, "__construct", NULL, 361, dependencyInjector, (autoBegin ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), _5);
+ ZEPHIR_CALL_METHOD(NULL, transaction, "__construct", NULL, 363, dependencyInjector, (autoBegin ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), _5);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, transaction, "settransactionmanager", NULL, 362, this_ptr);
+ ZEPHIR_CALL_METHOD(NULL, transaction, "settransactionmanager", NULL, 364, this_ptr);
zephir_check_call_status();
zephir_update_property_array_append(this_ptr, SL("_transactions"), transaction TSRMLS_CC);
RETURN_ON_FAILURE(zephir_property_incr(this_ptr, SL("_number") TSRMLS_CC));
@@ -111757,7 +112030,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Email, validate) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 274);
- ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 190, value, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_0);
@@ -112030,7 +112303,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Inclusionin, validate) {
zephir_check_temp_parameter(_0);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_5, "in_array", NULL, 363, value, domain, strict);
+ ZEPHIR_CALL_FUNCTION(&_5, "in_array", NULL, 365, value, domain, strict);
zephir_check_call_status();
if (!(zephir_is_true(_5))) {
ZEPHIR_INIT_NVAR(_0);
@@ -112176,7 +112449,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Ip, validate) {
zephir_array_update_string(&options, SL("flags"), &_6, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, 275);
- ZEPHIR_CALL_FUNCTION(&_7, "filter_var", NULL, 190, value, &_5, options);
+ ZEPHIR_CALL_FUNCTION(&_7, "filter_var", NULL, 191, value, &_5, options);
zephir_check_call_status();
if (!(zephir_is_true(_7))) {
ZEPHIR_INIT_NVAR(_0);
@@ -112646,7 +112919,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_StringLength, validate) {
RETURN_MM_BOOL(1);
}
if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 364, value);
+ ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, value);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(length);
@@ -112805,7 +113078,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
zephir_check_temp_parameter(_0);
zephir_check_call_status();
if (Z_TYPE_P(field) == IS_ARRAY) {
- zephir_is_iterable(field, &_2, &_1, 0, 0, "phalcon/mvc/model/validator/uniqueness.zep", 119);
+ zephir_is_iterable(field, &_2, &_1, 0, 0, "phalcon/mvc/model/validator/uniqueness.zep", 120);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -112820,7 +113093,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_4, "Column '", composeField, "' isn't part of the column map");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _4);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 96 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 97 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -112835,7 +113108,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_4, "Column '", columnField, "' isn't part of the table columns");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _4);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 106 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 107 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -112843,11 +113116,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZVAL_LONG(&_6, number);
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVSV(_7, "[", composeField, "] = ?", &_6);
- zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 112);
+ zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 113);
ZEPHIR_CALL_METHOD(&_8, record, "readattribute", &_9, 0, composeField);
zephir_check_call_status();
- zephir_array_append(&bindParams, _8, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 113);
- zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 114);
+ zephir_array_append(&bindParams, _8, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 114);
+ zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 115);
number++;
}
} else {
@@ -112860,7 +113133,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_7, "Column '", field, "' isn't part of the column map");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _7);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 126 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 127 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -112875,17 +113148,17 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_7, "Column '", columnField, "' isn't part of the table columns");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _7);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 136 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 137 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVS(_7, "[", field, "] = ?0");
- zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 142);
+ zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 143);
ZEPHIR_CALL_METHOD(&_8, record, "readattribute", NULL, 0, field);
zephir_check_call_status();
- zephir_array_append(&bindParams, _8, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 143);
- zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 144);
+ zephir_array_append(&bindParams, _8, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 144);
+ zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 145);
number++;
}
ZEPHIR_CALL_METHOD(&_10, record, "getoperationmade", NULL, 0);
@@ -112900,7 +113173,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
}
ZEPHIR_CALL_METHOD(&_8, metaData, "getprimarykeyattributes", NULL, 0, record);
zephir_check_call_status();
- zephir_is_iterable(_8, &_12, &_11, 0, 0, "phalcon/mvc/model/validator/uniqueness.zep", 189);
+ zephir_is_iterable(_8, &_12, &_11, 0, 0, "phalcon/mvc/model/validator/uniqueness.zep", 190);
for (
; zephir_hash_get_current_data_ex(_12, (void**) &_13, &_11) == SUCCESS
; zephir_hash_move_forward_ex(_12, &_11)
@@ -112914,7 +113187,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_7, "Column '", primaryField, "' isn't part of the table columns");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _7);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 166 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 167 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -112927,7 +113200,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_14, "Column '", primaryField, "' isn't part of the column map");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _14);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 174 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 175 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -112938,11 +113211,11 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZVAL_LONG(&_6, number);
ZEPHIR_INIT_LNVAR(_4);
ZEPHIR_CONCAT_SVSV(_4, "[", attributeField, "] <> ?", &_6);
- zephir_array_append(&conditions, _4, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 183);
+ zephir_array_append(&conditions, _4, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 184);
ZEPHIR_CALL_METHOD(&_15, record, "readattribute", &_16, 0, primaryField);
zephir_check_call_status();
- zephir_array_append(&bindParams, _15, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 184);
- zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 185);
+ zephir_array_append(&bindParams, _15, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 185);
+ zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 186);
number++;
}
}
@@ -113079,7 +113352,7 @@ static PHP_METHOD(Phalcon_Mvc_Model_Validator_Url, validate) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 273);
- ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 190, value, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_0);
@@ -113414,7 +113687,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Annotations, handle) {
}
zephir_update_property_this(this_ptr, SL("_processed"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
}
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_router_annotations_ce, this_ptr, "handle", &_18, 365, realUri);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_router_annotations_ce, this_ptr, "handle", &_18, 367, realUri);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -113809,6 +114082,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Router_Group) {
static PHP_METHOD(Phalcon_Mvc_Router_Group, __construct) {
int ZEPHIR_LAST_CALL_STATUS;
+ zend_bool _0;
zval *paths = NULL;
ZEPHIR_MM_GROW();
@@ -113819,12 +114093,12 @@ static PHP_METHOD(Phalcon_Mvc_Router_Group, __construct) {
}
- if (Z_TYPE_P(paths) == IS_ARRAY) {
+ _0 = Z_TYPE_P(paths) == IS_ARRAY;
+ if (!(_0)) {
+ _0 = Z_TYPE_P(paths) == IS_STRING;
+ }
+ if (_0) {
zephir_update_property_this(this_ptr, SL("_paths"), paths TSRMLS_CC);
- } else {
- if (Z_TYPE_P(paths) == IS_STRING) {
- zephir_update_property_this(this_ptr, SL("_paths"), paths TSRMLS_CC);
- }
}
if ((zephir_method_exists_ex(this_ptr, SS("initialize") TSRMLS_CC) == SUCCESS)) {
ZEPHIR_CALL_METHOD(NULL, this_ptr, "initialize", NULL, 0, paths);
@@ -114267,7 +114541,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Group, _addRoute) {
ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 74, _2, mergedPaths, httpMethods);
zephir_check_call_status();
zephir_update_property_array_append(this_ptr, SL("_routes"), route TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, route, "setgroup", NULL, 366, this_ptr);
+ ZEPHIR_CALL_METHOD(NULL, route, "setgroup", NULL, 368, this_ptr);
zephir_check_call_status();
RETURN_CCTOR(route);
@@ -114523,7 +114797,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, extractNamedParams) {
int tmp, cursor, cursorVar, marker, bracketCount = 0, parenthesesCount = 0, foundPattern = 0, intermediate = 0, numberMatches = 0;
char ch;
zval *pattern_param = NULL, *matches, _1 = zval_used_for_init, _2 = zval_used_for_init, *_3 = NULL, _18 = zval_used_for_init, _19 = zval_used_for_init, *_20 = NULL, _22 = zval_used_for_init, *_23 = NULL;
- zval *pattern = NULL, *route, *item = NULL, *variable = NULL, *regexp = NULL, *_4 = NULL, *_21 = NULL, *_24 = NULL;
+ zval *pattern = NULL, *route, *item = NULL, *variable = NULL, *regexp = NULL, *_4 = NULL, *_21 = NULL, *_24 = NULL, *_26 = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 0, &pattern_param);
@@ -114683,9 +114957,9 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, extractNamedParams) {
}
}
if (foundPattern != 2) {
- zephir_concat_self_str(&route, "(", sizeof("(")-1 TSRMLS_CC);
- zephir_concat_self(&route, regexp TSRMLS_CC);
- zephir_concat_self_str(&route, ")", sizeof(")")-1 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_26);
+ ZEPHIR_CONCAT_SVS(_26, "(", regexp, ")");
+ zephir_concat_self(&route, _26 TSRMLS_CC);
} else {
zephir_concat_self(&route, regexp TSRMLS_CC);
}
@@ -114699,9 +114973,9 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, extractNamedParams) {
zephir_array_update_zval(&matches, item, &_23, PH_COPY | PH_SEPARATE);
}
} else {
- zephir_concat_self_str(&route, "{", sizeof("{")-1 TSRMLS_CC);
- zephir_concat_self(&route, item TSRMLS_CC);
- zephir_concat_self_str(&route, "}", sizeof("}")-1 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_26);
+ ZEPHIR_CONCAT_SVS(_26, "{", item, "}");
+ zephir_concat_self(&route, _26 TSRMLS_CC);
}
continue;
}
@@ -114762,13 +115036,13 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, reConfigure) {
ZEPHIR_CALL_SELF(&routePaths, "getroutepaths", NULL, 0, paths);
zephir_check_call_status();
if (!(zephir_start_with_str(pattern, SL("#")))) {
- if (zephir_memnstr_str(pattern, SL("{"), "phalcon/mvc/router/route.zep", 299)) {
+ if (zephir_memnstr_str(pattern, SL("{"), "phalcon/mvc/router/route.zep", 295)) {
ZEPHIR_CALL_METHOD(&extracted, this_ptr, "extractnamedparams", NULL, 0, pattern);
zephir_check_call_status();
ZEPHIR_OBS_VAR(pcrePattern);
- zephir_array_fetch_long(&pcrePattern, extracted, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 304 TSRMLS_CC);
+ zephir_array_fetch_long(&pcrePattern, extracted, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 300 TSRMLS_CC);
ZEPHIR_INIT_VAR(_0);
- zephir_array_fetch_long(&_1, extracted, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/router/route.zep", 305 TSRMLS_CC);
+ zephir_array_fetch_long(&_1, extracted, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/router/route.zep", 301 TSRMLS_CC);
zephir_fast_array_merge(_0, &(routePaths), &(_1) TSRMLS_CC);
ZEPHIR_CPY_WRT(routePaths, _0);
} else {
@@ -114813,23 +115087,23 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, getRoutePaths) {
_0 = zephir_fast_count_int(parts TSRMLS_CC);
if (_0 == 3) {
ZEPHIR_OBS_NVAR(moduleName);
- zephir_array_fetch_long(&moduleName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 357 TSRMLS_CC);
+ zephir_array_fetch_long(&moduleName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 353 TSRMLS_CC);
ZEPHIR_OBS_NVAR(controllerName);
- zephir_array_fetch_long(&controllerName, parts, 1, PH_NOISY, "phalcon/mvc/router/route.zep", 358 TSRMLS_CC);
+ zephir_array_fetch_long(&controllerName, parts, 1, PH_NOISY, "phalcon/mvc/router/route.zep", 354 TSRMLS_CC);
ZEPHIR_OBS_NVAR(actionName);
- zephir_array_fetch_long(&actionName, parts, 2, PH_NOISY, "phalcon/mvc/router/route.zep", 359 TSRMLS_CC);
+ zephir_array_fetch_long(&actionName, parts, 2, PH_NOISY, "phalcon/mvc/router/route.zep", 355 TSRMLS_CC);
break;
}
if (_0 == 2) {
ZEPHIR_OBS_NVAR(controllerName);
- zephir_array_fetch_long(&controllerName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 363 TSRMLS_CC);
+ zephir_array_fetch_long(&controllerName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 359 TSRMLS_CC);
ZEPHIR_OBS_NVAR(actionName);
- zephir_array_fetch_long(&actionName, parts, 1, PH_NOISY, "phalcon/mvc/router/route.zep", 364 TSRMLS_CC);
+ zephir_array_fetch_long(&actionName, parts, 1, PH_NOISY, "phalcon/mvc/router/route.zep", 360 TSRMLS_CC);
break;
}
if (_0 == 1) {
ZEPHIR_OBS_NVAR(controllerName);
- zephir_array_fetch_long(&controllerName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 368 TSRMLS_CC);
+ zephir_array_fetch_long(&controllerName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 364 TSRMLS_CC);
break;
}
} while(0);
@@ -114840,7 +115114,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, getRoutePaths) {
zephir_array_update_string(&routePaths, SL("module"), &moduleName, PH_COPY | PH_SEPARATE);
}
if (Z_TYPE_P(controllerName) != IS_NULL) {
- if (zephir_memnstr_str(controllerName, SL("\\"), "phalcon/mvc/router/route.zep", 383)) {
+ if (zephir_memnstr_str(controllerName, SL("\\"), "phalcon/mvc/router/route.zep", 379)) {
ZEPHIR_INIT_VAR(realClassName);
zephir_get_class_ns(realClassName, controllerName, 0 TSRMLS_CC);
ZEPHIR_INIT_VAR(namespaceName);
@@ -114866,7 +115140,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, getRoutePaths) {
array_init(routePaths);
}
if (Z_TYPE_P(routePaths) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_router_exception_ce, "The route contains invalid paths", "phalcon/mvc/router/route.zep", 415);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_router_exception_ce, "The route contains invalid paths", "phalcon/mvc/router/route.zep", 411);
return;
}
RETURN_CCTOR(routePaths);
@@ -114955,7 +115229,7 @@ static PHP_METHOD(Phalcon_Mvc_Router_Route, getReversedPaths) {
ZEPHIR_INIT_VAR(reversed);
array_init(reversed);
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_paths"), PH_NOISY_CC);
- zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/router/route.zep", 506);
+ zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/router/route.zep", 502);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -115776,7 +116050,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, _loadTemplateEngines) {
if (Z_TYPE_P(registeredEngines) != IS_ARRAY) {
ZEPHIR_INIT_VAR(_0);
object_init_ex(_0, phalcon_mvc_view_engine_php_ce);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 368, this_ptr, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 370, this_ptr, dependencyInjector);
zephir_check_call_status();
zephir_array_update_string(&engines, SL(".phtml"), &_0, PH_COPY | PH_SEPARATE);
} else {
@@ -116029,7 +116303,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, render) {
} else {
ZEPHIR_CPY_WRT(mergedParams, viewParams);
}
- ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 387, path, mergedParams);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 389, path, mergedParams);
zephir_check_call_status();
if (Z_TYPE_P(cache) == IS_OBJECT) {
ZEPHIR_CALL_METHOD(&_0, cache, "isstarted", NULL, 0);
@@ -116097,7 +116371,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Simple, partial) {
} else {
ZEPHIR_CPY_WRT(mergedParams, params);
}
- ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 387, partialPath, mergedParams);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "_internalrender", NULL, 389, partialPath, mergedParams);
zephir_check_call_status();
if (Z_TYPE_P(params) == IS_ARRAY) {
zephir_update_property_this(this_ptr, SL("_viewParams"), viewParams TSRMLS_CC);
@@ -116481,7 +116755,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Php, render) {
if (mustClean == 1) {
- ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 369);
+ ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 371);
zephir_check_call_status();
}
if (Z_TYPE_P(params) == IS_ARRAY) {
@@ -116576,18 +116850,18 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, getCompiler) {
ZEPHIR_INIT_NVAR(compiler);
object_init_ex(compiler, phalcon_mvc_view_engine_volt_compiler_ce);
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_view"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, compiler, "__construct", NULL, 370, _0);
+ ZEPHIR_CALL_METHOD(NULL, compiler, "__construct", NULL, 372, _0);
zephir_check_call_status();
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
ZEPHIR_CPY_WRT(dependencyInjector, _1);
if (Z_TYPE_P(dependencyInjector) == IS_OBJECT) {
- ZEPHIR_CALL_METHOD(NULL, compiler, "setdi", NULL, 371, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, compiler, "setdi", NULL, 373, dependencyInjector);
zephir_check_call_status();
}
ZEPHIR_OBS_VAR(options);
zephir_read_property_this(&options, this_ptr, SL("_options"), PH_NOISY_CC);
if (Z_TYPE_P(options) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, compiler, "setoptions", NULL, 372, options);
+ ZEPHIR_CALL_METHOD(NULL, compiler, "setoptions", NULL, 374, options);
zephir_check_call_status();
}
zephir_update_property_this(this_ptr, SL("_compiler"), compiler TSRMLS_CC);
@@ -116627,7 +116901,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, render) {
if (mustClean) {
- ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 369);
+ ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 371);
zephir_check_call_status();
}
ZEPHIR_CALL_METHOD(&compiler, this_ptr, "getcompiler", NULL, 0);
@@ -116667,6 +116941,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, render) {
static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, length) {
int ZEPHIR_LAST_CALL_STATUS;
+ zend_bool _0;
zval *item, *length = NULL;
ZEPHIR_MM_GROW();
@@ -116676,21 +116951,20 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, length) {
ZEPHIR_INIT_VAR(length);
ZVAL_LONG(length, 0);
- if (Z_TYPE_P(item) == IS_OBJECT) {
+ _0 = Z_TYPE_P(item) == IS_OBJECT;
+ if (!(_0)) {
+ _0 = Z_TYPE_P(item) == IS_ARRAY;
+ }
+ if (_0) {
ZEPHIR_INIT_NVAR(length);
ZVAL_LONG(length, zephir_fast_count_int(item TSRMLS_CC));
} else {
- if (Z_TYPE_P(item) == IS_ARRAY) {
- ZEPHIR_INIT_NVAR(length);
- ZVAL_LONG(length, zephir_fast_count_int(item TSRMLS_CC));
+ if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) {
+ ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, item);
+ zephir_check_call_status();
} else {
- if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 364, item);
- zephir_check_call_status();
- } else {
- ZEPHIR_INIT_NVAR(length);
- ZVAL_LONG(length, zephir_fast_strlen_ev(item));
- }
+ ZEPHIR_INIT_NVAR(length);
+ ZVAL_LONG(length, zephir_fast_strlen_ev(item));
}
}
RETURN_CCTOR(length);
@@ -116712,7 +116986,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, isIncluded) {
}
if (Z_TYPE_P(haystack) == IS_STRING) {
if ((zephir_function_exists_ex(SS("mb_strpos") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_CALL_FUNCTION(&_0, "mb_strpos", NULL, 373, haystack, needle);
+ ZEPHIR_CALL_FUNCTION(&_0, "mb_strpos", NULL, 375, haystack, needle);
zephir_check_call_status();
RETURN_MM_BOOL(!ZEPHIR_IS_FALSE_IDENTICAL(_0));
}
@@ -116720,7 +116994,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, isIncluded) {
zephir_fast_strpos(_1, haystack, needle, 0 );
RETURN_MM_BOOL(!ZEPHIR_IS_FALSE_IDENTICAL(_1));
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Invalid haystack", "phalcon/mvc/view/engine/volt.zep", 170);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Invalid haystack", "phalcon/mvc/view/engine/volt.zep", 166);
return;
}
@@ -116765,7 +117039,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, convertEncoding) {
_0 = ZEPHIR_IS_STRING(to, "utf8");
}
if (_0) {
- ZEPHIR_RETURN_CALL_FUNCTION("utf8_encode", NULL, 374, text);
+ ZEPHIR_RETURN_CALL_FUNCTION("utf8_encode", NULL, 376, text);
zephir_check_call_status();
RETURN_MM();
}
@@ -116774,21 +117048,21 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, convertEncoding) {
_1 = ZEPHIR_IS_STRING(from, "utf8");
}
if (_1) {
- ZEPHIR_RETURN_CALL_FUNCTION("utf8_decode", NULL, 375, text);
+ ZEPHIR_RETURN_CALL_FUNCTION("utf8_decode", NULL, 377, text);
zephir_check_call_status();
RETURN_MM();
}
if ((zephir_function_exists_ex(SS("mb_convert_encoding") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 179, text, from, to);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 180, text, from, to);
zephir_check_call_status();
RETURN_MM();
}
if ((zephir_function_exists_ex(SS("iconv") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("iconv", NULL, 376, from, to, text);
+ ZEPHIR_RETURN_CALL_FUNCTION("iconv", NULL, 378, from, to, text);
zephir_check_call_status();
RETURN_MM();
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Any of 'mbstring' or 'iconv' is required to perform the charset conversion", "phalcon/mvc/view/engine/volt.zep", 209);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Any of 'mbstring' or 'iconv' is required to perform the charset conversion", "phalcon/mvc/view/engine/volt.zep", 205);
return;
}
@@ -116838,7 +117112,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) {
if (_1) {
ZEPHIR_CALL_METHOD(&_2, value, "current", &_3, 0);
zephir_check_call_status();
- zephir_array_append(&slice, _2, PH_SEPARATE, "phalcon/mvc/view/engine/volt.zep", 235);
+ zephir_array_append(&slice, _2, PH_SEPARATE, "phalcon/mvc/view/engine/volt.zep", 231);
}
ZEPHIR_CALL_METHOD(NULL, value, "next", &_4, 0);
zephir_check_call_status();
@@ -116855,7 +117129,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) {
if (Z_TYPE_P(value) == IS_ARRAY) {
ZEPHIR_SINIT_VAR(_5);
ZVAL_LONG(&_5, start);
- ZEPHIR_RETURN_CALL_FUNCTION("array_slice", NULL, 377, value, &_5, length);
+ ZEPHIR_RETURN_CALL_FUNCTION("array_slice", NULL, 379, value, &_5, length);
zephir_check_call_status();
RETURN_MM();
}
@@ -116863,13 +117137,13 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) {
if (Z_TYPE_P(length) != IS_NULL) {
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, start);
- ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 378, value, &_5, length);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 380, value, &_5, length);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, start);
- ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 378, value, &_5);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 380, value, &_5);
zephir_check_call_status();
RETURN_MM();
}
@@ -116899,7 +117173,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, sort) {
Z_SET_ISREF_P(value);
- ZEPHIR_CALL_FUNCTION(NULL, "asort", NULL, 379, value);
+ ZEPHIR_CALL_FUNCTION(NULL, "asort", NULL, 381, value);
Z_UNSET_ISREF_P(value);
zephir_check_call_status();
RETURN_CTOR(value);
@@ -116939,11 +117213,11 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, callMacro) {
ZEPHIR_CONCAT_SVS(_2, "Macro '", name, "' does not exist");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt.zep", 297 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt.zep", 293 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_RETURN_CALL_FUNCTION("call_user_func", NULL, 380, macro, arguments);
+ ZEPHIR_RETURN_CALL_FUNCTION("call_user_func", NULL, 382, macro, arguments);
zephir_check_call_status();
RETURN_MM();
@@ -117406,7 +117680,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) {
}
}
} else {
- ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_4, 381, left);
+ ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_4, 383, left);
zephir_check_call_status();
ZEPHIR_OBS_VAR(leftType);
zephir_array_fetch_string(&leftType, left, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 339 TSRMLS_CC);
@@ -117428,7 +117702,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) {
zephir_array_fetch_string(&_7, right, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 352 TSRMLS_CC);
zephir_concat_self(&exprCode, _7 TSRMLS_CC);
} else {
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_4, 381, right);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_4, 383, right);
zephir_check_call_status();
zephir_concat_self(&exprCode, _1 TSRMLS_CC);
}
@@ -117457,7 +117731,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
ZVAL_NULL(funcArguments);
ZEPHIR_OBS_NVAR(funcArguments);
if (zephir_array_isset_string_fetch(&funcArguments, expr, SS("arguments"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", &_0, 381, funcArguments);
+ ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", &_0, 383, funcArguments);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(arguments);
@@ -117480,7 +117754,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
zephir_array_fast_append(_1, funcArguments);
ZEPHIR_INIT_VAR(_2);
ZVAL_STRING(_2, "compileFunction", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 382, _2, _1);
+ ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 384, _2, _1);
zephir_check_temp_parameter(_2);
zephir_check_call_status();
if (Z_TYPE_P(code) == IS_STRING) {
@@ -117547,7 +117821,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
ZEPHIR_OBS_VAR(exprLevel);
zephir_read_property_this(&exprLevel, this_ptr, SL("_exprLevel"), PH_NOISY_CC);
if (Z_TYPE_P(block) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlistorextends", NULL, 383, block);
+ ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlistorextends", NULL, 385, block);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(exprLevel, 1)) {
ZEPHIR_CPY_WRT(escapedCode, code);
@@ -117583,7 +117857,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
zephir_read_property_this(&arrayHelpers, this_ptr, SL("_arrayHelpers"), PH_NOISY_CC);
if (Z_TYPE_P(arrayHelpers) != IS_ARRAY) {
ZEPHIR_INIT_NVAR(arrayHelpers);
- zephir_create_array(arrayHelpers, 17, 0 TSRMLS_CC);
+ zephir_create_array(arrayHelpers, 18, 0 TSRMLS_CC);
zephir_array_update_string(&arrayHelpers, SL("link_to"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("image"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("form"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
@@ -117599,6 +117873,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
zephir_array_update_string(&arrayHelpers, SL("text_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("email_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("date_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
+ zephir_array_update_string(&arrayHelpers, SL("tel_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("numeric_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("image_input"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_update_property_this(this_ptr, SL("_arrayHelpers"), arrayHelpers TSRMLS_CC);
@@ -117641,17 +117916,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
}
ZEPHIR_INIT_NVAR(_2);
object_init_ex(_2, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_3, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 572 TSRMLS_CC);
- zephir_array_fetch_string(&_4, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 572 TSRMLS_CC);
+ zephir_array_fetch_string(&_3, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVSVSV(_5, "Undefined function '", name, "' in ", _3, " on line ", _4);
ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _5);
zephir_check_call_status();
- zephir_throw_exception_debug(_2, "phalcon/mvc/view/engine/volt/compiler.zep", 572 TSRMLS_CC);
+ zephir_throw_exception_debug(_2, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_CALL_METHOD(&_8, this_ptr, "expression", &_0, 381, nameExpr);
+ ZEPHIR_CALL_METHOD(&_8, this_ptr, "expression", &_0, 383, nameExpr);
zephir_check_call_status();
ZEPHIR_CONCAT_VSVS(return_value, _8, "(", arguments, ")");
RETURN_MM();
@@ -117675,10 +117950,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveTest) {
ZEPHIR_OBS_VAR(type);
- zephir_array_fetch_string(&type, test, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 585 TSRMLS_CC);
+ zephir_array_fetch_string(&type, test, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 586 TSRMLS_CC);
if (ZEPHIR_IS_LONG(type, 265)) {
ZEPHIR_OBS_VAR(name);
- zephir_array_fetch_string(&name, test, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 592 TSRMLS_CC);
+ zephir_array_fetch_string(&name, test, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 593 TSRMLS_CC);
if (ZEPHIR_IS_STRING(name, "empty")) {
ZEPHIR_CONCAT_SVS(return_value, "empty(", left, ")");
RETURN_MM();
@@ -117706,33 +117981,33 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveTest) {
}
if (ZEPHIR_IS_LONG(type, 350)) {
ZEPHIR_OBS_VAR(testName);
- zephir_array_fetch_string(&testName, test, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 643 TSRMLS_CC);
+ zephir_array_fetch_string(&testName, test, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 644 TSRMLS_CC);
ZEPHIR_OBS_NVAR(name);
if (zephir_array_isset_string_fetch(&name, testName, SS("value"), 0 TSRMLS_CC)) {
if (ZEPHIR_IS_STRING(name, "divisibleby")) {
- zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 647 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 381, _1);
+ zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 648 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "(((", left, ") % (", _0, ")) == 0)");
RETURN_MM();
}
if (ZEPHIR_IS_STRING(name, "sameas")) {
- zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 654 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 381, _1);
+ zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 655 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "(", left, ") === (", _0, ")");
RETURN_MM();
}
if (ZEPHIR_IS_STRING(name, "type")) {
- zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 661 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 381, _1);
+ zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 662 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "gettype(", left, ") === (", _0, ")");
RETURN_MM();
}
}
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 381, test);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, test);
zephir_check_call_status();
ZEPHIR_CONCAT_VSV(return_value, left, " == ", _0);
RETURN_MM();
@@ -117758,28 +118033,28 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
ZEPHIR_INIT_VAR(code);
ZVAL_NULL(code);
ZEPHIR_OBS_VAR(type);
- zephir_array_fetch_string(&type, filter, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 680 TSRMLS_CC);
+ zephir_array_fetch_string(&type, filter, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 681 TSRMLS_CC);
if (ZEPHIR_IS_LONG(type, 265)) {
ZEPHIR_OBS_VAR(name);
- zephir_array_fetch_string(&name, filter, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 686 TSRMLS_CC);
+ zephir_array_fetch_string(&name, filter, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 687 TSRMLS_CC);
} else {
if (!ZEPHIR_IS_LONG(type, 350)) {
ZEPHIR_INIT_VAR(_0);
object_init_ex(_0, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 694 TSRMLS_CC);
- zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 694 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC);
ZEPHIR_INIT_VAR(_3);
ZEPHIR_CONCAT_SVSV(_3, "Unknown filter type in ", _1, " on line ", _2);
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 694 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
ZEPHIR_OBS_VAR(functionName);
- zephir_array_fetch_string(&functionName, filter, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 697 TSRMLS_CC);
+ zephir_array_fetch_string(&functionName, filter, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 698 TSRMLS_CC);
ZEPHIR_OBS_NVAR(name);
- zephir_array_fetch_string(&name, functionName, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 698 TSRMLS_CC);
+ zephir_array_fetch_string(&name, functionName, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 699 TSRMLS_CC);
}
ZEPHIR_INIT_VAR(funcArguments);
ZVAL_NULL(funcArguments);
@@ -117789,9 +118064,9 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
if (zephir_array_isset_string_fetch(&funcArguments, filter, SS("arguments"), 0 TSRMLS_CC)) {
if (!ZEPHIR_IS_STRING(name, "default")) {
ZEPHIR_OBS_VAR(file);
- zephir_array_fetch_string(&file, filter, SL("file"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 713 TSRMLS_CC);
+ zephir_array_fetch_string(&file, filter, SL("file"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 714 TSRMLS_CC);
ZEPHIR_OBS_VAR(line);
- zephir_array_fetch_string(&line, filter, SL("line"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 713 TSRMLS_CC);
+ zephir_array_fetch_string(&line, filter, SL("line"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 714 TSRMLS_CC);
ZEPHIR_INIT_VAR(_4);
zephir_create_array(_4, 3, 0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_5);
@@ -117804,11 +118079,11 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
zephir_array_update_string(&_4, SL("file"), &file, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("line"), &line, PH_COPY | PH_SEPARATE);
Z_SET_ISREF_P(funcArguments);
- ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 384, funcArguments, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 386, funcArguments, _4);
Z_UNSET_ISREF_P(funcArguments);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", NULL, 381, funcArguments);
+ ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", NULL, 383, funcArguments);
zephir_check_call_status();
} else {
ZEPHIR_CPY_WRT(arguments, left);
@@ -117823,7 +118098,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
zephir_array_fast_append(_4, funcArguments);
ZEPHIR_INIT_NVAR(_0);
ZVAL_STRING(_0, "compileFilter", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 382, _0, _4);
+ ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 384, _0, _4);
zephir_check_temp_parameter(_0);
zephir_check_call_status();
if (Z_TYPE_P(code) == IS_STRING) {
@@ -117852,13 +118127,13 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
}
ZEPHIR_INIT_NVAR(_0);
object_init_ex(_0, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 776 TSRMLS_CC);
- zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 776 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_3);
ZEPHIR_CONCAT_SVSVSV(_3, "Invalid definition for user filter '", name, "' in ", _1, " on line ", _2);
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 776 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -117981,13 +118256,13 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
}
ZEPHIR_INIT_NVAR(_0);
object_init_ex(_0, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 965 TSRMLS_CC);
- zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 965 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_3);
ZEPHIR_CONCAT_SVSVSV(_3, "Unknown filter \"", name, "\" in ", _1, " on line ", _2);
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 965 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -118021,7 +118296,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
zephir_array_fast_append(_0, expr);
ZEPHIR_INIT_NVAR(_1);
ZVAL_STRING(_1, "resolveExpression", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "fireextensionevent", &_2, 382, _1, _0);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "fireextensionevent", &_2, 384, _1, _0);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
if (Z_TYPE_P(exprCode) == IS_STRING) {
@@ -118032,22 +118307,22 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
if (!(zephir_array_isset_string_fetch(&type, expr, SS("type"), 0 TSRMLS_CC))) {
ZEPHIR_INIT_NVAR(items);
array_init(items);
- zephir_is_iterable(expr, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1006);
+ zephir_is_iterable(expr, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1007);
for (
; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS
; zephir_hash_move_forward_ex(_4, &_3)
) {
ZEPHIR_GET_HVALUE(singleExpr, _5);
- zephir_array_fetch_string(&_6, singleExpr, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 999 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&singleExprCode, this_ptr, "expression", &_7, 381, _6);
+ zephir_array_fetch_string(&_6, singleExpr, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1000 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&singleExprCode, this_ptr, "expression", &_7, 383, _6);
zephir_check_call_status();
ZEPHIR_OBS_NVAR(name);
if (zephir_array_isset_string_fetch(&name, singleExpr, SS("name"), 0 TSRMLS_CC)) {
ZEPHIR_INIT_LNVAR(_8);
ZEPHIR_CONCAT_SVSV(_8, "'", name, "' => ", singleExprCode);
- zephir_array_append(&items, _8, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1001);
+ zephir_array_append(&items, _8, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1002);
} else {
- zephir_array_append(&items, singleExprCode, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1003);
+ zephir_array_append(&items, singleExprCode, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1004);
}
}
ZEPHIR_INIT_NVAR(exprCode);
@@ -118061,24 +118336,24 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
}
ZEPHIR_OBS_NVAR(left);
if (zephir_array_isset_string_fetch(&left, expr, SS("left"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_7, 381, left);
+ ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_7, 383, left);
zephir_check_call_status();
}
if (ZEPHIR_IS_LONG(type, 311)) {
- zephir_array_fetch_string(&_6, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1029 TSRMLS_CC);
+ zephir_array_fetch_string(&_6, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1030 TSRMLS_CC);
ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvetest", &_10, 0, _6, leftCode);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 124)) {
- zephir_array_fetch_string(&_11, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1037 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvefilter", &_12, 385, _11, leftCode);
+ zephir_array_fetch_string(&_11, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1038 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvefilter", &_12, 387, _11, leftCode);
zephir_check_call_status();
break;
}
ZEPHIR_OBS_NVAR(right);
if (zephir_array_isset_string_fetch(&right, expr, SS("right"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&rightCode, this_ptr, "expression", &_7, 381, right);
+ ZEPHIR_CALL_METHOD(&rightCode, this_ptr, "expression", &_7, 383, right);
zephir_check_call_status();
}
ZEPHIR_INIT_NVAR(exprCode);
@@ -118150,17 +118425,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
}
if (ZEPHIR_IS_LONG(type, 258)) {
ZEPHIR_OBS_NVAR(exprCode);
- zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1104 TSRMLS_CC);
+ zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1105 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(type, 259)) {
ZEPHIR_OBS_NVAR(exprCode);
- zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1108 TSRMLS_CC);
+ zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1109 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(type, 260)) {
ZEPHIR_INIT_NVAR(_1);
- zephir_array_fetch_string(&_6, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1112 TSRMLS_CC);
+ zephir_array_fetch_string(&_6, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1113 TSRMLS_CC);
ZEPHIR_SINIT_NVAR(_13);
ZVAL_STRING(&_13, "'", 0);
ZEPHIR_SINIT_NVAR(_14);
@@ -118186,7 +118461,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
break;
}
if (ZEPHIR_IS_LONG(type, 265)) {
- zephir_array_fetch_string(&_11, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1128 TSRMLS_CC);
+ zephir_array_fetch_string(&_11, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1129 TSRMLS_CC);
ZEPHIR_INIT_NVAR(exprCode);
ZEPHIR_CONCAT_SV(exprCode, "$", _11);
break;
@@ -118254,7 +118529,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
if (ZEPHIR_IS_LONG(type, 365)) {
ZEPHIR_OBS_NVAR(start);
if (zephir_array_isset_string_fetch(&start, expr, SS("start"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&startCode, this_ptr, "expression", &_7, 381, start);
+ ZEPHIR_CALL_METHOD(&startCode, this_ptr, "expression", &_7, 383, start);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(startCode);
@@ -118262,7 +118537,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
}
ZEPHIR_OBS_NVAR(end);
if (zephir_array_isset_string_fetch(&end, expr, SS("end"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&endCode, this_ptr, "expression", &_7, 381, end);
+ ZEPHIR_CALL_METHOD(&endCode, this_ptr, "expression", &_7, 383, end);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(endCode);
@@ -118353,8 +118628,8 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
break;
}
if (ZEPHIR_IS_LONG(type, 366)) {
- zephir_array_fetch_string(&_6, expr, SL("ternary"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1267 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_16, this_ptr, "expression", &_7, 381, _6);
+ zephir_array_fetch_string(&_6, expr, SL("ternary"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1268 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_16, this_ptr, "expression", &_7, 383, _6);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(exprCode);
ZEPHIR_CONCAT_SVSVSVS(exprCode, "(", _16, " ? ", leftCode, " : ", rightCode, ")");
@@ -118372,18 +118647,18 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
}
if (ZEPHIR_IS_LONG(type, 364)) {
ZEPHIR_OBS_NVAR(exprCode);
- zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1279 TSRMLS_CC);
+ zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1280 TSRMLS_CC);
break;
}
ZEPHIR_INIT_NVAR(_1);
object_init_ex(_1, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_11, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1283 TSRMLS_CC);
- zephir_array_fetch_string(&_17, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1283 TSRMLS_CC);
+ zephir_array_fetch_string(&_11, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC);
+ zephir_array_fetch_string(&_17, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_8);
ZEPHIR_CONCAT_SVSVSV(_8, "Unknown expression ", type, " in ", _11, " on line ", _17);
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_18, 9, _8);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1283 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
} while(0);
@@ -118414,7 +118689,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, _statementListOrExtends
}
isStatementList = 1;
if (!(zephir_array_isset_string(statements, SS("type")))) {
- zephir_is_iterable(statements, &_1, &_0, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1323);
+ zephir_is_iterable(statements, &_1, &_0, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1324);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -118427,7 +118702,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, _statementListOrExtends
}
}
if (isStatementList == 1) {
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_statementlist", NULL, 386, statements);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_statementlist", NULL, 388, statements);
zephir_check_call_status();
RETURN_MM();
}
@@ -118459,7 +118734,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
if (!(zephir_array_isset_string(statement, SS("expr")))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1351);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1352);
return;
}
ZEPHIR_INIT_VAR(compilation);
@@ -118474,15 +118749,15 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
ZEPHIR_INIT_VAR(prefixLevel);
ZEPHIR_CONCAT_VV(prefixLevel, prefix, level);
ZEPHIR_OBS_VAR(expr);
- zephir_array_fetch_string(&expr, statement, SL("expr"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1369 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 381, expr);
+ zephir_array_fetch_string(&expr, statement, SL("expr"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1370 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 383, expr);
zephir_check_call_status();
ZEPHIR_OBS_VAR(blockStatements);
- zephir_array_fetch_string(&blockStatements, statement, SL("block_statements"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1375 TSRMLS_CC);
+ zephir_array_fetch_string(&blockStatements, statement, SL("block_statements"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1376 TSRMLS_CC);
ZEPHIR_INIT_NVAR(forElse);
ZVAL_BOOL(forElse, 0);
if (Z_TYPE_P(blockStatements) == IS_ARRAY) {
- zephir_is_iterable(blockStatements, &_2, &_1, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1401);
+ zephir_is_iterable(blockStatements, &_2, &_1, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1402);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -118505,7 +118780,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
}
}
}
- ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlist", NULL, 386, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlist", NULL, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
ZEPHIR_OBS_VAR(loopContext);
zephir_read_property_this(&loopContext, this_ptr, SL("_loopPointers"), PH_NOISY_CC);
@@ -118540,7 +118815,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
ZEPHIR_CPY_WRT(iterator, exprCode);
}
ZEPHIR_OBS_VAR(variable);
- zephir_array_fetch_string(&variable, statement, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1430 TSRMLS_CC);
+ zephir_array_fetch_string(&variable, statement, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1431 TSRMLS_CC);
ZEPHIR_OBS_VAR(key);
if (zephir_array_isset_string_fetch(&key, statement, SS("key"), 0 TSRMLS_CC)) {
ZEPHIR_INIT_LNVAR(_5);
@@ -118553,7 +118828,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
}
ZEPHIR_OBS_VAR(ifExpr);
if (zephir_array_isset_string_fetch(&ifExpr, statement, SS("if_expr"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_12, this_ptr, "expression", &_0, 381, ifExpr);
+ ZEPHIR_CALL_METHOD(&_12, this_ptr, "expression", &_0, 383, ifExpr);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVS(_5, "if (", _12, ") { ?>");
@@ -118648,19 +118923,19 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileIf) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1521);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1522);
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 381, expr);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr);
zephir_check_call_status();
- zephir_array_fetch_string(&_2, statement, SL("true_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1527 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_statementlist", &_3, 386, _2, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ zephir_array_fetch_string(&_2, statement, SL("true_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1528 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_statementlist", &_3, 388, _2, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
ZEPHIR_INIT_VAR(compilation);
ZEPHIR_CONCAT_SVSV(compilation, "", _1);
ZEPHIR_OBS_VAR(blockStatements);
if (zephir_array_isset_string_fetch(&blockStatements, statement, SS("false_statements"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "_statementlist", &_3, 386, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "_statementlist", &_3, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZEPHIR_CONCAT_SV(_5, "", _4);
@@ -118686,10 +118961,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileElseIf) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1556);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1557);
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 381, expr);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr);
zephir_check_call_status();
ZEPHIR_CONCAT_SVS(return_value, "");
RETURN_MM();
@@ -118718,12 +118993,12 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1576);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1577);
return;
}
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 381, expr);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 383, expr);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_0, 381, expr);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_0, 383, expr);
zephir_check_call_status();
ZEPHIR_INIT_VAR(compilation);
ZEPHIR_CONCAT_SVS(compilation, "di->get('viewCache'); ");
@@ -118732,14 +119007,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) {
ZEPHIR_INIT_VAR(_2);
ZEPHIR_CONCAT_SVS(_2, "$_cacheKey[", exprCode, "]");
zephir_concat_self(&compilation, _2 TSRMLS_CC);
- zephir_array_fetch_string(&_3, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1586 TSRMLS_CC);
+ zephir_array_fetch_string(&_3, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1587 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_3, 265)) {
- zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1587 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1588 TSRMLS_CC);
ZEPHIR_INIT_VAR(_5);
ZEPHIR_CONCAT_SVSVSVS(_5, " = $_cache[", exprCode, "]->start(", exprCode, ", $", _4, "); ");
zephir_concat_self(&compilation, _5 TSRMLS_CC);
} else {
- zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1589 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1590 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVSVSVS(_5, " = $_cache[", exprCode, "]->start(", exprCode, ", ", _4, "); ");
zephir_concat_self(&compilation, _5 TSRMLS_CC);
@@ -118752,20 +119027,20 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) {
ZEPHIR_INIT_LNVAR(_2);
ZEPHIR_CONCAT_SVS(_2, "if ($_cacheKey[", exprCode, "] === null) { ?>");
zephir_concat_self(&compilation, _2 TSRMLS_CC);
- zephir_array_fetch_string(&_3, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1599 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_6, this_ptr, "_statementlist", NULL, 386, _3, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ zephir_array_fetch_string(&_3, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1600 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_6, this_ptr, "_statementlist", NULL, 388, _3, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_concat_self(&compilation, _6 TSRMLS_CC);
ZEPHIR_OBS_NVAR(lifetime);
if (zephir_array_isset_string_fetch(&lifetime, statement, SS("lifetime"), 0 TSRMLS_CC)) {
- zephir_array_fetch_string(&_4, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1605 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1606 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_4, 265)) {
- zephir_array_fetch_string(&_7, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1606 TSRMLS_CC);
+ zephir_array_fetch_string(&_7, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1607 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVSVSVS(_5, "save(", exprCode, ", null, $", _7, "); ");
zephir_concat_self(&compilation, _5 TSRMLS_CC);
} else {
- zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1608 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1609 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVSVSVS(_5, "save(", exprCode, ", null, ", _4, "); ");
zephir_concat_self(&compilation, _5 TSRMLS_CC);
@@ -118800,24 +119075,24 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileSet) {
ZEPHIR_OBS_VAR(assignments);
if (!(zephir_array_isset_string_fetch(&assignments, statement, SS("assignments"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1629);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1630);
return;
}
ZEPHIR_INIT_VAR(compilation);
ZVAL_STRING(compilation, "");
RETURN_MM();
@@ -118895,10 +119170,10 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileReturn) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1710);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1711);
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 381, expr);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr);
zephir_check_call_status();
ZEPHIR_CONCAT_SVS(return_value, "");
RETURN_MM();
@@ -118922,14 +119197,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileAutoEscape) {
ZEPHIR_OBS_VAR(autoescape);
if (!(zephir_array_isset_string_fetch(&autoescape, statement, SS("enable"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1730);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1731);
return;
}
ZEPHIR_OBS_VAR(oldAutoescape);
zephir_read_property_this(&oldAutoescape, this_ptr, SL("_autoescape"), PH_NOISY_CC);
zephir_update_property_this(this_ptr, SL("_autoescape"), autoescape TSRMLS_CC);
- zephir_array_fetch_string(&_0, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1739 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&compilation, this_ptr, "_statementlist", NULL, 386, _0, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ zephir_array_fetch_string(&_0, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1740 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&compilation, this_ptr, "_statementlist", NULL, 388, _0, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_autoescape"), oldAutoescape TSRMLS_CC);
RETURN_CCTOR(compilation);
@@ -118951,17 +119226,17 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileEcho) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1760);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1761);
return;
}
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", NULL, 381, expr);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", NULL, 383, expr);
zephir_check_call_status();
- zephir_array_fetch_string(&_0, expr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1768 TSRMLS_CC);
+ zephir_array_fetch_string(&_0, expr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1769 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_0, 350)) {
- zephir_array_fetch_string(&name, expr, SL("name"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1770 TSRMLS_CC);
- zephir_array_fetch_string(&_1, name, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1772 TSRMLS_CC);
+ zephir_array_fetch_string(&name, expr, SL("name"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1771 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, name, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1773 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_1, 265)) {
- zephir_array_fetch_string(&_2, name, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1777 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, name, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1778 TSRMLS_CC);
if (ZEPHIR_IS_STRING(_2, "super")) {
RETURN_CCTOR(exprCode);
}
@@ -118993,14 +119268,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileInclude) {
ZEPHIR_OBS_VAR(pathExpr);
if (!(zephir_array_isset_string_fetch(&pathExpr, statement, SS("path"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1805);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1806);
return;
}
- zephir_array_fetch_string(&_0, pathExpr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1812 TSRMLS_CC);
+ zephir_array_fetch_string(&_0, pathExpr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1813 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_0, 260)) {
if (!(zephir_array_isset_string(statement, SS("params")))) {
ZEPHIR_OBS_VAR(path);
- zephir_array_fetch_string(&path, pathExpr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1822 TSRMLS_CC);
+ zephir_array_fetch_string(&path, pathExpr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1823 TSRMLS_CC);
ZEPHIR_OBS_VAR(view);
zephir_read_property_this(&view, this_ptr, SL("_view"), PH_NOISY_CC);
if (Z_TYPE_P(view) == IS_OBJECT) {
@@ -119028,14 +119303,14 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileInclude) {
RETURN_CCTOR(compilation);
}
}
- ZEPHIR_CALL_METHOD(&path, this_ptr, "expression", &_3, 381, pathExpr);
+ ZEPHIR_CALL_METHOD(&path, this_ptr, "expression", &_3, 383, pathExpr);
zephir_check_call_status();
ZEPHIR_OBS_VAR(params);
if (!(zephir_array_isset_string_fetch(¶ms, statement, SS("params"), 0 TSRMLS_CC))) {
ZEPHIR_CONCAT_SVS(return_value, "partial(", path, "); ?>");
RETURN_MM();
}
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_3, 381, params);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_3, 383, params);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "partial(", path, ", ", _1, "); ?>");
RETURN_MM();
@@ -119062,7 +119337,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
ZEPHIR_OBS_VAR(name);
if (!(zephir_array_isset_string_fetch(&name, statement, SS("name"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1877);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1878);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_macros"), PH_NOISY_CC);
@@ -119073,7 +119348,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
ZEPHIR_CONCAT_SVS(_2, "Macro '", name, "' is already defined");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1884 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1885 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -119091,7 +119366,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
ZEPHIR_INIT_LNVAR(_2);
ZEPHIR_CONCAT_VS(_2, macroName, " = function($__p = null) { ");
zephir_concat_self(&code, _2 TSRMLS_CC);
- zephir_is_iterable(parameters, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1922);
+ zephir_is_iterable(parameters, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1923);
for (
; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS
; zephir_hash_move_forward_ex(_4, &_3)
@@ -119099,7 +119374,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
ZEPHIR_GET_HMKEY(position, _4, _3);
ZEPHIR_GET_HVALUE(parameter, _5);
ZEPHIR_OBS_NVAR(variableName);
- zephir_array_fetch_string(&variableName, parameter, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1906 TSRMLS_CC);
+ zephir_array_fetch_string(&variableName, parameter, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1907 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_6);
ZEPHIR_CONCAT_SVS(_6, "if (isset($__p[", position, "])) { ");
zephir_concat_self(&code, _6 TSRMLS_CC);
@@ -119116,7 +119391,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
zephir_concat_self_str(&code, SL(" } else { ") TSRMLS_CC);
ZEPHIR_OBS_NVAR(defaultValue);
if (zephir_array_isset_string_fetch(&defaultValue, parameter, SS("default"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_10, this_ptr, "expression", &_11, 381, defaultValue);
+ ZEPHIR_CALL_METHOD(&_10, this_ptr, "expression", &_11, 383, defaultValue);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_12);
ZEPHIR_CONCAT_SVSVS(_12, "$", variableName, " = ", _10, ";");
@@ -119132,7 +119407,7 @@ static PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
}
ZEPHIR_OBS_VAR(blockStatements);
if (zephir_array_isset_string_fetch(&blockStatements, statement, SS("block_statements"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_10, this_ptr, "_statementlist", NULL, 386, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_10, this_ptr, "_statementlist", NULL, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_2);
ZEPHIR_CONCAT_VS(_2, _10, " 1) {
ZEPHIR_OBS_VAR(numberOfBytes);
- zephir_array_fetch_long(&numberOfBytes, response, 1, PH_NOISY, "phalcon/queue/beanstalk.zep", 288 TSRMLS_CC);
+ zephir_array_fetch_long(&numberOfBytes, response, 1, PH_NOISY, "phalcon/queue/beanstalk.zep", 293 TSRMLS_CC);
ZEPHIR_CALL_METHOD(&response, this_ptr, "read", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&data, "yaml_parse", NULL, 0, response);
@@ -130444,13 +130723,13 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, read) {
}
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, (length + 2));
- ZEPHIR_CALL_FUNCTION(&data, "fread", NULL, 393, connection, &_0);
+ ZEPHIR_CALL_FUNCTION(&data, "fread", NULL, 395, connection, &_0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_1, "stream_get_meta_data", NULL, 394, connection);
+ ZEPHIR_CALL_FUNCTION(&_1, "stream_get_meta_data", NULL, 396, connection);
zephir_check_call_status();
- zephir_array_fetch_string(&_2, _1, SL("timed_out"), PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 332 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, _1, SL("timed_out"), PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 337 TSRMLS_CC);
if (zephir_is_true(_2)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_exception_ce, "Connection timed out", "phalcon/queue/beanstalk.zep", 333);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_exception_ce, "Connection timed out", "phalcon/queue/beanstalk.zep", 338);
return;
}
ZEPHIR_SINIT_NVAR(_0);
@@ -130462,7 +130741,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, read) {
ZVAL_LONG(&_0, 16384);
ZEPHIR_SINIT_VAR(_3);
ZVAL_STRING(&_3, "\r\n", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("stream_get_line", NULL, 395, connection, &_0, &_3);
+ ZEPHIR_RETURN_CALL_FUNCTION("stream_get_line", NULL, 397, connection, &_0, &_3);
zephir_check_call_status();
RETURN_MM();
@@ -130494,7 +130773,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk, write) {
ZEPHIR_CPY_WRT(packet, _0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, zephir_fast_strlen_ev(packet));
- ZEPHIR_RETURN_CALL_FUNCTION("fwrite", NULL, 396, connection, packet, &_1);
+ ZEPHIR_RETURN_CALL_FUNCTION("fwrite", NULL, 398, connection, packet, &_1);
zephir_check_call_status();
RETURN_MM();
@@ -130560,15 +130839,19 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, getBody) {
static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, __construct) {
- zval *queue, *id, *body;
+ zval *id = NULL;
+ zval *queue, *id_param = NULL, *body;
- zephir_fetch_params(0, 3, 0, &queue, &id, &body);
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 3, 0, &queue, &id_param, &body);
+ zephir_get_strval(id, id_param);
zephir_update_property_this(this_ptr, SL("_queue"), queue TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_id"), id TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_body"), body TSRMLS_CC);
+ ZEPHIR_MM_RESTORE();
}
@@ -130588,7 +130871,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, delete) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 59 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 57 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_3, "DELETED"));
}
@@ -130626,7 +130909,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, release) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_4, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_5, _4, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 73 TSRMLS_CC);
+ zephir_array_fetch_long(&_5, _4, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 71 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_5, "RELEASED"));
}
@@ -130657,7 +130940,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, bury) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_3, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_4, _3, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 87 TSRMLS_CC);
+ zephir_array_fetch_long(&_4, _3, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 85 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_4, "BURIED"));
}
@@ -130678,7 +130961,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, touch) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 104 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 102 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_3, "TOUCHED"));
}
@@ -130699,7 +130982,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, kick) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 116 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 114 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_3, "KICKED"));
}
@@ -130720,11 +131003,11 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, stats) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&response, queue, "readyaml", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_2, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 130 TSRMLS_CC);
+ zephir_array_fetch_long(&_2, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 128 TSRMLS_CC);
if (ZEPHIR_IS_STRING(_2, "NOT_FOUND")) {
RETURN_MM_BOOL(0);
}
- zephir_array_fetch_long(&_3, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 134 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 132 TSRMLS_CC);
RETURN_CTOR(_3);
}
@@ -130749,7 +131032,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, __wakeup) {
zephir_check_temp_parameter(_2);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/queue/beanstalk/job.zep", 143 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/queue/beanstalk/job.zep", 141 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -131635,7 +131918,7 @@ static PHP_METHOD(Phalcon_Session_Bag, getIterator) {
}
object_init_ex(return_value, zephir_get_internal_ce(SS("arrayiterator") TSRMLS_CC));
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 410, _1);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 412, _1);
zephir_check_call_status();
RETURN_MM();
@@ -131923,7 +132206,7 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) {
ZEPHIR_OBS_VAR(_3);
zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC);
zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 317, _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_4);
zephir_create_array(_4, 4, 0 TSRMLS_CC);
@@ -131931,7 +132214,7 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) {
zephir_array_update_string(&_4, SL("client"), &client, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("prefix"), &prefix, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("statsKey"), &statsKey, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 318, _1, _4);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 319, _1, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_libmemcached"), _0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_5);
@@ -131970,9 +132253,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) {
ZEPHIR_INIT_NVAR(_6);
ZVAL_STRING(_6, "gc", 1);
zephir_array_fast_append(_11, _6);
- ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 408, _5, _7, _8, _9, _10, _11);
+ ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _5, _7, _8, _9, _10, _11);
zephir_check_call_status();
- ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_libmemcached_ce, this_ptr, "__construct", &_12, 409, options);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_libmemcached_ce, this_ptr, "__construct", &_12, 411, options);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -132148,9 +132431,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Memcache, __construct) {
ZEPHIR_OBS_VAR(_3);
zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC);
zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 317, _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 320, _1, options);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 321, _1, options);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_4);
@@ -132189,9 +132472,9 @@ static PHP_METHOD(Phalcon_Session_Adapter_Memcache, __construct) {
ZEPHIR_INIT_NVAR(_5);
ZVAL_STRING(_5, "gc", 1);
zephir_array_fast_append(_10, _5);
- ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 408, _4, _6, _7, _8, _9, _10);
+ ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _4, _6, _7, _8, _9, _10);
zephir_check_call_status();
- ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_memcache_ce, this_ptr, "__construct", &_11, 409, options);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_memcache_ce, this_ptr, "__construct", &_11, 411, options);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -132283,6 +132566,223 @@ static PHP_METHOD(Phalcon_Session_Adapter_Memcache, gc) {
+#ifdef HAVE_CONFIG_H
+#endif
+
+#include
+
+#include
+#include
+#include
+
+
+
+ZEPHIR_INIT_CLASS(Phalcon_Session_Adapter_Redis) {
+
+ ZEPHIR_REGISTER_CLASS_EX(Phalcon\\Session\\Adapter, Redis, phalcon, session_adapter_redis, phalcon_session_adapter_ce, phalcon_session_adapter_redis_method_entry, 0);
+
+ zend_declare_property_null(phalcon_session_adapter_redis_ce, SL("_redis"), ZEND_ACC_PROTECTED TSRMLS_CC);
+
+ zend_declare_property_long(phalcon_session_adapter_redis_ce, SL("_lifetime"), 8600, ZEND_ACC_PROTECTED TSRMLS_CC);
+
+ zend_class_implements(phalcon_session_adapter_redis_ce TSRMLS_CC, 1, phalcon_session_adapterinterface_ce);
+ return SUCCESS;
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, getRedis) {
+
+
+ RETURN_MEMBER(this_ptr, "_redis");
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, getLifetime) {
+
+
+ RETURN_MEMBER(this_ptr, "_lifetime");
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, __construct) {
+
+ zephir_fcall_cache_entry *_11 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *options_param = NULL, *lifetime, *_0 = NULL, *_1, *_3, *_5 = NULL;
+ zval *options = NULL, *_2, *_4, *_6, *_7, *_8, *_9, *_10;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 0, 1, &options_param);
+
+ if (!options_param) {
+ ZEPHIR_INIT_VAR(options);
+ array_init(options);
+ } else {
+ zephir_get_arrval(options, options_param);
+ }
+
+
+ if (!(zephir_array_isset_string(options, SS("host")))) {
+ ZEPHIR_INIT_VAR(_0);
+ ZVAL_STRING(_0, "127.0.0.1", 1);
+ zephir_array_update_string(&options, SL("host"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("port")))) {
+ ZEPHIR_INIT_NVAR(_0);
+ ZVAL_LONG(_0, 6379);
+ zephir_array_update_string(&options, SL("port"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("persistent")))) {
+ zephir_array_update_string(&options, SL("persistent"), &ZEPHIR_GLOBAL(global_false), PH_COPY | PH_SEPARATE);
+ }
+ ZEPHIR_OBS_VAR(lifetime);
+ if (zephir_array_isset_string_fetch(&lifetime, options, SS("lifetime"), 0 TSRMLS_CC)) {
+ zephir_update_property_this(this_ptr, SL("_lifetime"), lifetime TSRMLS_CC);
+ }
+ ZEPHIR_INIT_NVAR(_0);
+ object_init_ex(_0, phalcon_cache_backend_redis_ce);
+ ZEPHIR_INIT_VAR(_1);
+ object_init_ex(_1, phalcon_cache_frontend_data_ce);
+ ZEPHIR_INIT_VAR(_2);
+ zephir_create_array(_2, 1, 0 TSRMLS_CC);
+ ZEPHIR_OBS_VAR(_3);
+ zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC);
+ zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 322, _1, options);
+ zephir_check_call_status();
+ zephir_update_property_this(this_ptr, SL("_redis"), _0 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_4);
+ zephir_create_array(_4, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_4, this_ptr);
+ ZEPHIR_INIT_VAR(_5);
+ ZVAL_STRING(_5, "open", 1);
+ zephir_array_fast_append(_4, _5);
+ ZEPHIR_INIT_VAR(_6);
+ zephir_create_array(_6, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_6, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "close", 1);
+ zephir_array_fast_append(_6, _5);
+ ZEPHIR_INIT_VAR(_7);
+ zephir_create_array(_7, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_7, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "read", 1);
+ zephir_array_fast_append(_7, _5);
+ ZEPHIR_INIT_VAR(_8);
+ zephir_create_array(_8, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_8, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "write", 1);
+ zephir_array_fast_append(_8, _5);
+ ZEPHIR_INIT_VAR(_9);
+ zephir_create_array(_9, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_9, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "destroy", 1);
+ zephir_array_fast_append(_9, _5);
+ ZEPHIR_INIT_VAR(_10);
+ zephir_create_array(_10, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_10, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "gc", 1);
+ zephir_array_fast_append(_10, _5);
+ ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _4, _6, _7, _8, _9, _10);
+ zephir_check_call_status();
+ ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_redis_ce, this_ptr, "__construct", &_11, 411, options);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, open) {
+
+
+ RETURN_BOOL(1);
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, close) {
+
+
+ RETURN_BOOL(1);
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, read) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *sessionId, *_0, *_1;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 0, &sessionId);
+
+
+
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ _1 = zephir_fetch_nproperty_this(this_ptr, SL("_lifetime"), PH_NOISY_CC);
+ ZEPHIR_RETURN_CALL_METHOD(_0, "get", NULL, 0, sessionId, _1);
+ zephir_check_call_status();
+ RETURN_MM();
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, write) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *sessionId, *data, *_0, *_1;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 2, 0, &sessionId, &data);
+
+
+
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ _1 = zephir_fetch_nproperty_this(this_ptr, SL("_lifetime"), PH_NOISY_CC);
+ ZEPHIR_CALL_METHOD(NULL, _0, "save", NULL, 0, sessionId, data, _1);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, destroy) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *sessionId = NULL, *_0;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 0, 1, &sessionId);
+
+ if (!sessionId) {
+ ZEPHIR_CPY_WRT(sessionId, ZEPHIR_GLOBAL(global_null));
+ } else {
+ ZEPHIR_SEPARATE_PARAM(sessionId);
+ }
+
+
+ if (Z_TYPE_P(sessionId) == IS_NULL) {
+ ZEPHIR_CALL_METHOD(&sessionId, this_ptr, "getid", NULL, 0);
+ zephir_check_call_status();
+ }
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ ZEPHIR_RETURN_CALL_METHOD(_0, "delete", NULL, 0, sessionId);
+ zephir_check_call_status();
+ RETURN_MM();
+
+}
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, gc) {
+
+
+ RETURN_BOOL(1);
+
+}
+
+
+
+
#ifdef HAVE_CONFIG_H
#endif
@@ -132432,7 +132932,7 @@ static PHP_METHOD(Phalcon_Tag_Select, selectField) {
ZEPHIR_GET_CONSTANT(_6, "PHP_EOL");
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SV(_7, "", _6);
- ZEPHIR_CALL_SELF(&_8, "_optionsfromresultset", &_9, 414, options, using, value, _7);
+ ZEPHIR_CALL_SELF(&_8, "_optionsfromresultset", &_9, 416, options, using, value, _7);
zephir_check_call_status();
zephir_concat_self(&code, _8 TSRMLS_CC);
} else {
@@ -132441,7 +132941,7 @@ static PHP_METHOD(Phalcon_Tag_Select, selectField) {
ZEPHIR_GET_CONSTANT(_6, "PHP_EOL");
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SV(_7, "", _6);
- ZEPHIR_CALL_SELF(&_8, "_optionsfromarray", &_10, 415, options, value, _7);
+ ZEPHIR_CALL_SELF(&_8, "_optionsfromarray", &_10, 417, options, value, _7);
zephir_check_call_status();
zephir_concat_self(&code, _8 TSRMLS_CC);
} else {
@@ -132579,12 +133079,12 @@ static PHP_METHOD(Phalcon_Tag_Select, _optionsFromArray) {
) {
ZEPHIR_GET_HMKEY(optionValue, _1, _0);
ZEPHIR_GET_HVALUE(optionText, _2);
- ZEPHIR_CALL_FUNCTION(&escaped, "htmlspecialchars", &_3, 180, optionValue);
+ ZEPHIR_CALL_FUNCTION(&escaped, "htmlspecialchars", &_3, 181, optionValue);
zephir_check_call_status();
if (Z_TYPE_P(optionText) == IS_ARRAY) {
ZEPHIR_INIT_NVAR(_4);
ZEPHIR_GET_CONSTANT(_4, "PHP_EOL");
- ZEPHIR_CALL_SELF(&_5, "_optionsfromarray", &_6, 415, optionText, value, closeOption);
+ ZEPHIR_CALL_SELF(&_5, "_optionsfromarray", &_6, 417, optionText, value, closeOption);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_7);
ZEPHIR_GET_CONSTANT(_7, "PHP_EOL");
@@ -132641,10 +133141,53 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter) {
ZEPHIR_REGISTER_CLASS(Phalcon\\Translate, Adapter, phalcon, translate_adapter, phalcon_translate_adapter_method_entry, ZEND_ACC_EXPLICIT_ABSTRACT_CLASS);
+ zend_declare_property_null(phalcon_translate_adapter_ce, SL("_interpolator"), ZEND_ACC_PROTECTED TSRMLS_CC);
+
return SUCCESS;
}
+static PHP_METHOD(Phalcon_Translate_Adapter, __construct) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *options_param = NULL, *interpolator = NULL;
+ zval *options = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 0, &options_param);
+
+ options = options_param;
+
+
+
+ ZEPHIR_OBS_VAR(interpolator);
+ if (!(zephir_array_isset_string_fetch(&interpolator, options, SS("interpolator"), 0 TSRMLS_CC))) {
+ ZEPHIR_INIT_NVAR(interpolator);
+ object_init_ex(interpolator, phalcon_translate_interpolator_associativearray_ce);
+ if (zephir_has_constructor(interpolator TSRMLS_CC)) {
+ ZEPHIR_CALL_METHOD(NULL, interpolator, "__construct", NULL, 0);
+ zephir_check_call_status();
+ }
+ }
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "setinterpolator", NULL, 0, interpolator);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Translate_Adapter, setInterpolator) {
+
+ zval *interpolator;
+
+ zephir_fetch_params(0, 1, 0, &interpolator);
+
+
+
+ zephir_update_property_this(this_ptr, SL("_interpolator"), interpolator TSRMLS_CC);
+ RETURN_THISW();
+
+}
+
static PHP_METHOD(Phalcon_Translate_Adapter, t) {
int ZEPHIR_LAST_CALL_STATUS;
@@ -132715,7 +133258,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter, offsetSet) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_translate_exception_ce, "Translate is an immutable ArrayAccess object", "phalcon/translate/adapter.zep", 64);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_translate_exception_ce, "Translate is an immutable ArrayAccess object", "phalcon/translate/adapter.zep", 86);
return;
}
@@ -132756,7 +133299,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter, offsetUnset) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_translate_exception_ce, "Translate is an immutable ArrayAccess object", "phalcon/translate/adapter.zep", 82);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_translate_exception_ce, "Translate is an immutable ArrayAccess object", "phalcon/translate/adapter.zep", 104);
return;
}
@@ -132793,9 +133336,8 @@ static PHP_METHOD(Phalcon_Translate_Adapter, offsetGet) {
static PHP_METHOD(Phalcon_Translate_Adapter, replacePlaceholders) {
- HashTable *_1;
- HashPosition _0;
- zval *translation_param = NULL, *placeholders = NULL, *key = NULL, *value = NULL, **_2, *_3 = NULL, *_4 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *translation_param = NULL, *placeholders = NULL, *_0;
zval *translation = NULL;
ZEPHIR_MM_GROW();
@@ -132817,24 +133359,10 @@ static PHP_METHOD(Phalcon_Translate_Adapter, replacePlaceholders) {
}
- if (Z_TYPE_P(placeholders) == IS_ARRAY) {
- if (zephir_fast_count_int(placeholders TSRMLS_CC)) {
- zephir_is_iterable(placeholders, &_1, &_0, 0, 0, "phalcon/translate/adapter.zep", 108);
- for (
- ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
- ; zephir_hash_move_forward_ex(_1, &_0)
- ) {
- ZEPHIR_GET_HMKEY(key, _1, _0);
- ZEPHIR_GET_HVALUE(value, _2);
- ZEPHIR_INIT_NVAR(_3);
- ZEPHIR_INIT_LNVAR(_4);
- ZEPHIR_CONCAT_SVS(_4, "%", key, "%");
- zephir_fast_str_replace(&_3, _4, value, translation TSRMLS_CC);
- zephir_get_strval(translation, _3);
- }
- }
- }
- RETURN_CTOR(translation);
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_interpolator"), PH_NOISY_CC);
+ ZEPHIR_RETURN_CALL_METHOD(_0, "replaceplaceholders", NULL, 0, translation, placeholders);
+ zephir_check_call_status();
+ RETURN_MM();
}
@@ -132889,6 +133417,28 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Exception) {
+#ifdef HAVE_CONFIG_H
+#endif
+
+#include
+
+#include
+
+
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_InterpolatorInterface) {
+
+ ZEPHIR_REGISTER_INTERFACE(Phalcon\\Translate, InterpolatorInterface, phalcon, translate_interpolatorinterface, phalcon_translate_interpolatorinterface_method_entry);
+
+ return SUCCESS;
+
+}
+
+ZEPHIR_DOC_METHOD(Phalcon_Translate_InterpolatorInterface, replacePlaceholders);
+
+
+
+
#ifdef HAVE_CONFIG_H
#endif
@@ -132916,11 +133466,10 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter_Csv) {
static PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct) {
- zend_bool _12;
- zephir_fcall_cache_entry *_9 = NULL;
int ZEPHIR_LAST_CALL_STATUS;
- zval *options_param = NULL, *data = NULL, *file = NULL, *_0, *_2, _3 = zval_used_for_init, *_4 = NULL, *_5, *_6, *_7, *_8, *_10, _11 = zval_used_for_init, *_13, *_14 = NULL;
- zval *options = NULL, *_1;
+ zephir_fcall_cache_entry *_0 = NULL;
+ zval *options_param = NULL, *_1, *_2, *_3, *_4;
+ zval *options = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 0, &options_param);
@@ -132929,64 +133478,80 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct) {
+ ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_csv_ce, this_ptr, "__construct", &_0, 426, options);
+ zephir_check_call_status();
if (!(zephir_array_isset_string(options, SS("content")))) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter 'content' is required", "phalcon/translate/adapter/csv.zep", 43);
return;
}
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_INIT_VAR(_1);
- zephir_create_array(_1, 3, 0 TSRMLS_CC);
- add_assoc_stringl_ex(_1, SS("delimiter"), SL(";"), 1);
- add_assoc_long_ex(_1, SS("length"), 0);
- add_assoc_stringl_ex(_1, SS("enclosure"), SL("\""), 1);
- zephir_fast_array_merge(_0, &(_1), &(options) TSRMLS_CC);
- ZEPHIR_CPY_WRT(options, _0);
- zephir_array_fetch_string(&_2, options, SL("content"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 52 TSRMLS_CC);
- ZEPHIR_SINIT_VAR(_3);
- ZVAL_STRING(&_3, "rb", 0);
- ZEPHIR_CALL_FUNCTION(&file, "fopen", NULL, 291, _2, &_3);
+ zephir_array_fetch_string(&_1, options, SL("content"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 46 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_2);
+ ZVAL_LONG(_2, 0);
+ ZEPHIR_INIT_VAR(_3);
+ ZVAL_STRING(_3, ";", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_INIT_VAR(_4);
+ ZVAL_STRING(_4, "\"", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "_load", NULL, 427, _1, _2, _3, _4);
+ zephir_check_temp_parameter(_3);
+ zephir_check_temp_parameter(_4);
zephir_check_call_status();
- if (Z_TYPE_P(file) != IS_RESOURCE) {
- ZEPHIR_INIT_VAR(_4);
- object_init_ex(_4, phalcon_translate_exception_ce);
- zephir_array_fetch_string(&_5, options, SL("content"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 55 TSRMLS_CC);
- ZEPHIR_INIT_VAR(_6);
- ZEPHIR_CONCAT_SVS(_6, "Error opening translation file '", _5, "'");
- ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 9, _6);
+ ZEPHIR_MM_RESTORE();
+
+}
+
+static PHP_METHOD(Phalcon_Translate_Adapter_Csv, _load) {
+
+ zend_bool _6;
+ zephir_fcall_cache_entry *_3 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *file, *length, *delimiter, *enclosure, *data = NULL, *fileHandler = NULL, _0 = zval_used_for_init, *_1 = NULL, *_2, *_4, _5 = zval_used_for_init, *_7, *_8 = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 4, 0, &file, &length, &delimiter, &enclosure);
+
+
+
+ ZEPHIR_SINIT_VAR(_0);
+ ZVAL_STRING(&_0, "rb", 0);
+ ZEPHIR_CALL_FUNCTION(&fileHandler, "fopen", NULL, 292, file, &_0);
+ zephir_check_call_status();
+ if (Z_TYPE_P(fileHandler) != IS_RESOURCE) {
+ ZEPHIR_INIT_VAR(_1);
+ object_init_ex(_1, phalcon_translate_exception_ce);
+ ZEPHIR_INIT_VAR(_2);
+ ZEPHIR_CONCAT_SVS(_2, "Error opening translation file '", file, "'");
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_4, "phalcon/translate/adapter/csv.zep", 55 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/translate/adapter/csv.zep", 64 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
while (1) {
- zephir_array_fetch_string(&_5, options, SL("length"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 60 TSRMLS_CC);
- zephir_array_fetch_string(&_7, options, SL("delimiter"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 60 TSRMLS_CC);
- zephir_array_fetch_string(&_8, options, SL("enclosure"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 60 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&data, "fgetcsv", &_9, 424, file, _5, _7, _8);
+ ZEPHIR_CALL_FUNCTION(&data, "fgetcsv", &_3, 428, fileHandler, length, delimiter, enclosure);
zephir_check_call_status();
if (ZEPHIR_IS_FALSE_IDENTICAL(data)) {
break;
}
- zephir_array_fetch_long(&_10, data, 0, PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 65 TSRMLS_CC);
- ZEPHIR_SINIT_NVAR(_3);
- ZVAL_LONG(&_3, 0);
- ZEPHIR_SINIT_NVAR(_11);
- ZVAL_LONG(&_11, 1);
- ZEPHIR_INIT_NVAR(_4);
- zephir_substr(_4, _10, 0 , 1 , 0);
- _12 = ZEPHIR_IS_STRING_IDENTICAL(_4, "#");
- if (!(_12)) {
- _12 = !(zephir_array_isset_long(data, 1));
+ zephir_array_fetch_long(&_4, data, 0, PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 74 TSRMLS_CC);
+ ZEPHIR_SINIT_NVAR(_0);
+ ZVAL_LONG(&_0, 0);
+ ZEPHIR_SINIT_NVAR(_5);
+ ZVAL_LONG(&_5, 1);
+ ZEPHIR_INIT_NVAR(_1);
+ zephir_substr(_1, _4, 0 , 1 , 0);
+ _6 = ZEPHIR_IS_STRING_IDENTICAL(_1, "#");
+ if (!(_6)) {
+ _6 = !(zephir_array_isset_long(data, 1));
}
- if (_12) {
+ if (_6) {
continue;
}
- zephir_array_fetch_long(&_13, data, 1, PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 69 TSRMLS_CC);
- ZEPHIR_OBS_NVAR(_14);
- zephir_array_fetch_long(&_14, data, 0, PH_NOISY, "phalcon/translate/adapter/csv.zep", 69 TSRMLS_CC);
- zephir_update_property_array(this_ptr, SL("_translate"), _14, _13 TSRMLS_CC);
+ zephir_array_fetch_long(&_7, data, 1, PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 78 TSRMLS_CC);
+ ZEPHIR_OBS_NVAR(_8);
+ zephir_array_fetch_long(&_8, data, 0, PH_NOISY, "phalcon/translate/adapter/csv.zep", 78 TSRMLS_CC);
+ zephir_update_property_array(this_ptr, SL("_translate"), _8, _7 TSRMLS_CC);
}
- zephir_fclose(file TSRMLS_CC);
+ zephir_fclose(fileHandler TSRMLS_CC);
ZEPHIR_MM_RESTORE();
}
@@ -133109,6 +133674,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter_Gettext) {
static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, __construct) {
int ZEPHIR_LAST_CALL_STATUS;
+ zephir_fcall_cache_entry *_0 = NULL;
zval *options_param = NULL;
zval *options = NULL;
@@ -133119,6 +133685,8 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, __construct) {
+ ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_gettext_ce, this_ptr, "__construct", &_0, 426, options);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, this_ptr, "prepareoptions", NULL, 0, options);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -133150,22 +133718,22 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, query) {
}
- ZEPHIR_CALL_FUNCTION(&_0, "func_num_args", NULL, 419);
+ ZEPHIR_CALL_FUNCTION(&_0, "func_num_args", NULL, 421);
zephir_check_call_status();
if (ZEPHIR_GT_LONG(_0, 2)) {
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, 2);
- ZEPHIR_CALL_FUNCTION(&domain, "func_get_arg", NULL, 418, &_1);
+ ZEPHIR_CALL_FUNCTION(&domain, "func_get_arg", NULL, 420, &_1);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(domain);
ZVAL_NULL(domain);
}
if (!(zephir_is_true(domain))) {
- ZEPHIR_CALL_FUNCTION(&translation, "gettext", NULL, 425, index);
+ ZEPHIR_CALL_FUNCTION(&translation, "gettext", NULL, 429, index);
zephir_check_call_status();
} else {
- ZEPHIR_CALL_FUNCTION(&translation, "dgettext", NULL, 426, domain, index);
+ ZEPHIR_CALL_FUNCTION(&translation, "dgettext", NULL, 430, domain, index);
zephir_check_call_status();
}
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "replaceplaceholders", NULL, 0, translation, placeholders);
@@ -133263,12 +133831,12 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, nquery) {
if (!(domain && Z_STRLEN_P(domain))) {
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, count);
- ZEPHIR_CALL_FUNCTION(&translation, "ngettext", NULL, 427, msgid1, msgid2, &_0);
+ ZEPHIR_CALL_FUNCTION(&translation, "ngettext", NULL, 431, msgid1, msgid2, &_0);
zephir_check_call_status();
} else {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, count);
- ZEPHIR_CALL_FUNCTION(&translation, "dngettext", NULL, 428, domain, msgid1, msgid2, &_0);
+ ZEPHIR_CALL_FUNCTION(&translation, "dngettext", NULL, 432, domain, msgid1, msgid2, &_0);
zephir_check_call_status();
}
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "replaceplaceholders", NULL, 0, translation, placeholders);
@@ -133299,7 +133867,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setDomain) {
}
- ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 429, domain);
+ ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 433, domain);
zephir_check_call_status();
RETURN_MM();
@@ -133314,7 +133882,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, resetDomain) {
ZEPHIR_CALL_METHOD(&_0, this_ptr, "getdefaultdomain", NULL, 0);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 429, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 433, _0);
zephir_check_call_status();
RETURN_MM();
@@ -133369,21 +133937,21 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setDirectory) {
zephir_update_property_this(this_ptr, SL("_directory"), directory TSRMLS_CC);
if (Z_TYPE_P(directory) == IS_ARRAY) {
if (zephir_fast_count_int(directory TSRMLS_CC)) {
- zephir_is_iterable(directory, &_1, &_0, 0, 0, "phalcon/translate/adapter/gettext.zep", 180);
+ zephir_is_iterable(directory, &_1, &_0, 0, 0, "phalcon/translate/adapter/gettext.zep", 181);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
) {
ZEPHIR_GET_HMKEY(key, _1, _0);
ZEPHIR_GET_HVALUE(value, _2);
- ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 430, key, value);
+ ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 434, key, value);
zephir_check_call_status();
}
}
} else {
ZEPHIR_CALL_METHOD(&_4, this_ptr, "getdefaultdomain", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 430, _4, directory);
+ ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 434, _4, directory);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -133426,7 +133994,7 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setLocale) {
ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CALL_FUNCTION(&_1, "func_get_args", NULL, 165);
+ ZEPHIR_CALL_FUNCTION(&_1, "func_get_args", NULL, 166);
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_2);
ZVAL_STRING(&_2, "setlocale", 0);
@@ -133439,12 +134007,12 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setLocale) {
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_locale"), PH_NOISY_CC);
ZEPHIR_INIT_VAR(_4);
ZEPHIR_CONCAT_SV(_4, "LC_ALL=", _3);
- ZEPHIR_CALL_FUNCTION(NULL, "putenv", NULL, 431, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "putenv", NULL, 435, _4);
zephir_check_call_status();
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_locale"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_6);
ZVAL_LONG(&_6, 0);
- ZEPHIR_CALL_FUNCTION(NULL, "setlocale", NULL, 413, &_6, _5);
+ ZEPHIR_CALL_FUNCTION(NULL, "setlocale", NULL, 415, &_6, _5);
zephir_check_call_status();
RETURN_MM_MEMBER(this_ptr, "_locale");
@@ -133478,11 +134046,11 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, prepareOptions) {
if (!(zephir_array_isset_string(options, SS("locale")))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter \"locale\" is required", "phalcon/translate/adapter/gettext.zep", 230);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter \"locale\" is required", "phalcon/translate/adapter/gettext.zep", 231);
return;
}
if (!(zephir_array_isset_string(options, SS("directory")))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter \"directory\" is required", "phalcon/translate/adapter/gettext.zep", 234);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter \"directory\" is required", "phalcon/translate/adapter/gettext.zep", 235);
return;
}
ZEPHIR_INIT_VAR(_0);
@@ -133490,17 +134058,17 @@ static PHP_METHOD(Phalcon_Translate_Adapter_Gettext, prepareOptions) {
zephir_check_call_status();
zephir_fast_array_merge(_0, &(_1), &(options) TSRMLS_CC);
ZEPHIR_CPY_WRT(options, _0);
- zephir_array_fetch_string(&_2, options, SL("category"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 239 TSRMLS_CC);
- zephir_array_fetch_string(&_3, options, SL("locale"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 239 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, options, SL("category"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 240 TSRMLS_CC);
+ zephir_array_fetch_string(&_3, options, SL("locale"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 240 TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "setlocale", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_array_fetch_string(&_4, options, SL("defaultDomain"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 240 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, options, SL("defaultDomain"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 241 TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "setdefaultdomain", NULL, 0, _4);
zephir_check_call_status();
- zephir_array_fetch_string(&_5, options, SL("directory"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 241 TSRMLS_CC);
+ zephir_array_fetch_string(&_5, options, SL("directory"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 242 TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "setdirectory", NULL, 0, _5);
zephir_check_call_status();
- zephir_array_fetch_string(&_6, options, SL("defaultDomain"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 242 TSRMLS_CC);
+ zephir_array_fetch_string(&_6, options, SL("defaultDomain"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 243 TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "setdomain", NULL, 0, _6);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -133545,6 +134113,8 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter_NativeArray) {
static PHP_METHOD(Phalcon_Translate_Adapter_NativeArray, __construct) {
+ int ZEPHIR_LAST_CALL_STATUS;
+ zephir_fcall_cache_entry *_0 = NULL;
zval *options_param = NULL, *data;
zval *options = NULL;
@@ -133555,13 +134125,15 @@ static PHP_METHOD(Phalcon_Translate_Adapter_NativeArray, __construct) {
+ ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_nativearray_ce, this_ptr, "__construct", &_0, 426, options);
+ zephir_check_call_status();
ZEPHIR_OBS_VAR(data);
if (!(zephir_array_isset_string_fetch(&data, options, SS("content"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Translation content was not provided", "phalcon/translate/adapter/nativearray.zep", 44);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Translation content was not provided", "phalcon/translate/adapter/nativearray.zep", 46);
return;
}
if (Z_TYPE_P(data) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Translation data must be an array", "phalcon/translate/adapter/nativearray.zep", 48);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Translation data must be an array", "phalcon/translate/adapter/nativearray.zep", 50);
return;
}
zephir_update_property_this(this_ptr, SL("_translate"), data TSRMLS_CC);
@@ -133634,6 +134206,147 @@ static PHP_METHOD(Phalcon_Translate_Adapter_NativeArray, exists) {
+#ifdef HAVE_CONFIG_H
+#endif
+
+#include
+
+#include
+#include
+#include
+
+
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_Interpolator_AssociativeArray) {
+
+ ZEPHIR_REGISTER_CLASS(Phalcon\\Translate\\Interpolator, AssociativeArray, phalcon, translate_interpolator_associativearray, phalcon_translate_interpolator_associativearray_method_entry, 0);
+
+ zend_class_implements(phalcon_translate_interpolator_associativearray_ce TSRMLS_CC, 1, phalcon_translate_interpolatorinterface_ce);
+ return SUCCESS;
+
+}
+
+static PHP_METHOD(Phalcon_Translate_Interpolator_AssociativeArray, replacePlaceholders) {
+
+ HashTable *_2;
+ HashPosition _1;
+ zend_bool _0;
+ zval *translation_param = NULL, *placeholders = NULL, *key = NULL, *value = NULL, **_3, *_4 = NULL, *_5 = NULL;
+ zval *translation = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 1, &translation_param, &placeholders);
+
+ if (unlikely(Z_TYPE_P(translation_param) != IS_STRING && Z_TYPE_P(translation_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'translation' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(translation_param) == IS_STRING)) {
+ zephir_get_strval(translation, translation_param);
+ } else {
+ ZEPHIR_INIT_VAR(translation);
+ ZVAL_EMPTY_STRING(translation);
+ }
+ if (!placeholders) {
+ placeholders = ZEPHIR_GLOBAL(global_null);
+ }
+
+
+ _0 = Z_TYPE_P(placeholders) == IS_ARRAY;
+ if (_0) {
+ _0 = (zephir_fast_count_int(placeholders TSRMLS_CC)) ? 1 : 0;
+ }
+ if (_0) {
+ zephir_is_iterable(placeholders, &_2, &_1, 0, 0, "phalcon/translate/interpolator/associativearray.zep", 38);
+ for (
+ ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
+ ; zephir_hash_move_forward_ex(_2, &_1)
+ ) {
+ ZEPHIR_GET_HMKEY(key, _2, _1);
+ ZEPHIR_GET_HVALUE(value, _3);
+ ZEPHIR_INIT_NVAR(_4);
+ ZEPHIR_INIT_LNVAR(_5);
+ ZEPHIR_CONCAT_SVS(_5, "%", key, "%");
+ zephir_fast_str_replace(&_4, _5, value, translation TSRMLS_CC);
+ zephir_get_strval(translation, _4);
+ }
+ }
+ RETURN_CTOR(translation);
+
+}
+
+
+
+
+#ifdef HAVE_CONFIG_H
+#endif
+
+#include
+
+#include
+#include
+#include
+
+
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_Interpolator_IndexedArray) {
+
+ ZEPHIR_REGISTER_CLASS(Phalcon\\Translate\\Interpolator, IndexedArray, phalcon, translate_interpolator_indexedarray, phalcon_translate_interpolator_indexedarray_method_entry, 0);
+
+ zend_class_implements(phalcon_translate_interpolator_indexedarray_ce TSRMLS_CC, 1, phalcon_translate_interpolatorinterface_ce);
+ return SUCCESS;
+
+}
+
+static PHP_METHOD(Phalcon_Translate_Interpolator_IndexedArray, replacePlaceholders) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zend_bool _0;
+ zval *translation_param = NULL, *placeholders = NULL, _1;
+ zval *translation = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 1, &translation_param, &placeholders);
+
+ if (unlikely(Z_TYPE_P(translation_param) != IS_STRING && Z_TYPE_P(translation_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'translation' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(translation_param) == IS_STRING)) {
+ zephir_get_strval(translation, translation_param);
+ } else {
+ ZEPHIR_INIT_VAR(translation);
+ ZVAL_EMPTY_STRING(translation);
+ }
+ if (!placeholders) {
+ placeholders = ZEPHIR_GLOBAL(global_null);
+ }
+
+
+ _0 = Z_TYPE_P(placeholders) == IS_ARRAY;
+ if (_0) {
+ _0 = (zephir_fast_count_int(placeholders TSRMLS_CC)) ? 1 : 0;
+ }
+ if (_0) {
+ Z_SET_ISREF_P(placeholders);
+ ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 386, placeholders, translation);
+ Z_UNSET_ISREF_P(placeholders);
+ zephir_check_call_status();
+ ZEPHIR_SINIT_VAR(_1);
+ ZVAL_STRING(&_1, "sprintf", 0);
+ ZEPHIR_CALL_USER_FUNC_ARRAY(return_value, &_1, placeholders);
+ zephir_check_call_status();
+ RETURN_MM();
+ }
+ RETURN_CTOR(translation);
+
+}
+
+
+
+
#ifdef HAVE_CONFIG_H
#endif
@@ -133839,7 +134552,7 @@ static PHP_METHOD(Phalcon_Validation_Message, __set_state) {
zephir_array_fetch_string(&_0, message, SL("_message"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC);
zephir_array_fetch_string(&_1, message, SL("_field"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC);
zephir_array_fetch_string(&_2, message, SL("_type"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 432, _0, _1, _2);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 436, _0, _1, _2);
zephir_check_call_status();
RETURN_MM();
@@ -133925,7 +134638,7 @@ static PHP_METHOD(Phalcon_Validation_Validator, __construct) {
_0 = Z_TYPE_P(options) != IS_NULL;
}
if (_0) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_validation_exception_ce, "Options must be an array", "phalcon/validation/validator.zep", 39);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_validation_exception_ce, "Options must be an array", "phalcon/validation/validator.zep", 40);
return;
} else {
zephir_update_property_this(this_ptr, SL("_options"), options TSRMLS_CC);
@@ -134453,7 +135166,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alnum, validate) {
if (_2) {
RETURN_MM_BOOL(1);
}
- ZEPHIR_CALL_FUNCTION(&_3, "ctype_alnum", NULL, 433, value);
+ ZEPHIR_CALL_FUNCTION(&_3, "ctype_alnum", NULL, 437, value);
zephir_check_call_status();
if (!(zephir_is_true(_3))) {
ZEPHIR_INIT_NVAR(_1);
@@ -134486,7 +135199,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alnum, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZVAL_STRING(_5, "Alnum", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _4, field, _5);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5);
zephir_check_temp_parameter(_5);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -134556,7 +135269,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alpha, validate) {
if (_2) {
RETURN_MM_BOOL(1);
}
- ZEPHIR_CALL_FUNCTION(&_3, "ctype_alpha", NULL, 434, value);
+ ZEPHIR_CALL_FUNCTION(&_3, "ctype_alpha", NULL, 438, value);
zephir_check_call_status();
if (!(zephir_is_true(_3))) {
ZEPHIR_INIT_NVAR(_1);
@@ -134589,7 +135302,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Alpha, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZVAL_STRING(_5, "Alpha", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _4, field, _5);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5);
zephir_check_temp_parameter(_5);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -134706,7 +135419,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Between, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZVAL_STRING(_5, "Between", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 432, _4, field, _5);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _4, field, _5);
zephir_check_temp_parameter(_5);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -134770,7 +135483,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, validate) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&valueWith, validation, "getvalue", NULL, 0, fieldWith);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "compare", NULL, 435, value, valueWith);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "compare", NULL, 439, value, valueWith);
zephir_check_call_status();
if (!(zephir_is_true(_1))) {
ZEPHIR_INIT_NVAR(_0);
@@ -134813,7 +135526,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_3);
ZVAL_STRING(_3, "Confirmation", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 432, _2, field, _3);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _2, field, _3);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -134852,12 +135565,12 @@ static PHP_METHOD(Phalcon_Validation_Validator_Confirmation, compare) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_STRING(&_3, "utf-8", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "mb_strtolower", &_5, 193, a, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "mb_strtolower", &_5, 194, a, &_3);
zephir_check_call_status();
zephir_get_strval(a, _4);
ZEPHIR_SINIT_NVAR(_3);
ZVAL_STRING(&_3, "utf-8", 0);
- ZEPHIR_CALL_FUNCTION(&_6, "mb_strtolower", &_5, 193, b, &_3);
+ ZEPHIR_CALL_FUNCTION(&_6, "mb_strtolower", &_5, 194, b, &_3);
zephir_check_call_status();
zephir_get_strval(b, _6);
}
@@ -134924,7 +135637,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Digit, validate) {
if (_2) {
RETURN_MM_BOOL(1);
}
- ZEPHIR_CALL_FUNCTION(&_3, "ctype_digit", NULL, 436, value);
+ ZEPHIR_CALL_FUNCTION(&_3, "ctype_digit", NULL, 440, value);
zephir_check_call_status();
if (!(zephir_is_true(_3))) {
ZEPHIR_INIT_NVAR(_1);
@@ -134957,7 +135670,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Digit, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZVAL_STRING(_5, "Digit", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _4, field, _5);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5);
zephir_check_temp_parameter(_5);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -135029,7 +135742,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Email, validate) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 274);
- ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 190, value, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_1);
@@ -135062,7 +135775,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Email, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_6);
ZVAL_STRING(_6, "Email", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _5, field, _6);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6);
zephir_check_temp_parameter(_6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -135138,7 +135851,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_ExclusionIn, validate) {
zephir_check_temp_parameter(_1);
zephir_check_call_status();
if (Z_TYPE_P(domain) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'domain' must be an array", "phalcon/validation/validator/exclusionin.zep", 59);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'domain' must be an array", "phalcon/validation/validator/exclusionin.zep", 62);
return;
}
if (zephir_fast_in_array(value, domain TSRMLS_CC)) {
@@ -135175,7 +135888,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_ExclusionIn, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_4);
ZVAL_STRING(_4, "ExclusionIn", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _3, field, _4);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _3, field, _4);
zephir_check_temp_parameter(_4);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -135246,7 +135959,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
ZEPHIR_CALL_METHOD(&label, validation, "getlabel", NULL, 0, field);
zephir_check_call_status();
}
- zephir_array_fetch_string(&_1, _SERVER, SL("REQUEST_METHOD"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 61 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, _SERVER, SL("REQUEST_METHOD"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 62 TSRMLS_CC);
_2 = ZEPHIR_IS_STRING(_1, "POST");
if (_2) {
_2 = ZEPHIR_IS_EMPTY(_POST);
@@ -135257,14 +135970,14 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
}
_4 = _3;
if (_4) {
- zephir_array_fetch_string(&_5, _SERVER, SL("CONTENT_LENGTH"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 61 TSRMLS_CC);
+ zephir_array_fetch_string(&_5, _SERVER, SL("CONTENT_LENGTH"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 62 TSRMLS_CC);
_4 = ZEPHIR_GT_LONG(_5, 0);
}
_6 = _4;
if (!(_6)) {
_7 = zephir_array_isset_string(value, SS("error"));
if (_7) {
- zephir_array_fetch_string(&_8, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 61 TSRMLS_CC);
+ zephir_array_fetch_string(&_8, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 62 TSRMLS_CC);
_7 = ZEPHIR_IS_LONG_IDENTICAL(_8, 1);
}
_6 = _7;
@@ -135291,7 +136004,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_11);
ZVAL_STRING(_11, "FileIniSize", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_12, 432, _9, field, _11);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_12, 436, _9, field, _11);
zephir_check_temp_parameter(_11);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -135309,7 +136022,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
if (!(_14)) {
_15 = zephir_array_isset_string(value, SS("error"));
if (_15) {
- zephir_array_fetch_string(&_16, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 73 TSRMLS_CC);
+ zephir_array_fetch_string(&_16, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 75 TSRMLS_CC);
_15 = ZEPHIR_IS_LONG_IDENTICAL(_16, 4);
}
_14 = _15;
@@ -135325,13 +136038,13 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
}
_18 = _17;
if (!(_18)) {
- zephir_array_fetch_string(&_19, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 77 TSRMLS_CC);
+ zephir_array_fetch_string(&_19, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 79 TSRMLS_CC);
_18 = !ZEPHIR_IS_LONG_IDENTICAL(_19, 0);
}
_20 = _18;
if (!(_20)) {
- zephir_array_fetch_string(&_21, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 77 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_9, "is_uploaded_file", NULL, 231, _21);
+ zephir_array_fetch_string(&_21, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 79 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&_9, "is_uploaded_file", NULL, 232, _21);
zephir_check_call_status();
_20 = !zephir_is_true(_9);
}
@@ -135357,7 +136070,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_23);
ZVAL_STRING(_23, "FileEmpty", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 432, _22, field, _23);
+ ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _22, field, _23);
zephir_check_temp_parameter(_23);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11);
@@ -135394,7 +136107,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_23);
ZVAL_STRING(_23, "FileValid", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 432, _9, field, _23);
+ ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _9, field, _23);
zephir_check_temp_parameter(_23);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11);
@@ -135437,22 +136150,22 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_preg_match(_11, _27, maxSize, matches, 0, 0 , 0 TSRMLS_CC);
if (zephir_array_isset_long(matches, 2)) {
ZEPHIR_OBS_NVAR(unit);
- zephir_array_fetch_long(&unit, matches, 2, PH_NOISY, "phalcon/validation/validator/file.zep", 110 TSRMLS_CC);
+ zephir_array_fetch_long(&unit, matches, 2, PH_NOISY, "phalcon/validation/validator/file.zep", 115 TSRMLS_CC);
}
- zephir_array_fetch_long(&_28, matches, 1, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 113 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 310, _28);
+ zephir_array_fetch_long(&_28, matches, 1, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 118 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 311, _28);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_30);
- zephir_array_fetch(&_31, byteUnits, unit, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 113 TSRMLS_CC);
+ zephir_array_fetch(&_31, byteUnits, unit, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 118 TSRMLS_CC);
ZEPHIR_SINIT_VAR(_32);
ZVAL_LONG(&_32, 2);
zephir_pow_function(_30, &_32, _31);
ZEPHIR_INIT_VAR(bytes);
mul_function(bytes, _22, _30 TSRMLS_CC);
- zephir_array_fetch_string(&_33, value, SL("size"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 115 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 310, _33);
+ zephir_array_fetch_string(&_33, value, SL("size"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 120 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 311, _33);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_34, "floatval", &_29, 310, bytes);
+ ZEPHIR_CALL_FUNCTION(&_34, "floatval", &_29, 311, bytes);
zephir_check_call_status();
if (ZEPHIR_GT(_22, _34)) {
ZEPHIR_INIT_NVAR(_30);
@@ -135477,7 +136190,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_36);
ZVAL_STRING(_36, "FileSize", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _30, "__construct", &_12, 432, _35, field, _36);
+ ZEPHIR_CALL_METHOD(NULL, _30, "__construct", &_12, 436, _35, field, _36);
zephir_check_temp_parameter(_36);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _30);
@@ -135497,22 +136210,22 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_temp_parameter(_11);
zephir_check_call_status();
if (Z_TYPE_P(types) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'allowedTypes' must be an array", "phalcon/validation/validator/file.zep", 132);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'allowedTypes' must be an array", "phalcon/validation/validator/file.zep", 138);
return;
}
if ((zephir_function_exists_ex(SS("finfo_open") TSRMLS_CC) == SUCCESS)) {
ZEPHIR_SINIT_NVAR(_32);
ZVAL_LONG(&_32, 16);
- ZEPHIR_CALL_FUNCTION(&tmp, "finfo_open", NULL, 228, &_32);
+ ZEPHIR_CALL_FUNCTION(&tmp, "finfo_open", NULL, 229, &_32);
zephir_check_call_status();
- zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 137 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 229, tmp, _28);
+ zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 143 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 230, tmp, _28);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 230, tmp);
+ ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 231, tmp);
zephir_check_call_status();
} else {
ZEPHIR_OBS_NVAR(mime);
- zephir_array_fetch_string(&mime, value, SL("type"), PH_NOISY, "phalcon/validation/validator/file.zep", 141 TSRMLS_CC);
+ zephir_array_fetch_string(&mime, value, SL("type"), PH_NOISY, "phalcon/validation/validator/file.zep", 147 TSRMLS_CC);
}
if (!(zephir_fast_in_array(mime, types TSRMLS_CC))) {
ZEPHIR_INIT_NVAR(_11);
@@ -135539,7 +136252,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_23);
ZVAL_STRING(_23, "FileType", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 432, _22, field, _23);
+ ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _22, field, _23);
zephir_check_temp_parameter(_23);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11);
@@ -135562,13 +136275,13 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
_37 = zephir_is_true(_22);
}
if (_37) {
- zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 158 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&tmp, "getimagesize", NULL, 248, _28);
+ zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 164 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&tmp, "getimagesize", NULL, 249, _28);
zephir_check_call_status();
ZEPHIR_OBS_VAR(width);
- zephir_array_fetch_long(&width, tmp, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 159 TSRMLS_CC);
+ zephir_array_fetch_long(&width, tmp, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 165 TSRMLS_CC);
ZEPHIR_OBS_VAR(height);
- zephir_array_fetch_long(&height, tmp, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 160 TSRMLS_CC);
+ zephir_array_fetch_long(&height, tmp, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 166 TSRMLS_CC);
ZEPHIR_INIT_NVAR(_11);
ZVAL_STRING(_11, "minResolution", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_CALL_METHOD(&_34, this_ptr, "issetoption", NULL, 0, _11);
@@ -135583,9 +136296,9 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
ZEPHIR_INIT_VAR(minResolution);
zephir_fast_explode_str(minResolution, SL("x"), _35, LONG_MAX TSRMLS_CC);
ZEPHIR_OBS_VAR(minWidth);
- zephir_array_fetch_long(&minWidth, minResolution, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 164 TSRMLS_CC);
+ zephir_array_fetch_long(&minWidth, minResolution, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 170 TSRMLS_CC);
ZEPHIR_OBS_VAR(minHeight);
- zephir_array_fetch_long(&minHeight, minResolution, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 165 TSRMLS_CC);
+ zephir_array_fetch_long(&minHeight, minResolution, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 171 TSRMLS_CC);
} else {
ZEPHIR_INIT_NVAR(minWidth);
ZVAL_LONG(minWidth, 1);
@@ -135624,7 +136337,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_23);
ZVAL_STRING(_23, "FileMinResolution", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 432, _35, field, _23);
+ ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _35, field, _23);
zephir_check_temp_parameter(_23);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11);
@@ -135645,9 +136358,9 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
ZEPHIR_INIT_VAR(maxResolution);
zephir_fast_explode_str(maxResolution, SL("x"), _39, LONG_MAX TSRMLS_CC);
ZEPHIR_OBS_VAR(maxWidth);
- zephir_array_fetch_long(&maxWidth, maxResolution, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 186 TSRMLS_CC);
+ zephir_array_fetch_long(&maxWidth, maxResolution, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 192 TSRMLS_CC);
ZEPHIR_OBS_VAR(maxHeight);
- zephir_array_fetch_long(&maxHeight, maxResolution, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 187 TSRMLS_CC);
+ zephir_array_fetch_long(&maxHeight, maxResolution, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 193 TSRMLS_CC);
_40 = ZEPHIR_GT(width, maxWidth);
if (!(_40)) {
_40 = ZEPHIR_GT(height, maxHeight);
@@ -135680,7 +136393,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_26);
ZVAL_STRING(_26, "FileMaxResolution", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _23, "__construct", &_12, 432, _41, field, _26);
+ ZEPHIR_CALL_METHOD(NULL, _23, "__construct", &_12, 436, _41, field, _26);
zephir_check_temp_parameter(_26);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _23);
@@ -135718,8 +136431,9 @@ ZEPHIR_INIT_CLASS(Phalcon_Validation_Validator_Identical) {
static PHP_METHOD(Phalcon_Validation_Validator_Identical, validate) {
int ZEPHIR_LAST_CALL_STATUS;
+ zend_bool valid;
zval *field = NULL;
- zval *validation, *field_param = NULL, *message = NULL, *label = NULL, *replacePairs, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4;
+ zval *validation, *field_param = NULL, *message = NULL, *label = NULL, *replacePairs, *value = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 0, &validation, &field_param);
@@ -135737,48 +136451,70 @@ static PHP_METHOD(Phalcon_Validation_Validator_Identical, validate) {
}
- ZEPHIR_CALL_METHOD(&_0, validation, "getvalue", NULL, 0, field);
+ ZEPHIR_CALL_METHOD(&value, validation, "getvalue", NULL, 0, field);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_2);
- ZVAL_STRING(_2, "accepted", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "getoption", NULL, 0, _2);
- zephir_check_temp_parameter(_2);
+ ZEPHIR_INIT_VAR(_1);
+ ZVAL_STRING(_1, "accepted", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "hasoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
zephir_check_call_status();
- if (!ZEPHIR_IS_EQUAL(_0, _1)) {
- ZEPHIR_INIT_NVAR(_2);
- ZVAL_STRING(_2, "label", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&label, this_ptr, "getoption", NULL, 0, _2);
- zephir_check_temp_parameter(_2);
+ if (zephir_is_true(_0)) {
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "accepted", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&_2, this_ptr, "getoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
+ zephir_check_call_status();
+ valid = ZEPHIR_IS_EQUAL(value, _2);
+ } else {
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "value", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&_2, this_ptr, "hasoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
+ zephir_check_call_status();
+ if (zephir_is_true(_2)) {
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "value", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "getoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
+ zephir_check_call_status();
+ valid = ZEPHIR_IS_EQUAL(value, _3);
+ }
+ }
+ if (!(valid)) {
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "label", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&label, this_ptr, "getoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
zephir_check_call_status();
if (ZEPHIR_IS_EMPTY(label)) {
ZEPHIR_CALL_METHOD(&label, validation, "getlabel", NULL, 0, field);
zephir_check_call_status();
}
- ZEPHIR_INIT_NVAR(_2);
- ZVAL_STRING(_2, "message", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&message, this_ptr, "getoption", NULL, 0, _2);
- zephir_check_temp_parameter(_2);
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "message", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&message, this_ptr, "getoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
zephir_check_call_status();
ZEPHIR_INIT_VAR(replacePairs);
zephir_create_array(replacePairs, 1, 0 TSRMLS_CC);
zephir_array_update_string(&replacePairs, SL(":field"), &label, PH_COPY | PH_SEPARATE);
if (ZEPHIR_IS_EMPTY(message)) {
- ZEPHIR_INIT_NVAR(_2);
- ZVAL_STRING(_2, "Identical", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&message, validation, "getdefaultmessage", NULL, 0, _2);
- zephir_check_temp_parameter(_2);
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "Identical", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&message, validation, "getdefaultmessage", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
zephir_check_call_status();
}
- ZEPHIR_INIT_NVAR(_2);
- object_init_ex(_2, phalcon_validation_message_ce);
- ZEPHIR_CALL_FUNCTION(&_3, "strtr", NULL, 53, message, replacePairs);
+ ZEPHIR_INIT_NVAR(_1);
+ object_init_ex(_1, phalcon_validation_message_ce);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, message, replacePairs);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_4);
ZVAL_STRING(_4, "Identical", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 432, _3, field, _4);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _2, field, _4);
zephir_check_temp_parameter(_4);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _2);
+ ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
zephir_check_call_status();
RETURN_MM_BOOL(0);
}
@@ -135851,7 +136587,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) {
zephir_check_temp_parameter(_1);
zephir_check_call_status();
if (Z_TYPE_P(domain) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'domain' must be an array", "phalcon/validation/validator/inclusionin.zep", 61);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'domain' must be an array", "phalcon/validation/validator/inclusionin.zep", 62);
return;
}
ZEPHIR_INIT_VAR(strict);
@@ -135863,7 +136599,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) {
zephir_check_call_status();
if (zephir_is_true(_3)) {
if (Z_TYPE_P(strict) != IS_BOOL) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'strict' must be a boolean", "phalcon/validation/validator/inclusionin.zep", 67);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'strict' must be a boolean", "phalcon/validation/validator/inclusionin.zep", 68);
return;
}
ZEPHIR_INIT_NVAR(_1);
@@ -135872,7 +136608,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) {
zephir_check_temp_parameter(_1);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_4, "in_array", NULL, 363, value, domain, strict);
+ ZEPHIR_CALL_FUNCTION(&_4, "in_array", NULL, 365, value, domain, strict);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_1);
@@ -135908,7 +136644,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_6);
ZVAL_STRING(_6, "InclusionIn", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _5, field, _6);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6);
zephir_check_temp_parameter(_6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -136014,7 +136750,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Numericality, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_7);
ZVAL_STRING(_7, "Numericality", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 432, _6, field, _7);
+ ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 436, _6, field, _7);
zephir_check_temp_parameter(_7);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _5);
@@ -136107,7 +136843,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_PresenceOf, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_3);
ZVAL_STRING(_3, "PresenceOf", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _2, field, _3);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _2, field, _3);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -136223,7 +136959,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Regex, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_7);
ZVAL_STRING(_7, "Regex", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 432, _6, field, _7);
+ ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 436, _6, field, _7);
zephir_check_temp_parameter(_7);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _4);
@@ -136322,7 +137058,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) {
zephir_check_call_status();
}
if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 364, value);
+ ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, value);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(length);
@@ -136357,7 +137093,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_6);
ZVAL_STRING(_6, "TooLong", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_7, 432, _4, field, _6);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_7, 436, _4, field, _6);
zephir_check_temp_parameter(_6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -136394,7 +137130,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_8);
ZVAL_STRING(_8, "TooShort", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_7, 432, _4, field, _8);
+ ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_7, 436, _4, field, _8);
zephir_check_temp_parameter(_8);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _6);
@@ -136480,7 +137216,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Uniqueness, validate) {
ZEPHIR_INIT_VAR(_1);
zephir_create_array(_1, 2, 0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_2);
- ZEPHIR_CONCAT_VSVS(_2, attribute, "=:value: AND ", attribute, "!= :except:");
+ ZEPHIR_CONCAT_VSVS(_2, attribute, " = :value: AND ", attribute, " != :except:");
zephir_array_fast_append(_1, _2);
ZEPHIR_INIT_VAR(_3);
zephir_create_array(_3, 2, 0 TSRMLS_CC);
@@ -136494,7 +137230,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Uniqueness, validate) {
ZEPHIR_INIT_NVAR(_1);
zephir_create_array(_1, 2, 0 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_2);
- ZEPHIR_CONCAT_VS(_2, attribute, "=:value:");
+ ZEPHIR_CONCAT_VS(_2, attribute, " = :value:");
zephir_array_fast_append(_1, _2);
ZEPHIR_INIT_NVAR(_3);
zephir_create_array(_3, 1, 0 TSRMLS_CC);
@@ -136535,7 +137271,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Uniqueness, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_7);
ZVAL_STRING(_7, "Uniqueness", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 432, _6, field, _7);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _6, field, _7);
zephir_check_temp_parameter(_7);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -136607,7 +137343,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Url, validate) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 273);
- ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 190, value, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_1);
@@ -136640,7 +137376,7 @@ static PHP_METHOD(Phalcon_Validation_Validator_Url, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_6);
ZVAL_STRING(_6, "Url", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _5, field, _6);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6);
zephir_check_temp_parameter(_6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
@@ -136680,8 +137416,8 @@ zend_class_entry *phalcon_forms_elementinterface_ce;
zend_class_entry *phalcon_validation_validatorinterface_ce;
zend_class_entry *phalcon_mvc_model_validatorinterface_ce;
zend_class_entry *phalcon_cache_backendinterface_ce;
-zend_class_entry *phalcon_cache_frontendinterface_ce;
zend_class_entry *phalcon_mvc_model_metadatainterface_ce;
+zend_class_entry *phalcon_cache_frontendinterface_ce;
zend_class_entry *phalcon_db_dialectinterface_ce;
zend_class_entry *phalcon_dispatcherinterface_ce;
zend_class_entry *phalcon_annotations_adapterinterface_ce;
@@ -136690,11 +137426,11 @@ zend_class_entry *phalcon_logger_adapterinterface_ce;
zend_class_entry *phalcon_logger_formatterinterface_ce;
zend_class_entry *phalcon_mvc_entityinterface_ce;
zend_class_entry *phalcon_mvc_model_resultsetinterface_ce;
+zend_class_entry *phalcon_session_adapterinterface_ce;
zend_class_entry *phalcon_assets_filterinterface_ce;
zend_class_entry *phalcon_diinterface_ce;
zend_class_entry *phalcon_mvc_viewbaseinterface_ce;
zend_class_entry *phalcon_paginator_adapterinterface_ce;
-zend_class_entry *phalcon_session_adapterinterface_ce;
zend_class_entry *phalcon_translate_adapterinterface_ce;
zend_class_entry *phalcon_acl_adapterinterface_ce;
zend_class_entry *phalcon_flashinterface_ce;
@@ -136705,6 +137441,7 @@ zend_class_entry *phalcon_mvc_model_metadata_strategyinterface_ce;
zend_class_entry *phalcon_mvc_model_resultinterface_ce;
zend_class_entry *phalcon_mvc_routerinterface_ce;
zend_class_entry *phalcon_mvc_view_engineinterface_ce;
+zend_class_entry *phalcon_translate_interpolatorinterface_ce;
zend_class_entry *phalcon_acl_roleinterface_ce;
zend_class_entry *phalcon_annotations_readerinterface_ce;
zend_class_entry *phalcon_cryptinterface_ce;
@@ -136760,9 +137497,9 @@ zend_class_entry *phalcon_db_adapter_pdo_ce;
zend_class_entry *phalcon_db_dialect_ce;
zend_class_entry *phalcon_logger_adapter_ce;
zend_class_entry *phalcon_logger_formatter_ce;
+zend_class_entry *phalcon_session_adapter_ce;
zend_class_entry *phalcon_mvc_model_exception_ce;
zend_class_entry *phalcon_paginator_adapter_ce;
-zend_class_entry *phalcon_session_adapter_ce;
zend_class_entry *phalcon_translate_adapter_ce;
zend_class_entry *phalcon_assets_inline_ce;
zend_class_entry *phalcon_assets_resource_ce;
@@ -136937,6 +137674,7 @@ zend_class_entry *phalcon_mvc_model_metadata_files_ce;
zend_class_entry *phalcon_mvc_model_metadata_libmemcached_ce;
zend_class_entry *phalcon_mvc_model_metadata_memcache_ce;
zend_class_entry *phalcon_mvc_model_metadata_memory_ce;
+zend_class_entry *phalcon_mvc_model_metadata_redis_ce;
zend_class_entry *phalcon_mvc_model_metadata_session_ce;
zend_class_entry *phalcon_mvc_model_metadata_strategy_annotations_ce;
zend_class_entry *phalcon_mvc_model_metadata_strategy_introspection_ce;
@@ -136990,6 +137728,7 @@ zend_class_entry *phalcon_security_exception_ce;
zend_class_entry *phalcon_session_adapter_files_ce;
zend_class_entry *phalcon_session_adapter_libmemcached_ce;
zend_class_entry *phalcon_session_adapter_memcache_ce;
+zend_class_entry *phalcon_session_adapter_redis_ce;
zend_class_entry *phalcon_session_bag_ce;
zend_class_entry *phalcon_session_ce;
zend_class_entry *phalcon_session_exception_ce;
@@ -137002,6 +137741,8 @@ zend_class_entry *phalcon_translate_adapter_gettext_ce;
zend_class_entry *phalcon_translate_adapter_nativearray_ce;
zend_class_entry *phalcon_translate_ce;
zend_class_entry *phalcon_translate_exception_ce;
+zend_class_entry *phalcon_translate_interpolator_associativearray_ce;
+zend_class_entry *phalcon_translate_interpolator_indexedarray_ce;
zend_class_entry *phalcon_validation_ce;
zend_class_entry *phalcon_validation_exception_ce;
zend_class_entry *phalcon_validation_message_ce;
@@ -137068,8 +137809,8 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Validation_ValidatorInterface);
ZEPHIR_INIT(Phalcon_Mvc_Model_ValidatorInterface);
ZEPHIR_INIT(Phalcon_Cache_BackendInterface);
- ZEPHIR_INIT(Phalcon_Cache_FrontendInterface);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaDataInterface);
+ ZEPHIR_INIT(Phalcon_Cache_FrontendInterface);
ZEPHIR_INIT(Phalcon_Db_DialectInterface);
ZEPHIR_INIT(Phalcon_DispatcherInterface);
ZEPHIR_INIT(Phalcon_Annotations_AdapterInterface);
@@ -137078,11 +137819,11 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Logger_FormatterInterface);
ZEPHIR_INIT(Phalcon_Mvc_EntityInterface);
ZEPHIR_INIT(Phalcon_Mvc_Model_ResultsetInterface);
+ ZEPHIR_INIT(Phalcon_Session_AdapterInterface);
ZEPHIR_INIT(Phalcon_Assets_FilterInterface);
ZEPHIR_INIT(Phalcon_DiInterface);
ZEPHIR_INIT(Phalcon_Mvc_ViewBaseInterface);
ZEPHIR_INIT(Phalcon_Paginator_AdapterInterface);
- ZEPHIR_INIT(Phalcon_Session_AdapterInterface);
ZEPHIR_INIT(Phalcon_Translate_AdapterInterface);
ZEPHIR_INIT(Phalcon_Acl_AdapterInterface);
ZEPHIR_INIT(Phalcon_FlashInterface);
@@ -137093,6 +137834,7 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Mvc_Model_ResultInterface);
ZEPHIR_INIT(Phalcon_Mvc_RouterInterface);
ZEPHIR_INIT(Phalcon_Mvc_View_EngineInterface);
+ ZEPHIR_INIT(Phalcon_Translate_InterpolatorInterface);
ZEPHIR_INIT(Phalcon_Acl_RoleInterface);
ZEPHIR_INIT(Phalcon_Annotations_ReaderInterface);
ZEPHIR_INIT(Phalcon_CryptInterface);
@@ -137148,9 +137890,9 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Db_Dialect);
ZEPHIR_INIT(Phalcon_Logger_Adapter);
ZEPHIR_INIT(Phalcon_Logger_Formatter);
+ ZEPHIR_INIT(Phalcon_Session_Adapter);
ZEPHIR_INIT(Phalcon_Mvc_Model_Exception);
ZEPHIR_INIT(Phalcon_Paginator_Adapter);
- ZEPHIR_INIT(Phalcon_Session_Adapter);
ZEPHIR_INIT(Phalcon_Translate_Adapter);
ZEPHIR_INIT(Phalcon_Assets_Inline);
ZEPHIR_INIT(Phalcon_Assets_Resource);
@@ -137324,6 +138066,7 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Libmemcached);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Memcache);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Memory);
+ ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Redis);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Session);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Strategy_Annotations);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Strategy_Introspection);
@@ -137378,6 +138121,7 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Session_Adapter_Files);
ZEPHIR_INIT(Phalcon_Session_Adapter_Libmemcached);
ZEPHIR_INIT(Phalcon_Session_Adapter_Memcache);
+ ZEPHIR_INIT(Phalcon_Session_Adapter_Redis);
ZEPHIR_INIT(Phalcon_Session_Bag);
ZEPHIR_INIT(Phalcon_Session_Exception);
ZEPHIR_INIT(Phalcon_Tag);
@@ -137389,6 +138133,8 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Translate_Adapter_Gettext);
ZEPHIR_INIT(Phalcon_Translate_Adapter_NativeArray);
ZEPHIR_INIT(Phalcon_Translate_Exception);
+ ZEPHIR_INIT(Phalcon_Translate_Interpolator_AssociativeArray);
+ ZEPHIR_INIT(Phalcon_Translate_Interpolator_IndexedArray);
ZEPHIR_INIT(Phalcon_Validation);
ZEPHIR_INIT(Phalcon_Validation_Exception);
ZEPHIR_INIT(Phalcon_Validation_Message);
diff --git a/build/safe/phalcon.zep.h b/build/safe/phalcon.zep.h
index 984ec057a1c..877bafc5931 100644
--- a/build/safe/phalcon.zep.h
+++ b/build/safe/phalcon.zep.h
@@ -593,29 +593,6 @@ ZEPHIR_INIT_FUNCS(phalcon_cache_backendinterface_method_entry) {
PHP_FE_END
};
-zend_class_entry *phalcon_cache_frontendinterface_ce;
-
-ZEPHIR_INIT_CLASS(Phalcon_Cache_FrontendInterface);
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_cache_frontendinterface_beforestore, 0, 0, 1)
- ZEND_ARG_INFO(0, data)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_cache_frontendinterface_afterretrieve, 0, 0, 1)
- ZEND_ARG_INFO(0, data)
-ZEND_END_ARG_INFO()
-
-ZEPHIR_INIT_FUNCS(phalcon_cache_frontendinterface_method_entry) {
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, getLifetime, NULL)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, isBuffering, NULL)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, start, NULL)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, getContent, NULL)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, stop, NULL)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, beforeStore, arginfo_phalcon_cache_frontendinterface_beforestore)
- PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, afterRetrieve, arginfo_phalcon_cache_frontendinterface_afterretrieve)
- PHP_FE_END
-};
-
zend_class_entry *phalcon_mvc_model_metadata_ce;
ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_MetaData);
@@ -950,6 +927,29 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_model_metadatainterface_method_entry) {
PHP_FE_END
};
+zend_class_entry *phalcon_cache_frontendinterface_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Cache_FrontendInterface);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_cache_frontendinterface_beforestore, 0, 0, 1)
+ ZEND_ARG_INFO(0, data)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_cache_frontendinterface_afterretrieve, 0, 0, 1)
+ ZEND_ARG_INFO(0, data)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_cache_frontendinterface_method_entry) {
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, getLifetime, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, isBuffering, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, start, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, getContent, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, stop, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, beforeStore, arginfo_phalcon_cache_frontendinterface_beforestore)
+ PHP_ABSTRACT_ME(Phalcon_Cache_FrontendInterface, afterRetrieve, arginfo_phalcon_cache_frontendinterface_afterretrieve)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_db_adapter_ce;
ZEPHIR_INIT_CLASS(Phalcon_Db_Adapter);
@@ -2617,6 +2617,145 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_model_resultsetinterface_method_entry) {
PHP_FE_END
};
+zend_class_entry *phalcon_session_adapter_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Session_Adapter);
+
+static PHP_METHOD(Phalcon_Session_Adapter, __construct);
+static PHP_METHOD(Phalcon_Session_Adapter, start);
+static PHP_METHOD(Phalcon_Session_Adapter, setOptions);
+static PHP_METHOD(Phalcon_Session_Adapter, getOptions);
+static PHP_METHOD(Phalcon_Session_Adapter, setName);
+static PHP_METHOD(Phalcon_Session_Adapter, getName);
+static PHP_METHOD(Phalcon_Session_Adapter, get);
+static PHP_METHOD(Phalcon_Session_Adapter, set);
+static PHP_METHOD(Phalcon_Session_Adapter, has);
+static PHP_METHOD(Phalcon_Session_Adapter, remove);
+static PHP_METHOD(Phalcon_Session_Adapter, getId);
+static PHP_METHOD(Phalcon_Session_Adapter, setId);
+static PHP_METHOD(Phalcon_Session_Adapter, isStarted);
+static PHP_METHOD(Phalcon_Session_Adapter, destroy);
+static PHP_METHOD(Phalcon_Session_Adapter, status);
+static PHP_METHOD(Phalcon_Session_Adapter, __get);
+static PHP_METHOD(Phalcon_Session_Adapter, __set);
+static PHP_METHOD(Phalcon_Session_Adapter, __isset);
+static PHP_METHOD(Phalcon_Session_Adapter, __unset);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___construct, 0, 0, 0)
+ ZEND_ARG_INFO(0, options)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setoptions, 0, 0, 1)
+ ZEND_ARG_ARRAY_INFO(0, options, 0)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setname, 0, 0, 1)
+ ZEND_ARG_INFO(0, name)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_get, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ ZEND_ARG_INFO(0, defaultValue)
+ ZEND_ARG_INFO(0, remove)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_set, 0, 0, 2)
+ ZEND_ARG_INFO(0, index)
+ ZEND_ARG_INFO(0, value)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_has, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_remove, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setid, 0, 0, 1)
+ ZEND_ARG_INFO(0, id)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___get, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___set, 0, 0, 2)
+ ZEND_ARG_INFO(0, index)
+ ZEND_ARG_INFO(0, value)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___isset, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___unset, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_session_adapter_method_entry) {
+ PHP_ME(Phalcon_Session_Adapter, __construct, arginfo_phalcon_session_adapter___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Session_Adapter, start, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, setOptions, arginfo_phalcon_session_adapter_setoptions, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, getOptions, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, setName, arginfo_phalcon_session_adapter_setname, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, getName, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, get, arginfo_phalcon_session_adapter_get, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, set, arginfo_phalcon_session_adapter_set, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, has, arginfo_phalcon_session_adapter_has, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, remove, arginfo_phalcon_session_adapter_remove, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, getId, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, setId, arginfo_phalcon_session_adapter_setid, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, isStarted, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, destroy, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, status, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, __get, arginfo_phalcon_session_adapter___get, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, __set, arginfo_phalcon_session_adapter___set, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, __isset, arginfo_phalcon_session_adapter___isset, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter, __unset, arginfo_phalcon_session_adapter___unset, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
+
+zend_class_entry *phalcon_session_adapterinterface_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Session_AdapterInterface);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_setoptions, 0, 0, 1)
+ ZEND_ARG_ARRAY_INFO(0, options, 0)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_get, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ ZEND_ARG_INFO(0, defaultValue)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_set, 0, 0, 2)
+ ZEND_ARG_INFO(0, index)
+ ZEND_ARG_INFO(0, value)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_has, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_remove, 0, 0, 1)
+ ZEND_ARG_INFO(0, index)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_session_adapterinterface_method_entry) {
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, start, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, setOptions, arginfo_phalcon_session_adapterinterface_setoptions)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, getOptions, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, get, arginfo_phalcon_session_adapterinterface_get)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, set, arginfo_phalcon_session_adapterinterface_set)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, has, arginfo_phalcon_session_adapterinterface_has)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, remove, arginfo_phalcon_session_adapterinterface_remove)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, getId, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, isStarted, NULL)
+ PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, destroy, NULL)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_assets_filterinterface_ce;
ZEPHIR_INIT_CLASS(Phalcon_Assets_FilterInterface);
@@ -2803,149 +2942,12 @@ ZEPHIR_INIT_FUNCS(phalcon_paginator_adapterinterface_method_entry) {
PHP_FE_END
};
-zend_class_entry *phalcon_session_adapter_ce;
-
-ZEPHIR_INIT_CLASS(Phalcon_Session_Adapter);
-
-static PHP_METHOD(Phalcon_Session_Adapter, __construct);
-static PHP_METHOD(Phalcon_Session_Adapter, start);
-static PHP_METHOD(Phalcon_Session_Adapter, setOptions);
-static PHP_METHOD(Phalcon_Session_Adapter, getOptions);
-static PHP_METHOD(Phalcon_Session_Adapter, setName);
-static PHP_METHOD(Phalcon_Session_Adapter, getName);
-static PHP_METHOD(Phalcon_Session_Adapter, get);
-static PHP_METHOD(Phalcon_Session_Adapter, set);
-static PHP_METHOD(Phalcon_Session_Adapter, has);
-static PHP_METHOD(Phalcon_Session_Adapter, remove);
-static PHP_METHOD(Phalcon_Session_Adapter, getId);
-static PHP_METHOD(Phalcon_Session_Adapter, setId);
-static PHP_METHOD(Phalcon_Session_Adapter, isStarted);
-static PHP_METHOD(Phalcon_Session_Adapter, destroy);
-static PHP_METHOD(Phalcon_Session_Adapter, status);
-static PHP_METHOD(Phalcon_Session_Adapter, __get);
-static PHP_METHOD(Phalcon_Session_Adapter, __set);
-static PHP_METHOD(Phalcon_Session_Adapter, __isset);
-static PHP_METHOD(Phalcon_Session_Adapter, __unset);
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___construct, 0, 0, 0)
- ZEND_ARG_INFO(0, options)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setoptions, 0, 0, 1)
- ZEND_ARG_ARRAY_INFO(0, options, 0)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setname, 0, 0, 1)
- ZEND_ARG_INFO(0, name)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_get, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
- ZEND_ARG_INFO(0, defaultValue)
- ZEND_ARG_INFO(0, remove)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_set, 0, 0, 2)
- ZEND_ARG_INFO(0, index)
- ZEND_ARG_INFO(0, value)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_has, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_remove, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_setid, 0, 0, 1)
- ZEND_ARG_INFO(0, id)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___get, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___set, 0, 0, 2)
- ZEND_ARG_INFO(0, index)
- ZEND_ARG_INFO(0, value)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___isset, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter___unset, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEPHIR_INIT_FUNCS(phalcon_session_adapter_method_entry) {
- PHP_ME(Phalcon_Session_Adapter, __construct, arginfo_phalcon_session_adapter___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
- PHP_ME(Phalcon_Session_Adapter, start, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, setOptions, arginfo_phalcon_session_adapter_setoptions, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, getOptions, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, setName, arginfo_phalcon_session_adapter_setname, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, getName, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, get, arginfo_phalcon_session_adapter_get, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, set, arginfo_phalcon_session_adapter_set, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, has, arginfo_phalcon_session_adapter_has, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, remove, arginfo_phalcon_session_adapter_remove, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, getId, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, setId, arginfo_phalcon_session_adapter_setid, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, isStarted, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, destroy, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, status, NULL, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, __get, arginfo_phalcon_session_adapter___get, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, __set, arginfo_phalcon_session_adapter___set, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, __isset, arginfo_phalcon_session_adapter___isset, ZEND_ACC_PUBLIC)
- PHP_ME(Phalcon_Session_Adapter, __unset, arginfo_phalcon_session_adapter___unset, ZEND_ACC_PUBLIC)
- PHP_FE_END
-};
-
-zend_class_entry *phalcon_session_adapterinterface_ce;
-
-ZEPHIR_INIT_CLASS(Phalcon_Session_AdapterInterface);
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_setoptions, 0, 0, 1)
- ZEND_ARG_ARRAY_INFO(0, options, 0)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_get, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
- ZEND_ARG_INFO(0, defaultValue)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_set, 0, 0, 2)
- ZEND_ARG_INFO(0, index)
- ZEND_ARG_INFO(0, value)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_has, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapterinterface_remove, 0, 0, 1)
- ZEND_ARG_INFO(0, index)
-ZEND_END_ARG_INFO()
-
-ZEPHIR_INIT_FUNCS(phalcon_session_adapterinterface_method_entry) {
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, start, NULL)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, setOptions, arginfo_phalcon_session_adapterinterface_setoptions)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, getOptions, NULL)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, get, arginfo_phalcon_session_adapterinterface_get)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, set, arginfo_phalcon_session_adapterinterface_set)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, has, arginfo_phalcon_session_adapterinterface_has)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, remove, arginfo_phalcon_session_adapterinterface_remove)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, getId, NULL)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, isStarted, NULL)
- PHP_ABSTRACT_ME(Phalcon_Session_AdapterInterface, destroy, NULL)
- PHP_FE_END
-};
-
zend_class_entry *phalcon_translate_adapter_ce;
ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter);
+static PHP_METHOD(Phalcon_Translate_Adapter, __construct);
+static PHP_METHOD(Phalcon_Translate_Adapter, setInterpolator);
static PHP_METHOD(Phalcon_Translate_Adapter, t);
static PHP_METHOD(Phalcon_Translate_Adapter, _);
static PHP_METHOD(Phalcon_Translate_Adapter, offsetSet);
@@ -2954,6 +2956,14 @@ static PHP_METHOD(Phalcon_Translate_Adapter, offsetUnset);
static PHP_METHOD(Phalcon_Translate_Adapter, offsetGet);
static PHP_METHOD(Phalcon_Translate_Adapter, replacePlaceholders);
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter___construct, 0, 0, 1)
+ ZEND_ARG_ARRAY_INFO(0, options, 0)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_setinterpolator, 0, 0, 1)
+ ZEND_ARG_OBJ_INFO(0, interpolator, Phalcon\\Translate\\InterpolatorInterface, 0)
+ZEND_END_ARG_INFO()
+
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_t, 0, 0, 1)
ZEND_ARG_INFO(0, translateKey)
ZEND_ARG_INFO(0, placeholders)
@@ -2987,6 +2997,8 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_replaceplaceholders, 0,
ZEND_END_ARG_INFO()
ZEPHIR_INIT_FUNCS(phalcon_translate_adapter_method_entry) {
+ PHP_ME(Phalcon_Translate_Adapter, __construct, arginfo_phalcon_translate_adapter___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Translate_Adapter, setInterpolator, arginfo_phalcon_translate_adapter_setinterpolator, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Translate_Adapter, t, arginfo_phalcon_translate_adapter_t, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Translate_Adapter, _, arginfo_phalcon_translate_adapter__, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Translate_Adapter, offsetSet, arginfo_phalcon_translate_adapter_offsetset, ZEND_ACC_PUBLIC)
@@ -4259,6 +4271,20 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_view_engineinterface_method_entry) {
PHP_FE_END
};
+zend_class_entry *phalcon_translate_interpolatorinterface_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_InterpolatorInterface);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_interpolatorinterface_replaceplaceholders, 0, 0, 1)
+ ZEND_ARG_INFO(0, translation)
+ ZEND_ARG_INFO(0, placeholders)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_translate_interpolatorinterface_method_entry) {
+ PHP_ABSTRACT_ME(Phalcon_Translate_InterpolatorInterface, replacePlaceholders, arginfo_phalcon_translate_interpolatorinterface_replaceplaceholders)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_acl_adapter_ce;
ZEPHIR_INIT_CLASS(Phalcon_Acl_Adapter);
@@ -9050,6 +9076,7 @@ static PHP_METHOD(Phalcon_Db_Dialect_Oracle, describeReferences);
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, tableOptions);
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, supportsSavepoints);
static PHP_METHOD(Phalcon_Db_Dialect_Oracle, supportsReleaseSavepoints);
+static PHP_METHOD(Phalcon_Db_Dialect_Oracle, prepareTable);
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_dialect_oracle_limit, 0, 0, 2)
ZEND_ARG_INFO(0, sqlQuery)
@@ -9176,6 +9203,13 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_dialect_oracle_tableoptions, 0, 0, 1)
ZEND_ARG_INFO(0, schema)
ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_dialect_oracle_preparetable, 0, 0, 1)
+ ZEND_ARG_INFO(0, table)
+ ZEND_ARG_INFO(0, schema)
+ ZEND_ARG_INFO(0, alias)
+ ZEND_ARG_INFO(0, escapeChar)
+ZEND_END_ARG_INFO()
+
ZEPHIR_INIT_FUNCS(phalcon_db_dialect_oracle_method_entry) {
PHP_ME(Phalcon_Db_Dialect_Oracle, limit, arginfo_phalcon_db_dialect_oracle_limit, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Db_Dialect_Oracle, getColumnDefinition, arginfo_phalcon_db_dialect_oracle_getcolumndefinition, ZEND_ACC_PUBLIC)
@@ -9202,6 +9236,7 @@ ZEPHIR_INIT_FUNCS(phalcon_db_dialect_oracle_method_entry) {
PHP_ME(Phalcon_Db_Dialect_Oracle, tableOptions, arginfo_phalcon_db_dialect_oracle_tableoptions, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Db_Dialect_Oracle, supportsSavepoints, NULL, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Db_Dialect_Oracle, supportsReleaseSavepoints, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Db_Dialect_Oracle, prepareTable, arginfo_phalcon_db_dialect_oracle_preparetable, ZEND_ACC_PROTECTED)
PHP_FE_END
};
@@ -11232,6 +11267,7 @@ static PHP_METHOD(Phalcon_Http_Response, setHeader);
static PHP_METHOD(Phalcon_Http_Response, setRawHeader);
static PHP_METHOD(Phalcon_Http_Response, resetHeaders);
static PHP_METHOD(Phalcon_Http_Response, setExpires);
+static PHP_METHOD(Phalcon_Http_Response, setCache);
static PHP_METHOD(Phalcon_Http_Response, setNotModified);
static PHP_METHOD(Phalcon_Http_Response, setContentType);
static PHP_METHOD(Phalcon_Http_Response, setEtag);
@@ -11282,6 +11318,10 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_response_setexpires, 0, 0, 1)
ZEND_ARG_OBJ_INFO(0, datetime, DateTime, 0)
ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_response_setcache, 0, 0, 1)
+ ZEND_ARG_INFO(0, minutes)
+ZEND_END_ARG_INFO()
+
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_response_setcontenttype, 0, 0, 1)
ZEND_ARG_INFO(0, contentType)
ZEND_ARG_INFO(0, charset)
@@ -11331,6 +11371,7 @@ ZEPHIR_INIT_FUNCS(phalcon_http_response_method_entry) {
PHP_ME(Phalcon_Http_Response, setRawHeader, arginfo_phalcon_http_response_setrawheader, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, resetHeaders, NULL, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, setExpires, arginfo_phalcon_http_response_setexpires, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Http_Response, setCache, arginfo_phalcon_http_response_setcache, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, setNotModified, NULL, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, setContentType, arginfo_phalcon_http_response_setcontenttype, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, setEtag, arginfo_phalcon_http_response_setetag, ZEND_ACC_PUBLIC)
@@ -14498,6 +14539,36 @@ ZEPHIR_INIT_FUNCS(phalcon_mvc_model_metadata_memory_method_entry) {
PHP_FE_END
};
+zend_class_entry *phalcon_mvc_model_metadata_redis_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_MetaData_Redis);
+
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, __construct);
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, read);
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, write);
+static PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, reset);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_metadata_redis___construct, 0, 0, 0)
+ ZEND_ARG_INFO(0, options)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_metadata_redis_read, 0, 0, 1)
+ ZEND_ARG_INFO(0, key)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_metadata_redis_write, 0, 0, 2)
+ ZEND_ARG_INFO(0, key)
+ ZEND_ARG_INFO(0, data)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_mvc_model_metadata_redis_method_entry) {
+ PHP_ME(Phalcon_Mvc_Model_MetaData_Redis, __construct, arginfo_phalcon_mvc_model_metadata_redis___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Mvc_Model_MetaData_Redis, read, arginfo_phalcon_mvc_model_metadata_redis_read, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Mvc_Model_MetaData_Redis, write, arginfo_phalcon_mvc_model_metadata_redis_write, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Mvc_Model_MetaData_Redis, reset, NULL, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_mvc_model_metadata_session_ce;
ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_MetaData_Session);
@@ -16852,7 +16923,7 @@ static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, stats);
static PHP_METHOD(Phalcon_Queue_Beanstalk_Job, __wakeup);
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_queue_beanstalk_job___construct, 0, 0, 3)
- ZEND_ARG_INFO(0, queue)
+ ZEND_ARG_OBJ_INFO(0, queue, Phalcon\\Queue\\Beanstalk, 0)
ZEND_ARG_INFO(0, id)
ZEND_ARG_INFO(0, body)
ZEND_END_ARG_INFO()
@@ -17157,6 +17228,50 @@ ZEPHIR_INIT_FUNCS(phalcon_session_adapter_memcache_method_entry) {
PHP_FE_END
};
+zend_class_entry *phalcon_session_adapter_redis_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Session_Adapter_Redis);
+
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, getRedis);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, getLifetime);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, __construct);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, open);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, close);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, read);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, write);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, destroy);
+static PHP_METHOD(Phalcon_Session_Adapter_Redis, gc);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_redis___construct, 0, 0, 0)
+ ZEND_ARG_ARRAY_INFO(0, options, 1)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_redis_read, 0, 0, 1)
+ ZEND_ARG_INFO(0, sessionId)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_redis_write, 0, 0, 2)
+ ZEND_ARG_INFO(0, sessionId)
+ ZEND_ARG_INFO(0, data)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_redis_destroy, 0, 0, 0)
+ ZEND_ARG_INFO(0, sessionId)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_session_adapter_redis_method_entry) {
+ PHP_ME(Phalcon_Session_Adapter_Redis, getRedis, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, getLifetime, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, __construct, arginfo_phalcon_session_adapter_redis___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Session_Adapter_Redis, open, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, close, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, read, arginfo_phalcon_session_adapter_redis_read, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, write, arginfo_phalcon_session_adapter_redis_write, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, destroy, arginfo_phalcon_session_adapter_redis_destroy, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, gc, NULL, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_session_bag_ce;
ZEPHIR_INIT_CLASS(Phalcon_Session_Bag);
@@ -17739,6 +17854,7 @@ zend_class_entry *phalcon_translate_adapter_csv_ce;
ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter_Csv);
static PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct);
+static PHP_METHOD(Phalcon_Translate_Adapter_Csv, _load);
static PHP_METHOD(Phalcon_Translate_Adapter_Csv, query);
static PHP_METHOD(Phalcon_Translate_Adapter_Csv, exists);
static zend_object_value zephir_init_properties_Phalcon_Translate_Adapter_Csv(zend_class_entry *class_type TSRMLS_DC);
@@ -17747,6 +17863,13 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_csv___construct, 0, 0,
ZEND_ARG_ARRAY_INFO(0, options, 0)
ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_csv__load, 0, 0, 4)
+ ZEND_ARG_INFO(0, file)
+ ZEND_ARG_INFO(0, length)
+ ZEND_ARG_INFO(0, delimiter)
+ ZEND_ARG_INFO(0, enclosure)
+ZEND_END_ARG_INFO()
+
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_csv_query, 0, 0, 1)
ZEND_ARG_INFO(0, index)
ZEND_ARG_INFO(0, placeholders)
@@ -17758,6 +17881,7 @@ ZEND_END_ARG_INFO()
ZEPHIR_INIT_FUNCS(phalcon_translate_adapter_csv_method_entry) {
PHP_ME(Phalcon_Translate_Adapter_Csv, __construct, arginfo_phalcon_translate_adapter_csv___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Translate_Adapter_Csv, _load, arginfo_phalcon_translate_adapter_csv__load, ZEND_ACC_PRIVATE)
PHP_ME(Phalcon_Translate_Adapter_Csv, query, arginfo_phalcon_translate_adapter_csv_query, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Translate_Adapter_Csv, exists, arginfo_phalcon_translate_adapter_csv_exists, ZEND_ACC_PUBLIC)
PHP_FE_END
@@ -17881,6 +18005,38 @@ zend_class_entry *phalcon_translate_exception_ce;
ZEPHIR_INIT_CLASS(Phalcon_Translate_Exception);
+zend_class_entry *phalcon_translate_interpolator_associativearray_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_Interpolator_AssociativeArray);
+
+static PHP_METHOD(Phalcon_Translate_Interpolator_AssociativeArray, replacePlaceholders);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_interpolator_associativearray_replaceplaceholders, 0, 0, 1)
+ ZEND_ARG_INFO(0, translation)
+ ZEND_ARG_INFO(0, placeholders)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_translate_interpolator_associativearray_method_entry) {
+ PHP_ME(Phalcon_Translate_Interpolator_AssociativeArray, replacePlaceholders, arginfo_phalcon_translate_interpolator_associativearray_replaceplaceholders, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
+
+zend_class_entry *phalcon_translate_interpolator_indexedarray_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_Interpolator_IndexedArray);
+
+static PHP_METHOD(Phalcon_Translate_Interpolator_IndexedArray, replacePlaceholders);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_interpolator_indexedarray_replaceplaceholders, 0, 0, 1)
+ ZEND_ARG_INFO(0, translation)
+ ZEND_ARG_INFO(0, placeholders)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_translate_interpolator_indexedarray_method_entry) {
+ PHP_ME(Phalcon_Translate_Interpolator_IndexedArray, replacePlaceholders, arginfo_phalcon_translate_interpolator_indexedarray_replaceplaceholders, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
+
zend_class_entry *phalcon_validation_ce;
ZEPHIR_INIT_CLASS(Phalcon_Validation);
diff --git a/build/safe/php_phalcon.h b/build/safe/php_phalcon.h
index e67d31674a1..aed59e8482d 100644
--- a/build/safe/php_phalcon.h
+++ b/build/safe/php_phalcon.h
@@ -196,7 +196,7 @@ typedef zend_function zephir_fcall_cache_entry;
#define PHP_PHALCON_NAME "phalcon"
-#define PHP_PHALCON_VERSION "2.0.5"
+#define PHP_PHALCON_VERSION "2.0.6"
#define PHP_PHALCON_EXTNAME "phalcon"
#define PHP_PHALCON_AUTHOR "Phalcon Team and contributors"
#define PHP_PHALCON_ZEPVERSION "0.7.1b"
diff --git a/config.json b/config.json
index 7cc20316985..8bf29fc525d 100644
--- a/config.json
+++ b/config.json
@@ -10,7 +10,7 @@
"name": "phalcon",
"description": "Web framework delivered as a C-extension for PHP",
"author": "Phalcon Team and contributors",
- "version": "2.0.5",
+ "version": "2.0.6",
"verbose": false,
"optimizer-dirs": [
"optimizers"
diff --git a/ext/config.m4 b/ext/config.m4
index f856b45f533..df0249c878b 100644
--- a/ext/config.m4
+++ b/ext/config.m4
@@ -21,9 +21,9 @@ if test "$PHP_PHALCON" = "yes"; then
phalcon/mvc/model/validatorinterface.zep.c
phalcon/cache/backend.zep.c
phalcon/cache/backendinterface.zep.c
- phalcon/cache/frontendinterface.zep.c
phalcon/mvc/model/metadata.zep.c
phalcon/mvc/model/metadatainterface.zep.c
+ phalcon/cache/frontendinterface.zep.c
phalcon/db/adapter.zep.c
phalcon/db/dialectinterface.zep.c
phalcon/dispatcherinterface.zep.c
@@ -39,14 +39,14 @@ if test "$PHP_PHALCON" = "yes"; then
phalcon/logger/formatterinterface.zep.c
phalcon/mvc/entityinterface.zep.c
phalcon/mvc/model/resultsetinterface.zep.c
+ phalcon/session/adapter.zep.c
+ phalcon/session/adapterinterface.zep.c
phalcon/assets/filterinterface.zep.c
phalcon/diinterface.zep.c
phalcon/mvc/model/exception.zep.c
phalcon/mvc/viewbaseinterface.zep.c
phalcon/paginator/adapter.zep.c
phalcon/paginator/adapterinterface.zep.c
- phalcon/session/adapter.zep.c
- phalcon/session/adapterinterface.zep.c
phalcon/translate/adapter.zep.c
phalcon/translate/adapterinterface.zep.c
phalcon/acl/adapterinterface.zep.c
@@ -68,6 +68,7 @@ if test "$PHP_PHALCON" = "yes"; then
phalcon/mvc/routerinterface.zep.c
phalcon/mvc/view/engine.zep.c
phalcon/mvc/view/engineinterface.zep.c
+ phalcon/translate/interpolatorinterface.zep.c
phalcon/acl/adapter.zep.c
phalcon/acl/roleinterface.zep.c
phalcon/annotations/readerinterface.zep.c
@@ -270,6 +271,7 @@ if test "$PHP_PHALCON" = "yes"; then
phalcon/mvc/model/metadata/libmemcached.zep.c
phalcon/mvc/model/metadata/memcache.zep.c
phalcon/mvc/model/metadata/memory.zep.c
+ phalcon/mvc/model/metadata/redis.zep.c
phalcon/mvc/model/metadata/session.zep.c
phalcon/mvc/model/metadata/strategy/annotations.zep.c
phalcon/mvc/model/metadata/strategy/introspection.zep.c
@@ -325,6 +327,7 @@ if test "$PHP_PHALCON" = "yes"; then
phalcon/session/adapter/files.zep.c
phalcon/session/adapter/libmemcached.zep.c
phalcon/session/adapter/memcache.zep.c
+ phalcon/session/adapter/redis.zep.c
phalcon/session/bag.zep.c
phalcon/session/exception.zep.c
phalcon/tag.zep.c
@@ -336,6 +339,8 @@ if test "$PHP_PHALCON" = "yes"; then
phalcon/translate/adapter/gettext.zep.c
phalcon/translate/adapter/nativearray.zep.c
phalcon/translate/exception.zep.c
+ phalcon/translate/interpolator/associativearray.zep.c
+ phalcon/translate/interpolator/indexedarray.zep.c
phalcon/validation.zep.c
phalcon/validation/exception.zep.c
phalcon/validation/message.zep.c
diff --git a/ext/config.w32 b/ext/config.w32
index 23b1d39ce34..95c18f1229b 100644
--- a/ext/config.w32
+++ b/ext/config.w32
@@ -28,14 +28,14 @@ if (PHP_PHALCON != "no") {
ADD_SOURCES(configure_module_dirname + "/phalcon/db/adapter", "pdo.zep.c", "phalcon");
ADD_SOURCES(configure_module_dirname + "/phalcon/logger", "adapter.zep.c adapterinterface.zep.c formatter.zep.c formatterinterface.zep.c exception.zep.c item.zep.c multiple.zep.c", "phalcon");
ADD_SOURCES(configure_module_dirname + "/phalcon/mvc", "entityinterface.zep.c viewbaseinterface.zep.c routerinterface.zep.c collectioninterface.zep.c controllerinterface.zep.c dispatcherinterface.zep.c modelinterface.zep.c router.zep.c urlinterface.zep.c viewinterface.zep.c application.zep.c collection.zep.c controller.zep.c dispatcher.zep.c micro.zep.c model.zep.c moduledefinitioninterface.zep.c url.zep.c view.zep.c", "phalcon");
+ ADD_SOURCES(configure_module_dirname + "/phalcon/session", "adapter.zep.c adapterinterface.zep.c baginterface.zep.c bag.zep.c exception.zep.c", "phalcon");
ADD_SOURCES(configure_module_dirname + "/phalcon/assets", "filterinterface.zep.c inline.zep.c resource.zep.c collection.zep.c exception.zep.c manager.zep.c", "phalcon");
ADD_SOURCES(configure_module_dirname + "/phalcon/paginator", "adapter.zep.c adapterinterface.zep.c exception.zep.c", "phalcon");
- ADD_SOURCES(configure_module_dirname + "/phalcon/session", "adapter.zep.c adapterinterface.zep.c baginterface.zep.c bag.zep.c exception.zep.c", "phalcon");
- ADD_SOURCES(configure_module_dirname + "/phalcon/translate", "adapter.zep.c adapterinterface.zep.c exception.zep.c", "phalcon");
+ ADD_SOURCES(configure_module_dirname + "/phalcon/translate", "adapter.zep.c adapterinterface.zep.c interpolatorinterface.zep.c exception.zep.c", "phalcon");
ADD_SOURCES(configure_module_dirname + "/phalcon/acl", "adapterinterface.zep.c adapter.zep.c roleinterface.zep.c exception.zep.c resource.zep.c resourceinterface.zep.c role.zep.c", "phalcon");
ADD_SOURCES(configure_module_dirname + "/phalcon/image", "adapter.zep.c adapterinterface.zep.c exception.zep.c", "phalcon");
ADD_SOURCES(configure_module_dirname + "/phalcon/mvc/collection", "behavior.zep.c behaviorinterface.zep.c document.zep.c exception.zep.c manager.zep.c managerinterface.zep.c", "phalcon");
- ADD_SOURCES(configure_module_dirname + "/phalcon/mvc/model/metadata", "strategyinterface.zep.c apc.zep.c files.zep.c libmemcached.zep.c memcache.zep.c memory.zep.c session.zep.c xcache.zep.c", "phalcon");
+ ADD_SOURCES(configure_module_dirname + "/phalcon/mvc/model/metadata", "strategyinterface.zep.c apc.zep.c files.zep.c libmemcached.zep.c memcache.zep.c memory.zep.c redis.zep.c session.zep.c xcache.zep.c", "phalcon");
ADD_SOURCES(configure_module_dirname + "/phalcon/mvc/view", "engine.zep.c engineinterface.zep.c exception.zep.c simple.zep.c", "phalcon");
ADD_SOURCES(configure_module_dirname + "/phalcon/cache/frontend", "data.zep.c base64.zep.c igbinary.zep.c json.zep.c none.zep.c output.zep.c", "phalcon");
ADD_SOURCES(configure_module_dirname + "/phalcon/http/request", "fileinterface.zep.c exception.zep.c file.zep.c", "phalcon");
@@ -89,9 +89,10 @@ if (PHP_PHALCON != "no") {
ADD_SOURCES(configure_module_dirname + "/phalcon/queue", "beanstalk.zep.c", "phalcon");
ADD_SOURCES(configure_module_dirname + "/phalcon/queue/beanstalk", "job.zep.c", "phalcon");
ADD_SOURCES(configure_module_dirname + "/phalcon/security", "exception.zep.c", "phalcon");
- ADD_SOURCES(configure_module_dirname + "/phalcon/session/adapter", "files.zep.c libmemcached.zep.c memcache.zep.c", "phalcon");
+ ADD_SOURCES(configure_module_dirname + "/phalcon/session/adapter", "files.zep.c libmemcached.zep.c memcache.zep.c redis.zep.c", "phalcon");
ADD_SOURCES(configure_module_dirname + "/phalcon/tag", "exception.zep.c select.zep.c", "phalcon");
ADD_SOURCES(configure_module_dirname + "/phalcon/translate/adapter", "csv.zep.c gettext.zep.c nativearray.zep.c", "phalcon");
+ ADD_SOURCES(configure_module_dirname + "/phalcon/translate/interpolator", "associativearray.zep.c indexedarray.zep.c", "phalcon");
ADD_SOURCES(configure_module_dirname + "/phalcon/validation/message", "group.zep.c", "phalcon");
ADD_SOURCES(configure_module_dirname + "/phalcon/validation/validator", "alnum.zep.c alpha.zep.c between.zep.c confirmation.zep.c digit.zep.c email.zep.c exclusionin.zep.c file.zep.c identical.zep.c inclusionin.zep.c numericality.zep.c presenceof.zep.c regex.zep.c stringlength.zep.c uniqueness.zep.c url.zep.c", "phalcon");
ADD_FLAG("CFLAGS_PHALCON", "/D ZEPHIR_RELEASE");
diff --git a/ext/kernel/concat.c b/ext/kernel/concat.c
index aacd55274c1..c24e9b3a549 100644
--- a/ext/kernel/concat.c
+++ b/ext/kernel/concat.c
@@ -463,6 +463,107 @@ void zephir_concat_svsvsvs(zval **result, const char *op1, zend_uint op1_len, zv
}
+void zephir_concat_svsvsvssvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, const char *op8, zend_uint op8_len, zval *op9, const char *op10, zend_uint op10_len, zval *op11, const char *op12, zend_uint op12_len, int self_var TSRMLS_DC){
+
+ zval result_copy, op2_copy, op4_copy, op6_copy, op9_copy, op11_copy;
+ int use_copy = 0, use_copy2 = 0, use_copy4 = 0, use_copy6 = 0, use_copy9 = 0, use_copy11 = 0;
+ uint offset = 0, length;
+
+ if (Z_TYPE_P(op2) != IS_STRING) {
+ zend_make_printable_zval(op2, &op2_copy, &use_copy2);
+ if (use_copy2) {
+ op2 = &op2_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op4) != IS_STRING) {
+ zend_make_printable_zval(op4, &op4_copy, &use_copy4);
+ if (use_copy4) {
+ op4 = &op4_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op6) != IS_STRING) {
+ zend_make_printable_zval(op6, &op6_copy, &use_copy6);
+ if (use_copy6) {
+ op6 = &op6_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op9) != IS_STRING) {
+ zend_make_printable_zval(op9, &op9_copy, &use_copy9);
+ if (use_copy9) {
+ op9 = &op9_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op11) != IS_STRING) {
+ zend_make_printable_zval(op11, &op11_copy, &use_copy11);
+ if (use_copy11) {
+ op11 = &op11_copy;
+ }
+ }
+
+ length = op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len + Z_STRLEN_P(op9) + op10_len + Z_STRLEN_P(op11) + op12_len;
+ if (self_var) {
+
+ if (Z_TYPE_PP(result) != IS_STRING) {
+ zend_make_printable_zval(*result, &result_copy, &use_copy);
+ if (use_copy) {
+ ZEPHIR_CPY_WRT_CTOR(*result, (&result_copy));
+ }
+ }
+
+ offset = Z_STRLEN_PP(result);
+ length += offset;
+ Z_STRVAL_PP(result) = (char *) str_erealloc(Z_STRVAL_PP(result), length + 1);
+
+ } else {
+ Z_STRVAL_PP(result) = (char *) emalloc(length + 1);
+ }
+
+ memcpy(Z_STRVAL_PP(result) + offset, op1, op1_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len, Z_STRVAL_P(op2), Z_STRLEN_P(op2));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2), op3, op3_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len, Z_STRVAL_P(op4), Z_STRLEN_P(op4));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4), op5, op5_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len, Z_STRVAL_P(op6), Z_STRLEN_P(op6));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6), op7, op7_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len, op8, op8_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len, Z_STRVAL_P(op9), Z_STRLEN_P(op9));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len + Z_STRLEN_P(op9), op10, op10_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len + Z_STRLEN_P(op9) + op10_len, Z_STRVAL_P(op11), Z_STRLEN_P(op11));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + op8_len + Z_STRLEN_P(op9) + op10_len + Z_STRLEN_P(op11), op12, op12_len);
+ Z_STRVAL_PP(result)[length] = 0;
+ Z_TYPE_PP(result) = IS_STRING;
+ Z_STRLEN_PP(result) = length;
+
+ if (use_copy2) {
+ zval_dtor(op2);
+ }
+
+ if (use_copy4) {
+ zval_dtor(op4);
+ }
+
+ if (use_copy6) {
+ zval_dtor(op6);
+ }
+
+ if (use_copy9) {
+ zval_dtor(op9);
+ }
+
+ if (use_copy11) {
+ zval_dtor(op11);
+ }
+
+ if (use_copy) {
+ zval_dtor(&result_copy);
+ }
+
+}
+
void zephir_concat_svsvsvsv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, int self_var TSRMLS_DC){
zval result_copy, op2_copy, op4_copy, op6_copy, op8_copy;
@@ -636,6 +737,106 @@ void zephir_concat_svsvsvsvs(zval **result, const char *op1, zend_uint op1_len,
}
+void zephir_concat_svsvsvsvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, const char *op9, zend_uint op9_len, zval *op10, const char *op11, zend_uint op11_len, int self_var TSRMLS_DC){
+
+ zval result_copy, op2_copy, op4_copy, op6_copy, op8_copy, op10_copy;
+ int use_copy = 0, use_copy2 = 0, use_copy4 = 0, use_copy6 = 0, use_copy8 = 0, use_copy10 = 0;
+ uint offset = 0, length;
+
+ if (Z_TYPE_P(op2) != IS_STRING) {
+ zend_make_printable_zval(op2, &op2_copy, &use_copy2);
+ if (use_copy2) {
+ op2 = &op2_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op4) != IS_STRING) {
+ zend_make_printable_zval(op4, &op4_copy, &use_copy4);
+ if (use_copy4) {
+ op4 = &op4_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op6) != IS_STRING) {
+ zend_make_printable_zval(op6, &op6_copy, &use_copy6);
+ if (use_copy6) {
+ op6 = &op6_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op8) != IS_STRING) {
+ zend_make_printable_zval(op8, &op8_copy, &use_copy8);
+ if (use_copy8) {
+ op8 = &op8_copy;
+ }
+ }
+
+ if (Z_TYPE_P(op10) != IS_STRING) {
+ zend_make_printable_zval(op10, &op10_copy, &use_copy10);
+ if (use_copy10) {
+ op10 = &op10_copy;
+ }
+ }
+
+ length = op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + Z_STRLEN_P(op8) + op9_len + Z_STRLEN_P(op10) + op11_len;
+ if (self_var) {
+
+ if (Z_TYPE_PP(result) != IS_STRING) {
+ zend_make_printable_zval(*result, &result_copy, &use_copy);
+ if (use_copy) {
+ ZEPHIR_CPY_WRT_CTOR(*result, (&result_copy));
+ }
+ }
+
+ offset = Z_STRLEN_PP(result);
+ length += offset;
+ Z_STRVAL_PP(result) = (char *) str_erealloc(Z_STRVAL_PP(result), length + 1);
+
+ } else {
+ Z_STRVAL_PP(result) = (char *) emalloc(length + 1);
+ }
+
+ memcpy(Z_STRVAL_PP(result) + offset, op1, op1_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len, Z_STRVAL_P(op2), Z_STRLEN_P(op2));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2), op3, op3_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len, Z_STRVAL_P(op4), Z_STRLEN_P(op4));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4), op5, op5_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len, Z_STRVAL_P(op6), Z_STRLEN_P(op6));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6), op7, op7_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len, Z_STRVAL_P(op8), Z_STRLEN_P(op8));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + Z_STRLEN_P(op8), op9, op9_len);
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + Z_STRLEN_P(op8) + op9_len, Z_STRVAL_P(op10), Z_STRLEN_P(op10));
+ memcpy(Z_STRVAL_PP(result) + offset + op1_len + Z_STRLEN_P(op2) + op3_len + Z_STRLEN_P(op4) + op5_len + Z_STRLEN_P(op6) + op7_len + Z_STRLEN_P(op8) + op9_len + Z_STRLEN_P(op10), op11, op11_len);
+ Z_STRVAL_PP(result)[length] = 0;
+ Z_TYPE_PP(result) = IS_STRING;
+ Z_STRLEN_PP(result) = length;
+
+ if (use_copy2) {
+ zval_dtor(op2);
+ }
+
+ if (use_copy4) {
+ zval_dtor(op4);
+ }
+
+ if (use_copy6) {
+ zval_dtor(op6);
+ }
+
+ if (use_copy8) {
+ zval_dtor(op8);
+ }
+
+ if (use_copy10) {
+ zval_dtor(op10);
+ }
+
+ if (use_copy) {
+ zval_dtor(&result_copy);
+ }
+
+}
+
void zephir_concat_svsvv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, zval *op5, int self_var TSRMLS_DC){
zval result_copy, op2_copy, op4_copy, op5_copy;
diff --git a/ext/kernel/concat.h b/ext/kernel/concat.h
index 6a5ded39285..3bb2560ab78 100644
--- a/ext/kernel/concat.h
+++ b/ext/kernel/concat.h
@@ -42,6 +42,11 @@
#define ZEPHIR_SCONCAT_SVSVSVS(result, op1, op2, op3, op4, op5, op6, op7) \
zephir_concat_svsvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, 1 TSRMLS_CC);
+#define ZEPHIR_CONCAT_SVSVSVSSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9, op10, op11, op12) \
+ zephir_concat_svsvsvssvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, sizeof(op8)-1, op9, op10, sizeof(op10)-1, op11, op12, sizeof(op12)-1, 0 TSRMLS_CC);
+#define ZEPHIR_SCONCAT_SVSVSVSSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9, op10, op11, op12) \
+ zephir_concat_svsvsvssvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, sizeof(op8)-1, op9, op10, sizeof(op10)-1, op11, op12, sizeof(op12)-1, 1 TSRMLS_CC);
+
#define ZEPHIR_CONCAT_SVSVSVSV(result, op1, op2, op3, op4, op5, op6, op7, op8) \
zephir_concat_svsvsvsv(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, 0 TSRMLS_CC);
#define ZEPHIR_SCONCAT_SVSVSVSV(result, op1, op2, op3, op4, op5, op6, op7, op8) \
@@ -52,6 +57,11 @@
#define ZEPHIR_SCONCAT_SVSVSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9) \
zephir_concat_svsvsvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, op9, sizeof(op9)-1, 1 TSRMLS_CC);
+#define ZEPHIR_CONCAT_SVSVSVSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9, op10, op11) \
+ zephir_concat_svsvsvsvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, op9, sizeof(op9)-1, op10, op11, sizeof(op11)-1, 0 TSRMLS_CC);
+#define ZEPHIR_SCONCAT_SVSVSVSVSVS(result, op1, op2, op3, op4, op5, op6, op7, op8, op9, op10, op11) \
+ zephir_concat_svsvsvsvsvs(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, sizeof(op5)-1, op6, op7, sizeof(op7)-1, op8, op9, sizeof(op9)-1, op10, op11, sizeof(op11)-1, 1 TSRMLS_CC);
+
#define ZEPHIR_CONCAT_SVSVV(result, op1, op2, op3, op4, op5) \
zephir_concat_svsvv(&result, op1, sizeof(op1)-1, op2, op3, sizeof(op3)-1, op4, op5, 0 TSRMLS_CC);
#define ZEPHIR_SCONCAT_SVSVV(result, op1, op2, op3, op4, op5) \
@@ -155,8 +165,10 @@ void zephir_concat_svsvs(zval **result, const char *op1, zend_uint op1_len, zval
void zephir_concat_svsvssvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, const char *op6, zend_uint op6_len, zval *op7, const char *op8, zend_uint op8_len, zval *op9, const char *op10, zend_uint op10_len, int self_var TSRMLS_DC);
void zephir_concat_svsvsv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, int self_var TSRMLS_DC);
void zephir_concat_svsvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, int self_var TSRMLS_DC);
+void zephir_concat_svsvsvssvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, const char *op8, zend_uint op8_len, zval *op9, const char *op10, zend_uint op10_len, zval *op11, const char *op12, zend_uint op12_len, int self_var TSRMLS_DC);
void zephir_concat_svsvsvsv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, int self_var TSRMLS_DC);
void zephir_concat_svsvsvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, const char *op9, zend_uint op9_len, int self_var TSRMLS_DC);
+void zephir_concat_svsvsvsvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, const char *op5, zend_uint op5_len, zval *op6, const char *op7, zend_uint op7_len, zval *op8, const char *op9, zend_uint op9_len, zval *op10, const char *op11, zend_uint op11_len, int self_var TSRMLS_DC);
void zephir_concat_svsvv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, zval *op5, int self_var TSRMLS_DC);
void zephir_concat_svsvvsv(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, zval *op5, const char *op6, zend_uint op6_len, zval *op7, int self_var TSRMLS_DC);
void zephir_concat_svsvvsvs(zval **result, const char *op1, zend_uint op1_len, zval *op2, const char *op3, zend_uint op3_len, zval *op4, zval *op5, const char *op6, zend_uint op6_len, zval *op7, const char *op8, zend_uint op8_len, int self_var TSRMLS_DC);
diff --git a/ext/kernel/string.c b/ext/kernel/string.c
index f08413b30c9..11d5e8397e5 100644
--- a/ext/kernel/string.c
+++ b/ext/kernel/string.c
@@ -256,7 +256,7 @@ void zephir_fast_join_str(zval *return_value, char *glue, unsigned int glue_leng
*/
void zephir_camelize(zval *return_value, const zval *str) {
- int i, len;
+ int i, len, first = 0;
smart_str camelize_str = {0};
char *marker, ch;
@@ -268,35 +268,40 @@ void zephir_camelize(zval *return_value, const zval *str) {
marker = Z_STRVAL_P(str);
len = Z_STRLEN_P(str);
- for (i = 0; i < len - 1; i++) {
- ch = *marker;
- if (i == 0 || ch == '-' || ch == '_') {
+ for (i = 0; i < len; i++) {
+
+ ch = marker[i];
+
+ if (first == 0) {
+
if (ch == '-' || ch == '_') {
- i++;
- marker++;
+ continue;
}
- smart_str_appendc(&camelize_str, toupper(*marker));
- }
- else {
- smart_str_appendc(&camelize_str, tolower(*marker));
+ first = 1;
+ smart_str_appendc(&camelize_str, toupper(ch));
+ continue;
}
- marker++;
- }
+ if (ch == '-' || ch == '_') {
+ if (i != (len - 1)) {
+ i++;
+ ch = marker[i];
+ smart_str_appendc(&camelize_str, toupper(ch));
+ }
+ continue;
+ }
- if (likely(i == len - 1)) {
- smart_str_appendc(&camelize_str, *marker);
+ smart_str_appendc(&camelize_str, tolower(ch));
}
smart_str_0(&camelize_str);
if (camelize_str.c) {
RETURN_STRINGL(camelize_str.c, camelize_str.len, 0);
- } else {
- RETURN_EMPTY_STRING();
}
+ RETURN_EMPTY_STRING();
}
/**
@@ -315,10 +320,13 @@ void zephir_uncamelize(zval *return_value, const zval *str) {
marker = Z_STRVAL_P(str);
for (i = 0; i < Z_STRLEN_P(str); i++) {
+
ch = *marker;
+
if (ch == '\0') {
break;
}
+
if (ch >= 'A' && ch <= 'Z') {
if (i > 0) {
smart_str_appendc(&uncamelize_str, '_');
@@ -327,6 +335,7 @@ void zephir_uncamelize(zval *return_value, const zval *str) {
} else {
smart_str_appendc(&uncamelize_str, (*marker));
}
+
marker++;
}
smart_str_0(&uncamelize_str);
@@ -521,7 +530,7 @@ void zephir_fast_str_replace(zval **return_value_ptr, zval *search, zval *replac
*/
if (Z_TYPE_P(search) == IS_ARRAY) {
do {
- zval *params[] = { search, replace, subject };
+ zval *params[] = { search, replace, subject };
zval_ptr_dtor(return_value_ptr);
return_value_ptr = NULL;
zephir_call_func_aparams(return_value_ptr, "str_replace", sizeof("str_replace")-1, NULL, 0, 3, params TSRMLS_CC);
diff --git a/ext/phalcon.c b/ext/phalcon.c
index 778cc80a8eb..7dfc4d1679d 100644
--- a/ext/phalcon.c
+++ b/ext/phalcon.c
@@ -33,8 +33,8 @@ zend_class_entry *phalcon_forms_elementinterface_ce;
zend_class_entry *phalcon_validation_validatorinterface_ce;
zend_class_entry *phalcon_mvc_model_validatorinterface_ce;
zend_class_entry *phalcon_cache_backendinterface_ce;
-zend_class_entry *phalcon_cache_frontendinterface_ce;
zend_class_entry *phalcon_mvc_model_metadatainterface_ce;
+zend_class_entry *phalcon_cache_frontendinterface_ce;
zend_class_entry *phalcon_db_dialectinterface_ce;
zend_class_entry *phalcon_dispatcherinterface_ce;
zend_class_entry *phalcon_annotations_adapterinterface_ce;
@@ -43,11 +43,11 @@ zend_class_entry *phalcon_logger_adapterinterface_ce;
zend_class_entry *phalcon_logger_formatterinterface_ce;
zend_class_entry *phalcon_mvc_entityinterface_ce;
zend_class_entry *phalcon_mvc_model_resultsetinterface_ce;
+zend_class_entry *phalcon_session_adapterinterface_ce;
zend_class_entry *phalcon_assets_filterinterface_ce;
zend_class_entry *phalcon_diinterface_ce;
zend_class_entry *phalcon_mvc_viewbaseinterface_ce;
zend_class_entry *phalcon_paginator_adapterinterface_ce;
-zend_class_entry *phalcon_session_adapterinterface_ce;
zend_class_entry *phalcon_translate_adapterinterface_ce;
zend_class_entry *phalcon_acl_adapterinterface_ce;
zend_class_entry *phalcon_flashinterface_ce;
@@ -58,6 +58,7 @@ zend_class_entry *phalcon_mvc_model_metadata_strategyinterface_ce;
zend_class_entry *phalcon_mvc_model_resultinterface_ce;
zend_class_entry *phalcon_mvc_routerinterface_ce;
zend_class_entry *phalcon_mvc_view_engineinterface_ce;
+zend_class_entry *phalcon_translate_interpolatorinterface_ce;
zend_class_entry *phalcon_acl_roleinterface_ce;
zend_class_entry *phalcon_annotations_readerinterface_ce;
zend_class_entry *phalcon_cryptinterface_ce;
@@ -113,9 +114,9 @@ zend_class_entry *phalcon_db_adapter_pdo_ce;
zend_class_entry *phalcon_db_dialect_ce;
zend_class_entry *phalcon_logger_adapter_ce;
zend_class_entry *phalcon_logger_formatter_ce;
+zend_class_entry *phalcon_session_adapter_ce;
zend_class_entry *phalcon_mvc_model_exception_ce;
zend_class_entry *phalcon_paginator_adapter_ce;
-zend_class_entry *phalcon_session_adapter_ce;
zend_class_entry *phalcon_translate_adapter_ce;
zend_class_entry *phalcon_assets_inline_ce;
zend_class_entry *phalcon_assets_resource_ce;
@@ -290,6 +291,7 @@ zend_class_entry *phalcon_mvc_model_metadata_files_ce;
zend_class_entry *phalcon_mvc_model_metadata_libmemcached_ce;
zend_class_entry *phalcon_mvc_model_metadata_memcache_ce;
zend_class_entry *phalcon_mvc_model_metadata_memory_ce;
+zend_class_entry *phalcon_mvc_model_metadata_redis_ce;
zend_class_entry *phalcon_mvc_model_metadata_session_ce;
zend_class_entry *phalcon_mvc_model_metadata_strategy_annotations_ce;
zend_class_entry *phalcon_mvc_model_metadata_strategy_introspection_ce;
@@ -343,6 +345,7 @@ zend_class_entry *phalcon_security_exception_ce;
zend_class_entry *phalcon_session_adapter_files_ce;
zend_class_entry *phalcon_session_adapter_libmemcached_ce;
zend_class_entry *phalcon_session_adapter_memcache_ce;
+zend_class_entry *phalcon_session_adapter_redis_ce;
zend_class_entry *phalcon_session_bag_ce;
zend_class_entry *phalcon_session_ce;
zend_class_entry *phalcon_session_exception_ce;
@@ -355,6 +358,8 @@ zend_class_entry *phalcon_translate_adapter_gettext_ce;
zend_class_entry *phalcon_translate_adapter_nativearray_ce;
zend_class_entry *phalcon_translate_ce;
zend_class_entry *phalcon_translate_exception_ce;
+zend_class_entry *phalcon_translate_interpolator_associativearray_ce;
+zend_class_entry *phalcon_translate_interpolator_indexedarray_ce;
zend_class_entry *phalcon_validation_ce;
zend_class_entry *phalcon_validation_exception_ce;
zend_class_entry *phalcon_validation_message_ce;
@@ -421,8 +426,8 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Validation_ValidatorInterface);
ZEPHIR_INIT(Phalcon_Mvc_Model_ValidatorInterface);
ZEPHIR_INIT(Phalcon_Cache_BackendInterface);
- ZEPHIR_INIT(Phalcon_Cache_FrontendInterface);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaDataInterface);
+ ZEPHIR_INIT(Phalcon_Cache_FrontendInterface);
ZEPHIR_INIT(Phalcon_Db_DialectInterface);
ZEPHIR_INIT(Phalcon_DispatcherInterface);
ZEPHIR_INIT(Phalcon_Annotations_AdapterInterface);
@@ -431,11 +436,11 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Logger_FormatterInterface);
ZEPHIR_INIT(Phalcon_Mvc_EntityInterface);
ZEPHIR_INIT(Phalcon_Mvc_Model_ResultsetInterface);
+ ZEPHIR_INIT(Phalcon_Session_AdapterInterface);
ZEPHIR_INIT(Phalcon_Assets_FilterInterface);
ZEPHIR_INIT(Phalcon_DiInterface);
ZEPHIR_INIT(Phalcon_Mvc_ViewBaseInterface);
ZEPHIR_INIT(Phalcon_Paginator_AdapterInterface);
- ZEPHIR_INIT(Phalcon_Session_AdapterInterface);
ZEPHIR_INIT(Phalcon_Translate_AdapterInterface);
ZEPHIR_INIT(Phalcon_Acl_AdapterInterface);
ZEPHIR_INIT(Phalcon_FlashInterface);
@@ -446,6 +451,7 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Mvc_Model_ResultInterface);
ZEPHIR_INIT(Phalcon_Mvc_RouterInterface);
ZEPHIR_INIT(Phalcon_Mvc_View_EngineInterface);
+ ZEPHIR_INIT(Phalcon_Translate_InterpolatorInterface);
ZEPHIR_INIT(Phalcon_Acl_RoleInterface);
ZEPHIR_INIT(Phalcon_Annotations_ReaderInterface);
ZEPHIR_INIT(Phalcon_CryptInterface);
@@ -501,9 +507,9 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Db_Dialect);
ZEPHIR_INIT(Phalcon_Logger_Adapter);
ZEPHIR_INIT(Phalcon_Logger_Formatter);
+ ZEPHIR_INIT(Phalcon_Session_Adapter);
ZEPHIR_INIT(Phalcon_Mvc_Model_Exception);
ZEPHIR_INIT(Phalcon_Paginator_Adapter);
- ZEPHIR_INIT(Phalcon_Session_Adapter);
ZEPHIR_INIT(Phalcon_Translate_Adapter);
ZEPHIR_INIT(Phalcon_Assets_Inline);
ZEPHIR_INIT(Phalcon_Assets_Resource);
@@ -677,6 +683,7 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Libmemcached);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Memcache);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Memory);
+ ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Redis);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Session);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Strategy_Annotations);
ZEPHIR_INIT(Phalcon_Mvc_Model_MetaData_Strategy_Introspection);
@@ -731,6 +738,7 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Session_Adapter_Files);
ZEPHIR_INIT(Phalcon_Session_Adapter_Libmemcached);
ZEPHIR_INIT(Phalcon_Session_Adapter_Memcache);
+ ZEPHIR_INIT(Phalcon_Session_Adapter_Redis);
ZEPHIR_INIT(Phalcon_Session_Bag);
ZEPHIR_INIT(Phalcon_Session_Exception);
ZEPHIR_INIT(Phalcon_Tag);
@@ -742,6 +750,8 @@ static PHP_MINIT_FUNCTION(phalcon)
ZEPHIR_INIT(Phalcon_Translate_Adapter_Gettext);
ZEPHIR_INIT(Phalcon_Translate_Adapter_NativeArray);
ZEPHIR_INIT(Phalcon_Translate_Exception);
+ ZEPHIR_INIT(Phalcon_Translate_Interpolator_AssociativeArray);
+ ZEPHIR_INIT(Phalcon_Translate_Interpolator_IndexedArray);
ZEPHIR_INIT(Phalcon_Validation);
ZEPHIR_INIT(Phalcon_Validation_Exception);
ZEPHIR_INIT(Phalcon_Validation_Message);
diff --git a/ext/phalcon.h b/ext/phalcon.h
index 6825dc32d1d..e5d4f6eaf90 100644
--- a/ext/phalcon.h
+++ b/ext/phalcon.h
@@ -16,9 +16,9 @@
#include "phalcon/mvc/model/validatorinterface.zep.h"
#include "phalcon/cache/backend.zep.h"
#include "phalcon/cache/backendinterface.zep.h"
-#include "phalcon/cache/frontendinterface.zep.h"
#include "phalcon/mvc/model/metadata.zep.h"
#include "phalcon/mvc/model/metadatainterface.zep.h"
+#include "phalcon/cache/frontendinterface.zep.h"
#include "phalcon/db/adapter.zep.h"
#include "phalcon/db/dialectinterface.zep.h"
#include "phalcon/dispatcherinterface.zep.h"
@@ -34,14 +34,14 @@
#include "phalcon/logger/formatterinterface.zep.h"
#include "phalcon/mvc/entityinterface.zep.h"
#include "phalcon/mvc/model/resultsetinterface.zep.h"
+#include "phalcon/session/adapter.zep.h"
+#include "phalcon/session/adapterinterface.zep.h"
#include "phalcon/assets/filterinterface.zep.h"
#include "phalcon/diinterface.zep.h"
#include "phalcon/mvc/model/exception.zep.h"
#include "phalcon/mvc/viewbaseinterface.zep.h"
#include "phalcon/paginator/adapter.zep.h"
#include "phalcon/paginator/adapterinterface.zep.h"
-#include "phalcon/session/adapter.zep.h"
-#include "phalcon/session/adapterinterface.zep.h"
#include "phalcon/translate/adapter.zep.h"
#include "phalcon/translate/adapterinterface.zep.h"
#include "phalcon/acl/adapterinterface.zep.h"
@@ -63,6 +63,7 @@
#include "phalcon/mvc/routerinterface.zep.h"
#include "phalcon/mvc/view/engine.zep.h"
#include "phalcon/mvc/view/engineinterface.zep.h"
+#include "phalcon/translate/interpolatorinterface.zep.h"
#include "phalcon/acl/adapter.zep.h"
#include "phalcon/acl/roleinterface.zep.h"
#include "phalcon/annotations/readerinterface.zep.h"
@@ -265,6 +266,7 @@
#include "phalcon/mvc/model/metadata/libmemcached.zep.h"
#include "phalcon/mvc/model/metadata/memcache.zep.h"
#include "phalcon/mvc/model/metadata/memory.zep.h"
+#include "phalcon/mvc/model/metadata/redis.zep.h"
#include "phalcon/mvc/model/metadata/session.zep.h"
#include "phalcon/mvc/model/metadata/strategy/annotations.zep.h"
#include "phalcon/mvc/model/metadata/strategy/introspection.zep.h"
@@ -320,6 +322,7 @@
#include "phalcon/session/adapter/files.zep.h"
#include "phalcon/session/adapter/libmemcached.zep.h"
#include "phalcon/session/adapter/memcache.zep.h"
+#include "phalcon/session/adapter/redis.zep.h"
#include "phalcon/session/bag.zep.h"
#include "phalcon/session/exception.zep.h"
#include "phalcon/tag.zep.h"
@@ -331,6 +334,8 @@
#include "phalcon/translate/adapter/gettext.zep.h"
#include "phalcon/translate/adapter/nativearray.zep.h"
#include "phalcon/translate/exception.zep.h"
+#include "phalcon/translate/interpolator/associativearray.zep.h"
+#include "phalcon/translate/interpolator/indexedarray.zep.h"
#include "phalcon/validation.zep.h"
#include "phalcon/validation/exception.zep.h"
#include "phalcon/validation/message.zep.h"
diff --git a/ext/phalcon/0__closure.zep.c b/ext/phalcon/0__closure.zep.c
index b36fc947954..19f92a3bb7c 100644
--- a/ext/phalcon/0__closure.zep.c
+++ b/ext/phalcon/0__closure.zep.c
@@ -36,12 +36,12 @@ PHP_METHOD(phalcon_0__closure, __invoke) {
- zephir_array_fetch_long(&_0, matches, 1, PH_NOISY | PH_READONLY, "phalcon/text.zep", 276 TSRMLS_CC);
+ zephir_array_fetch_long(&_0, matches, 1, PH_NOISY | PH_READONLY, "phalcon/text.zep", 272 TSRMLS_CC);
ZEPHIR_INIT_VAR(words);
zephir_fast_explode_str(words, SL("|"), _0, LONG_MAX TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_2, "array_rand", NULL, 438, words);
+ ZEPHIR_CALL_FUNCTION(&_2, "array_rand", NULL, 442, words);
zephir_check_call_status();
- zephir_array_fetch(&_1, words, _2, PH_NOISY | PH_READONLY, "phalcon/text.zep", 277 TSRMLS_CC);
+ zephir_array_fetch(&_1, words, _2, PH_NOISY | PH_READONLY, "phalcon/text.zep", 273 TSRMLS_CC);
RETURN_CTOR(_1);
}
diff --git a/ext/phalcon/cache/backend/libmemcached.zep.c b/ext/phalcon/cache/backend/libmemcached.zep.c
index 59ea9f38b95..e071b67cdfe 100644
--- a/ext/phalcon/cache/backend/libmemcached.zep.c
+++ b/ext/phalcon/cache/backend/libmemcached.zep.c
@@ -223,7 +223,7 @@ PHP_METHOD(Phalcon_Cache_Backend_Libmemcached, save) {
int ZEPHIR_LAST_CALL_STATUS;
zend_bool stopBuffer;
- zval *keyName = NULL, *content = NULL, *lifetime = NULL, *stopBuffer_param = NULL, *lastKey = NULL, *frontend, *memcache = NULL, *cachedContent = NULL, *preparedContent = NULL, *tmp, *tt1 = NULL, *success = NULL, *options, *specialKey, *keys = NULL, *isBuffering = NULL, *_0;
+ zval *keyName = NULL, *content = NULL, *lifetime = NULL, *stopBuffer_param = NULL, *lastKey = NULL, *frontend, *memcache = NULL, *cachedContent = NULL, *preparedContent = NULL, *tmp, *tt1 = NULL, *success = NULL, *options, *specialKey, *keys = NULL, *isBuffering = NULL, *_0, *_1, *_2 = NULL, *_3;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 0, 4, &keyName, &content, &lifetime, &stopBuffer_param);
@@ -296,7 +296,16 @@ PHP_METHOD(Phalcon_Cache_Backend_Libmemcached, save) {
zephir_check_call_status();
}
if (!(zephir_is_true(success))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_cache_exception_ce, "Failed storing data in memcached", "phalcon/cache/backend/libmemcached.zep", 223);
+ ZEPHIR_INIT_VAR(_1);
+ object_init_ex(_1, phalcon_cache_exception_ce);
+ ZEPHIR_CALL_METHOD(&_2, memcache, "getresultcode", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_INIT_VAR(_3);
+ ZEPHIR_CONCAT_SV(_3, "Failed storing data in memcached, error code: ", _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3);
+ zephir_check_call_status();
+ zephir_throw_exception_debug(_1, "phalcon/cache/backend/libmemcached.zep", 223 TSRMLS_CC);
+ ZEPHIR_MM_RESTORE();
return;
}
ZEPHIR_OBS_VAR(options);
diff --git a/ext/phalcon/crypt.zep.c b/ext/phalcon/crypt.zep.c
index 07542ae3870..ca0716ee4bc 100644
--- a/ext/phalcon/crypt.zep.c
+++ b/ext/phalcon/crypt.zep.c
@@ -70,9 +70,9 @@ ZEPHIR_INIT_CLASS(Phalcon_Crypt) {
}
/**
- * @brief Phalcon\CryptInterface Phalcon\Crypt::setPadding(int $scheme)
+ * Changes the padding scheme used
*
- * @param int scheme Padding scheme
+ * @param int scheme
*/
PHP_METHOD(Phalcon_Crypt, setPadding) {
@@ -214,13 +214,8 @@ PHP_METHOD(Phalcon_Crypt, getKey) {
}
/**
- * Adds padding @a padding_type to @a text
+ * Pads texts before encryption
*
- * @param return_value Result, possibly padded
- * @param text Message to be padded
- * @param mode Encryption mode; padding is applied only in CBC or ECB mode
- * @param block_size Cipher block size
- * @param padding_type Padding scheme
* @see http://www.di-mgt.com.au/cryptopad.html
*/
PHP_METHOD(Phalcon_Crypt, _cryptPadText) {
@@ -269,7 +264,7 @@ PHP_METHOD(Phalcon_Crypt, _cryptPadText) {
if (_0) {
paddingSize = (blockSize - (zephir_safe_mod_long_long(zephir_fast_strlen_ev(text), blockSize TSRMLS_CC)));
if (paddingSize >= 256) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Block size is bigger than 256", "phalcon/crypt.zep", 147);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Block size is bigger than 256", "phalcon/crypt.zep", 142);
return;
}
do {
@@ -378,7 +373,7 @@ PHP_METHOD(Phalcon_Crypt, _cryptPadText) {
RETURN_CTOR(text);
}
if (paddingSize > blockSize) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Invalid padding size", "phalcon/crypt.zep", 191);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Invalid padding size", "phalcon/crypt.zep", 186);
return;
}
ZEPHIR_SINIT_NVAR(_1);
@@ -671,7 +666,7 @@ PHP_METHOD(Phalcon_Crypt, encrypt) {
if (!((zephir_function_exists_ex(SS("mcrypt_get_iv_size") TSRMLS_CC) == SUCCESS))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "mcrypt extension is required", "phalcon/crypt.zep", 307);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "mcrypt extension is required", "phalcon/crypt.zep", 302);
return;
}
if (ZEPHIR_IS_STRING_IDENTICAL(key, "")) {
@@ -681,7 +676,7 @@ PHP_METHOD(Phalcon_Crypt, encrypt) {
ZEPHIR_CPY_WRT(encryptKey, key);
}
if (ZEPHIR_IS_EMPTY(encryptKey)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Encryption key cannot be empty", "phalcon/crypt.zep", 317);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Encryption key cannot be empty", "phalcon/crypt.zep", 312);
return;
}
ZEPHIR_OBS_VAR(cipher);
@@ -691,7 +686,7 @@ PHP_METHOD(Phalcon_Crypt, encrypt) {
ZEPHIR_CALL_FUNCTION(&ivSize, "mcrypt_get_iv_size", NULL, 131, cipher, mode);
zephir_check_call_status();
if (ZEPHIR_LT_LONG(ivSize, zephir_fast_strlen_ev(encryptKey))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 325);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 320);
return;
}
ZEPHIR_SINIT_VAR(_0);
@@ -767,7 +762,7 @@ PHP_METHOD(Phalcon_Crypt, decrypt) {
if (!((zephir_function_exists_ex(SS("mcrypt_get_iv_size") TSRMLS_CC) == SUCCESS))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "mcrypt extension is required", "phalcon/crypt.zep", 361);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "mcrypt extension is required", "phalcon/crypt.zep", 356);
return;
}
if (Z_TYPE_P(key) == IS_NULL) {
@@ -777,7 +772,7 @@ PHP_METHOD(Phalcon_Crypt, decrypt) {
ZEPHIR_CPY_WRT(decryptKey, key);
}
if (ZEPHIR_IS_EMPTY(decryptKey)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Decryption key cannot be empty", "phalcon/crypt.zep", 371);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Decryption key cannot be empty", "phalcon/crypt.zep", 366);
return;
}
ZEPHIR_OBS_VAR(cipher);
@@ -789,13 +784,13 @@ PHP_METHOD(Phalcon_Crypt, decrypt) {
ZEPHIR_INIT_VAR(keySize);
ZVAL_LONG(keySize, zephir_fast_strlen_ev(decryptKey));
if (ZEPHIR_GT(keySize, ivSize)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 380);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of key is too large for this algorithm", "phalcon/crypt.zep", 375);
return;
}
ZEPHIR_INIT_VAR(length);
ZVAL_LONG(length, zephir_fast_strlen_ev(text));
if (ZEPHIR_GT(keySize, length)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of IV is larger than text to decrypt", "phalcon/crypt.zep", 385);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_crypt_exception_ce, "Size of IV is larger than text to decrypt", "phalcon/crypt.zep", 380);
return;
}
ZEPHIR_INIT_VAR(_0);
diff --git a/ext/phalcon/db/adapter.zep.c b/ext/phalcon/db/adapter.zep.c
index 3742ee2e64d..f97c1d71a5a 100644
--- a/ext/phalcon/db/adapter.zep.c
+++ b/ext/phalcon/db/adapter.zep.c
@@ -253,12 +253,6 @@ PHP_METHOD(Phalcon_Db_Adapter, getDialect) {
* $robot = $connection->fecthOne("SELECT * FROM robots", Phalcon\Db::FETCH_ASSOC);
* print_r($robot);
*
- *
- * @param string sqlQuery
- * @param int fetchMode
- * @param array bindParams
- * @param array bindTypes
- * @return array
*/
PHP_METHOD(Phalcon_Db_Adapter, fetchOne) {
@@ -372,7 +366,7 @@ PHP_METHOD(Phalcon_Db_Adapter, fetchAll) {
if (!(zephir_is_true(row))) {
break;
}
- zephir_array_append(&results, row, PH_SEPARATE, "phalcon/db/adapter.zep", 249);
+ zephir_array_append(&results, row, PH_SEPARATE, "phalcon/db/adapter.zep", 243);
}
}
RETURN_CCTOR(results);
@@ -481,7 +475,7 @@ PHP_METHOD(Phalcon_Db_Adapter, insert) {
ZEPHIR_CONCAT_SVS(_1, "Unable to insert into ", table, " without data");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _1);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/db/adapter.zep", 317 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/db/adapter.zep", 312 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -491,7 +485,7 @@ PHP_METHOD(Phalcon_Db_Adapter, insert) {
array_init(insertValues);
ZEPHIR_INIT_VAR(bindDataTypes);
array_init(bindDataTypes);
- zephir_is_iterable(values, &_3, &_2, 0, 0, "phalcon/db/adapter.zep", 347);
+ zephir_is_iterable(values, &_3, &_2, 0, 0, "phalcon/db/adapter.zep", 342);
for (
; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS
; zephir_hash_move_forward_ex(_3, &_2)
@@ -500,24 +494,24 @@ PHP_METHOD(Phalcon_Db_Adapter, insert) {
ZEPHIR_GET_HVALUE(value, _4);
if (Z_TYPE_P(value) == IS_OBJECT) {
zephir_get_strval(_5, value);
- zephir_array_append(&placeholders, _5, PH_SEPARATE, "phalcon/db/adapter.zep", 330);
+ zephir_array_append(&placeholders, _5, PH_SEPARATE, "phalcon/db/adapter.zep", 325);
} else {
if (Z_TYPE_P(value) == IS_NULL) {
ZEPHIR_INIT_NVAR(_0);
ZVAL_STRING(_0, "null", 1);
- zephir_array_append(&placeholders, _0, PH_SEPARATE, "phalcon/db/adapter.zep", 333);
+ zephir_array_append(&placeholders, _0, PH_SEPARATE, "phalcon/db/adapter.zep", 328);
} else {
ZEPHIR_INIT_NVAR(_0);
ZVAL_STRING(_0, "?", 1);
- zephir_array_append(&placeholders, _0, PH_SEPARATE, "phalcon/db/adapter.zep", 335);
- zephir_array_append(&insertValues, value, PH_SEPARATE, "phalcon/db/adapter.zep", 336);
+ zephir_array_append(&placeholders, _0, PH_SEPARATE, "phalcon/db/adapter.zep", 330);
+ zephir_array_append(&insertValues, value, PH_SEPARATE, "phalcon/db/adapter.zep", 331);
if (Z_TYPE_P(dataTypes) == IS_ARRAY) {
ZEPHIR_OBS_NVAR(bindType);
if (!(zephir_array_isset_fetch(&bindType, dataTypes, position, 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Incomplete number of bind types", "phalcon/db/adapter.zep", 339);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Incomplete number of bind types", "phalcon/db/adapter.zep", 334);
return;
}
- zephir_array_append(&bindDataTypes, bindType, PH_SEPARATE, "phalcon/db/adapter.zep", 341);
+ zephir_array_append(&bindDataTypes, bindType, PH_SEPARATE, "phalcon/db/adapter.zep", 336);
}
}
}
@@ -535,7 +529,7 @@ PHP_METHOD(Phalcon_Db_Adapter, insert) {
if (ZEPHIR_GLOBAL(db).escape_identifiers) {
ZEPHIR_INIT_VAR(escapedFields);
array_init(escapedFields);
- zephir_is_iterable(fields, &_7, &_6, 0, 0, "phalcon/db/adapter.zep", 364);
+ zephir_is_iterable(fields, &_7, &_6, 0, 0, "phalcon/db/adapter.zep", 359);
for (
; zephir_hash_get_current_data_ex(_7, (void**) &_8, &_6) == SUCCESS
; zephir_hash_move_forward_ex(_7, &_6)
@@ -543,7 +537,7 @@ PHP_METHOD(Phalcon_Db_Adapter, insert) {
ZEPHIR_GET_HVALUE(field, _8);
ZEPHIR_CALL_METHOD(&_9, this_ptr, "escapeidentifier", &_10, 0, field);
zephir_check_call_status();
- zephir_array_append(&escapedFields, _9, PH_SEPARATE, "phalcon/db/adapter.zep", 362);
+ zephir_array_append(&escapedFields, _9, PH_SEPARATE, "phalcon/db/adapter.zep", 357);
}
} else {
ZEPHIR_CPY_WRT(escapedFields, fields);
@@ -614,15 +608,15 @@ PHP_METHOD(Phalcon_Db_Adapter, insertAsDict) {
if (_0) {
RETURN_MM_BOOL(0);
}
- zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/db/adapter.zep", 419);
+ zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/db/adapter.zep", 414);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
) {
ZEPHIR_GET_HMKEY(field, _2, _1);
ZEPHIR_GET_HVALUE(value, _3);
- zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/db/adapter.zep", 415);
- zephir_array_append(&values, value, PH_SEPARATE, "phalcon/db/adapter.zep", 416);
+ zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/db/adapter.zep", 410);
+ zephir_array_append(&values, value, PH_SEPARATE, "phalcon/db/adapter.zep", 411);
}
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "insert", NULL, 0, table, values, fields, dataTypes);
zephir_check_call_status();
@@ -694,7 +688,7 @@ PHP_METHOD(Phalcon_Db_Adapter, update) {
array_init(updateValues);
ZEPHIR_INIT_VAR(bindDataTypes);
array_init(bindDataTypes);
- zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/db/adapter.zep", 505);
+ zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/db/adapter.zep", 500);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -703,7 +697,7 @@ PHP_METHOD(Phalcon_Db_Adapter, update) {
ZEPHIR_GET_HVALUE(value, _2);
ZEPHIR_OBS_NVAR(field);
if (!(zephir_array_isset_fetch(&field, fields, position, 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The number of values in the update is not the same as fields", "phalcon/db/adapter.zep", 478);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The number of values in the update is not the same as fields", "phalcon/db/adapter.zep", 473);
return;
}
if (ZEPHIR_GLOBAL(db).escape_identifiers) {
@@ -715,25 +709,25 @@ PHP_METHOD(Phalcon_Db_Adapter, update) {
if (Z_TYPE_P(value) == IS_OBJECT) {
ZEPHIR_INIT_LNVAR(_4);
ZEPHIR_CONCAT_VSV(_4, escapedField, " = ", value);
- zephir_array_append(&placeholders, _4, PH_SEPARATE, "phalcon/db/adapter.zep", 488);
+ zephir_array_append(&placeholders, _4, PH_SEPARATE, "phalcon/db/adapter.zep", 483);
} else {
if (Z_TYPE_P(value) == IS_NULL) {
ZEPHIR_INIT_LNVAR(_4);
ZEPHIR_CONCAT_VS(_4, escapedField, " = null");
- zephir_array_append(&placeholders, _4, PH_SEPARATE, "phalcon/db/adapter.zep", 491);
+ zephir_array_append(&placeholders, _4, PH_SEPARATE, "phalcon/db/adapter.zep", 486);
} else {
- zephir_array_append(&updateValues, value, PH_SEPARATE, "phalcon/db/adapter.zep", 493);
+ zephir_array_append(&updateValues, value, PH_SEPARATE, "phalcon/db/adapter.zep", 488);
if (Z_TYPE_P(dataTypes) == IS_ARRAY) {
ZEPHIR_OBS_NVAR(bindType);
if (!(zephir_array_isset_fetch(&bindType, dataTypes, position, 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Incomplete number of bind types", "phalcon/db/adapter.zep", 496);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Incomplete number of bind types", "phalcon/db/adapter.zep", 491);
return;
}
- zephir_array_append(&bindDataTypes, bindType, PH_SEPARATE, "phalcon/db/adapter.zep", 498);
+ zephir_array_append(&bindDataTypes, bindType, PH_SEPARATE, "phalcon/db/adapter.zep", 493);
}
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_VS(_5, escapedField, " = ?");
- zephir_array_append(&placeholders, _5, PH_SEPARATE, "phalcon/db/adapter.zep", 500);
+ zephir_array_append(&placeholders, _5, PH_SEPARATE, "phalcon/db/adapter.zep", 495);
}
}
}
@@ -752,7 +746,7 @@ PHP_METHOD(Phalcon_Db_Adapter, update) {
zephir_concat_self(&updateSql, whereCondition TSRMLS_CC);
} else {
if (Z_TYPE_P(whereCondition) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Invalid WHERE clause conditions", "phalcon/db/adapter.zep", 528);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Invalid WHERE clause conditions", "phalcon/db/adapter.zep", 523);
return;
}
ZEPHIR_OBS_VAR(conditions);
@@ -836,15 +830,15 @@ PHP_METHOD(Phalcon_Db_Adapter, updateAsDict) {
if (_0) {
RETURN_MM_BOOL(0);
}
- zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/db/adapter.zep", 604);
+ zephir_is_iterable(data, &_2, &_1, 0, 0, "phalcon/db/adapter.zep", 599);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
) {
ZEPHIR_GET_HMKEY(field, _2, _1);
ZEPHIR_GET_HVALUE(value, _3);
- zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/db/adapter.zep", 600);
- zephir_array_append(&values, value, PH_SEPARATE, "phalcon/db/adapter.zep", 601);
+ zephir_array_append(&fields, field, PH_SEPARATE, "phalcon/db/adapter.zep", 595);
+ zephir_array_append(&values, value, PH_SEPARATE, "phalcon/db/adapter.zep", 596);
}
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "update", NULL, 0, table, fields, values, whereCondition, dataTypes);
zephir_check_call_status();
@@ -974,9 +968,9 @@ PHP_METHOD(Phalcon_Db_Adapter, limit) {
/**
* Generates SQL checking for the existence of a schema.table
*
- *
+ *
* var_dump($connection->tableExists("blog", "posts"));
- *
+ *
*/
PHP_METHOD(Phalcon_Db_Adapter, tableExists) {
@@ -1023,7 +1017,7 @@ PHP_METHOD(Phalcon_Db_Adapter, tableExists) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchone", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_array_fetch_long(&_4, _0, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 681 TSRMLS_CC);
+ zephir_array_fetch_long(&_4, _0, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 676 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_GT_LONG(_4, 0));
}
@@ -1080,7 +1074,7 @@ PHP_METHOD(Phalcon_Db_Adapter, viewExists) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchone", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_array_fetch_long(&_4, _0, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 693 TSRMLS_CC);
+ zephir_array_fetch_long(&_4, _0, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 688 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_GT_LONG(_4, 0));
}
@@ -1190,11 +1184,11 @@ PHP_METHOD(Phalcon_Db_Adapter, createTable) {
ZEPHIR_OBS_VAR(columns);
if (!(zephir_array_isset_string_fetch(&columns, definition, SS("columns"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 720);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 715);
return;
}
if (!(zephir_fast_count_int(columns TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 724);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 719);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dialect"), PH_NOISY_CC);
@@ -1263,12 +1257,7 @@ PHP_METHOD(Phalcon_Db_Adapter, dropTable) {
}
/**
- * Creates a view
- *
- * @param string tableName
- * @param array definition
- * @param string schemaName
- * @return boolean
+ * Creates a view
*/
PHP_METHOD(Phalcon_Db_Adapter, createView) {
@@ -1299,7 +1288,7 @@ PHP_METHOD(Phalcon_Db_Adapter, createView) {
if (!(zephir_array_isset_string(definition, SS("sql")))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 749);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The table must contain at least one column", "phalcon/db/adapter.zep", 739);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dialect"), PH_NOISY_CC);
@@ -1852,14 +1841,14 @@ PHP_METHOD(Phalcon_Db_Adapter, listTables) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchall", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 858);
+ zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 848);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
) {
ZEPHIR_GET_HVALUE(table, _6);
- zephir_array_fetch_long(&_7, table, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 856 TSRMLS_CC);
- zephir_array_append(&allTables, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 856);
+ zephir_array_fetch_long(&_7, table, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 846 TSRMLS_CC);
+ zephir_array_append(&allTables, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 846);
}
RETURN_CCTOR(allTables);
@@ -1910,14 +1899,14 @@ PHP_METHOD(Phalcon_Db_Adapter, listViews) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchall", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 876);
+ zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 866);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
) {
ZEPHIR_GET_HVALUE(table, _6);
- zephir_array_fetch_long(&_7, table, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 874 TSRMLS_CC);
- zephir_array_append(&allTables, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 874);
+ zephir_array_fetch_long(&_7, table, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 864 TSRMLS_CC);
+ zephir_array_append(&allTables, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 864);
}
RETURN_CCTOR(allTables);
@@ -1971,27 +1960,27 @@ PHP_METHOD(Phalcon_Db_Adapter, describeIndexes) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchall", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 908);
+ zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 898);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
) {
ZEPHIR_GET_HVALUE(index, _6);
- zephir_array_fetch_long(&keyName, index, 2, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 897 TSRMLS_CC);
+ zephir_array_fetch_long(&keyName, index, 2, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 887 TSRMLS_CC);
if (!(zephir_array_isset(indexes, keyName))) {
ZEPHIR_INIT_NVAR(columns);
array_init(columns);
} else {
ZEPHIR_OBS_NVAR(columns);
- zephir_array_fetch(&columns, indexes, keyName, PH_NOISY, "phalcon/db/adapter.zep", 901 TSRMLS_CC);
+ zephir_array_fetch(&columns, indexes, keyName, PH_NOISY, "phalcon/db/adapter.zep", 891 TSRMLS_CC);
}
- zephir_array_fetch_long(&_7, index, 4, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 904 TSRMLS_CC);
- zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 904);
+ zephir_array_fetch_long(&_7, index, 4, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 894 TSRMLS_CC);
+ zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 894);
zephir_array_update_zval(&indexes, keyName, &columns, PH_COPY | PH_SEPARATE);
}
ZEPHIR_INIT_VAR(indexObjects);
array_init(indexObjects);
- zephir_is_iterable(indexes, &_9, &_8, 0, 0, "phalcon/db/adapter.zep", 917);
+ zephir_is_iterable(indexes, &_9, &_8, 0, 0, "phalcon/db/adapter.zep", 907);
for (
; zephir_hash_get_current_data_ex(_9, (void**) &_10, &_8) == SUCCESS
; zephir_hash_move_forward_ex(_9, &_8)
@@ -2066,40 +2055,40 @@ PHP_METHOD(Phalcon_Db_Adapter, describeReferences) {
ZVAL_LONG(_3, 3);
ZEPHIR_CALL_METHOD(&_0, this_ptr, "fetchall", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 961);
+ zephir_is_iterable(_0, &_5, &_4, 0, 0, "phalcon/db/adapter.zep", 951);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
) {
ZEPHIR_GET_HVALUE(reference, _6);
- zephir_array_fetch_long(&constraintName, reference, 2, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 937 TSRMLS_CC);
+ zephir_array_fetch_long(&constraintName, reference, 2, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 927 TSRMLS_CC);
if (!(zephir_array_isset(references, constraintName))) {
ZEPHIR_OBS_NVAR(referencedSchema);
- zephir_array_fetch_long(&referencedSchema, reference, 3, PH_NOISY, "phalcon/db/adapter.zep", 939 TSRMLS_CC);
+ zephir_array_fetch_long(&referencedSchema, reference, 3, PH_NOISY, "phalcon/db/adapter.zep", 929 TSRMLS_CC);
ZEPHIR_OBS_NVAR(referencedTable);
- zephir_array_fetch_long(&referencedTable, reference, 4, PH_NOISY, "phalcon/db/adapter.zep", 940 TSRMLS_CC);
+ zephir_array_fetch_long(&referencedTable, reference, 4, PH_NOISY, "phalcon/db/adapter.zep", 930 TSRMLS_CC);
ZEPHIR_INIT_NVAR(columns);
array_init(columns);
ZEPHIR_INIT_NVAR(referencedColumns);
array_init(referencedColumns);
} else {
- zephir_array_fetch(&_7, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 944 TSRMLS_CC);
+ zephir_array_fetch(&_7, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 934 TSRMLS_CC);
ZEPHIR_OBS_NVAR(referencedSchema);
- zephir_array_fetch_string(&referencedSchema, _7, SL("referencedSchema"), PH_NOISY, "phalcon/db/adapter.zep", 944 TSRMLS_CC);
- zephir_array_fetch(&_8, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 945 TSRMLS_CC);
+ zephir_array_fetch_string(&referencedSchema, _7, SL("referencedSchema"), PH_NOISY, "phalcon/db/adapter.zep", 934 TSRMLS_CC);
+ zephir_array_fetch(&_8, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 935 TSRMLS_CC);
ZEPHIR_OBS_NVAR(referencedTable);
- zephir_array_fetch_string(&referencedTable, _8, SL("referencedTable"), PH_NOISY, "phalcon/db/adapter.zep", 945 TSRMLS_CC);
- zephir_array_fetch(&_9, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 946 TSRMLS_CC);
+ zephir_array_fetch_string(&referencedTable, _8, SL("referencedTable"), PH_NOISY, "phalcon/db/adapter.zep", 935 TSRMLS_CC);
+ zephir_array_fetch(&_9, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 936 TSRMLS_CC);
ZEPHIR_OBS_NVAR(columns);
- zephir_array_fetch_string(&columns, _9, SL("columns"), PH_NOISY, "phalcon/db/adapter.zep", 946 TSRMLS_CC);
- zephir_array_fetch(&_10, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 947 TSRMLS_CC);
+ zephir_array_fetch_string(&columns, _9, SL("columns"), PH_NOISY, "phalcon/db/adapter.zep", 936 TSRMLS_CC);
+ zephir_array_fetch(&_10, references, constraintName, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 937 TSRMLS_CC);
ZEPHIR_OBS_NVAR(referencedColumns);
- zephir_array_fetch_string(&referencedColumns, _10, SL("referencedColumns"), PH_NOISY, "phalcon/db/adapter.zep", 947 TSRMLS_CC);
+ zephir_array_fetch_string(&referencedColumns, _10, SL("referencedColumns"), PH_NOISY, "phalcon/db/adapter.zep", 937 TSRMLS_CC);
}
- zephir_array_fetch_long(&_7, reference, 1, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 950 TSRMLS_CC);
- zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 950);
- zephir_array_fetch_long(&_8, reference, 5, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 951 TSRMLS_CC);
- zephir_array_append(&referencedColumns, _8, PH_SEPARATE, "phalcon/db/adapter.zep", 951);
+ zephir_array_fetch_long(&_7, reference, 1, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 940 TSRMLS_CC);
+ zephir_array_append(&columns, _7, PH_SEPARATE, "phalcon/db/adapter.zep", 940);
+ zephir_array_fetch_long(&_8, reference, 5, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 941 TSRMLS_CC);
+ zephir_array_append(&referencedColumns, _8, PH_SEPARATE, "phalcon/db/adapter.zep", 941);
ZEPHIR_INIT_NVAR(_11);
zephir_create_array(_11, 4, 0 TSRMLS_CC);
zephir_array_update_string(&_11, SL("referencedSchema"), &referencedSchema, PH_COPY | PH_SEPARATE);
@@ -2110,7 +2099,7 @@ PHP_METHOD(Phalcon_Db_Adapter, describeReferences) {
}
ZEPHIR_INIT_VAR(referenceObjects);
array_init(referenceObjects);
- zephir_is_iterable(references, &_13, &_12, 0, 0, "phalcon/db/adapter.zep", 971);
+ zephir_is_iterable(references, &_13, &_12, 0, 0, "phalcon/db/adapter.zep", 961);
for (
; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS
; zephir_hash_move_forward_ex(_13, &_12)
@@ -2122,16 +2111,16 @@ PHP_METHOD(Phalcon_Db_Adapter, describeReferences) {
ZEPHIR_INIT_NVAR(_11);
zephir_create_array(_11, 4, 0 TSRMLS_CC);
ZEPHIR_OBS_NVAR(_15);
- zephir_array_fetch_string(&_15, arrayReference, SL("referencedSchema"), PH_NOISY, "phalcon/db/adapter.zep", 964 TSRMLS_CC);
+ zephir_array_fetch_string(&_15, arrayReference, SL("referencedSchema"), PH_NOISY, "phalcon/db/adapter.zep", 954 TSRMLS_CC);
zephir_array_update_string(&_11, SL("referencedSchema"), &_15, PH_COPY | PH_SEPARATE);
ZEPHIR_OBS_NVAR(_15);
- zephir_array_fetch_string(&_15, arrayReference, SL("referencedTable"), PH_NOISY, "phalcon/db/adapter.zep", 965 TSRMLS_CC);
+ zephir_array_fetch_string(&_15, arrayReference, SL("referencedTable"), PH_NOISY, "phalcon/db/adapter.zep", 955 TSRMLS_CC);
zephir_array_update_string(&_11, SL("referencedTable"), &_15, PH_COPY | PH_SEPARATE);
ZEPHIR_OBS_NVAR(_15);
- zephir_array_fetch_string(&_15, arrayReference, SL("columns"), PH_NOISY, "phalcon/db/adapter.zep", 966 TSRMLS_CC);
+ zephir_array_fetch_string(&_15, arrayReference, SL("columns"), PH_NOISY, "phalcon/db/adapter.zep", 956 TSRMLS_CC);
zephir_array_update_string(&_11, SL("columns"), &_15, PH_COPY | PH_SEPARATE);
ZEPHIR_OBS_NVAR(_15);
- zephir_array_fetch_string(&_15, arrayReference, SL("referencedColumns"), PH_NOISY, "phalcon/db/adapter.zep", 968 TSRMLS_CC);
+ zephir_array_fetch_string(&_15, arrayReference, SL("referencedColumns"), PH_NOISY, "phalcon/db/adapter.zep", 958 TSRMLS_CC);
zephir_array_update_string(&_11, SL("referencedColumns"), &_15, PH_COPY | PH_SEPARATE);
ZEPHIR_CALL_METHOD(NULL, _3, "__construct", &_16, 16, name, _11);
zephir_check_call_status();
@@ -2184,7 +2173,7 @@ PHP_METHOD(Phalcon_Db_Adapter, tableOptions) {
ZVAL_LONG(_2, 2);
ZEPHIR_CALL_METHOD(&_1, this_ptr, "fetchall", NULL, 0, sql, _2);
zephir_check_call_status();
- zephir_array_fetch_long(&_3, _1, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 987 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, _1, 0, PH_NOISY | PH_READONLY, "phalcon/db/adapter.zep", 977 TSRMLS_CC);
RETURN_CTOR(_3);
}
array_init(return_value);
@@ -2222,7 +2211,7 @@ PHP_METHOD(Phalcon_Db_Adapter, createSavepoint) {
ZEPHIR_CALL_METHOD(&_0, dialect, "supportssavepoints", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_0))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter.", "phalcon/db/adapter.zep", 1002);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter.", "phalcon/db/adapter.zep", 992);
return;
}
ZEPHIR_CALL_METHOD(&_1, dialect, "createsavepoint", NULL, 0, name);
@@ -2263,7 +2252,7 @@ PHP_METHOD(Phalcon_Db_Adapter, releaseSavepoint) {
ZEPHIR_CALL_METHOD(&_0, dialect, "supportssavepoints", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_0))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1018);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1008);
return;
}
ZEPHIR_CALL_METHOD(&_1, dialect, "supportsreleasesavepoints", NULL, 0);
@@ -2309,7 +2298,7 @@ PHP_METHOD(Phalcon_Db_Adapter, rollbackSavepoint) {
ZEPHIR_CALL_METHOD(&_0, dialect, "supportssavepoints", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_0))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1038);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1028);
return;
}
ZEPHIR_CALL_METHOD(&_1, dialect, "rollbacksavepoint", NULL, 0, name);
@@ -2337,14 +2326,14 @@ PHP_METHOD(Phalcon_Db_Adapter, setNestedTransactionsWithSavepoints) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_transactionLevel"), PH_NOISY_CC);
if (ZEPHIR_GT_LONG(_0, 0)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Nested transaction with savepoints behavior cannot be changed while a transaction is open", "phalcon/db/adapter.zep", 1051);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Nested transaction with savepoints behavior cannot be changed while a transaction is open", "phalcon/db/adapter.zep", 1041);
return;
}
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_dialect"), PH_NOISY_CC);
ZEPHIR_CALL_METHOD(&_2, _1, "supportssavepoints", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_2))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1055);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Savepoints are not supported by this database adapter", "phalcon/db/adapter.zep", 1045);
return;
}
zephir_update_property_this(this_ptr, SL("_transactionsWithSavepoints"), nestedTransactionsWithSavepoints ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
diff --git a/ext/phalcon/db/dialect.zep.c b/ext/phalcon/db/dialect.zep.c
index 67c2ec9e224..82f70df8fee 100644
--- a/ext/phalcon/db/dialect.zep.c
+++ b/ext/phalcon/db/dialect.zep.c
@@ -1614,11 +1614,10 @@ PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionGroupBy) {
if (unlikely(Z_TYPE_P(filed) != IS_ARRAY)) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Invalid SQL-GROUP-BY expression", "phalcon/db/dialect.zep", 829);
return;
- } else {
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqlexpression", &_4, 0, filed, escapeChar, bindCounts);
- zephir_check_call_status();
- zephir_array_append(&fields, _3, PH_SEPARATE, "phalcon/db/dialect.zep", 831);
}
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "getsqlexpression", &_4, 0, filed, escapeChar, bindCounts);
+ zephir_check_call_status();
+ zephir_array_append(&fields, _3, PH_SEPARATE, "phalcon/db/dialect.zep", 832);
}
ZEPHIR_INIT_VAR(_5);
zephir_fast_join_str(_5, SL(", "), fields TSRMLS_CC);
@@ -1706,11 +1705,10 @@ PHP_METHOD(Phalcon_Db_Dialect, getSqlExpressionOrderBy) {
if (unlikely(Z_TYPE_P(filed) != IS_ARRAY)) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Invalid SQL-ORDER-BY expression", "phalcon/db/dialect.zep", 870);
return;
- } else {
- zephir_array_fetch_long(&_3, filed, 0, PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 872 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&fieldSql, this_ptr, "getsqlexpression", &_4, 0, _3, escapeChar, bindCounts);
- zephir_check_call_status();
}
+ zephir_array_fetch_long(&_3, filed, 0, PH_NOISY | PH_READONLY, "phalcon/db/dialect.zep", 873 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&fieldSql, this_ptr, "getsqlexpression", &_4, 0, _3, escapeChar, bindCounts);
+ zephir_check_call_status();
ZEPHIR_OBS_NVAR(type);
_5 = zephir_array_isset_long_fetch(&type, filed, 1, 0 TSRMLS_CC);
if (_5) {
diff --git a/ext/phalcon/db/dialect/mysql.zep.c b/ext/phalcon/db/dialect/mysql.zep.c
index 97e5e878faf..f4928ac3dd0 100644
--- a/ext/phalcon/db/dialect/mysql.zep.c
+++ b/ext/phalcon/db/dialect/mysql.zep.c
@@ -153,15 +153,14 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) {
if (zephir_is_true(size)) {
ZEPHIR_CALL_METHOD(&scale, column, "getscale", NULL, 0);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_1);
- ZEPHIR_CONCAT_SV(_1, "(", size);
- zephir_concat_self(&columnSql, _1 TSRMLS_CC);
if (zephir_is_true(scale)) {
+ ZEPHIR_INIT_LNVAR(_1);
+ ZEPHIR_CONCAT_SVSVS(_1, "(", size, ",", scale, ")");
+ zephir_concat_self(&columnSql, _1 TSRMLS_CC);
+ } else {
ZEPHIR_INIT_VAR(_4);
- ZEPHIR_CONCAT_SVS(_4, ",", scale, ")");
+ ZEPHIR_CONCAT_SVS(_4, "(", size, ")");
zephir_concat_self(&columnSql, _4 TSRMLS_CC);
- } else {
- zephir_concat_self_str(&columnSql, SL(")") TSRMLS_CC);
}
}
ZEPHIR_CALL_METHOD(&_0, column, "isunsigned", NULL, 0);
@@ -243,7 +242,7 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) {
break;
}
if (ZEPHIR_IS_EMPTY(columnSql)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Unrecognized MySQL data type", "phalcon/db/dialect/mysql.zep", 192);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Unrecognized MySQL data type", "phalcon/db/dialect/mysql.zep", 191);
return;
}
ZEPHIR_CALL_METHOD(&typeValues, column, "gettypevalues", NULL, 0);
@@ -252,7 +251,7 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) {
if (Z_TYPE_P(typeValues) == IS_ARRAY) {
ZEPHIR_INIT_VAR(valueSql);
ZVAL_STRING(valueSql, "", 1);
- zephir_is_iterable(typeValues, &_6, &_5, 0, 0, "phalcon/db/dialect/mysql.zep", 203);
+ zephir_is_iterable(typeValues, &_6, &_5, 0, 0, "phalcon/db/dialect/mysql.zep", 202);
for (
; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS
; zephir_hash_move_forward_ex(_6, &_5)
@@ -297,8 +296,8 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, getColumnDefinition) {
PHP_METHOD(Phalcon_Db_Dialect_MySQL, addColumn) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *afterPosition = NULL, *sql = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *afterPosition = NULL, *sql, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, _3, *_4 = NULL, *_5 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &column);
@@ -327,50 +326,41 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, addColumn) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` ADD ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` ADD ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumndefinition", NULL, 0, column);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVSV(_3, "`", _1, "` ", _2);
- zephir_concat_self(&sql, _3 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(sql);
+ ZEPHIR_CONCAT_SVSVSV(sql, "ALTER TABLE ", _0, " ADD `", _1, "` ", _2);
ZEPHIR_CALL_METHOD(&defaultValue, column, "getdefault", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(defaultValue))) {
- ZEPHIR_SINIT_VAR(_4);
- ZVAL_STRING(&_4, "\"", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 141, defaultValue, &_4);
+ ZEPHIR_SINIT_VAR(_3);
+ ZVAL_STRING(&_3, "\"", 0);
+ ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 141, defaultValue, &_3);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_6);
- ZEPHIR_CONCAT_SVS(_6, " DEFAULT \"", _5, "\"");
- zephir_concat_self(&sql, _6 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_5);
+ ZEPHIR_CONCAT_SVS(_5, " DEFAULT \"", _4, "\"");
+ zephir_concat_self(&sql, _5 TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_5, column, "isnotnull", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, column, "isnotnull", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_5)) {
+ if (zephir_is_true(_4)) {
zephir_concat_self_str(&sql, SL(" NOT NULL") TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_5, column, "isfirst", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, column, "isfirst", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_5)) {
+ if (zephir_is_true(_4)) {
zephir_concat_self_str(&sql, SL(" FIRST") TSRMLS_CC);
} else {
ZEPHIR_CALL_METHOD(&afterPosition, column, "getafterposition", NULL, 0);
zephir_check_call_status();
if (zephir_is_true(afterPosition)) {
- ZEPHIR_INIT_LNVAR(_6);
- ZEPHIR_CONCAT_SV(_6, " AFTER ", afterPosition);
- zephir_concat_self(&sql, _6 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_5);
+ ZEPHIR_CONCAT_SV(_5, " AFTER ", afterPosition);
+ zephir_concat_self(&sql, _5 TSRMLS_CC);
}
}
RETURN_CCTOR(sql);
@@ -383,8 +373,8 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, addColumn) {
PHP_METHOD(Phalcon_Db_Dialect_MySQL, modifyColumn) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *currentColumn = NULL, *sql = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *currentColumn = NULL, *sql, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, _3, *_4 = NULL, *_5;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 1, &tableName_param, &schemaName_param, &column, ¤tColumn);
@@ -416,37 +406,28 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, modifyColumn) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` MODIFY ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` MODIFY ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumndefinition", NULL, 0, column);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVSV(_3, "`", _1, "` ", _2);
- zephir_concat_self(&sql, _3 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(sql);
+ ZEPHIR_CONCAT_SVSVSV(sql, "ALTER TABLE ", _0, " MODIFY `", _1, "` ", _2);
ZEPHIR_CALL_METHOD(&defaultValue, column, "getdefault", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(defaultValue))) {
- ZEPHIR_SINIT_VAR(_4);
- ZVAL_STRING(&_4, "\"", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "addcslashes", NULL, 141, defaultValue, &_4);
+ ZEPHIR_SINIT_VAR(_3);
+ ZVAL_STRING(&_3, "\"", 0);
+ ZEPHIR_CALL_FUNCTION(&_4, "addcslashes", NULL, 141, defaultValue, &_3);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_6);
- ZEPHIR_CONCAT_SVS(_6, " DEFAULT \"", _5, "\"");
- zephir_concat_self(&sql, _6 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_5);
+ ZEPHIR_CONCAT_SVS(_5, " DEFAULT \"", _4, "\"");
+ zephir_concat_self(&sql, _5 TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_5, column, "isnotnull", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, column, "isnotnull", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_5)) {
+ if (zephir_is_true(_4)) {
zephir_concat_self_str(&sql, SL(" NOT NULL") TSRMLS_CC);
}
RETURN_CCTOR(sql);
@@ -458,8 +439,9 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, modifyColumn) {
*/
PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropColumn) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *columnName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *columnName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *columnName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *columnName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &columnName_param);
@@ -499,20 +481,10 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropColumn) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` DROP COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` DROP COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", columnName, "`");
- zephir_concat_self(&sql, _0 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP COLUMN `", columnName, "`");
+ RETURN_MM();
}
@@ -522,8 +494,8 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropColumn) {
PHP_METHOD(Phalcon_Db_Dialect_MySQL, addIndex) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql = NULL, *indexType = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql, *indexType = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
@@ -552,24 +524,18 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, addIndex) {
}
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSV(_0, "ALTER TABLE `", schemaName, "`.`", tableName);
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SV(_0, "ALTER TABLE `", tableName);
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CONCAT_SV(sql, "ALTER TABLE ", _0);
ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(indexType))) {
ZEPHIR_INIT_VAR(_1);
- ZEPHIR_CONCAT_SVS(_1, "` ADD ", indexType, " INDEX ");
+ ZEPHIR_CONCAT_SVS(_1, " ADD ", indexType, " INDEX ");
zephir_concat_self(&sql, _1 TSRMLS_CC);
} else {
- zephir_concat_self_str(&sql, SL("` ADD INDEX ") TSRMLS_CC);
+ zephir_concat_self_str(&sql, SL(" ADD INDEX ") TSRMLS_CC);
}
ZEPHIR_CALL_METHOD(&_2, index, "getname", NULL, 0);
zephir_check_call_status();
@@ -589,8 +555,9 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, addIndex) {
*/
PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropIndex) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *indexName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *indexName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *indexName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *indexName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &indexName_param);
@@ -630,20 +597,10 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropIndex) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` DROP INDEX ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` DROP INDEX ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", indexName, "`");
- zephir_concat_self(&sql, _0 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP INDEX `", indexName, "`");
+ RETURN_MM();
}
@@ -653,8 +610,8 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropIndex) {
PHP_METHOD(Phalcon_Db_Dialect_MySQL, addPrimaryKey) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql = NULL, *_1 = NULL, *_2 = NULL, *_3;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *index, *_0 = NULL, *_1 = NULL, *_2 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
@@ -683,24 +640,14 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, addPrimaryKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` ADD PRIMARY KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` ADD PRIMARY KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 43, _2);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVS(_3, "(", _1, ")");
- zephir_concat_self(&sql, _3 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " ADD PRIMARY KEY (", _1, ")");
+ RETURN_MM();
}
@@ -709,8 +656,9 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, addPrimaryKey) {
*/
PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropPrimaryKey) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 0, &tableName_param, &schemaName_param);
@@ -739,17 +687,10 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropPrimaryKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` DROP PRIMARY KEY");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` DROP PRIMARY KEY");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVS(return_value, "ALTER TABLE ", _0, " DROP PRIMARY KEY");
+ RETURN_MM();
}
@@ -759,8 +700,8 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropPrimaryKey) {
PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *reference, *sql = NULL, *referencedSchema = NULL, *onDelete = NULL, *onUpdate = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *reference, *sql, *onDelete = NULL, *onUpdate = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &reference);
@@ -789,41 +730,26 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` ADD FOREIGN KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` ADD FOREIGN KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, reference, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_3, reference, "getcolumns", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumnlist", NULL, 43, _3);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_4);
- ZEPHIR_CONCAT_SVSVS(_4, "`", _1, "`(", _2, ") REFERENCES ");
- zephir_concat_self(&sql, _4 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&referencedSchema, reference, "getreferencedschema", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_5, reference, "getreferencedtable", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(referencedSchema)) {
- ZEPHIR_INIT_VAR(_5);
- ZEPHIR_CONCAT_SVS(_5, "`", referencedSchema, "`.");
- zephir_concat_self(&sql, _5 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_6, reference, "getreferencedtable", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_6, reference, "getreferencedschema", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "preparetable", NULL, 0, _5, _6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_8, reference, "getreferencedcolumns", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", NULL, 43, _8);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_5);
- ZEPHIR_CONCAT_SVSVS(_5, "`", _6, "`(", _7, ")");
- zephir_concat_self(&sql, _5 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(sql);
+ ZEPHIR_CONCAT_SVSVSVSVSVS(sql, "ALTER TABLE ", _0, " ADD FOREIGN KEY `", _1, "`(", _2, ") REFERENCES ", _4, "(", _7, ")");
ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onDelete))) {
@@ -834,9 +760,9 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) {
ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onUpdate))) {
- ZEPHIR_INIT_LNVAR(_5);
- ZEPHIR_CONCAT_SV(_5, " ON UPDATE ", onUpdate);
- zephir_concat_self(&sql, _5 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SV(_9, " ON UPDATE ", onUpdate);
+ zephir_concat_self(&sql, _9 TSRMLS_CC);
}
RETURN_CCTOR(sql);
@@ -847,8 +773,9 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, addForeignKey) {
*/
PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropForeignKey) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *referenceName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *referenceName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *referenceName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *referenceName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &referenceName_param);
@@ -888,17 +815,9 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropForeignKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE `", schemaName, "`.`", tableName, "` DROP FOREIGN KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE `", tableName, "` DROP FOREIGN KEY ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_CONCAT_VSVS(return_value, sql, "`", referenceName, "`");
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP FOREIGN KEY `", referenceName, "`");
RETURN_MM();
}
@@ -908,13 +827,13 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropForeignKey) {
*/
PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) {
- zephir_fcall_cache_entry *_6 = NULL, *_9 = NULL, *_14 = NULL;
+ zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_13 = NULL;
+ HashTable *_1, *_11, *_17;
+ HashPosition _0, _10, _16;
int ZEPHIR_LAST_CALL_STATUS;
- HashTable *_2, *_12, *_18;
- HashPosition _1, _11, _17;
zval *definition = NULL;
- zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, **_3, *_4 = NULL, *_5 = NULL, _7 = zval_used_for_init, *_8 = NULL, *_10 = NULL, **_13, *_15 = NULL, *_16 = NULL, **_19, *_20 = NULL, *_21 = NULL, *_22;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, **_2, *_3 = NULL, *_4 = NULL, _6 = zval_used_for_init, *_7 = NULL, *_9 = NULL, **_12, *_14 = NULL, *_15 = NULL, **_18, *_19 = NULL, *_20 = NULL, *_21;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &definition_param);
@@ -947,19 +866,11 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) {
ZEPHIR_OBS_VAR(columns);
if (!(zephir_array_isset_string_fetch(&columns, definition, SS("columns"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'columns' is required in the definition array", "phalcon/db/dialect/mysql.zep", 424);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'columns' is required in the definition array", "phalcon/db/dialect/mysql.zep", 354);
return;
}
- ZEPHIR_INIT_VAR(table);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "`", schemaName, "`.`", tableName, "`");
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", tableName, "`");
- ZEPHIR_CPY_WRT(table, _0);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(temporary);
ZVAL_BOOL(temporary, 0);
ZEPHIR_OBS_VAR(options);
@@ -975,134 +886,134 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) {
}
ZEPHIR_INIT_VAR(createLines);
array_init(createLines);
- zephir_is_iterable(columns, &_2, &_1, 0, 0, "phalcon/db/dialect/mysql.zep", 487);
+ zephir_is_iterable(columns, &_1, &_0, 0, 0, "phalcon/db/dialect/mysql.zep", 413);
for (
- ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
- ; zephir_hash_move_forward_ex(_2, &_1)
+ ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
+ ; zephir_hash_move_forward_ex(_1, &_0)
) {
- ZEPHIR_GET_HVALUE(column, _3);
- ZEPHIR_CALL_METHOD(&_4, column, "getname", NULL, 0);
+ ZEPHIR_GET_HVALUE(column, _2);
+ ZEPHIR_CALL_METHOD(&_3, column, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumndefinition", &_6, 0, column);
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumndefinition", &_5, 0, column);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(columnLine);
- ZEPHIR_CONCAT_SVSV(columnLine, "`", _4, "` ", _5);
+ ZEPHIR_CONCAT_SVSV(columnLine, "`", _3, "` ", _4);
ZEPHIR_CALL_METHOD(&defaultValue, column, "getdefault", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(defaultValue))) {
- ZEPHIR_SINIT_NVAR(_7);
- ZVAL_STRING(&_7, "\"", 0);
- ZEPHIR_CALL_FUNCTION(&_8, "addcslashes", &_9, 141, defaultValue, &_7);
+ ZEPHIR_SINIT_NVAR(_6);
+ ZVAL_STRING(&_6, "\"", 0);
+ ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 141, defaultValue, &_6);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SVS(_10, " DEFAULT \"", _8, "\"");
- zephir_concat_self(&columnLine, _10 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, " DEFAULT \"", _7, "\"");
+ zephir_concat_self(&columnLine, _9 TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isnotnull", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isnotnull", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
zephir_concat_self_str(&columnLine, SL(" NOT NULL") TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isautoincrement", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isautoincrement", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
zephir_concat_self_str(&columnLine, SL(" AUTO_INCREMENT") TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isprimary", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isprimary", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
zephir_concat_self_str(&columnLine, SL(" PRIMARY KEY") TSRMLS_CC);
}
- zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 481);
+ zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 407);
}
ZEPHIR_OBS_VAR(indexes);
if (zephir_array_isset_string_fetch(&indexes, definition, SS("indexes"), 0 TSRMLS_CC)) {
- zephir_is_iterable(indexes, &_12, &_11, 0, 0, "phalcon/db/dialect/mysql.zep", 509);
+ zephir_is_iterable(indexes, &_11, &_10, 0, 0, "phalcon/db/dialect/mysql.zep", 435);
for (
- ; zephir_hash_get_current_data_ex(_12, (void**) &_13, &_11) == SUCCESS
- ; zephir_hash_move_forward_ex(_12, &_11)
+ ; zephir_hash_get_current_data_ex(_11, (void**) &_12, &_10) == SUCCESS
+ ; zephir_hash_move_forward_ex(_11, &_10)
) {
- ZEPHIR_GET_HVALUE(index, _13);
+ ZEPHIR_GET_HVALUE(index, _12);
ZEPHIR_CALL_METHOD(&indexName, index, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
zephir_check_call_status();
if (ZEPHIR_IS_STRING(indexName, "PRIMARY")) {
- ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_14, 43, _5);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_13, 43, _4);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(indexSql);
- ZEPHIR_CONCAT_SVS(indexSql, "PRIMARY KEY (", _4, ")");
+ ZEPHIR_CONCAT_SVS(indexSql, "PRIMARY KEY (", _3, ")");
} else {
ZEPHIR_INIT_NVAR(indexSql);
if (!(ZEPHIR_IS_EMPTY(indexType))) {
- ZEPHIR_CALL_METHOD(&_15, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_14, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, this_ptr, "getcolumnlist", &_14, 43, _15);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_13, 43, _14);
zephir_check_call_status();
- ZEPHIR_CONCAT_VSVSVS(indexSql, indexType, " KEY `", indexName, "` (", _8, ")");
+ ZEPHIR_CONCAT_VSVSVS(indexSql, indexType, " KEY `", indexName, "` (", _7, ")");
} else {
- ZEPHIR_CALL_METHOD(&_16, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_15, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", &_14, 43, _16);
+ ZEPHIR_CALL_METHOD(&_14, this_ptr, "getcolumnlist", &_13, 43, _15);
zephir_check_call_status();
- ZEPHIR_CONCAT_SVSVS(indexSql, "KEY `", indexName, "` (", _15, ")");
+ ZEPHIR_CONCAT_SVSVS(indexSql, "KEY `", indexName, "` (", _14, ")");
}
}
- zephir_array_append(&createLines, indexSql, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 507);
+ zephir_array_append(&createLines, indexSql, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 433);
}
}
ZEPHIR_OBS_VAR(references);
if (zephir_array_isset_string_fetch(&references, definition, SS("references"), 0 TSRMLS_CC)) {
- zephir_is_iterable(references, &_18, &_17, 0, 0, "phalcon/db/dialect/mysql.zep", 531);
+ zephir_is_iterable(references, &_17, &_16, 0, 0, "phalcon/db/dialect/mysql.zep", 457);
for (
- ; zephir_hash_get_current_data_ex(_18, (void**) &_19, &_17) == SUCCESS
- ; zephir_hash_move_forward_ex(_18, &_17)
+ ; zephir_hash_get_current_data_ex(_17, (void**) &_18, &_16) == SUCCESS
+ ; zephir_hash_move_forward_ex(_17, &_16)
) {
- ZEPHIR_GET_HVALUE(reference, _19);
- ZEPHIR_CALL_METHOD(&_4, reference, "getname", NULL, 0);
+ ZEPHIR_GET_HVALUE(reference, _18);
+ ZEPHIR_CALL_METHOD(&_3, reference, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, reference, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, reference, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", &_14, 43, _8);
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_13, 43, _7);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_15, reference, "getreferencedtable", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_14, reference, "getreferencedtable", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_20, reference, "getreferencedcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_19, reference, "getreferencedcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_16, this_ptr, "getcolumnlist", &_14, 43, _20);
+ ZEPHIR_CALL_METHOD(&_15, this_ptr, "getcolumnlist", &_13, 43, _19);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(referenceSql);
- ZEPHIR_CONCAT_SVSVSSVSVS(referenceSql, "CONSTRAINT `", _4, "` FOREIGN KEY (", _5, ")", " REFERENCES `", _15, "`(", _16, ")");
+ ZEPHIR_CONCAT_SVSVSSVSVS(referenceSql, "CONSTRAINT `", _3, "` FOREIGN KEY (", _4, ")", " REFERENCES `", _14, "`(", _15, ")");
ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onDelete))) {
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SV(_10, " ON DELETE ", onDelete);
- zephir_concat_self(&referenceSql, _10 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SV(_9, " ON DELETE ", onDelete);
+ zephir_concat_self(&referenceSql, _9 TSRMLS_CC);
}
ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onUpdate))) {
- ZEPHIR_INIT_LNVAR(_21);
- ZEPHIR_CONCAT_SV(_21, " ON UPDATE ", onUpdate);
- zephir_concat_self(&referenceSql, _21 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_20);
+ ZEPHIR_CONCAT_SV(_20, " ON UPDATE ", onUpdate);
+ zephir_concat_self(&referenceSql, _20 TSRMLS_CC);
}
- zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 529);
+ zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 455);
}
}
- ZEPHIR_INIT_VAR(_22);
- zephir_fast_join_str(_22, SL(",\n\t"), createLines TSRMLS_CC);
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_VS(_10, _22, "\n)");
- zephir_concat_self(&sql, _10 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_21);
+ zephir_fast_join_str(_21, SL(",\n\t"), createLines TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_VS(_9, _21, "\n)");
+ zephir_concat_self(&sql, _9 TSRMLS_CC);
if (zephir_array_isset_string(definition, SS("options"))) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "_gettableoptions", NULL, 0, definition);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_gettableoptions", NULL, 0, definition);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_21);
- ZEPHIR_CONCAT_SV(_21, " ", _4);
- zephir_concat_self(&sql, _21 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_20);
+ ZEPHIR_CONCAT_SV(_20, " ", _3);
+ zephir_concat_self(&sql, _20 TSRMLS_CC);
}
RETURN_CCTOR(sql);
@@ -1113,9 +1024,10 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, createTable) {
*/
PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropTable) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *sql, *table = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &tableName_param, &schemaName_param, &ifExists_param);
@@ -1149,16 +1061,8 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropTable) {
}
- ZEPHIR_INIT_VAR(table);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "`", schemaName, "`.`", tableName, "`");
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", tableName, "`");
- ZEPHIR_CPY_WRT(table, _0);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
ZEPHIR_CONCAT_SV(sql, "DROP TABLE IF EXISTS ", table);
@@ -1174,9 +1078,10 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropTable) {
*/
PHP_METHOD(Phalcon_Db_Dialect_MySQL, createView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zval *definition = NULL;
- zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *view = NULL, *viewSql;
- zval *viewName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *_0 = NULL;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 1, &viewName_param, &definition_param, &schemaName_param);
@@ -1204,20 +1109,12 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, createView) {
ZEPHIR_OBS_VAR(viewSql);
if (!(zephir_array_isset_string_fetch(&viewSql, definition, SS("sql"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/mysql.zep", 571);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/mysql.zep", 493);
return;
}
- ZEPHIR_INIT_VAR(view);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "`", schemaName, "`.`", viewName, "`");
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "`", viewName, "`");
- ZEPHIR_CPY_WRT(view, _0);
- }
- ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", view, " AS ", viewSql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", _0, " AS ", viewSql);
RETURN_MM();
}
@@ -1227,9 +1124,10 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, createView) {
*/
PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *sql, *view = NULL;
- zval *viewName = NULL, *schemaName = NULL, *_0;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &viewName_param, &schemaName_param, &ifExists_param);
@@ -1263,13 +1161,8 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, dropView) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_VSV(_0, schemaName, ".", viewName);
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_CPY_WRT(view, viewName);
- }
+ ZEPHIR_CALL_METHOD(&view, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
ZEPHIR_CONCAT_SV(sql, "DROP VIEW IF EXISTS ", view);
@@ -1372,7 +1265,8 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, viewExists) {
*/
PHP_METHOD(Phalcon_Db_Dialect_MySQL, describeColumns) {
- zval *table_param = NULL, *schema_param = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *table_param = NULL, *schema_param = NULL, *_0 = NULL;
zval *table = NULL, *schema = NULL;
ZEPHIR_MM_GROW();
@@ -1397,11 +1291,9 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, describeColumns) {
}
- if (schema && Z_STRLEN_P(schema)) {
- ZEPHIR_CONCAT_SVSVS(return_value, "DESCRIBE `", schema, "`.`", table, "`");
- RETURN_MM();
- }
- ZEPHIR_CONCAT_SVS(return_value, "DESCRIBE `", table, "`");
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, table, schema);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SV(return_value, "DESCRIBE ", _0);
RETURN_MM();
}
@@ -1479,7 +1371,8 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, listViews) {
*/
PHP_METHOD(Phalcon_Db_Dialect_MySQL, describeIndexes) {
- zval *table_param = NULL, *schema_param = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *table_param = NULL, *schema_param = NULL, *_0 = NULL;
zval *table = NULL, *schema = NULL;
ZEPHIR_MM_GROW();
@@ -1504,11 +1397,9 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, describeIndexes) {
}
- if (schema && Z_STRLEN_P(schema)) {
- ZEPHIR_CONCAT_SVSVS(return_value, "SHOW INDEXES FROM `", schema, "`.`", table, "`");
- RETURN_MM();
- }
- ZEPHIR_CONCAT_SVS(return_value, "SHOW INDEXES FROM `", table, "`");
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, table, schema);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SV(return_value, "SHOW INDEXES FROM ", _0);
RETURN_MM();
}
@@ -1623,7 +1514,7 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, _getTableOptions) {
if (zephir_is_true(engine)) {
ZEPHIR_INIT_VAR(_0);
ZEPHIR_CONCAT_SV(_0, "ENGINE=", engine);
- zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 727);
+ zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 633);
}
}
ZEPHIR_OBS_VAR(autoIncrement);
@@ -1631,7 +1522,7 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, _getTableOptions) {
if (zephir_is_true(autoIncrement)) {
ZEPHIR_INIT_LNVAR(_0);
ZEPHIR_CONCAT_SV(_0, "AUTO_INCREMENT=", autoIncrement);
- zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 736);
+ zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 642);
}
}
ZEPHIR_OBS_VAR(tableCollation);
@@ -1639,13 +1530,13 @@ PHP_METHOD(Phalcon_Db_Dialect_MySQL, _getTableOptions) {
if (zephir_is_true(tableCollation)) {
ZEPHIR_INIT_VAR(collationParts);
zephir_fast_explode_str(collationParts, SL("_"), tableCollation, LONG_MAX TSRMLS_CC);
- zephir_array_fetch_long(&_1, collationParts, 0, PH_NOISY | PH_READONLY, "phalcon/db/dialect/mysql.zep", 746 TSRMLS_CC);
+ zephir_array_fetch_long(&_1, collationParts, 0, PH_NOISY | PH_READONLY, "phalcon/db/dialect/mysql.zep", 652 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_0);
ZEPHIR_CONCAT_SV(_0, "DEFAULT CHARSET=", _1);
- zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 746);
+ zephir_array_append(&tableOptions, _0, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 652);
ZEPHIR_INIT_VAR(_2);
ZEPHIR_CONCAT_SV(_2, "COLLATE=", tableCollation);
- zephir_array_append(&tableOptions, _2, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 747);
+ zephir_array_append(&tableOptions, _2, PH_SEPARATE, "phalcon/db/dialect/mysql.zep", 653);
}
}
if (zephir_fast_count_int(tableOptions TSRMLS_CC)) {
diff --git a/ext/phalcon/db/dialect/oracle.zep.c b/ext/phalcon/db/dialect/oracle.zep.c
index 14e32829438..684ad8d82c4 100644
--- a/ext/phalcon/db/dialect/oracle.zep.c
+++ b/ext/phalcon/db/dialect/oracle.zep.c
@@ -591,9 +591,8 @@ PHP_METHOD(Phalcon_Db_Dialect_Oracle, createTable) {
PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropTable) {
int ZEPHIR_LAST_CALL_STATUS;
- zephir_fcall_cache_entry *_2 = NULL;
zend_bool ifExists;
- zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *table = NULL, *_0 = NULL, *_1 = NULL, *_3 = NULL, *_4 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *table = NULL;
zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
@@ -633,23 +632,8 @@ PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropTable) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_CALL_CE_STATIC(&_1, phalcon_text_ce, "upper", &_2, 142, schemaName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "escape", NULL, 42, _1);
- zephir_check_call_status();
- ZEPHIR_CALL_CE_STATIC(&_4, phalcon_text_ce, "upper", &_2, 142, tableName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "escape", NULL, 42, _4);
- zephir_check_call_status();
- ZEPHIR_INIT_VAR(table);
- ZEPHIR_CONCAT_VSV(table, _0, ".", _3);
- } else {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_2, 142, tableName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&table, this_ptr, "escape", NULL, 42, _0);
- zephir_check_call_status();
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
if (ifExists) {
ZEPHIR_CONCAT_SV(return_value, "DROP TABLE IF EXISTS ", table);
RETURN_MM();
@@ -665,9 +649,8 @@ PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropTable) {
PHP_METHOD(Phalcon_Db_Dialect_Oracle, createView) {
int ZEPHIR_LAST_CALL_STATUS;
- zephir_fcall_cache_entry *_1 = NULL;
zval *definition = NULL;
- zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *view = NULL, *viewSql, *_0 = NULL, *_2 = NULL, *_3;
+ zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *_0 = NULL;
zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
@@ -696,25 +679,12 @@ PHP_METHOD(Phalcon_Db_Dialect_Oracle, createView) {
ZEPHIR_OBS_VAR(viewSql);
if (!(zephir_array_isset_string_fetch(&viewSql, definition, SS("sql"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/oracle.zep", 234);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/oracle.zep", 230);
return;
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schemaName);
- zephir_check_call_status();
- ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, viewName);
- zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_VSV(_3, _0, ".", _2);
- ZEPHIR_CALL_METHOD(&view, this_ptr, "escape", NULL, 42, _3);
- zephir_check_call_status();
- } else {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, viewName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&view, this_ptr, "escape", NULL, 42, _0);
- zephir_check_call_status();
- }
- ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", view, " AS ", viewSql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", _0, " AS ", viewSql);
RETURN_MM();
}
@@ -725,9 +695,8 @@ PHP_METHOD(Phalcon_Db_Dialect_Oracle, createView) {
PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropView) {
int ZEPHIR_LAST_CALL_STATUS;
- zephir_fcall_cache_entry *_1 = NULL;
zend_bool ifExists;
- zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *view = NULL, *_0 = NULL, *_2 = NULL, *_3;
+ zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *view = NULL;
zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
@@ -762,21 +731,8 @@ PHP_METHOD(Phalcon_Db_Dialect_Oracle, dropView) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, schemaName);
- zephir_check_call_status();
- ZEPHIR_CALL_CE_STATIC(&_2, phalcon_text_ce, "upper", &_1, 142, viewName);
- zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_VSV(_3, _0, ".", _2);
- ZEPHIR_CALL_METHOD(&view, this_ptr, "escape", NULL, 42, _3);
- zephir_check_call_status();
- } else {
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_text_ce, "upper", &_1, 142, viewName);
- zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&view, this_ptr, "escape", NULL, 42, _0);
- zephir_check_call_status();
- }
+ ZEPHIR_CALL_METHOD(&view, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
if (ifExists) {
ZEPHIR_CONCAT_SV(return_value, "DROP VIEW IF EXISTS ", view);
RETURN_MM();
@@ -1156,3 +1112,57 @@ PHP_METHOD(Phalcon_Db_Dialect_Oracle, supportsReleaseSavepoints) {
}
+/**
+ * Prepares table for this RDBMS
+ */
+PHP_METHOD(Phalcon_Db_Dialect_Oracle, prepareTable) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zephir_fcall_cache_entry *_0 = NULL, *_2 = NULL;
+ zval *table_param = NULL, *schema_param = NULL, *alias_param = NULL, *escapeChar_param = NULL, *_1 = NULL, *_3 = NULL;
+ zval *table = NULL, *schema = NULL, *alias = NULL, *escapeChar = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 3, &table_param, &schema_param, &alias_param, &escapeChar_param);
+
+ if (unlikely(Z_TYPE_P(table_param) != IS_STRING && Z_TYPE_P(table_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'table' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(table_param) == IS_STRING)) {
+ zephir_get_strval(table, table_param);
+ } else {
+ ZEPHIR_INIT_VAR(table);
+ ZVAL_EMPTY_STRING(table);
+ }
+ if (!schema_param) {
+ ZEPHIR_INIT_VAR(schema);
+ ZVAL_EMPTY_STRING(schema);
+ } else {
+ zephir_get_strval(schema, schema_param);
+ }
+ if (!alias_param) {
+ ZEPHIR_INIT_VAR(alias);
+ ZVAL_EMPTY_STRING(alias);
+ } else {
+ zephir_get_strval(alias, alias_param);
+ }
+ if (!escapeChar_param) {
+ ZEPHIR_INIT_VAR(escapeChar);
+ ZVAL_EMPTY_STRING(escapeChar);
+ } else {
+ zephir_get_strval(escapeChar, escapeChar_param);
+ }
+
+
+ ZEPHIR_CALL_CE_STATIC(&_1, phalcon_text_ce, "upper", &_2, 142, table);
+ zephir_check_call_status();
+ ZEPHIR_CALL_CE_STATIC(&_3, phalcon_text_ce, "upper", &_2, 142, schema);
+ zephir_check_call_status();
+ ZEPHIR_RETURN_CALL_PARENT(phalcon_db_dialect_oracle_ce, this_ptr, "preparetable", &_0, 143, _1, _3, alias, escapeChar);
+ zephir_check_call_status();
+ RETURN_MM();
+
+}
+
diff --git a/ext/phalcon/db/dialect/oracle.zep.h b/ext/phalcon/db/dialect/oracle.zep.h
index 414f196ad30..01a7969301f 100644
--- a/ext/phalcon/db/dialect/oracle.zep.h
+++ b/ext/phalcon/db/dialect/oracle.zep.h
@@ -28,6 +28,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Oracle, describeReferences);
PHP_METHOD(Phalcon_Db_Dialect_Oracle, tableOptions);
PHP_METHOD(Phalcon_Db_Dialect_Oracle, supportsSavepoints);
PHP_METHOD(Phalcon_Db_Dialect_Oracle, supportsReleaseSavepoints);
+PHP_METHOD(Phalcon_Db_Dialect_Oracle, prepareTable);
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_dialect_oracle_limit, 0, 0, 2)
ZEND_ARG_INFO(0, sqlQuery)
@@ -154,6 +155,13 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_dialect_oracle_tableoptions, 0, 0, 1)
ZEND_ARG_INFO(0, schema)
ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_db_dialect_oracle_preparetable, 0, 0, 1)
+ ZEND_ARG_INFO(0, table)
+ ZEND_ARG_INFO(0, schema)
+ ZEND_ARG_INFO(0, alias)
+ ZEND_ARG_INFO(0, escapeChar)
+ZEND_END_ARG_INFO()
+
ZEPHIR_INIT_FUNCS(phalcon_db_dialect_oracle_method_entry) {
PHP_ME(Phalcon_Db_Dialect_Oracle, limit, arginfo_phalcon_db_dialect_oracle_limit, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Db_Dialect_Oracle, getColumnDefinition, arginfo_phalcon_db_dialect_oracle_getcolumndefinition, ZEND_ACC_PUBLIC)
@@ -180,5 +188,6 @@ ZEPHIR_INIT_FUNCS(phalcon_db_dialect_oracle_method_entry) {
PHP_ME(Phalcon_Db_Dialect_Oracle, tableOptions, arginfo_phalcon_db_dialect_oracle_tableoptions, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Db_Dialect_Oracle, supportsSavepoints, NULL, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Db_Dialect_Oracle, supportsReleaseSavepoints, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Db_Dialect_Oracle, prepareTable, arginfo_phalcon_db_dialect_oracle_preparetable, ZEND_ACC_PROTECTED)
PHP_FE_END
};
diff --git a/ext/phalcon/db/dialect/postgresql.zep.c b/ext/phalcon/db/dialect/postgresql.zep.c
index 2d4216ad550..fcb5a52d650 100644
--- a/ext/phalcon/db/dialect/postgresql.zep.c
+++ b/ext/phalcon/db/dialect/postgresql.zep.c
@@ -217,8 +217,8 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, getColumnDefinition) {
PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addColumn) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *sql = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *sql, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &column);
@@ -247,16 +247,10 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addColumn) {
}
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\" ADD COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\" ADD COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CONCAT_SVS(sql, "ALTER TABLE ", _0, " ADD COLUMN ");
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumndefinition", NULL, 0, column);
@@ -291,8 +285,8 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, modifyColumn) {
zend_bool _10;
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *currentColumn = NULL, *sql, *sqlAlterTable = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9 = NULL, _11, *_12 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *currentColumn = NULL, *sql, *sqlAlterTable, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9 = NULL, _11, *_12 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 1, &tableName_param, &schemaName_param, &column, ¤tColumn);
@@ -326,16 +320,10 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, modifyColumn) {
ZVAL_STRING(sql, "", 1);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sqlAlterTable);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(sqlAlterTable, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\"");
- ZEPHIR_CPY_WRT(sqlAlterTable, _0);
- }
+ ZEPHIR_CONCAT_SV(sqlAlterTable, "ALTER TABLE ", _0);
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, currentColumn, "getname", NULL, 0);
@@ -426,8 +414,9 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, modifyColumn) {
*/
PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropColumn) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *columnName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *columnName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *columnName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *columnName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &columnName_param);
@@ -467,20 +456,10 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropColumn) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\" ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\" ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, " DROP COLUMN \"", columnName, "\"");
- zephir_concat_self(&sql, _0 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP COLUMN \"", columnName, "\"");
+ RETURN_MM();
}
@@ -490,8 +469,8 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropColumn) {
PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addIndex) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql, *indexType = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_4 = NULL, *_5 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_3 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql, *indexType = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
@@ -538,25 +517,18 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addIndex) {
}
ZEPHIR_CALL_METHOD(&_2, index, "getname", NULL, 0);
zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_1);
- ZEPHIR_CONCAT_SVS(_1, " INDEX \"", _2, "\" ON");
+ ZEPHIR_CONCAT_SVSV(_1, " INDEX \"", _2, "\" ON ", _3);
zephir_concat_self(&sql, _1 TSRMLS_CC);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVSVS(_3, " \"", schemaName, "\".\"", tableName, "\"");
- zephir_concat_self(&sql, _3 TSRMLS_CC);
- } else {
- ZEPHIR_INIT_LNVAR(_3);
- ZEPHIR_CONCAT_SVS(_3, " \"", tableName, "\"");
- zephir_concat_self(&sql, _3 TSRMLS_CC);
- }
ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", NULL, 43, _5);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_1);
- ZEPHIR_CONCAT_SVS(_1, " (", _4, ")");
- zephir_concat_self(&sql, _1 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_6);
+ ZEPHIR_CONCAT_SVS(_6, " (", _4, ")");
+ zephir_concat_self(&sql, _6 TSRMLS_CC);
RETURN_CCTOR(sql);
}
@@ -618,8 +590,8 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropIndex) {
PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addPrimaryKey) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *index, *sql = NULL, *_1 = NULL, *_2 = NULL, *_3;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *index, *_0 = NULL, *_1 = NULL, *_2 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &index);
@@ -648,24 +620,14 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addPrimaryKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, index, "getcolumns", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, this_ptr, "getcolumnlist", NULL, 43, _2);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_3);
- ZEPHIR_CONCAT_SVS(_3, " ADD CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _1, ")");
- zephir_concat_self(&sql, _3 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " ADD CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _1, ")");
+ RETURN_MM();
}
@@ -674,8 +636,9 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addPrimaryKey) {
*/
PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropPrimaryKey) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 0, &tableName_param, &schemaName_param);
@@ -704,18 +667,10 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropPrimaryKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- zephir_concat_self_str(&sql, SL(" DROP CONSTRAINT \"PRIMARY\"") TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVS(return_value, "ALTER TABLE ", _0, " DROP CONSTRAINT \"PRIMARY\"");
+ RETURN_MM();
}
@@ -725,8 +680,8 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropPrimaryKey) {
PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *reference, *sql = NULL, *onDelete = NULL, *onUpdate = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7, *_8 = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *reference, *sql, *onDelete = NULL, *onUpdate = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4 = NULL, *_5 = NULL, *_6 = NULL, *_7 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &reference);
@@ -755,16 +710,8 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\" ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\" ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, reference, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_3, reference, "getcolumns", NULL, 0);
@@ -777,22 +724,21 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", NULL, 43, _6);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_7);
- ZEPHIR_CONCAT_SVSVSSVSVS(_7, "ADD CONSTRAINT \"", _1, "\" FOREIGN KEY (", _2, ")", " REFERENCES \"", _4, "\" (", _5, ")");
- zephir_concat_self(&sql, _7 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(sql);
+ ZEPHIR_CONCAT_SVSVSVSSVSVS(sql, "ALTER TABLE ", _0, " ADD CONSTRAINT \"", _1, "\" FOREIGN KEY (", _2, ")", " REFERENCES \"", _4, "\" (", _5, ")");
ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onDelete))) {
- ZEPHIR_INIT_VAR(_8);
- ZEPHIR_CONCAT_SV(_8, " ON DELETE ", onDelete);
- zephir_concat_self(&sql, _8 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_7);
+ ZEPHIR_CONCAT_SV(_7, " ON DELETE ", onDelete);
+ zephir_concat_self(&sql, _7 TSRMLS_CC);
}
ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onUpdate))) {
- ZEPHIR_INIT_LNVAR(_8);
- ZEPHIR_CONCAT_SV(_8, " ON UPDATE ", onUpdate);
- zephir_concat_self(&sql, _8 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_7);
+ ZEPHIR_CONCAT_SV(_7, " ON UPDATE ", onUpdate);
+ zephir_concat_self(&sql, _7 TSRMLS_CC);
}
RETURN_CCTOR(sql);
@@ -803,8 +749,9 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, addForeignKey) {
*/
PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropForeignKey) {
- zval *tableName_param = NULL, *schemaName_param = NULL, *referenceName_param = NULL, *sql = NULL;
- zval *tableName = NULL, *schemaName = NULL, *referenceName = NULL, *_0 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *referenceName_param = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL, *referenceName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &referenceName_param);
@@ -844,20 +791,10 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropForeignKey) {
}
- ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\"");
- ZEPHIR_CPY_WRT(sql, _0);
- }
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, " DROP CONSTRAINT \"", referenceName, "\"");
- zephir_concat_self(&sql, _0 TSRMLS_CC);
- RETURN_CCTOR(sql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSVS(return_value, "ALTER TABLE ", _0, " DROP CONSTRAINT \"", referenceName, "\"");
+ RETURN_MM();
}
@@ -866,13 +803,13 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropForeignKey) {
*/
PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) {
- zephir_fcall_cache_entry *_6 = NULL, *_9 = NULL, *_17 = NULL;
+ zephir_fcall_cache_entry *_5 = NULL, *_8 = NULL, *_16 = NULL;
+ HashTable *_1, *_14, *_23;
+ HashPosition _0, _13, _22;
int ZEPHIR_LAST_CALL_STATUS;
- HashTable *_2, *_15, *_24;
- HashPosition _1, _14, _23;
zval *definition = NULL;
- zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *indexSqlAfterCreate, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, *primaryColumns, **_3, *_4 = NULL, *_5 = NULL, _7 = zval_used_for_init, *_8 = NULL, *_10 = NULL, *_11 = NULL, *_12 = NULL, *_13 = NULL, **_16, *_18 = NULL, *_20 = NULL, *_21 = NULL, *_22 = NULL, **_25, *_26 = NULL, *_27;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL, *_19 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *definition_param = NULL, *temporary = NULL, *options, *table = NULL, *createLines, *columns, *column = NULL, *indexes, *index = NULL, *reference = NULL, *references, *indexName = NULL, *indexSql = NULL, *indexSqlAfterCreate, *sql, *columnLine = NULL, *indexType = NULL, *referenceSql = NULL, *onDelete = NULL, *onUpdate = NULL, *defaultValue = NULL, *primaryColumns, **_2, *_3 = NULL, *_4 = NULL, _6 = zval_used_for_init, *_7 = NULL, *_9 = NULL, *_10 = NULL, *_11 = NULL, *_12 = NULL, **_15, *_17 = NULL, *_18 = NULL, *_19 = NULL, *_20 = NULL, *_21 = NULL, **_24, *_25 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &definition_param);
@@ -905,19 +842,11 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) {
ZEPHIR_OBS_VAR(columns);
if (!(zephir_array_isset_string_fetch(&columns, definition, SS("columns"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'columns' is required in the definition array", "phalcon/db/dialect/postgresql.zep", 383);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'columns' is required in the definition array", "phalcon/db/dialect/postgresql.zep", 327);
return;
}
- ZEPHIR_INIT_VAR(table);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "\"", tableName, "\"");
- ZEPHIR_CPY_WRT(table, _0);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(temporary);
ZVAL_BOOL(temporary, 0);
ZEPHIR_OBS_VAR(options);
@@ -935,64 +864,64 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) {
array_init(createLines);
ZEPHIR_INIT_VAR(primaryColumns);
array_init(primaryColumns);
- zephir_is_iterable(columns, &_2, &_1, 0, 0, "phalcon/db/dialect/postgresql.zep", 443);
+ zephir_is_iterable(columns, &_1, &_0, 0, 0, "phalcon/db/dialect/postgresql.zep", 383);
for (
- ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
- ; zephir_hash_move_forward_ex(_2, &_1)
+ ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
+ ; zephir_hash_move_forward_ex(_1, &_0)
) {
- ZEPHIR_GET_HVALUE(column, _3);
- ZEPHIR_CALL_METHOD(&_4, column, "getname", NULL, 0);
+ ZEPHIR_GET_HVALUE(column, _2);
+ ZEPHIR_CALL_METHOD(&_3, column, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumndefinition", &_6, 0, column);
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumndefinition", &_5, 0, column);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(columnLine);
- ZEPHIR_CONCAT_SVSV(columnLine, "\"", _4, "\" ", _5);
+ ZEPHIR_CONCAT_SVSV(columnLine, "\"", _3, "\" ", _4);
ZEPHIR_CALL_METHOD(&defaultValue, column, "getdefault", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(defaultValue))) {
- ZEPHIR_SINIT_NVAR(_7);
- ZVAL_STRING(&_7, "\"", 0);
- ZEPHIR_CALL_FUNCTION(&_8, "addcslashes", &_9, 141, defaultValue, &_7);
+ ZEPHIR_SINIT_NVAR(_6);
+ ZVAL_STRING(&_6, "\"", 0);
+ ZEPHIR_CALL_FUNCTION(&_7, "addcslashes", &_8, 141, defaultValue, &_6);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SVS(_10, " DEFAULT \"", _8, "\"");
- zephir_concat_self(&columnLine, _10 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, " DEFAULT \"", _7, "\"");
+ zephir_concat_self(&columnLine, _9 TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isnotnull", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isnotnull", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
zephir_concat_self_str(&columnLine, SL(" NOT NULL") TSRMLS_CC);
}
- ZEPHIR_CALL_METHOD(&_8, column, "isautoincrement", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, column, "isautoincrement", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_8)) {
+ if (zephir_is_true(_7)) {
}
- ZEPHIR_CALL_METHOD(&_11, column, "isprimary", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_10, column, "isprimary", NULL, 0);
zephir_check_call_status();
- if (zephir_is_true(_11)) {
- ZEPHIR_CALL_METHOD(&_12, column, "getname", NULL, 0);
+ if (zephir_is_true(_10)) {
+ ZEPHIR_CALL_METHOD(&_11, column, "getname", NULL, 0);
zephir_check_call_status();
- zephir_array_append(&primaryColumns, _12, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 438);
+ zephir_array_append(&primaryColumns, _11, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 378);
}
- zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 441);
+ zephir_array_append(&createLines, columnLine, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 381);
}
if (!(ZEPHIR_IS_EMPTY(primaryColumns))) {
- ZEPHIR_INIT_VAR(_13);
- zephir_fast_join_str(_13, SL(","), primaryColumns TSRMLS_CC);
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SVS(_10, "PRIMARY KEY (", _13, ")");
- zephir_array_append(&createLines, _10, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 444);
+ ZEPHIR_INIT_VAR(_12);
+ zephir_fast_join_str(_12, SL(","), primaryColumns TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, "PRIMARY KEY (", _12, ")");
+ zephir_array_append(&createLines, _9, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 384);
}
ZEPHIR_INIT_VAR(indexSqlAfterCreate);
ZVAL_STRING(indexSqlAfterCreate, "", 1);
ZEPHIR_OBS_VAR(indexes);
if (zephir_array_isset_string_fetch(&indexes, definition, SS("indexes"), 0 TSRMLS_CC)) {
- zephir_is_iterable(indexes, &_15, &_14, 0, 0, "phalcon/db/dialect/postgresql.zep", 484);
+ zephir_is_iterable(indexes, &_14, &_13, 0, 0, "phalcon/db/dialect/postgresql.zep", 418);
for (
- ; zephir_hash_get_current_data_ex(_15, (void**) &_16, &_14) == SUCCESS
- ; zephir_hash_move_forward_ex(_15, &_14)
+ ; zephir_hash_get_current_data_ex(_14, (void**) &_15, &_13) == SUCCESS
+ ; zephir_hash_move_forward_ex(_14, &_13)
) {
- ZEPHIR_GET_HVALUE(index, _16);
+ ZEPHIR_GET_HVALUE(index, _15);
ZEPHIR_CALL_METHOD(&indexName, index, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&indexType, index, "gettype", NULL, 0);
@@ -1000,117 +929,102 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) {
ZEPHIR_INIT_NVAR(indexSql);
ZVAL_STRING(indexSql, "", 1);
if (ZEPHIR_IS_STRING(indexName, "PRIMARY")) {
- ZEPHIR_CALL_METHOD(&_5, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_4, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_17, 43, _5);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "getcolumnlist", &_16, 43, _4);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(indexSql);
- ZEPHIR_CONCAT_SVS(indexSql, "CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _4, ")");
+ ZEPHIR_CONCAT_SVS(indexSql, "CONSTRAINT \"PRIMARY\" PRIMARY KEY (", _3, ")");
} else {
if (!(ZEPHIR_IS_EMPTY(indexType))) {
- ZEPHIR_CALL_METHOD(&_11, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_10, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, this_ptr, "getcolumnlist", &_17, 43, _11);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "getcolumnlist", &_16, 43, _10);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(indexSql);
- ZEPHIR_CONCAT_SVSVSVS(indexSql, "CONSTRAINT \"", indexName, "\" ", indexType, " (", _8, ")");
+ ZEPHIR_CONCAT_SVSVSVS(indexSql, "CONSTRAINT \"", indexName, "\" ", indexType, " (", _7, ")");
} else {
- ZEPHIR_CALL_METHOD(&_12, index, "getname", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_11, index, "getname", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_17, this_ptr, "preparetable", NULL, 143, tableName, schemaName);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_18);
- ZEPHIR_CONCAT_SVS(_18, "CREATE INDEX \"", _12, "\" ON ");
+ ZEPHIR_CONCAT_SVSV(_18, "CREATE INDEX \"", _11, "\" ON ", _17);
zephir_concat_self(&indexSqlAfterCreate, _18 TSRMLS_CC);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", tableName, "\"");
- zephir_concat_self(&indexSqlAfterCreate, _0 TSRMLS_CC);
- } else {
- ZEPHIR_INIT_LNVAR(_19);
- ZEPHIR_CONCAT_SVS(_19, "\"", tableName, "\"");
- zephir_concat_self(&indexSqlAfterCreate, _19 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_21, index, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_20, index, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_20, this_ptr, "getcolumnlist", &_17, 43, _21);
+ ZEPHIR_CALL_METHOD(&_19, this_ptr, "getcolumnlist", &_16, 43, _20);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_22);
- ZEPHIR_CONCAT_SVS(_22, " (", _20, ");");
- zephir_concat_self(&indexSqlAfterCreate, _22 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_21);
+ ZEPHIR_CONCAT_SVS(_21, " (", _19, ");");
+ zephir_concat_self(&indexSqlAfterCreate, _21 TSRMLS_CC);
}
}
if (!(ZEPHIR_IS_EMPTY(indexSql))) {
- zephir_array_append(&createLines, indexSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 481);
+ zephir_array_append(&createLines, indexSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 415);
}
}
}
ZEPHIR_OBS_VAR(references);
if (zephir_array_isset_string_fetch(&references, definition, SS("references"), 0 TSRMLS_CC)) {
- zephir_is_iterable(references, &_24, &_23, 0, 0, "phalcon/db/dialect/postgresql.zep", 513);
+ zephir_is_iterable(references, &_23, &_22, 0, 0, "phalcon/db/dialect/postgresql.zep", 443);
for (
- ; zephir_hash_get_current_data_ex(_24, (void**) &_25, &_23) == SUCCESS
- ; zephir_hash_move_forward_ex(_24, &_23)
+ ; zephir_hash_get_current_data_ex(_23, (void**) &_24, &_22) == SUCCESS
+ ; zephir_hash_move_forward_ex(_23, &_22)
) {
- ZEPHIR_GET_HVALUE(reference, _25);
- ZEPHIR_CALL_METHOD(&_4, reference, "getname", NULL, 0);
+ ZEPHIR_GET_HVALUE(reference, _24);
+ ZEPHIR_CALL_METHOD(&_3, reference, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, reference, "getcolumns", NULL, 0);
+ ZEPHIR_CALL_METHOD(&_7, reference, "getcolumns", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "getcolumnlist", &_17, 43, _8);
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "getcolumnlist", &_16, 43, _7);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(referenceSql);
- ZEPHIR_CONCAT_SVSVS(referenceSql, "CONSTRAINT \"", _4, "\" FOREIGN KEY (", _5, ") REFERENCES ");
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_CALL_METHOD(&_11, reference, "getreferencedtable", NULL, 0);
- zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_SVSVS(_10, "\"", schemaName, "\".\"", _11, "\" ");
- zephir_concat_self(&referenceSql, _10 TSRMLS_CC);
- } else {
- ZEPHIR_CALL_METHOD(&_12, reference, "getreferencedtable", NULL, 0);
- zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_18);
- ZEPHIR_CONCAT_SVS(_18, "\"", _12, "\" ");
- zephir_concat_self(&referenceSql, _18 TSRMLS_CC);
- }
- ZEPHIR_CALL_METHOD(&_21, reference, "getreferencedcolumns", NULL, 0);
+ ZEPHIR_CONCAT_SVSVS(referenceSql, "CONSTRAINT \"", _3, "\" FOREIGN KEY (", _4, ") REFERENCES ");
+ ZEPHIR_CALL_METHOD(&_11, reference, "getreferencedtable", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_20, this_ptr, "getcolumnlist", &_17, 43, _21);
+ ZEPHIR_CALL_METHOD(&_10, this_ptr, "preparetable", NULL, 143, _11, schemaName);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_22);
- ZEPHIR_CONCAT_SVS(_22, "(", _20, ")");
- zephir_concat_self(&referenceSql, _22 TSRMLS_CC);
+ zephir_concat_self(&referenceSql, _10 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_19, reference, "getreferencedcolumns", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&_17, this_ptr, "getcolumnlist", &_16, 43, _19);
+ zephir_check_call_status();
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, " (", _17, ")");
+ zephir_concat_self(&referenceSql, _9 TSRMLS_CC);
ZEPHIR_CALL_METHOD(&onDelete, reference, "getondelete", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onDelete))) {
- ZEPHIR_INIT_LNVAR(_26);
- ZEPHIR_CONCAT_SV(_26, " ON DELETE ", onDelete);
- zephir_concat_self(&referenceSql, _26 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_18);
+ ZEPHIR_CONCAT_SV(_18, " ON DELETE ", onDelete);
+ zephir_concat_self(&referenceSql, _18 TSRMLS_CC);
}
ZEPHIR_CALL_METHOD(&onUpdate, reference, "getonupdate", NULL, 0);
zephir_check_call_status();
if (!(ZEPHIR_IS_EMPTY(onUpdate))) {
- ZEPHIR_INIT_LNVAR(_26);
- ZEPHIR_CONCAT_SV(_26, " ON UPDATE ", onUpdate);
- zephir_concat_self(&referenceSql, _26 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_21);
+ ZEPHIR_CONCAT_SV(_21, " ON UPDATE ", onUpdate);
+ zephir_concat_self(&referenceSql, _21 TSRMLS_CC);
}
- zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 511);
+ zephir_array_append(&createLines, referenceSql, PH_SEPARATE, "phalcon/db/dialect/postgresql.zep", 441);
}
}
- ZEPHIR_INIT_NVAR(_13);
- zephir_fast_join_str(_13, SL(",\n\t"), createLines TSRMLS_CC);
- ZEPHIR_INIT_LNVAR(_10);
- ZEPHIR_CONCAT_VS(_10, _13, "\n)");
- zephir_concat_self(&sql, _10 TSRMLS_CC);
+ ZEPHIR_INIT_NVAR(_12);
+ zephir_fast_join_str(_12, SL(",\n\t"), createLines TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_VS(_9, _12, "\n)");
+ zephir_concat_self(&sql, _9 TSRMLS_CC);
if (zephir_array_isset_string(definition, SS("options"))) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "_gettableoptions", NULL, 0, definition);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_gettableoptions", NULL, 0, definition);
zephir_check_call_status();
- ZEPHIR_INIT_LNVAR(_26);
- ZEPHIR_CONCAT_SV(_26, " ", _4);
- zephir_concat_self(&sql, _26 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_25);
+ ZEPHIR_CONCAT_SV(_25, " ", _3);
+ zephir_concat_self(&sql, _25 TSRMLS_CC);
}
- ZEPHIR_INIT_VAR(_27);
- ZEPHIR_CONCAT_SV(_27, ";", indexSqlAfterCreate);
- zephir_concat_self(&sql, _27 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_25);
+ ZEPHIR_CONCAT_SV(_25, ";", indexSqlAfterCreate);
+ zephir_concat_self(&sql, _25 TSRMLS_CC);
RETURN_CCTOR(sql);
}
@@ -1120,9 +1034,10 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createTable) {
*/
PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropTable) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *table = NULL, *sql;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &tableName_param, &schemaName_param, &ifExists_param);
@@ -1156,21 +1071,13 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropTable) {
}
- ZEPHIR_INIT_VAR(table);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", tableName, "\"");
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "\"", tableName, "\"");
- ZEPHIR_CPY_WRT(table, _0);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
- ZEPHIR_CONCAT_SVS(sql, "DROP TABLE IF EXISTS \"", table, "\"");
+ ZEPHIR_CONCAT_SV(sql, "DROP TABLE IF EXISTS ", table);
} else {
- ZEPHIR_CONCAT_SVS(sql, "DROP TABLE \"", table, "\"");
+ ZEPHIR_CONCAT_SV(sql, "DROP TABLE ", table);
}
RETURN_CCTOR(sql);
@@ -1181,9 +1088,10 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropTable) {
*/
PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zval *definition = NULL;
- zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *view = NULL;
- zval *viewName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *_0 = NULL;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 1, &viewName_param, &definition_param, &schemaName_param);
@@ -1211,20 +1119,12 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createView) {
ZEPHIR_OBS_VAR(viewSql);
if (!(zephir_array_isset_string_fetch(&viewSql, definition, SS("sql"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/postgresql.zep", 554);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/postgresql.zep", 480);
return;
}
- ZEPHIR_INIT_VAR(view);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", viewName, "\"");
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "\"", viewName, "\"");
- ZEPHIR_CPY_WRT(view, _0);
- }
- ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", view, " AS ", viewSql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", _0, " AS ", viewSql);
RETURN_MM();
}
@@ -1234,9 +1134,10 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, createView) {
*/
PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *view = NULL, *sql;
- zval *viewName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &viewName_param, &schemaName_param, &ifExists_param);
@@ -1270,21 +1171,13 @@ PHP_METHOD(Phalcon_Db_Dialect_Postgresql, dropView) {
}
- ZEPHIR_INIT_VAR(view);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "\"", schemaName, "\".\"", viewName, "\"");
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "\"", viewName, "\"");
- ZEPHIR_CPY_WRT(view, _0);
- }
+ ZEPHIR_CALL_METHOD(&view, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
- ZEPHIR_CONCAT_SVS(sql, "DROP VIEW IF EXISTS ", view, "");
+ ZEPHIR_CONCAT_SV(sql, "DROP VIEW IF EXISTS ", view);
} else {
- ZEPHIR_CONCAT_SVS(sql, "DROP VIEW ", view, "");
+ ZEPHIR_CONCAT_SV(sql, "DROP VIEW ", view);
}
RETURN_CCTOR(sql);
diff --git a/ext/phalcon/db/dialect/sqlite.zep.c b/ext/phalcon/db/dialect/sqlite.zep.c
index fd72860cc4a..ed05aa1ae66 100644
--- a/ext/phalcon/db/dialect/sqlite.zep.c
+++ b/ext/phalcon/db/dialect/sqlite.zep.c
@@ -184,8 +184,8 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, getColumnDefinition) {
PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addColumn) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *tableName_param = NULL, *schemaName_param = NULL, *column, *sql = NULL, *defaultValue = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
- zval *tableName = NULL, *schemaName = NULL, *_0 = NULL;
+ zval *tableName_param = NULL, *schemaName_param = NULL, *column, *sql, *defaultValue = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3, _4, *_5 = NULL, *_6;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &tableName_param, &schemaName_param, &column);
@@ -214,16 +214,10 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addColumn) {
}
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_SVSVS(_0, "ALTER TABLE \"", schemaName, "\".\"", tableName, "\" ADD COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- } else {
- ZEPHIR_INIT_LNVAR(_0);
- ZEPHIR_CONCAT_SVS(_0, "ALTER TABLE \"", tableName, "\" ADD COLUMN ");
- ZEPHIR_CPY_WRT(sql, _0);
- }
+ ZEPHIR_CONCAT_SVS(sql, "ALTER TABLE ", _0, " ADD COLUMN ");
ZEPHIR_CALL_METHOD(&_1, column, "getname", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, this_ptr, "getcolumndefinition", NULL, 0, column);
@@ -294,7 +288,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, modifyColumn) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Altering a DB column is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 169);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Altering a DB column is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 165);
return;
}
@@ -345,7 +339,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropColumn) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Dropping DB column is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 177);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Dropping DB column is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 173);
return;
}
@@ -508,7 +502,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addPrimaryKey) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Adding a primary key after table has been created is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 221);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Adding a primary key after table has been created is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 217);
return;
}
@@ -548,7 +542,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropPrimaryKey) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Removing a primary key after table has been created is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 229);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Removing a primary key after table has been created is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 225);
return;
}
@@ -588,7 +582,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, addForeignKey) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Adding a foreign key constraint to an existing table is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 237);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Adding a foreign key constraint to an existing table is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 233);
return;
}
@@ -639,7 +633,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropForeignKey) {
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Dropping a foreign key constraint is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 245);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Dropping a foreign key constraint is not supported by SQLite", "phalcon/db/dialect/sqlite.zep", 241);
return;
}
@@ -682,7 +676,7 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, createTable) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Not implemented yet", "phalcon/db/dialect/sqlite.zep", 253);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "Not implemented yet", "phalcon/db/dialect/sqlite.zep", 249);
return;
}
@@ -692,9 +686,10 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, createTable) {
*/
PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropTable) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *tableName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *sql, *table = NULL;
- zval *tableName = NULL, *schemaName = NULL, *_0;
+ zval *tableName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &tableName_param, &schemaName_param, &ifExists_param);
@@ -728,18 +723,13 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropTable) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_VSV(_0, schemaName, "\".\"", tableName);
- ZEPHIR_CPY_WRT(table, _0);
- } else {
- ZEPHIR_CPY_WRT(table, tableName);
- }
+ ZEPHIR_CALL_METHOD(&table, this_ptr, "preparetable", NULL, 0, tableName, schemaName);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(sql);
if (ifExists) {
- ZEPHIR_CONCAT_SVS(sql, "DROP TABLE IF EXISTS \"", table, "\"");
+ ZEPHIR_CONCAT_SV(sql, "DROP TABLE IF EXISTS ", table);
} else {
- ZEPHIR_CONCAT_SVS(sql, "DROP TABLE \"", table, "\"");
+ ZEPHIR_CONCAT_SV(sql, "DROP TABLE ", table);
}
RETURN_CCTOR(sql);
@@ -750,9 +740,10 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropTable) {
*/
PHP_METHOD(Phalcon_Db_Dialect_Sqlite, createView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zval *definition = NULL;
- zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *view = NULL, *viewSql;
- zval *viewName = NULL, *schemaName = NULL, *_0;
+ zval *viewName_param = NULL, *definition_param = NULL, *schemaName_param = NULL, *viewSql, *_0 = NULL;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 1, &viewName_param, &definition_param, &schemaName_param);
@@ -780,17 +771,12 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, createView) {
ZEPHIR_OBS_VAR(viewSql);
if (!(zephir_array_isset_string_fetch(&viewSql, definition, SS("sql"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/sqlite.zep", 286);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_db_exception_ce, "The index 'sql' is required in the definition array", "phalcon/db/dialect/sqlite.zep", 278);
return;
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_VSV(_0, schemaName, "\".\"", viewName);
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_CPY_WRT(view, viewName);
- }
- ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW \"", view, "\" AS ", viewSql);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
+ ZEPHIR_CONCAT_SVSV(return_value, "CREATE VIEW ", _0, " AS ", viewSql);
RETURN_MM();
}
@@ -800,9 +786,10 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, createView) {
*/
PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropView) {
+ int ZEPHIR_LAST_CALL_STATUS;
zend_bool ifExists;
zval *viewName_param = NULL, *schemaName_param = NULL, *ifExists_param = NULL, *view = NULL;
- zval *viewName = NULL, *schemaName = NULL, *_0;
+ zval *viewName = NULL, *schemaName = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 2, &viewName_param, &schemaName_param, &ifExists_param);
@@ -836,18 +823,13 @@ PHP_METHOD(Phalcon_Db_Dialect_Sqlite, dropView) {
}
- if (schemaName && Z_STRLEN_P(schemaName)) {
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CONCAT_VSV(_0, schemaName, "\".\"", viewName);
- ZEPHIR_CPY_WRT(view, _0);
- } else {
- ZEPHIR_CPY_WRT(view, viewName);
- }
+ ZEPHIR_CALL_METHOD(&view, this_ptr, "preparetable", NULL, 0, viewName, schemaName);
+ zephir_check_call_status();
if (ifExists) {
- ZEPHIR_CONCAT_SVS(return_value, "DROP VIEW IF EXISTS \"", view, "\"");
+ ZEPHIR_CONCAT_SV(return_value, "DROP VIEW IF EXISTS ", view);
RETURN_MM();
}
- ZEPHIR_CONCAT_SVS(return_value, "DROP VIEW \"", view, "\"");
+ ZEPHIR_CONCAT_SV(return_value, "DROP VIEW ", view);
RETURN_MM();
}
diff --git a/ext/phalcon/db/profiler.zep.c b/ext/phalcon/db/profiler.zep.c
index 6b99ba8c542..3250aaa92a1 100644
--- a/ext/phalcon/db/profiler.zep.c
+++ b/ext/phalcon/db/profiler.zep.c
@@ -59,7 +59,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Db_Profiler) {
/**
* All the Phalcon\Db\Profiler\Item in the active profile
*
- * @var array
+ * @var \Phalcon\Db\Profiler\Item[]
*/
zend_declare_property_null(phalcon_db_profiler_ce, SL("_allProfiles"), ZEND_ACC_PROTECTED TSRMLS_CC);
@@ -109,19 +109,19 @@ PHP_METHOD(Phalcon_Db_Profiler, startProfile) {
ZEPHIR_CALL_METHOD(NULL, activeProfile, "__construct", NULL, 0);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlstatement", NULL, 143, sqlStatement);
+ ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlstatement", NULL, 144, sqlStatement);
zephir_check_call_status();
if (Z_TYPE_P(sqlVariables) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlvariables", NULL, 144, sqlVariables);
+ ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlvariables", NULL, 145, sqlVariables);
zephir_check_call_status();
}
if (Z_TYPE_P(sqlBindTypes) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlbindtypes", NULL, 145, sqlBindTypes);
+ ZEPHIR_CALL_METHOD(NULL, activeProfile, "setsqlbindtypes", NULL, 146, sqlBindTypes);
zephir_check_call_status();
}
ZEPHIR_INIT_VAR(_0);
zephir_microtime(_0, ZEPHIR_GLOBAL(global_true) TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, activeProfile, "setinitialtime", NULL, 146, _0);
+ ZEPHIR_CALL_METHOD(NULL, activeProfile, "setinitialtime", NULL, 147, _0);
zephir_check_call_status();
if ((zephir_method_exists_ex(this_ptr, SS("beforestartprofile") TSRMLS_CC) == SUCCESS)) {
ZEPHIR_CALL_METHOD(NULL, this_ptr, "beforestartprofile", NULL, 0, activeProfile);
diff --git a/ext/phalcon/db/rawvalue.zep.c b/ext/phalcon/db/rawvalue.zep.c
index 3137191d493..2e769732a97 100644
--- a/ext/phalcon/db/rawvalue.zep.c
+++ b/ext/phalcon/db/rawvalue.zep.c
@@ -22,7 +22,7 @@
*
* This class allows to insert/update raw data without quoting or formating.
*
- *The next example shows how to use the MySQL now() function as a field value.
+ * The next example shows how to use the MySQL now() function as a field value.
*
*
* $subscriber = new Subscribers();
diff --git a/ext/phalcon/debug.zep.c b/ext/phalcon/debug.zep.c
index 4f29b16e440..ce744f9b56a 100644
--- a/ext/phalcon/debug.zep.c
+++ b/ext/phalcon/debug.zep.c
@@ -84,7 +84,7 @@ PHP_METHOD(Phalcon_Debug, setUri) {
}
/**
- * Sets if files the exception"s backtrace must be showed
+ * Sets if files the exception's backtrace must be showed
*/
PHP_METHOD(Phalcon_Debug, setShowBackTrace) {
@@ -191,7 +191,7 @@ PHP_METHOD(Phalcon_Debug, listenExceptions) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "onUncaughtException", 1);
zephir_array_fast_append(_0, _1);
- ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 147, _0);
+ ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 148, _0);
zephir_check_call_status();
RETURN_THIS();
@@ -214,7 +214,7 @@ PHP_METHOD(Phalcon_Debug, listenLowSeverity) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "onUncaughtLowSeverity", 1);
zephir_array_fast_append(_0, _1);
- ZEPHIR_CALL_FUNCTION(NULL, "set_error_handler", NULL, 148, _0);
+ ZEPHIR_CALL_FUNCTION(NULL, "set_error_handler", NULL, 149, _0);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_2);
zephir_create_array(_2, 2, 0 TSRMLS_CC);
@@ -222,7 +222,7 @@ PHP_METHOD(Phalcon_Debug, listenLowSeverity) {
ZEPHIR_INIT_NVAR(_1);
ZVAL_STRING(_1, "onUncaughtException", 1);
zephir_array_fast_append(_2, _1);
- ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 147, _2);
+ ZEPHIR_CALL_FUNCTION(NULL, "set_exception_handler", NULL, 148, _2);
zephir_check_call_status();
RETURN_THIS();
@@ -263,7 +263,7 @@ PHP_METHOD(Phalcon_Debug, debugVar) {
ZEPHIR_INIT_VAR(_0);
zephir_create_array(_0, 3, 0 TSRMLS_CC);
zephir_array_fast_append(_0, varz);
- ZEPHIR_CALL_FUNCTION(&_1, "debug_backtrace", NULL, 149);
+ ZEPHIR_CALL_FUNCTION(&_1, "debug_backtrace", NULL, 150);
zephir_check_call_status();
zephir_array_fast_append(_0, _1);
ZEPHIR_INIT_VAR(_2);
@@ -309,7 +309,7 @@ PHP_METHOD(Phalcon_Debug, _escapeString) {
ZVAL_LONG(&_3, 2);
ZEPHIR_SINIT_VAR(_4);
ZVAL_STRING(&_4, "utf-8", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("htmlentities", NULL, 150, _0, &_3, &_4);
+ ZEPHIR_RETURN_CALL_FUNCTION("htmlentities", NULL, 151, _0, &_3, &_4);
zephir_check_call_status();
RETURN_MM();
}
@@ -363,7 +363,7 @@ PHP_METHOD(Phalcon_Debug, _getArrayDump) {
) {
ZEPHIR_GET_HMKEY(k, _2, _1);
ZEPHIR_GET_HVALUE(v, _3);
- ZEPHIR_CALL_FUNCTION(&_4, "is_scalar", &_5, 151, v);
+ ZEPHIR_CALL_FUNCTION(&_4, "is_scalar", &_5, 152, v);
zephir_check_call_status();
if (zephir_is_true(_4)) {
ZEPHIR_INIT_NVAR(varDump);
@@ -380,7 +380,7 @@ PHP_METHOD(Phalcon_Debug, _getArrayDump) {
if (Z_TYPE_P(v) == IS_ARRAY) {
ZEPHIR_INIT_NVAR(_8);
ZVAL_LONG(_8, (zephir_get_numberval(n) + 1));
- ZEPHIR_CALL_METHOD(&_6, this_ptr, "_getarraydump", &_9, 152, v, _8);
+ ZEPHIR_CALL_METHOD(&_6, this_ptr, "_getarraydump", &_9, 153, v, _8);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_10);
ZEPHIR_CONCAT_SVSVS(_10, "[", k, "] => Array(", _6, ")");
@@ -417,14 +417,14 @@ PHP_METHOD(Phalcon_Debug, _getVarDump) {
zephir_fcall_cache_entry *_2 = NULL;
int ZEPHIR_LAST_CALL_STATUS;
- zval *variable, *className, *dumpedObject = NULL, *dump, *_0 = NULL, *_1 = NULL;
+ zval *variable, *className, *dumpedObject = NULL, *_0 = NULL, *_1 = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 0, &variable);
- ZEPHIR_CALL_FUNCTION(&_0, "is_scalar", NULL, 151, variable);
+ ZEPHIR_CALL_FUNCTION(&_0, "is_scalar", NULL, 152, variable);
zephir_check_call_status();
if (zephir_is_true(_0)) {
if (Z_TYPE_P(variable) == IS_BOOL) {
@@ -445,20 +445,20 @@ PHP_METHOD(Phalcon_Debug, _getVarDump) {
if (Z_TYPE_P(variable) == IS_OBJECT) {
ZEPHIR_INIT_VAR(className);
zephir_get_class(className, variable, 0 TSRMLS_CC);
- ZEPHIR_INIT_VAR(dump);
if ((zephir_method_exists_ex(variable, SS("dump") TSRMLS_CC) == SUCCESS)) {
ZEPHIR_CALL_METHOD(&dumpedObject, variable, "dump", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 0, dumpedObject);
zephir_check_call_status();
- ZEPHIR_CONCAT_SVSVS(dump, "Object(", className, ": ", _1, ")");
+ ZEPHIR_CONCAT_SVSVS(return_value, "Object(", className, ": ", _1, ")");
+ RETURN_MM();
} else {
- ZEPHIR_CONCAT_SVS(dump, "Object(", className, ")");
+ ZEPHIR_CONCAT_SVS(return_value, "Object(", className, ")");
+ RETURN_MM();
}
- RETURN_CCTOR(dump);
}
if (Z_TYPE_P(variable) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 152, variable);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getarraydump", &_2, 153, variable);
zephir_check_call_status();
ZEPHIR_CONCAT_SVS(return_value, "Array(", _1, ")");
RETURN_MM();
@@ -482,11 +482,11 @@ PHP_METHOD(Phalcon_Debug, getMajorVersion) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_CE_STATIC(&_0, phalcon_version_ce, "get", &_1, 153);
+ ZEPHIR_CALL_CE_STATIC(&_0, phalcon_version_ce, "get", &_1, 154);
zephir_check_call_status();
ZEPHIR_INIT_VAR(parts);
zephir_fast_explode_str(parts, SL(" "), _0, LONG_MAX TSRMLS_CC);
- zephir_array_fetch_long(&_2, parts, 0, PH_NOISY | PH_READONLY, "phalcon/debug.zep", 290 TSRMLS_CC);
+ zephir_array_fetch_long(&_2, parts, 0, PH_NOISY | PH_READONLY, "phalcon/debug.zep", 289 TSRMLS_CC);
RETURN_CTOR(_2);
}
@@ -504,7 +504,7 @@ PHP_METHOD(Phalcon_Debug, getVersion) {
ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmajorversion", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_CE_STATIC(&_1, phalcon_version_ce, "get", &_2, 153);
+ ZEPHIR_CALL_CE_STATIC(&_1, phalcon_version_ce, "get", &_2, 154);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "");
RETURN_MM();
@@ -563,12 +563,13 @@ PHP_METHOD(Phalcon_Debug, getJsSources) {
*/
PHP_METHOD(Phalcon_Debug, showTraceItem) {
- zephir_fcall_cache_entry *_15 = NULL, *_21 = NULL;
+ zend_bool _24;
+ zephir_fcall_cache_entry *_15 = NULL, *_26 = NULL;
HashTable *_13;
HashPosition _12;
zval *_1, *_17 = NULL;
zval *trace = NULL;
- zval *n_param = NULL, *trace_param = NULL, *space, *twoSpaces, *underscore, *minus, *className, *prepareInternalClass, *preparedFunctionName, *html = NULL, *classReflection, *prepareUriClass, *functionName, *functionReflection, *traceArgs, *arguments, *argument = NULL, *filez, *line = NULL, *showFiles, *lines = NULL, *numberLines, *showFileFragment, *beforeLine, *afterLine, *lastLine = NULL, *commentPattern, *utf8, *entCompat, *tab, *comment, linePosition = zval_used_for_init, *currentLine = NULL, _0, *_2, *_3 = NULL, _4 = zval_used_for_init, _5 = zval_used_for_init, _6 = zval_used_for_init, *_7 = NULL, *_8 = NULL, *_9 = NULL, *_10 = NULL, *_11, **_14, *_16, *_18, *_19 = NULL, *_20 = NULL;
+ zval *n_param = NULL, *trace_param = NULL, *className, *prepareInternalClass, *preparedFunctionName, *html = NULL, *classReflection, *prepareUriClass, *functionName, *functionReflection, *traceArgs, *arguments, *argument = NULL, *filez, *line = NULL, *showFiles, *lines = NULL, *numberLines, *showFileFragment, *beforeLine, *afterLine, *lastLine = NULL, linePosition = zval_used_for_init, *currentLine = NULL, _0, *_2, *_3 = NULL, _4 = zval_used_for_init, _5 = zval_used_for_init, _6 = zval_used_for_init, *_7 = NULL, *_8 = NULL, *_9 = NULL, *_10 = NULL, *_11, **_14, *_16, *_18, *_19 = NULL, _20 = zval_used_for_init, *_21 = NULL, _22 = zval_used_for_init, _23 = zval_used_for_init, _25 = zval_used_for_init;
int n, firstLine, i, ZEPHIR_LAST_CALL_STATUS;
ZEPHIR_MM_GROW();
@@ -579,22 +580,13 @@ PHP_METHOD(Phalcon_Debug, showTraceItem) {
- ZEPHIR_INIT_VAR(space);
- ZVAL_STRING(space, " ", 1);
- ZEPHIR_INIT_VAR(twoSpaces);
- ZVAL_STRING(twoSpaces, " ", 1);
- ZEPHIR_INIT_VAR(underscore);
- ZVAL_STRING(underscore, "_", 1);
- ZEPHIR_INIT_VAR(minus);
- ZVAL_STRING(minus, "-", 1);
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, n);
ZEPHIR_INIT_VAR(_1);
ZEPHIR_CONCAT_SVS(_1, "#", &_0, " | ");
ZEPHIR_CPY_WRT(html, _1);
- if (zephir_array_isset_string(trace, SS("class"))) {
- ZEPHIR_OBS_VAR(className);
- zephir_array_fetch_string(&className, trace, SL("class"), PH_NOISY, "phalcon/debug.zep", 356 TSRMLS_CC);
+ ZEPHIR_OBS_VAR(className);
+ if (zephir_array_isset_string_fetch(&className, trace, SS("class"), 0 TSRMLS_CC)) {
ZEPHIR_INIT_VAR(_2);
ZEPHIR_INIT_VAR(_3);
ZEPHIR_SINIT_VAR(_4);
@@ -615,13 +607,17 @@ PHP_METHOD(Phalcon_Debug, showTraceItem) {
object_init_ex(classReflection, zephir_get_internal_ce(SS("reflectionclass") TSRMLS_CC));
ZEPHIR_CALL_METHOD(NULL, classReflection, "__construct", NULL, 62, className);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, classReflection, "isinternal", NULL, 154);
+ ZEPHIR_CALL_METHOD(&_8, classReflection, "isinternal", NULL, 155);
zephir_check_call_status();
if (zephir_is_true(_8)) {
ZEPHIR_INIT_VAR(_9);
zephir_fast_strtolower(_9, className);
+ ZEPHIR_SINIT_NVAR(_5);
+ ZVAL_STRING(&_5, "_", 0);
+ ZEPHIR_SINIT_NVAR(_6);
+ ZVAL_STRING(&_6, "-", 0);
ZEPHIR_INIT_VAR(prepareInternalClass);
- zephir_fast_str_replace(&prepareInternalClass, underscore, minus, _9 TSRMLS_CC);
+ zephir_fast_str_replace(&prepareInternalClass, &_5, &_6, _9 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVSVS(_7, "", className, "");
zephir_concat_self(&html, _7 TSRMLS_CC);
@@ -631,11 +627,11 @@ PHP_METHOD(Phalcon_Debug, showTraceItem) {
zephir_concat_self(&html, _10 TSRMLS_CC);
}
}
- zephir_array_fetch_string(&_11, trace, SL("type"), PH_NOISY | PH_READONLY, "phalcon/debug.zep", 395 TSRMLS_CC);
+ zephir_array_fetch_string(&_11, trace, SL("type"), PH_NOISY | PH_READONLY, "phalcon/debug.zep", 385 TSRMLS_CC);
zephir_concat_self(&html, _11 TSRMLS_CC);
}
ZEPHIR_OBS_VAR(functionName);
- zephir_array_fetch_string(&functionName, trace, SL("function"), PH_NOISY, "phalcon/debug.zep", 401 TSRMLS_CC);
+ zephir_array_fetch_string(&functionName, trace, SL("function"), PH_NOISY, "phalcon/debug.zep", 391 TSRMLS_CC);
if (zephir_array_isset_string(trace, SS("class"))) {
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVS(_7, "", functionName, "");
@@ -644,13 +640,17 @@ PHP_METHOD(Phalcon_Debug, showTraceItem) {
if ((zephir_function_exists(functionName TSRMLS_CC) == SUCCESS)) {
ZEPHIR_INIT_VAR(functionReflection);
object_init_ex(functionReflection, zephir_get_internal_ce(SS("reflectionfunction") TSRMLS_CC));
- ZEPHIR_CALL_METHOD(NULL, functionReflection, "__construct", NULL, 155, functionName);
+ ZEPHIR_CALL_METHOD(NULL, functionReflection, "__construct", NULL, 156, functionName);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_8, functionReflection, "isinternal", NULL, 156);
+ ZEPHIR_CALL_METHOD(&_8, functionReflection, "isinternal", NULL, 157);
zephir_check_call_status();
if (zephir_is_true(_8)) {
+ ZEPHIR_SINIT_NVAR(_4);
+ ZVAL_STRING(&_4, "_", 0);
+ ZEPHIR_SINIT_NVAR(_5);
+ ZVAL_STRING(&_5, "-", 0);
ZEPHIR_INIT_VAR(preparedFunctionName);
- zephir_fast_str_replace(&preparedFunctionName, underscore, minus, functionName TSRMLS_CC);
+ zephir_fast_str_replace(&preparedFunctionName, &_4, &_5, functionName TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_10);
ZEPHIR_CONCAT_SVSVS(_10, "", functionName, "");
zephir_concat_self(&html, _10 TSRMLS_CC);
@@ -665,13 +665,12 @@ PHP_METHOD(Phalcon_Debug, showTraceItem) {
zephir_concat_self(&html, _7 TSRMLS_CC);
}
}
- if (zephir_array_isset_string(trace, SS("args"))) {
- ZEPHIR_OBS_VAR(traceArgs);
- zephir_array_fetch_string(&traceArgs, trace, SL("args"), PH_NOISY, "phalcon/debug.zep", 435 TSRMLS_CC);
+ ZEPHIR_OBS_VAR(traceArgs);
+ if (zephir_array_isset_string_fetch(&traceArgs, trace, SS("args"), 0 TSRMLS_CC)) {
if (zephir_fast_count_int(traceArgs TSRMLS_CC)) {
ZEPHIR_INIT_VAR(arguments);
array_init(arguments);
- zephir_is_iterable(traceArgs, &_13, &_12, 0, 0, "phalcon/debug.zep", 450);
+ zephir_is_iterable(traceArgs, &_13, &_12, 0, 0, "phalcon/debug.zep", 439);
for (
; zephir_hash_get_current_data_ex(_13, (void**) &_14, &_12) == SUCCESS
; zephir_hash_move_forward_ex(_13, &_12)
@@ -681,7 +680,7 @@ PHP_METHOD(Phalcon_Debug, showTraceItem) {
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVS(_7, "", _8, "");
- zephir_array_append(&arguments, _7, PH_SEPARATE, "phalcon/debug.zep", 444);
+ zephir_array_append(&arguments, _7, PH_SEPARATE, "phalcon/debug.zep", 433);
}
ZEPHIR_INIT_NVAR(_3);
zephir_fast_join_str(_3, SL(", "), arguments TSRMLS_CC);
@@ -695,7 +694,7 @@ PHP_METHOD(Phalcon_Debug, showTraceItem) {
ZEPHIR_OBS_VAR(filez);
if (zephir_array_isset_string_fetch(&filez, trace, SS("file"), 0 TSRMLS_CC)) {
ZEPHIR_OBS_VAR(_16);
- zephir_array_fetch_string(&_16, trace, SL("line"), PH_NOISY, "phalcon/debug.zep", 461 TSRMLS_CC);
+ zephir_array_fetch_string(&_16, trace, SL("line"), PH_NOISY, "phalcon/debug.zep", 450 TSRMLS_CC);
zephir_get_strval(_17, _16);
ZEPHIR_CPY_WRT(line, _17);
ZEPHIR_INIT_LNVAR(_7);
@@ -704,7 +703,7 @@ PHP_METHOD(Phalcon_Debug, showTraceItem) {
ZEPHIR_OBS_VAR(showFiles);
zephir_read_property_this(&showFiles, this_ptr, SL("_showFiles"), PH_NOISY_CC);
if (zephir_is_true(showFiles)) {
- ZEPHIR_CALL_FUNCTION(&lines, "file", NULL, 157, filez);
+ ZEPHIR_CALL_FUNCTION(&lines, "file", NULL, 158, filez);
zephir_check_call_status();
ZEPHIR_INIT_VAR(numberLines);
ZVAL_LONG(numberLines, zephir_fast_count_int(lines TSRMLS_CC));
@@ -741,16 +740,6 @@ PHP_METHOD(Phalcon_Debug, showTraceItem) {
ZEPHIR_CONCAT_SVSVS(_10, "");
zephir_concat_self(&html, _10 TSRMLS_CC);
}
- ZEPHIR_INIT_VAR(commentPattern);
- ZVAL_STRING(commentPattern, "#\\*\\/#", 1);
- ZEPHIR_INIT_VAR(utf8);
- ZVAL_STRING(utf8, "UTF-8", 1);
- ZEPHIR_INIT_VAR(entCompat);
- ZVAL_LONG(entCompat, 2);
- ZEPHIR_INIT_VAR(tab);
- ZVAL_STRING(tab, "\t", 1);
- ZEPHIR_INIT_VAR(comment);
- ZVAL_STRING(comment, "* /", 1);
i = firstLine;
while (1) {
if (!(ZEPHIR_GE_LONG(lastLine, i))) {
@@ -759,33 +748,47 @@ PHP_METHOD(Phalcon_Debug, showTraceItem) {
ZEPHIR_SINIT_NVAR(linePosition);
ZVAL_LONG(&linePosition, (i - 1));
ZEPHIR_OBS_NVAR(currentLine);
- zephir_array_fetch(¤tLine, lines, &linePosition, PH_NOISY, "phalcon/debug.zep", 549 TSRMLS_CC);
+ zephir_array_fetch(¤tLine, lines, &linePosition, PH_NOISY, "phalcon/debug.zep", 523 TSRMLS_CC);
if (zephir_is_true(showFileFragment)) {
if (i == firstLine) {
ZEPHIR_INIT_NVAR(_19);
ZEPHIR_INIT_NVAR(_3);
ZEPHIR_INIT_NVAR(_9);
zephir_fast_trim(_9, currentLine, NULL , ZEPHIR_TRIM_RIGHT TSRMLS_CC);
- zephir_preg_match(_3, commentPattern, _9, _19, 0, 0 , 0 TSRMLS_CC);
+ ZEPHIR_SINIT_NVAR(_20);
+ ZVAL_STRING(&_20, "#\\*\\/#", 0);
+ zephir_preg_match(_3, &_20, _9, _19, 0, 0 , 0 TSRMLS_CC);
if (zephir_is_true(_3)) {
- ZEPHIR_INIT_NVAR(_20);
- zephir_fast_str_replace(&_20, comment, space, currentLine TSRMLS_CC);
- ZEPHIR_CPY_WRT(currentLine, _20);
+ ZEPHIR_INIT_NVAR(_21);
+ ZEPHIR_SINIT_NVAR(_22);
+ ZVAL_STRING(&_22, "* /", 0);
+ ZEPHIR_SINIT_NVAR(_23);
+ ZVAL_STRING(&_23, " ", 0);
+ zephir_fast_str_replace(&_21, &_22, &_23, currentLine TSRMLS_CC);
+ ZEPHIR_CPY_WRT(currentLine, _21);
}
}
}
- if (ZEPHIR_IS_STRING(currentLine, "\n")) {
+ _24 = ZEPHIR_IS_STRING(currentLine, "\n");
+ if (!(_24)) {
+ _24 = ZEPHIR_IS_STRING(currentLine, "\r\n");
+ }
+ if (_24) {
zephir_concat_self_str(&html, SL(" \n") TSRMLS_CC);
} else {
- if (ZEPHIR_IS_STRING(currentLine, "\r\n")) {
- zephir_concat_self_str(&html, SL(" \n") TSRMLS_CC);
- } else {
- ZEPHIR_INIT_NVAR(_20);
- zephir_fast_str_replace(&_20, tab, twoSpaces, currentLine TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_8, "htmlentities", &_21, 150, _20, entCompat, utf8);
- zephir_check_call_status();
- zephir_concat_self(&html, _8 TSRMLS_CC);
- }
+ ZEPHIR_INIT_NVAR(_21);
+ ZEPHIR_SINIT_NVAR(_20);
+ ZVAL_STRING(&_20, "\t", 0);
+ ZEPHIR_SINIT_NVAR(_22);
+ ZVAL_STRING(&_22, " ", 0);
+ zephir_fast_str_replace(&_21, &_20, &_22, currentLine TSRMLS_CC);
+ ZEPHIR_SINIT_NVAR(_23);
+ ZVAL_LONG(&_23, 2);
+ ZEPHIR_SINIT_NVAR(_25);
+ ZVAL_STRING(&_25, "UTF-8", 0);
+ ZEPHIR_CALL_FUNCTION(&_8, "htmlentities", &_26, 151, _21, &_23, &_25);
+ zephir_check_call_status();
+ zephir_concat_self(&html, _8 TSRMLS_CC);
}
i++;
}
@@ -810,7 +813,7 @@ PHP_METHOD(Phalcon_Debug, onUncaughtLowSeverity) {
- ZEPHIR_CALL_FUNCTION(&_0, "error_reporting", NULL, 158);
+ ZEPHIR_CALL_FUNCTION(&_0, "error_reporting", NULL, 159);
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_1);
zephir_bitwise_and_function(&_1, _0, severity TSRMLS_CC);
@@ -819,9 +822,9 @@ PHP_METHOD(Phalcon_Debug, onUncaughtLowSeverity) {
object_init_ex(_2, zephir_get_internal_ce(SS("errorexception") TSRMLS_CC));
ZEPHIR_INIT_VAR(_3);
ZVAL_LONG(_3, 0);
- ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 159, message, _3, severity, file, line);
+ ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 160, message, _3, severity, file, line);
zephir_check_call_status();
- zephir_throw_exception_debug(_2, "phalcon/debug.zep", 592 TSRMLS_CC);
+ zephir_throw_exception_debug(_2, "phalcon/debug.zep", 566 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -847,7 +850,7 @@ PHP_METHOD(Phalcon_Debug, onUncaughtException) {
- ZEPHIR_CALL_FUNCTION(&obLevel, "ob_get_level", NULL, 160);
+ ZEPHIR_CALL_FUNCTION(&obLevel, "ob_get_level", NULL, 161);
zephir_check_call_status();
if (ZEPHIR_GT_LONG(obLevel, 0)) {
ZEPHIR_CALL_FUNCTION(NULL, "ob_end_clean", NULL, 118);
@@ -907,21 +910,21 @@ PHP_METHOD(Phalcon_Debug, onUncaughtException) {
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
ZEPHIR_CALL_METHOD(&_9, exception, "gettrace", NULL, 0);
zephir_check_call_status();
- zephir_is_iterable(_9, &_11, &_10, 0, 0, "phalcon/debug.zep", 686);
+ zephir_is_iterable(_9, &_11, &_10, 0, 0, "phalcon/debug.zep", 660);
for (
; zephir_hash_get_current_data_ex(_11, (void**) &_12, &_10) == SUCCESS
; zephir_hash_move_forward_ex(_11, &_10)
) {
ZEPHIR_GET_HMKEY(n, _11, _10);
ZEPHIR_GET_HVALUE(traceItem, _12);
- ZEPHIR_CALL_METHOD(&_13, this_ptr, "showtraceitem", &_14, 161, n, traceItem);
+ ZEPHIR_CALL_METHOD(&_13, this_ptr, "showtraceitem", &_14, 162, n, traceItem);
zephir_check_call_status();
zephir_concat_self(&html, _13 TSRMLS_CC);
}
zephir_concat_self_str(&html, SL(" ") TSRMLS_CC);
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
zephir_concat_self_str(&html, SL("Key | Value | ") TSRMLS_CC);
- zephir_is_iterable(_REQUEST, &_16, &_15, 0, 0, "phalcon/debug.zep", 700);
+ zephir_is_iterable(_REQUEST, &_16, &_15, 0, 0, "phalcon/debug.zep", 674);
for (
; zephir_hash_get_current_data_ex(_16, (void**) &_17, &_15) == SUCCESS
; zephir_hash_move_forward_ex(_16, &_15)
@@ -933,7 +936,7 @@ PHP_METHOD(Phalcon_Debug, onUncaughtException) {
ZEPHIR_CONCAT_SVSVS(_18, "", keyRequest, " | ", value, " | ");
zephir_concat_self(&html, _18 TSRMLS_CC);
} else {
- ZEPHIR_CALL_FUNCTION(&_13, "print_r", &_19, 162, value, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(&_13, "print_r", &_19, 163, value, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_18);
ZEPHIR_CONCAT_SVSVS(_18, "", keyRequest, " | ", _13, " | ");
@@ -943,7 +946,7 @@ PHP_METHOD(Phalcon_Debug, onUncaughtException) {
zephir_concat_self_str(&html, SL(" ") TSRMLS_CC);
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
zephir_concat_self_str(&html, SL("Key | Value | ") TSRMLS_CC);
- zephir_is_iterable(_SERVER, &_21, &_20, 0, 0, "phalcon/debug.zep", 710);
+ zephir_is_iterable(_SERVER, &_21, &_20, 0, 0, "phalcon/debug.zep", 684);
for (
; zephir_hash_get_current_data_ex(_21, (void**) &_22, &_20) == SUCCESS
; zephir_hash_move_forward_ex(_21, &_20)
@@ -959,9 +962,9 @@ PHP_METHOD(Phalcon_Debug, onUncaughtException) {
zephir_concat_self_str(&html, SL(" ") TSRMLS_CC);
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
zephir_concat_self_str(&html, SL("# | Path | ") TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_13, "get_included_files", NULL, 163);
+ ZEPHIR_CALL_FUNCTION(&_13, "get_included_files", NULL, 164);
zephir_check_call_status();
- zephir_is_iterable(_13, &_25, &_24, 0, 0, "phalcon/debug.zep", 720);
+ zephir_is_iterable(_13, &_25, &_24, 0, 0, "phalcon/debug.zep", 694);
for (
; zephir_hash_get_current_data_ex(_25, (void**) &_26, &_24) == SUCCESS
; zephir_hash_move_forward_ex(_25, &_24)
@@ -974,7 +977,7 @@ PHP_METHOD(Phalcon_Debug, onUncaughtException) {
}
zephir_concat_self_str(&html, SL(" ") TSRMLS_CC);
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_13, "memory_get_usage", NULL, 164, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(&_13, "memory_get_usage", NULL, 165, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_27);
ZEPHIR_CONCAT_SVS(_27, "Memory |
---|
Usage | ", _13, " | ");
@@ -983,14 +986,14 @@ PHP_METHOD(Phalcon_Debug, onUncaughtException) {
if (Z_TYPE_P(dataVars) == IS_ARRAY) {
zephir_concat_self_str(&html, SL("") TSRMLS_CC);
zephir_concat_self_str(&html, SL("Key | Value | ") TSRMLS_CC);
- zephir_is_iterable(dataVars, &_29, &_28, 0, 0, "phalcon/debug.zep", 738);
+ zephir_is_iterable(dataVars, &_29, &_28, 0, 0, "phalcon/debug.zep", 712);
for (
; zephir_hash_get_current_data_ex(_29, (void**) &_30, &_28) == SUCCESS
; zephir_hash_move_forward_ex(_29, &_28)
) {
ZEPHIR_GET_HMKEY(keyVar, _29, _28);
ZEPHIR_GET_HVALUE(dataVar, _30);
- zephir_array_fetch_long(&_32, dataVar, 0, PH_NOISY | PH_READONLY, "phalcon/debug.zep", 736 TSRMLS_CC);
+ zephir_array_fetch_long(&_32, dataVar, 0, PH_NOISY | PH_READONLY, "phalcon/debug.zep", 710 TSRMLS_CC);
ZEPHIR_CALL_METHOD(&_31, this_ptr, "_getvardump", &_23, 0, _32);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_33);
diff --git a/ext/phalcon/debug/dump.zep.c b/ext/phalcon/debug/dump.zep.c
index a3c1c82e250..a5d81c14def 100644
--- a/ext/phalcon/debug/dump.zep.c
+++ b/ext/phalcon/debug/dump.zep.c
@@ -140,7 +140,7 @@ PHP_METHOD(Phalcon_Debug_Dump, all) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "variables", 1);
zephir_array_fast_append(_0, _1);
- ZEPHIR_CALL_FUNCTION(&_2, "func_get_args", NULL, 165);
+ ZEPHIR_CALL_FUNCTION(&_2, "func_get_args", NULL, 166);
zephir_check_call_status();
ZEPHIR_CALL_USER_FUNC_ARRAY(return_value, _0, _2);
zephir_check_call_status();
@@ -352,7 +352,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) {
ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, (tab + 1));
- ZEPHIR_CALL_METHOD(&_18, this_ptr, "output", &_19, 166, value, _3, &_5);
+ ZEPHIR_CALL_METHOD(&_18, this_ptr, "output", &_19, 167, value, _3, &_5);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_20);
@@ -384,7 +384,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) {
ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
zephir_concat_self(&output, _2 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_13, "get_parent_class", &_21, 167, variable);
+ ZEPHIR_CALL_FUNCTION(&_13, "get_parent_class", &_21, 168, variable);
zephir_check_call_status();
if (zephir_is_true(_13)) {
ZEPHIR_INIT_NVAR(_12);
@@ -395,7 +395,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_check_temp_parameter(_3);
zephir_check_call_status();
zephir_array_update_string(&_12, SL(":style"), &_18, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_FUNCTION(&_18, "get_parent_class", &_21, 167, variable);
+ ZEPHIR_CALL_FUNCTION(&_18, "get_parent_class", &_21, 168, variable);
zephir_check_call_status();
zephir_array_update_string(&_12, SL(":parent"), &_18, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
@@ -441,7 +441,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) {
ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, (tab + 1));
- ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 166, value, _3, &_5);
+ ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 167, value, _3, &_5);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_20);
@@ -451,7 +451,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) {
} else {
do {
Z_SET_ISREF_P(variable);
- ZEPHIR_CALL_FUNCTION(&attr, "each", &_28, 168, variable);
+ ZEPHIR_CALL_FUNCTION(&attr, "each", &_28, 169, variable);
Z_UNSET_ISREF_P(variable);
zephir_check_call_status();
if (!(zephir_is_true(attr))) {
@@ -497,7 +497,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_check_call_status();
zephir_array_update_string(&_12, SL(":style"), &_26, PH_COPY | PH_SEPARATE);
Z_SET_ISREF_P(key);
- ZEPHIR_CALL_FUNCTION(&_26, "end", &_32, 169, key);
+ ZEPHIR_CALL_FUNCTION(&_26, "end", &_32, 170, key);
Z_UNSET_ISREF_P(key);
zephir_check_call_status();
zephir_array_update_string(&_12, SL(":key"), &_26, PH_COPY | PH_SEPARATE);
@@ -513,7 +513,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) {
ZVAL_STRING(_3, "", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, (tab + 1));
- ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 166, value, _3, &_5);
+ ZEPHIR_CALL_METHOD(&_27, this_ptr, "output", &_19, 167, value, _3, &_5);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_20);
@@ -521,7 +521,7 @@ PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_concat_self(&output, _20 TSRMLS_CC);
} while (zephir_is_true(attr));
}
- ZEPHIR_CALL_FUNCTION(&attr, "get_class_methods", NULL, 170, variable);
+ ZEPHIR_CALL_FUNCTION(&attr, "get_class_methods", NULL, 171, variable);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, tab);
@@ -638,11 +638,12 @@ PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Integer (:var)", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
- ZEPHIR_CALL_FUNCTION(&_2, "is_float", NULL, 171, variable);
+ ZEPHIR_CALL_FUNCTION(&_2, "is_float", NULL, 172, variable);
zephir_check_call_status();
if (zephir_is_true(_2)) {
ZEPHIR_INIT_NVAR(_1);
@@ -656,8 +657,9 @@ PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Float (:var)", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_13, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _13);
RETURN_MM();
}
if (zephir_is_numeric(variable)) {
@@ -673,8 +675,9 @@ PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Numeric string (:length) \":var\"", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
if (Z_TYPE_P(variable) == IS_STRING) {
@@ -691,15 +694,16 @@ PHP_METHOD(Phalcon_Debug_Dump, output) {
ZVAL_LONG(&_5, 4);
ZEPHIR_SINIT_VAR(_40);
ZVAL_STRING(&_40, "utf-8", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "htmlentities", NULL, 150, variable, &_5, &_40);
+ ZEPHIR_CALL_FUNCTION(&_2, "htmlentities", NULL, 151, variable, &_5, &_40);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_13, "nl2br", NULL, 172, _2);
+ ZEPHIR_CALL_FUNCTION(&_26, "nl2br", NULL, 173, _2);
zephir_check_call_status();
- zephir_array_update_string(&_1, SL(":var"), &_13, PH_COPY | PH_SEPARATE);
+ zephir_array_update_string(&_1, SL(":var"), &_26, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "String (:length) \":var\"", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_26, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _26);
RETURN_MM();
}
if (Z_TYPE_P(variable) == IS_BOOL) {
@@ -722,8 +726,9 @@ PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &_14, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Boolean (:var)", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
if (Z_TYPE_P(variable) == IS_NULL) {
@@ -737,8 +742,9 @@ PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":style"), &_2, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "NULL", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
ZEPHIR_INIT_NVAR(_1);
@@ -752,8 +758,9 @@ PHP_METHOD(Phalcon_Debug_Dump, output) {
zephir_array_update_string(&_1, SL(":var"), &variable, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "(:var)", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("strtr", &_6, 53, &_5, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", &_6, 53, &_5, _1);
zephir_check_call_status();
+ ZEPHIR_CONCAT_VV(return_value, output, _2);
RETURN_MM();
}
@@ -828,7 +835,7 @@ PHP_METHOD(Phalcon_Debug_Dump, variables) {
ZEPHIR_INIT_VAR(output);
ZVAL_STRING(output, "", 1);
- ZEPHIR_CALL_FUNCTION(&_0, "func_get_args", NULL, 165);
+ ZEPHIR_CALL_FUNCTION(&_0, "func_get_args", NULL, 166);
zephir_check_call_status();
zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/debug/dump.zep", 290);
for (
diff --git a/ext/phalcon/di.zep.c b/ext/phalcon/di.zep.c
index 8f9dd27a75a..d498dd96427 100644
--- a/ext/phalcon/di.zep.c
+++ b/ext/phalcon/di.zep.c
@@ -211,10 +211,11 @@ PHP_METHOD(Phalcon_Di, setShared) {
/**
* Removes a service in the services container
+ * It also removes any shared instance created for the service
*/
PHP_METHOD(Phalcon_Di, remove) {
- zval *name_param = NULL, *_0;
+ zval *name_param = NULL, *_0, *_1;
zval *name = NULL;
ZEPHIR_MM_GROW();
@@ -235,6 +236,8 @@ PHP_METHOD(Phalcon_Di, remove) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_services"), PH_NOISY_CC);
zephir_array_unset(&_0, name, PH_SEPARATE);
+ _1 = zephir_fetch_nproperty_this(this_ptr, SL("_sharedInstances"), PH_NOISY_CC);
+ zephir_array_unset(&_1, name, PH_SEPARATE);
ZEPHIR_MM_RESTORE();
}
@@ -353,7 +356,7 @@ PHP_METHOD(Phalcon_Di, getRaw) {
ZEPHIR_CONCAT_SVS(_2, "Service '", name, "' wasn't found in the dependency injection container");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/di.zep", 187 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/di.zep", 189 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -395,7 +398,7 @@ PHP_METHOD(Phalcon_Di, getService) {
ZEPHIR_CONCAT_SVS(_2, "Service '", name, "' wasn't found in the dependency injection container");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/di.zep", 201 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/di.zep", 203 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -456,7 +459,7 @@ PHP_METHOD(Phalcon_Di, get) {
ZEPHIR_CONCAT_SVS(_3, "Service '", name, "' wasn't found in the dependency injection container");
ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_2, "phalcon/di.zep", 227 TSRMLS_CC);
+ zephir_throw_exception_debug(_2, "phalcon/di.zep", 229 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -829,7 +832,7 @@ PHP_METHOD(Phalcon_Di, __call) {
ZEPHIR_CONCAT_SVS(_5, "Call to undefined method or service '", method, "'");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _5);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/di.zep", 425 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/di.zep", 427 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
diff --git a/ext/phalcon/di/factorydefault/cli.zep.c b/ext/phalcon/di/factorydefault/cli.zep.c
index 5b9d07fe522..eff6410c256 100644
--- a/ext/phalcon/di/factorydefault/cli.zep.c
+++ b/ext/phalcon/di/factorydefault/cli.zep.c
@@ -46,7 +46,7 @@ PHP_METHOD(Phalcon_Di_FactoryDefault_Cli, __construct) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_cli_ce, this_ptr, "__construct", &_0, 173);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_di_factorydefault_cli_ce, this_ptr, "__construct", &_0, 174);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_1);
zephir_create_array(_1, 10, 0 TSRMLS_CC);
diff --git a/ext/phalcon/di/service.zep.c b/ext/phalcon/di/service.zep.c
index 021ebbb8f27..4867d262366 100644
--- a/ext/phalcon/di/service.zep.c
+++ b/ext/phalcon/di/service.zep.c
@@ -258,7 +258,7 @@ PHP_METHOD(Phalcon_Di_Service, resolve) {
ZEPHIR_CALL_METHOD(NULL, builder, "__construct", NULL, 0);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&instance, builder, "build", NULL, 174, dependencyInjector, definition, parameters);
+ ZEPHIR_CALL_METHOD(&instance, builder, "build", NULL, 175, dependencyInjector, definition, parameters);
zephir_check_call_status();
} else {
found = 0;
diff --git a/ext/phalcon/di/service/builder.zep.c b/ext/phalcon/di/service/builder.zep.c
index 20d9a40a826..d6c44ad9c90 100644
--- a/ext/phalcon/di/service/builder.zep.c
+++ b/ext/phalcon/di/service/builder.zep.c
@@ -188,7 +188,7 @@ PHP_METHOD(Phalcon_Di_Service_Builder, _buildParameters) {
) {
ZEPHIR_GET_HMKEY(position, _1, _0);
ZEPHIR_GET_HVALUE(argument, _2);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_buildparameter", &_4, 175, dependencyInjector, position, argument);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_buildparameter", &_4, 176, dependencyInjector, position, argument);
zephir_check_call_status();
zephir_array_append(&buildArguments, _3, PH_SEPARATE, "phalcon/di/service/builder.zep", 117);
}
@@ -241,7 +241,7 @@ PHP_METHOD(Phalcon_Di_Service_Builder, build) {
} else {
ZEPHIR_OBS_VAR(arguments);
if (zephir_array_isset_string_fetch(&arguments, definition, SS("arguments"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 176, dependencyInjector, arguments);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 177, dependencyInjector, arguments);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(instance);
ZEPHIR_LAST_CALL_STATUS = zephir_create_instance_params(instance, className, _0 TSRMLS_CC);
@@ -311,7 +311,7 @@ PHP_METHOD(Phalcon_Di_Service_Builder, build) {
}
if (zephir_fast_count_int(arguments TSRMLS_CC)) {
ZEPHIR_INIT_NVAR(_5);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 176, dependencyInjector, arguments);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameters", &_1, 177, dependencyInjector, arguments);
zephir_check_call_status();
ZEPHIR_CALL_USER_FUNC_ARRAY(_5, methodCall, _0);
zephir_check_call_status();
@@ -375,7 +375,7 @@ PHP_METHOD(Phalcon_Di_Service_Builder, build) {
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameter", &_12, 175, dependencyInjector, propertyPosition, propertyValue);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_buildparameter", &_12, 176, dependencyInjector, propertyPosition, propertyValue);
zephir_check_call_status();
zephir_update_property_zval_zval(instance, propertyName, _0 TSRMLS_CC);
}
diff --git a/ext/phalcon/diinterface.zep.c b/ext/phalcon/diinterface.zep.c
index e6129a9d959..3148f1ffac6 100644
--- a/ext/phalcon/diinterface.zep.c
+++ b/ext/phalcon/diinterface.zep.c
@@ -111,7 +111,7 @@ ZEPHIR_DOC_METHOD(Phalcon_DiInterface, wasFreshInstance);
/**
* Return the services registered in the DI
*
- * @return array
+ * @return \Phalcon\Di\ServiceInterface[]
*/
ZEPHIR_DOC_METHOD(Phalcon_DiInterface, getServices);
diff --git a/ext/phalcon/escaper.zep.c b/ext/phalcon/escaper.zep.c
index 250269454bc..9ac3dd53f1a 100644
--- a/ext/phalcon/escaper.zep.c
+++ b/ext/phalcon/escaper.zep.c
@@ -155,13 +155,13 @@ PHP_METHOD(Phalcon_Escaper, detectEncoding) {
; zephir_hash_move_forward_ex(_3, &_2)
) {
ZEPHIR_GET_HVALUE(charset, _4);
- ZEPHIR_CALL_FUNCTION(&_5, "mb_detect_encoding", &_6, 177, str, charset, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(&_5, "mb_detect_encoding", &_6, 178, str, charset, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
if (zephir_is_true(_5)) {
RETURN_CCTOR(charset);
}
}
- ZEPHIR_RETURN_CALL_FUNCTION("mb_detect_encoding", &_6, 177, str);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_detect_encoding", &_6, 178, str);
zephir_check_call_status();
RETURN_MM();
@@ -186,11 +186,11 @@ PHP_METHOD(Phalcon_Escaper, normalizeEncoding) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_escaper_exception_ce, "Extension 'mbstring' is required", "phalcon/escaper.zep", 128);
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "detectencoding", NULL, 178, str);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "detectencoding", NULL, 179, str);
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "UTF-32", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 179, str, &_1, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 180, str, &_1, _0);
zephir_check_call_status();
RETURN_MM();
@@ -213,7 +213,7 @@ PHP_METHOD(Phalcon_Escaper, escapeHtml) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_htmlQuoteType"), PH_NOISY_CC);
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_encoding"), PH_NOISY_CC);
- ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 180, text, _0, _1);
+ ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 181, text, _0, _1);
zephir_check_call_status();
RETURN_MM();
@@ -237,7 +237,7 @@ PHP_METHOD(Phalcon_Escaper, escapeHtmlAttr) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_encoding"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, 3);
- ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 180, attribute, &_1, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("htmlspecialchars", NULL, 181, attribute, &_1, _0);
zephir_check_call_status();
RETURN_MM();
@@ -258,7 +258,7 @@ PHP_METHOD(Phalcon_Escaper, escapeCss) {
zephir_get_strval(css, css_param);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 181, css);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 182, css);
zephir_check_call_status();
zephir_escape_css(return_value, _0);
RETURN_MM();
@@ -280,7 +280,7 @@ PHP_METHOD(Phalcon_Escaper, escapeJs) {
zephir_get_strval(js, js_param);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 181, js);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "normalizeencoding", NULL, 182, js);
zephir_check_call_status();
zephir_escape_js(return_value, _0);
RETURN_MM();
@@ -302,7 +302,7 @@ PHP_METHOD(Phalcon_Escaper, escapeUrl) {
zephir_get_strval(url, url_param);
- ZEPHIR_RETURN_CALL_FUNCTION("rawurlencode", NULL, 182, url);
+ ZEPHIR_RETURN_CALL_FUNCTION("rawurlencode", NULL, 183, url);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/events/manager.zep.c b/ext/phalcon/events/manager.zep.c
index a6ba911d405..705234658e0 100644
--- a/ext/phalcon/events/manager.zep.c
+++ b/ext/phalcon/events/manager.zep.c
@@ -107,7 +107,7 @@ PHP_METHOD(Phalcon_Events_Manager, attach) {
}
ZEPHIR_INIT_VAR(_2);
ZVAL_LONG(_2, 1);
- ZEPHIR_CALL_METHOD(NULL, priorityQueue, "setextractflags", NULL, 183, _2);
+ ZEPHIR_CALL_METHOD(NULL, priorityQueue, "setextractflags", NULL, 184, _2);
zephir_check_call_status();
zephir_update_property_array(this_ptr, SL("_events"), eventType, priorityQueue TSRMLS_CC);
} else {
@@ -117,7 +117,7 @@ PHP_METHOD(Phalcon_Events_Manager, attach) {
if (Z_TYPE_P(priorityQueue) == IS_OBJECT) {
ZEPHIR_INIT_NVAR(_2);
ZVAL_LONG(_2, priority);
- ZEPHIR_CALL_METHOD(NULL, priorityQueue, "insert", NULL, 184, handler, _2);
+ ZEPHIR_CALL_METHOD(NULL, priorityQueue, "insert", NULL, 185, handler, _2);
zephir_check_call_status();
} else {
zephir_array_append(&priorityQueue, handler, PH_SEPARATE, "phalcon/events/manager.zep", 82);
@@ -172,7 +172,7 @@ PHP_METHOD(Phalcon_Events_Manager, detach) {
}
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, 1);
- ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "setextractflags", NULL, 183, _1);
+ ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "setextractflags", NULL, 184, _1);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_1);
ZVAL_LONG(_1, 3);
@@ -194,13 +194,13 @@ PHP_METHOD(Phalcon_Events_Manager, detach) {
if (!ZEPHIR_IS_IDENTICAL(_5, handler)) {
zephir_array_fetch_string(&_6, data, SL("data"), PH_NOISY | PH_READONLY, "phalcon/events/manager.zep", 117 TSRMLS_CC);
zephir_array_fetch_string(&_7, data, SL("priority"), PH_NOISY | PH_READONLY, "phalcon/events/manager.zep", 117 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "insert", &_8, 184, _6, _7);
+ ZEPHIR_CALL_METHOD(NULL, newPriorityQueue, "insert", &_8, 185, _6, _7);
zephir_check_call_status();
}
}
zephir_update_property_array(this_ptr, SL("_events"), eventType, newPriorityQueue TSRMLS_CC);
} else {
- ZEPHIR_CALL_FUNCTION(&key, "array_search", NULL, 185, handler, priorityQueue, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(&key, "array_search", NULL, 186, handler, priorityQueue, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
if (!ZEPHIR_IS_FALSE_IDENTICAL(key)) {
zephir_array_unset(&priorityQueue, key, PH_SEPARATE);
@@ -388,7 +388,7 @@ PHP_METHOD(Phalcon_Events_Manager, fireQueue) {
zephir_get_class(_1, queue, 0 TSRMLS_CC);
ZEPHIR_SINIT_VAR(_2);
ZVAL_STRING(&_2, "Unexpected value type: expected object of type SplPriorityQueue, %s given", 0);
- ZEPHIR_CALL_FUNCTION(&_3, "sprintf", NULL, 186, &_2, _1);
+ ZEPHIR_CALL_FUNCTION(&_3, "sprintf", NULL, 187, &_2, _1);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3);
zephir_check_call_status();
@@ -531,7 +531,7 @@ PHP_METHOD(Phalcon_Events_Manager, fireQueue) {
}
/**
- * Fires an event in the events manager causing that active listeners be notified about it
+ * Fires an event in the events manager causing the active listeners to be notified about it
*
*
* $eventsManager->fire('db', $connection);
@@ -614,9 +614,9 @@ PHP_METHOD(Phalcon_Events_Manager, fire) {
if (_3) {
ZEPHIR_INIT_NVAR(event);
object_init_ex(event, phalcon_events_event_ce);
- ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 187, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 188, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 188, fireEvents, event);
+ ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 189, fireEvents, event);
zephir_check_call_status();
}
}
@@ -630,10 +630,10 @@ PHP_METHOD(Phalcon_Events_Manager, fire) {
if (Z_TYPE_P(event) == IS_NULL) {
ZEPHIR_INIT_NVAR(event);
object_init_ex(event, phalcon_events_event_ce);
- ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 187, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(NULL, event, "__construct", &_4, 188, eventName, source, data, (cancelable ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 188, fireEvents, event);
+ ZEPHIR_CALL_METHOD(&status, this_ptr, "firequeue", &_5, 189, fireEvents, event);
zephir_check_call_status();
}
}
diff --git a/ext/phalcon/events/managerinterface.zep.c b/ext/phalcon/events/managerinterface.zep.c
index 48043443c2a..30d8d200c27 100644
--- a/ext/phalcon/events/managerinterface.zep.c
+++ b/ext/phalcon/events/managerinterface.zep.c
@@ -49,7 +49,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Events_ManagerInterface, detach);
ZEPHIR_DOC_METHOD(Phalcon_Events_ManagerInterface, detachAll);
/**
- * Fires a event in the events manager causing that the acive listeners will be notified about it
+ * Fires an event in the events manager causing the active listeners to be notified about it
*
* @param string eventType
* @param object source
diff --git a/ext/phalcon/filter.zep.c b/ext/phalcon/filter.zep.c
index c6cfe0e8661..30b575a4c5a 100644
--- a/ext/phalcon/filter.zep.c
+++ b/ext/phalcon/filter.zep.c
@@ -250,16 +250,16 @@ PHP_METHOD(Phalcon_Filter, _sanitize) {
if (ZEPHIR_IS_STRING(filter, "email")) {
ZEPHIR_SINIT_VAR(_3);
ZVAL_STRING(&_3, "FILTER_SANITIZE_EMAIL", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 189, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 190, &_3);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 190, value, _4);
+ ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, _4);
zephir_check_call_status();
RETURN_MM();
}
if (ZEPHIR_IS_STRING(filter, "int")) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 519);
- ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 190, value, &_3);
+ ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3);
zephir_check_call_status();
RETURN_MM();
}
@@ -269,14 +269,14 @@ PHP_METHOD(Phalcon_Filter, _sanitize) {
if (ZEPHIR_IS_STRING(filter, "absint")) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, zephir_get_intval(value));
- ZEPHIR_RETURN_CALL_FUNCTION("abs", NULL, 191, &_3);
+ ZEPHIR_RETURN_CALL_FUNCTION("abs", NULL, 192, &_3);
zephir_check_call_status();
RETURN_MM();
}
if (ZEPHIR_IS_STRING(filter, "string")) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 513);
- ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 190, value, &_3);
+ ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3);
zephir_check_call_status();
RETURN_MM();
}
@@ -286,7 +286,7 @@ PHP_METHOD(Phalcon_Filter, _sanitize) {
add_assoc_long_ex(_2, SS("flags"), 4096);
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 520);
- ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 190, value, &_3, _2);
+ ZEPHIR_RETURN_CALL_FUNCTION("filter_var", &_5, 191, value, &_3, _2);
zephir_check_call_status();
RETURN_MM();
}
@@ -309,13 +309,13 @@ PHP_METHOD(Phalcon_Filter, _sanitize) {
RETURN_MM();
}
if (ZEPHIR_IS_STRING(filter, "striptags")) {
- ZEPHIR_RETURN_CALL_FUNCTION("strip_tags", NULL, 192, value);
+ ZEPHIR_RETURN_CALL_FUNCTION("strip_tags", NULL, 193, value);
zephir_check_call_status();
RETURN_MM();
}
if (ZEPHIR_IS_STRING(filter, "lower")) {
if ((zephir_function_exists_ex(SS("mb_strtolower") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 193, value);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 194, value);
zephir_check_call_status();
RETURN_MM();
}
@@ -324,7 +324,7 @@ PHP_METHOD(Phalcon_Filter, _sanitize) {
}
if (ZEPHIR_IS_STRING(filter, "upper")) {
if ((zephir_function_exists_ex(SS("mb_strtoupper") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 194, value);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 195, value);
zephir_check_call_status();
RETURN_MM();
}
diff --git a/ext/phalcon/flash/direct.zep.c b/ext/phalcon/flash/direct.zep.c
index f4926b4f014..ff5d9c6d11c 100644
--- a/ext/phalcon/flash/direct.zep.c
+++ b/ext/phalcon/flash/direct.zep.c
@@ -89,7 +89,7 @@ PHP_METHOD(Phalcon_Flash_Direct, output) {
}
}
if (remove) {
- ZEPHIR_CALL_PARENT(NULL, phalcon_flash_direct_ce, this_ptr, "clear", &_3, 195);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_flash_direct_ce, this_ptr, "clear", &_3, 196);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
diff --git a/ext/phalcon/flash/session.zep.c b/ext/phalcon/flash/session.zep.c
index 66032b3b112..1efd06c2b45 100644
--- a/ext/phalcon/flash/session.zep.c
+++ b/ext/phalcon/flash/session.zep.c
@@ -281,7 +281,7 @@ PHP_METHOD(Phalcon_Flash_Session, output) {
zephir_check_call_status();
}
}
- ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_4, 195);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_4, 196);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -302,7 +302,7 @@ PHP_METHOD(Phalcon_Flash_Session, clear) {
ZVAL_BOOL(_0, 1);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "_getsessionmessages", NULL, 0, _0);
zephir_check_call_status();
- ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_1, 195);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_flash_session_ce, this_ptr, "clear", &_1, 196);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
diff --git a/ext/phalcon/forms/element/check.zep.c b/ext/phalcon/forms/element/check.zep.c
index b514ed59578..d2bc5503ce3 100644
--- a/ext/phalcon/forms/element/check.zep.c
+++ b/ext/phalcon/forms/element/check.zep.c
@@ -54,7 +54,7 @@ PHP_METHOD(Phalcon_Forms_Element_Check, render) {
ZVAL_BOOL(_2, 1);
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes, _2);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "checkfield", &_0, 196, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "checkfield", &_0, 197, _1);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/forms/element/date.zep.c b/ext/phalcon/forms/element/date.zep.c
index 24a257b835a..c00de18cb01 100644
--- a/ext/phalcon/forms/element/date.zep.c
+++ b/ext/phalcon/forms/element/date.zep.c
@@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_Date, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "datefield", &_0, 197, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "datefield", &_0, 198, _1);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/forms/element/email.zep.c b/ext/phalcon/forms/element/email.zep.c
index 3a241a393c5..10daf4398b9 100644
--- a/ext/phalcon/forms/element/email.zep.c
+++ b/ext/phalcon/forms/element/email.zep.c
@@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_Email, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "emailfield", &_0, 198, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "emailfield", &_0, 199, _1);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/forms/element/file.zep.c b/ext/phalcon/forms/element/file.zep.c
index b3dbf38747d..70d7eaa7379 100644
--- a/ext/phalcon/forms/element/file.zep.c
+++ b/ext/phalcon/forms/element/file.zep.c
@@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_File, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "filefield", &_0, 199, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "filefield", &_0, 200, _1);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/forms/element/hidden.zep.c b/ext/phalcon/forms/element/hidden.zep.c
index 7752c1fc312..653ac0a0b80 100644
--- a/ext/phalcon/forms/element/hidden.zep.c
+++ b/ext/phalcon/forms/element/hidden.zep.c
@@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_Hidden, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "hiddenfield", &_0, 200, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "hiddenfield", &_0, 201, _1);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/forms/element/numeric.zep.c b/ext/phalcon/forms/element/numeric.zep.c
index 886a4e0dfb1..0d58d68f440 100644
--- a/ext/phalcon/forms/element/numeric.zep.c
+++ b/ext/phalcon/forms/element/numeric.zep.c
@@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_Numeric, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "numericfield", &_0, 201, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "numericfield", &_0, 202, _1);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/forms/element/password.zep.c b/ext/phalcon/forms/element/password.zep.c
index 990f8fbe935..bad4d1b3e08 100644
--- a/ext/phalcon/forms/element/password.zep.c
+++ b/ext/phalcon/forms/element/password.zep.c
@@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_Password, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "passwordfield", &_0, 202, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "passwordfield", &_0, 203, _1);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/forms/element/radio.zep.c b/ext/phalcon/forms/element/radio.zep.c
index 14367c90f73..7ef61441588 100644
--- a/ext/phalcon/forms/element/radio.zep.c
+++ b/ext/phalcon/forms/element/radio.zep.c
@@ -54,7 +54,7 @@ PHP_METHOD(Phalcon_Forms_Element_Radio, render) {
ZVAL_BOOL(_2, 1);
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes, _2);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "radiofield", &_0, 203, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "radiofield", &_0, 204, _1);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/forms/element/select.zep.c b/ext/phalcon/forms/element/select.zep.c
index 691bd13a060..1c6af3a03a7 100644
--- a/ext/phalcon/forms/element/select.zep.c
+++ b/ext/phalcon/forms/element/select.zep.c
@@ -61,7 +61,7 @@ PHP_METHOD(Phalcon_Forms_Element_Select, __construct) {
zephir_update_property_this(this_ptr, SL("_optionsValues"), options TSRMLS_CC);
- ZEPHIR_CALL_PARENT(NULL, phalcon_forms_element_select_ce, this_ptr, "__construct", &_0, 204, name, attributes);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_forms_element_select_ce, this_ptr, "__construct", &_0, 205, name, attributes);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -140,7 +140,7 @@ PHP_METHOD(Phalcon_Forms_Element_Select, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
_2 = zephir_fetch_nproperty_this(this_ptr, SL("_optionsValues"), PH_NOISY_CC);
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 205, _1, _2);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, _1, _2);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/forms/element/submit.zep.c b/ext/phalcon/forms/element/submit.zep.c
index b67be0d05f6..10fee5e33b8 100644
--- a/ext/phalcon/forms/element/submit.zep.c
+++ b/ext/phalcon/forms/element/submit.zep.c
@@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_Submit, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "submitbutton", &_0, 206, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "submitbutton", &_0, 207, _1);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/forms/element/text.zep.c b/ext/phalcon/forms/element/text.zep.c
index 2f073871012..52ec831bb04 100644
--- a/ext/phalcon/forms/element/text.zep.c
+++ b/ext/phalcon/forms/element/text.zep.c
@@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_Text, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textfield", &_0, 207, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textfield", &_0, 208, _1);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/forms/element/textarea.zep.c b/ext/phalcon/forms/element/textarea.zep.c
index 8e47f956d4b..71836016d2d 100644
--- a/ext/phalcon/forms/element/textarea.zep.c
+++ b/ext/phalcon/forms/element/textarea.zep.c
@@ -52,7 +52,7 @@ PHP_METHOD(Phalcon_Forms_Element_TextArea, render) {
ZEPHIR_CALL_METHOD(&_1, this_ptr, "prepareattributes", NULL, 0, attributes);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textarea", &_0, 208, _1);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_ce, "textarea", &_0, 209, _1);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/forms/form.zep.c b/ext/phalcon/forms/form.zep.c
index 2ca9bd64e6a..f0408088795 100644
--- a/ext/phalcon/forms/form.zep.c
+++ b/ext/phalcon/forms/form.zep.c
@@ -446,7 +446,7 @@ PHP_METHOD(Phalcon_Forms_Form, isValid) {
} else {
ZEPHIR_INIT_NVAR(validation);
object_init_ex(validation, phalcon_validation_ce);
- ZEPHIR_CALL_METHOD(NULL, validation, "__construct", &_11, 209, preparedValidators);
+ ZEPHIR_CALL_METHOD(NULL, validation, "__construct", &_11, 210, preparedValidators);
zephir_check_call_status();
}
ZEPHIR_CALL_METHOD(&filters, element, "getfilters", NULL, 0);
@@ -454,10 +454,10 @@ PHP_METHOD(Phalcon_Forms_Form, isValid) {
if (Z_TYPE_P(filters) == IS_ARRAY) {
ZEPHIR_CALL_METHOD(&_2, element, "getname", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, validation, "setfilters", &_12, 210, _2, filters);
+ ZEPHIR_CALL_METHOD(NULL, validation, "setfilters", &_12, 211, _2, filters);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&elementMessages, validation, "validate", &_13, 211, data, entity);
+ ZEPHIR_CALL_METHOD(&elementMessages, validation, "validate", &_13, 212, data, entity);
zephir_check_call_status();
if (zephir_fast_count_int(elementMessages TSRMLS_CC)) {
ZEPHIR_CALL_METHOD(&_14, element, "getname", NULL, 0);
@@ -523,7 +523,7 @@ PHP_METHOD(Phalcon_Forms_Form, getMessages) {
; zephir_hash_move_forward_ex(_2, &_1)
) {
ZEPHIR_GET_HVALUE(elementMessages, _3);
- ZEPHIR_CALL_METHOD(NULL, group, "appendmessages", &_4, 212, elementMessages);
+ ZEPHIR_CALL_METHOD(NULL, group, "appendmessages", &_4, 213, elementMessages);
zephir_check_call_status();
}
}
@@ -1053,7 +1053,7 @@ PHP_METHOD(Phalcon_Forms_Form, rewind) {
ZVAL_LONG(_0, 0);
zephir_update_property_this(this_ptr, SL("_position"), _0 TSRMLS_CC);
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_elements"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_1, "array_values", NULL, 213, _0);
+ ZEPHIR_CALL_FUNCTION(&_1, "array_values", NULL, 214, _0);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_elementsIndexed"), _1 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
diff --git a/ext/phalcon/forms/manager.zep.c b/ext/phalcon/forms/manager.zep.c
index 7f79b8f7966..906aea6e052 100644
--- a/ext/phalcon/forms/manager.zep.c
+++ b/ext/phalcon/forms/manager.zep.c
@@ -63,7 +63,7 @@ PHP_METHOD(Phalcon_Forms_Manager, create) {
}
ZEPHIR_INIT_VAR(form);
object_init_ex(form, phalcon_forms_form_ce);
- ZEPHIR_CALL_METHOD(NULL, form, "__construct", NULL, 214, entity);
+ ZEPHIR_CALL_METHOD(NULL, form, "__construct", NULL, 215, entity);
zephir_check_call_status();
zephir_update_property_array(this_ptr, SL("_forms"), name, form TSRMLS_CC);
RETURN_CCTOR(form);
diff --git a/ext/phalcon/http/cookie.zep.c b/ext/phalcon/http/cookie.zep.c
index 43558a8beb1..9ee2b695050 100644
--- a/ext/phalcon/http/cookie.zep.c
+++ b/ext/phalcon/http/cookie.zep.c
@@ -349,7 +349,7 @@ PHP_METHOD(Phalcon_Http_Cookie, send) {
} else {
ZEPHIR_CPY_WRT(encryptValue, value);
}
- ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 215, name, encryptValue, expire, path, domain, secure, httpOnly);
+ ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 216, name, encryptValue, expire, path, domain, secure, httpOnly);
zephir_check_call_status();
RETURN_THIS();
@@ -444,7 +444,7 @@ PHP_METHOD(Phalcon_Http_Cookie, delete) {
zephir_time(_2);
ZEPHIR_SINIT_VAR(_4);
ZVAL_LONG(&_4, (zephir_get_numberval(_2) - 691200));
- ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 215, name, ZEPHIR_GLOBAL(global_null), &_4, path, domain, secure, httpOnly);
+ ZEPHIR_CALL_FUNCTION(NULL, "setcookie", NULL, 216, name, ZEPHIR_GLOBAL(global_null), &_4, path, domain, secure, httpOnly);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
diff --git a/ext/phalcon/http/request.zep.c b/ext/phalcon/http/request.zep.c
index 64b747b2363..2c7c58a6cf1 100644
--- a/ext/phalcon/http/request.zep.c
+++ b/ext/phalcon/http/request.zep.c
@@ -18,10 +18,10 @@
#include "ext/spl/spl_exceptions.h"
#include "kernel/exception.h"
#include "kernel/operators.h"
-#include "kernel/file.h"
#include "kernel/array.h"
#include "kernel/string.h"
#include "kernel/concat.h"
+#include "kernel/file.h"
#include "kernel/hash.h"
@@ -143,7 +143,7 @@ PHP_METHOD(Phalcon_Http_Request, get) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 216, _REQUEST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _REQUEST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -206,7 +206,7 @@ PHP_METHOD(Phalcon_Http_Request, getPost) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 216, _POST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _POST, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -227,7 +227,7 @@ PHP_METHOD(Phalcon_Http_Request, getPut) {
int ZEPHIR_LAST_CALL_STATUS;
zend_bool notAllowEmpty, noRecursive;
- zval *name_param = NULL, *filters = NULL, *defaultValue = NULL, *notAllowEmpty_param = NULL, *noRecursive_param = NULL, *put = NULL, *_0, _1;
+ zval *name_param = NULL, *filters = NULL, *defaultValue = NULL, *notAllowEmpty_param = NULL, *noRecursive_param = NULL, *put = NULL, *_0 = NULL;
zval *name = NULL;
ZEPHIR_MM_GROW();
@@ -272,17 +272,15 @@ PHP_METHOD(Phalcon_Http_Request, getPut) {
if (Z_TYPE_P(put) != IS_ARRAY) {
ZEPHIR_INIT_NVAR(put);
array_init(put);
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_SINIT_VAR(_1);
- ZVAL_STRING(&_1, "php://input", 0);
- zephir_file_get_contents(_0, &_1 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getrawbody", NULL, 0);
+ zephir_check_call_status();
Z_SET_ISREF_P(put);
- ZEPHIR_CALL_FUNCTION(NULL, "parse_str", NULL, 217, _0, put);
+ ZEPHIR_CALL_FUNCTION(NULL, "parse_str", NULL, 218, _0, put);
Z_UNSET_ISREF_P(put);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_putCache"), put TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 216, put, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, put, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -348,7 +346,7 @@ PHP_METHOD(Phalcon_Http_Request, getQuery) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 216, _GET, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "gethelper", NULL, 217, _GET, name, filters, defaultValue, (notAllowEmpty ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), (noRecursive ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -831,7 +829,7 @@ PHP_METHOD(Phalcon_Http_Request, getServerAddress) {
}
ZEPHIR_SINIT_VAR(_0);
ZVAL_STRING(&_0, "localhost", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("gethostbyname", NULL, 218, &_0);
+ ZEPHIR_RETURN_CALL_FUNCTION("gethostbyname", NULL, 219, &_0);
zephir_check_call_status();
RETURN_MM();
@@ -1047,7 +1045,7 @@ PHP_METHOD(Phalcon_Http_Request, isMethod) {
}
- ZEPHIR_CALL_METHOD(&httpMethod, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&httpMethod, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
if (Z_TYPE_P(methods) == IS_STRING) {
_0 = strict;
@@ -1122,7 +1120,7 @@ PHP_METHOD(Phalcon_Http_Request, isPost) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "POST"));
@@ -1138,7 +1136,7 @@ PHP_METHOD(Phalcon_Http_Request, isGet) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "GET"));
@@ -1154,7 +1152,7 @@ PHP_METHOD(Phalcon_Http_Request, isPut) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "PUT"));
@@ -1170,7 +1168,7 @@ PHP_METHOD(Phalcon_Http_Request, isPatch) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "PATCH"));
@@ -1186,7 +1184,7 @@ PHP_METHOD(Phalcon_Http_Request, isHead) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "HEAD"));
@@ -1202,7 +1200,7 @@ PHP_METHOD(Phalcon_Http_Request, isDelete) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "DELETE"));
@@ -1218,7 +1216,7 @@ PHP_METHOD(Phalcon_Http_Request, isOptions) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 219);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getmethod", NULL, 220);
zephir_check_call_status();
RETURN_MM_BOOL(ZEPHIR_IS_STRING_IDENTICAL(_0, "OPTIONS"));
@@ -1269,7 +1267,7 @@ PHP_METHOD(Phalcon_Http_Request, hasFiles) {
}
}
if (Z_TYPE_P(error) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 220, error, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 221, error, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
numberFiles += zephir_get_numberval(_4);
}
@@ -1316,7 +1314,7 @@ PHP_METHOD(Phalcon_Http_Request, hasFileHelper) {
}
}
if (Z_TYPE_P(value) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 220, value, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "hasfilehelper", &_5, 221, value, (onlySuccessful ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
numberFiles += zephir_get_numberval(_4);
}
@@ -1368,7 +1366,7 @@ PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) {
zephir_array_fetch_string(&_6, input, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC);
zephir_array_fetch_string(&_7, input, SL("size"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC);
zephir_array_fetch_string(&_8, input, SL("error"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 699 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&smoothInput, this_ptr, "smoothfiles", &_9, 221, _4, _5, _6, _7, _8, prefix);
+ ZEPHIR_CALL_METHOD(&smoothInput, this_ptr, "smoothfiles", &_9, 222, _4, _5, _6, _7, _8, prefix);
zephir_check_call_status();
zephir_is_iterable(smoothInput, &_11, &_10, 0, 0, "phalcon/http/request.zep", 714);
for (
@@ -1402,7 +1400,7 @@ PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) {
ZEPHIR_INIT_NVAR(_16);
object_init_ex(_16, phalcon_http_request_file_ce);
zephir_array_fetch_string(&_17, file, SL("key"), PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 711 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 222, dataFile, _17);
+ ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 223, dataFile, _17);
zephir_check_call_status();
zephir_array_append(&files, _16, PH_SEPARATE, "phalcon/http/request.zep", 711);
}
@@ -1416,7 +1414,7 @@ PHP_METHOD(Phalcon_Http_Request, getUploadedFiles) {
if (_13) {
ZEPHIR_INIT_NVAR(_16);
object_init_ex(_16, phalcon_http_request_file_ce);
- ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 222, input, prefix);
+ ZEPHIR_CALL_METHOD(NULL, _16, "__construct", &_18, 223, input, prefix);
zephir_check_call_status();
zephir_array_append(&files, _16, PH_SEPARATE, "phalcon/http/request.zep", 716);
}
@@ -1492,7 +1490,7 @@ PHP_METHOD(Phalcon_Http_Request, smoothFiles) {
zephir_array_fetch(&_7, tmp_names, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC);
zephir_array_fetch(&_8, sizes, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC);
zephir_array_fetch(&_9, errors, idx, PH_NOISY | PH_READONLY, "phalcon/http/request.zep", 750 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&parentFiles, this_ptr, "smoothfiles", &_10, 221, _5, _6, _7, _8, _9, p);
+ ZEPHIR_CALL_METHOD(&parentFiles, this_ptr, "smoothfiles", &_10, 222, _5, _6, _7, _8, _9, p);
zephir_check_call_status();
zephir_is_iterable(parentFiles, &_12, &_11, 0, 0, "phalcon/http/request.zep", 755);
for (
@@ -1549,7 +1547,7 @@ PHP_METHOD(Phalcon_Http_Request, getHeaders) {
ZVAL_STRING(&_8, " ", 0);
zephir_fast_str_replace(&_4, &_7, &_8, _6 TSRMLS_CC);
zephir_fast_strtolower(_3, _4);
- ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 223, _3);
+ ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 224, _3);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_10);
ZEPHIR_SINIT_NVAR(_11);
@@ -1568,7 +1566,7 @@ PHP_METHOD(Phalcon_Http_Request, getHeaders) {
ZVAL_STRING(&_7, " ", 0);
zephir_fast_str_replace(&_4, &_5, &_7, name TSRMLS_CC);
zephir_fast_strtolower(_3, _4);
- ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 223, _3);
+ ZEPHIR_CALL_FUNCTION(&name, "ucwords", &_9, 224, _3);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_6);
ZEPHIR_SINIT_NVAR(_8);
@@ -1649,7 +1647,7 @@ PHP_METHOD(Phalcon_Http_Request, _getQualityHeader) {
ZVAL_LONG(&_2, -1);
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 1);
- ZEPHIR_CALL_FUNCTION(&_4, "preg_split", &_5, 224, &_1, _0, &_2, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "preg_split", &_5, 225, &_1, _0, &_2, &_3);
zephir_check_call_status();
zephir_is_iterable(_4, &_7, &_6, 0, 0, "phalcon/http/request.zep", 827);
for (
@@ -1667,7 +1665,7 @@ PHP_METHOD(Phalcon_Http_Request, _getQualityHeader) {
ZVAL_LONG(&_2, -1);
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 1);
- ZEPHIR_CALL_FUNCTION(&_10, "preg_split", &_5, 224, &_1, _9, &_2, &_3);
+ ZEPHIR_CALL_FUNCTION(&_10, "preg_split", &_5, 225, &_1, _9, &_2, &_3);
zephir_check_call_status();
zephir_is_iterable(_10, &_12, &_11, 0, 0, "phalcon/http/request.zep", 824);
for (
@@ -1807,7 +1805,7 @@ PHP_METHOD(Phalcon_Http_Request, getAcceptableContent) {
ZVAL_STRING(_0, "HTTP_ACCEPT", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "accept", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 225, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1);
zephir_check_temp_parameter(_0);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
@@ -1829,7 +1827,7 @@ PHP_METHOD(Phalcon_Http_Request, getBestAccept) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "accept", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 226, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1850,7 +1848,7 @@ PHP_METHOD(Phalcon_Http_Request, getClientCharsets) {
ZVAL_STRING(_0, "HTTP_ACCEPT_CHARSET", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "charset", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 225, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1);
zephir_check_temp_parameter(_0);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
@@ -1872,7 +1870,7 @@ PHP_METHOD(Phalcon_Http_Request, getBestCharset) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "charset", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 226, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1893,7 +1891,7 @@ PHP_METHOD(Phalcon_Http_Request, getLanguages) {
ZVAL_STRING(_0, "HTTP_ACCEPT_LANGUAGE", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "language", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 225, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualityheader", NULL, 226, _0, _1);
zephir_check_temp_parameter(_0);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
@@ -1915,7 +1913,7 @@ PHP_METHOD(Phalcon_Http_Request, getBestLanguage) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "language", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 226, _0, _1);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getbestquality", NULL, 227, _0, _1);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/http/request/file.zep.c b/ext/phalcon/http/request/file.zep.c
index adbf2cc8edc..91a2f7678f3 100644
--- a/ext/phalcon/http/request/file.zep.c
+++ b/ext/phalcon/http/request/file.zep.c
@@ -58,10 +58,19 @@ ZEPHIR_INIT_CLASS(Phalcon_Http_Request_File) {
zend_declare_property_null(phalcon_http_request_file_ce, SL("_realType"), ZEND_ACC_PROTECTED TSRMLS_CC);
+ /**
+ * @var string|null
+ */
zend_declare_property_null(phalcon_http_request_file_ce, SL("_error"), ZEND_ACC_PROTECTED TSRMLS_CC);
+ /**
+ * @var string|null
+ */
zend_declare_property_null(phalcon_http_request_file_ce, SL("_key"), ZEND_ACC_PROTECTED TSRMLS_CC);
+ /**
+ * @var string
+ */
zend_declare_property_null(phalcon_http_request_file_ce, SL("_extension"), ZEND_ACC_PROTECTED TSRMLS_CC);
zend_class_implements(phalcon_http_request_file_ce TSRMLS_CC, 1, phalcon_http_request_fileinterface_ce);
@@ -69,6 +78,9 @@ ZEPHIR_INIT_CLASS(Phalcon_Http_Request_File) {
}
+/**
+ * @var string|null
+ */
PHP_METHOD(Phalcon_Http_Request_File, getError) {
@@ -76,6 +88,9 @@ PHP_METHOD(Phalcon_Http_Request_File, getError) {
}
+/**
+ * @var string|null
+ */
PHP_METHOD(Phalcon_Http_Request_File, getKey) {
@@ -83,6 +98,9 @@ PHP_METHOD(Phalcon_Http_Request_File, getKey) {
}
+/**
+ * @var string
+ */
PHP_METHOD(Phalcon_Http_Request_File, getExtension) {
@@ -114,7 +132,7 @@ PHP_METHOD(Phalcon_Http_Request_File, __construct) {
zephir_update_property_this(this_ptr, SL("_name"), name TSRMLS_CC);
ZEPHIR_SINIT_VAR(_0);
ZVAL_STRING(&_0, "PATHINFO_EXTENSION", 0);
- ZEPHIR_CALL_FUNCTION(&_1, "defined", NULL, 227, &_0);
+ ZEPHIR_CALL_FUNCTION(&_1, "defined", NULL, 228, &_0);
zephir_check_call_status();
if (zephir_is_true(_1)) {
ZEPHIR_SINIT_NVAR(_0);
@@ -196,15 +214,15 @@ PHP_METHOD(Phalcon_Http_Request_File, getRealType) {
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, 16);
- ZEPHIR_CALL_FUNCTION(&finfo, "finfo_open", NULL, 228, &_0);
+ ZEPHIR_CALL_FUNCTION(&finfo, "finfo_open", NULL, 229, &_0);
zephir_check_call_status();
if (Z_TYPE_P(finfo) != IS_RESOURCE) {
RETURN_MM_STRING("", 1);
}
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_tmp"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 229, finfo, _1);
+ ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 230, finfo, _1);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 230, finfo);
+ ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 231, finfo);
zephir_check_call_status();
RETURN_CCTOR(mime);
@@ -225,7 +243,7 @@ PHP_METHOD(Phalcon_Http_Request_File, isUploadedFile) {
zephir_check_call_status();
_0 = Z_TYPE_P(tmp) == IS_STRING;
if (_0) {
- ZEPHIR_CALL_FUNCTION(&_1, "is_uploaded_file", NULL, 231, tmp);
+ ZEPHIR_CALL_FUNCTION(&_1, "is_uploaded_file", NULL, 232, tmp);
zephir_check_call_status();
_0 = zephir_is_true(_1);
}
@@ -259,7 +277,7 @@ PHP_METHOD(Phalcon_Http_Request_File, moveTo) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_tmp"), PH_NOISY_CC);
- ZEPHIR_RETURN_CALL_FUNCTION("move_uploaded_file", NULL, 232, _0, destination);
+ ZEPHIR_RETURN_CALL_FUNCTION("move_uploaded_file", NULL, 233, _0, destination);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/http/requestinterface.zep.c b/ext/phalcon/http/requestinterface.zep.c
index 37df8fceda6..da2e44967a2 100644
--- a/ext/phalcon/http/requestinterface.zep.c
+++ b/ext/phalcon/http/requestinterface.zep.c
@@ -64,7 +64,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Http_RequestInterface, getQuery);
ZEPHIR_DOC_METHOD(Phalcon_Http_RequestInterface, getServer);
/**
- * Checks whether $_SERVER superglobal has certain index
+ * Checks whether $_REQUEST superglobal has certain index
*/
ZEPHIR_DOC_METHOD(Phalcon_Http_RequestInterface, has);
diff --git a/ext/phalcon/http/response.zep.c b/ext/phalcon/http/response.zep.c
index d1b7c7b35d1..5500577d24f 100644
--- a/ext/phalcon/http/response.zep.c
+++ b/ext/phalcon/http/response.zep.c
@@ -21,6 +21,7 @@
#include "kernel/array.h"
#include "kernel/concat.h"
#include "ext/date/php_date.h"
+#include "ext/spl/spl_exceptions.h"
#include "kernel/string.h"
#include "kernel/file.h"
@@ -188,7 +189,7 @@ PHP_METHOD(Phalcon_Http_Response, setStatusCode) {
if (_4) {
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "HTTP/", 0);
- ZEPHIR_CALL_FUNCTION(&_6, "strstr", &_7, 233, key, &_5);
+ ZEPHIR_CALL_FUNCTION(&_6, "strstr", &_7, 234, key, &_5);
zephir_check_call_status();
_4 = zephir_is_true(_6);
}
@@ -508,6 +509,55 @@ PHP_METHOD(Phalcon_Http_Response, setExpires) {
}
+/**
+ * Sets Cache headers to use HTTP cache
+ *
+ *
+ * $this->response->setCache(60);
+ *
+ */
+PHP_METHOD(Phalcon_Http_Response, setCache) {
+
+ zval *_1, *_3;
+ zval *minutes_param = NULL, *date, _0, _2, *_4;
+ int minutes, ZEPHIR_LAST_CALL_STATUS;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 0, &minutes_param);
+
+ if (unlikely(Z_TYPE_P(minutes_param) != IS_LONG)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'minutes' must be a long/integer") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ minutes = Z_LVAL_P(minutes_param);
+
+
+ ZEPHIR_INIT_VAR(date);
+ object_init_ex(date, php_date_get_date_ce());
+ ZEPHIR_CALL_METHOD(NULL, date, "__construct", NULL, 0);
+ zephir_check_call_status();
+ ZEPHIR_SINIT_VAR(_0);
+ ZVAL_LONG(&_0, minutes);
+ ZEPHIR_INIT_VAR(_1);
+ ZEPHIR_CONCAT_SVS(_1, "+", &_0, " minutes");
+ ZEPHIR_CALL_METHOD(NULL, date, "modify", NULL, 0, _1);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "setexpires", NULL, 0, date);
+ zephir_check_call_status();
+ ZEPHIR_SINIT_VAR(_2);
+ ZVAL_LONG(&_2, ((minutes * 60)));
+ ZEPHIR_INIT_VAR(_3);
+ ZEPHIR_CONCAT_SV(_3, "max-age=", &_2);
+ ZEPHIR_INIT_VAR(_4);
+ ZVAL_STRING(_4, "Cache-Control", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "setheader", NULL, 0, _4, _3);
+ zephir_check_temp_parameter(_4);
+ zephir_check_call_status();
+ RETURN_THIS();
+
+}
+
/**
* Sends a Not-Modified response
*/
@@ -666,7 +716,7 @@ PHP_METHOD(Phalcon_Http_Response, redirect) {
if (_0) {
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "://", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "strstr", NULL, 233, location, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strstr", NULL, 234, location, &_1);
zephir_check_call_status();
_0 = zephir_is_true(_2);
}
@@ -723,7 +773,7 @@ PHP_METHOD(Phalcon_Http_Response, redirect) {
statusCode = 302;
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_statusCodes"), PH_NOISY_CC);
ZEPHIR_OBS_VAR(message);
- zephir_array_fetch_long(&message, _5, 302, PH_NOISY, "phalcon/http/response.zep", 461 TSRMLS_CC);
+ zephir_array_fetch_long(&message, _5, 302, PH_NOISY, "phalcon/http/response.zep", 481 TSRMLS_CC);
} else {
ZEPHIR_OBS_NVAR(message);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_statusCodes"), PH_NOISY_CC);
@@ -898,7 +948,7 @@ PHP_METHOD(Phalcon_Http_Response, send) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_sent"), PH_NOISY_CC);
if (zephir_is_true(_0)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_response_exception_ce, "Response was already sent", "phalcon/http/response.zep", 568);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_http_response_exception_ce, "Response was already sent", "phalcon/http/response.zep", 588);
return;
}
ZEPHIR_OBS_VAR(headers);
@@ -925,7 +975,7 @@ PHP_METHOD(Phalcon_Http_Response, send) {
_1 = (zephir_fast_strlen_ev(file)) ? 1 : 0;
}
if (_1) {
- ZEPHIR_CALL_FUNCTION(NULL, "readfile", NULL, 234, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "readfile", NULL, 235, file);
zephir_check_call_status();
}
}
diff --git a/ext/phalcon/http/response.zep.h b/ext/phalcon/http/response.zep.h
index 5af7781041c..8d346c2d105 100644
--- a/ext/phalcon/http/response.zep.h
+++ b/ext/phalcon/http/response.zep.h
@@ -16,6 +16,7 @@ PHP_METHOD(Phalcon_Http_Response, setHeader);
PHP_METHOD(Phalcon_Http_Response, setRawHeader);
PHP_METHOD(Phalcon_Http_Response, resetHeaders);
PHP_METHOD(Phalcon_Http_Response, setExpires);
+PHP_METHOD(Phalcon_Http_Response, setCache);
PHP_METHOD(Phalcon_Http_Response, setNotModified);
PHP_METHOD(Phalcon_Http_Response, setContentType);
PHP_METHOD(Phalcon_Http_Response, setEtag);
@@ -66,6 +67,10 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_response_setexpires, 0, 0, 1)
ZEND_ARG_OBJ_INFO(0, datetime, DateTime, 0)
ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_response_setcache, 0, 0, 1)
+ ZEND_ARG_INFO(0, minutes)
+ZEND_END_ARG_INFO()
+
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_http_response_setcontenttype, 0, 0, 1)
ZEND_ARG_INFO(0, contentType)
ZEND_ARG_INFO(0, charset)
@@ -115,6 +120,7 @@ ZEPHIR_INIT_FUNCS(phalcon_http_response_method_entry) {
PHP_ME(Phalcon_Http_Response, setRawHeader, arginfo_phalcon_http_response_setrawheader, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, resetHeaders, NULL, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, setExpires, arginfo_phalcon_http_response_setexpires, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Http_Response, setCache, arginfo_phalcon_http_response_setcache, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, setNotModified, NULL, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, setContentType, arginfo_phalcon_http_response_setcontenttype, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Http_Response, setEtag, arginfo_phalcon_http_response_setetag, ZEND_ACC_PUBLIC)
diff --git a/ext/phalcon/http/response/cookies.zep.c b/ext/phalcon/http/response/cookies.zep.c
index 3da99790330..df2cf0e1111 100644
--- a/ext/phalcon/http/response/cookies.zep.c
+++ b/ext/phalcon/http/response/cookies.zep.c
@@ -179,30 +179,30 @@ PHP_METHOD(Phalcon_Http_Response_Cookies, set) {
object_init_ex(cookie, phalcon_http_cookie_ce);
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, expire);
- ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 235, name, value, _1, path, secure, domain, httpOnly);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 236, name, value, _1, path, secure, domain, httpOnly);
zephir_check_call_status();
_2 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 236, _2);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 237, _2);
zephir_check_call_status();
if (zephir_is_true(encryption)) {
- ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 237, encryption);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 238, encryption);
zephir_check_call_status();
}
zephir_update_property_array(this_ptr, SL("_cookies"), name, cookie TSRMLS_CC);
} else {
- ZEPHIR_CALL_METHOD(NULL, cookie, "setvalue", NULL, 238, value);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setvalue", NULL, 239, value);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_1);
ZVAL_LONG(_1, expire);
- ZEPHIR_CALL_METHOD(NULL, cookie, "setexpiration", NULL, 239, _1);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setexpiration", NULL, 240, _1);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, cookie, "setpath", NULL, 240, path);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setpath", NULL, 241, path);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, cookie, "setsecure", NULL, 241, secure);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setsecure", NULL, 242, secure);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, cookie, "setdomain", NULL, 242, domain);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setdomain", NULL, 243, domain);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, cookie, "sethttponly", NULL, 243, httpOnly);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "sethttponly", NULL, 244, httpOnly);
zephir_check_call_status();
}
_2 = zephir_fetch_nproperty_this(this_ptr, SL("_registered"), PH_NOISY_CC);
@@ -257,17 +257,17 @@ PHP_METHOD(Phalcon_Http_Response_Cookies, get) {
}
ZEPHIR_INIT_NVAR(cookie);
object_init_ex(cookie, phalcon_http_cookie_ce);
- ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 235, name);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "__construct", NULL, 236, name);
zephir_check_call_status();
ZEPHIR_OBS_VAR(dependencyInjector);
zephir_read_property_this(&dependencyInjector, this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
if (Z_TYPE_P(dependencyInjector) == IS_OBJECT) {
- ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 236, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "setdi", NULL, 237, dependencyInjector);
zephir_check_call_status();
ZEPHIR_OBS_VAR(encryption);
zephir_read_property_this(&encryption, this_ptr, SL("_useEncryption"), PH_NOISY_CC);
if (zephir_is_true(encryption)) {
- ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 237, encryption);
+ ZEPHIR_CALL_METHOD(NULL, cookie, "useencryption", NULL, 238, encryption);
zephir_check_call_status();
}
}
diff --git a/ext/phalcon/http/response/headers.zep.c b/ext/phalcon/http/response/headers.zep.c
index 5cbf64e914d..100e5b1900d 100644
--- a/ext/phalcon/http/response/headers.zep.c
+++ b/ext/phalcon/http/response/headers.zep.c
@@ -149,10 +149,10 @@ PHP_METHOD(Phalcon_Http_Response_Headers, send) {
if (!(ZEPHIR_IS_EMPTY(value))) {
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_VSV(_5, header, ": ", value);
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 244, _5, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 245, _5, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
} else {
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 244, header, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_6, 245, header, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
}
}
@@ -222,7 +222,7 @@ PHP_METHOD(Phalcon_Http_Response_Headers, __set_state) {
) {
ZEPHIR_GET_HMKEY(key, _1, _0);
ZEPHIR_GET_HVALUE(value, _2);
- ZEPHIR_CALL_METHOD(NULL, headers, "set", &_3, 245, key, value);
+ ZEPHIR_CALL_METHOD(NULL, headers, "set", &_3, 246, key, value);
zephir_check_call_status();
}
}
diff --git a/ext/phalcon/image/adapter/gd.zep.c b/ext/phalcon/image/adapter/gd.zep.c
index 60c6f986a73..e255c7734b7 100644
--- a/ext/phalcon/image/adapter/gd.zep.c
+++ b/ext/phalcon/image/adapter/gd.zep.c
@@ -55,13 +55,13 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, check) {
ZVAL_NULL(version);
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "GD_VERSION", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "defined", NULL, 227, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "defined", NULL, 228, &_1);
zephir_check_call_status();
if (zephir_is_true(_2)) {
ZEPHIR_INIT_NVAR(version);
ZEPHIR_GET_CONSTANT(version, "GD_VERSION");
} else {
- ZEPHIR_CALL_FUNCTION(&info, "gd_info", NULL, 246);
+ ZEPHIR_CALL_FUNCTION(&info, "gd_info", NULL, 247);
zephir_check_call_status();
ZEPHIR_INIT_VAR(matches);
ZVAL_NULL(matches);
@@ -79,7 +79,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, check) {
ZVAL_STRING(&_5, "2.0.1", 0);
ZEPHIR_SINIT_VAR(_6);
ZVAL_STRING(&_6, ">=", 0);
- ZEPHIR_CALL_FUNCTION(&_7, "version_compare", NULL, 247, version, &_5, &_6);
+ ZEPHIR_CALL_FUNCTION(&_7, "version_compare", NULL, 248, version, &_5, &_6);
zephir_check_call_status();
if (!(zephir_is_true(_7))) {
ZEPHIR_INIT_NVAR(_3);
@@ -145,7 +145,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) {
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_realpath"), _3 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&imageinfo, "getimagesize", NULL, 248, _4);
+ ZEPHIR_CALL_FUNCTION(&imageinfo, "getimagesize", NULL, 249, _4);
zephir_check_call_status();
if (zephir_is_true(imageinfo)) {
zephir_array_fetch_long(&_5, imageinfo, 0, PH_NOISY | PH_READONLY, "phalcon/image/adapter/gd.zep", 77 TSRMLS_CC);
@@ -161,35 +161,35 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) {
do {
if (ZEPHIR_IS_LONG(_9, 1)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromgif", NULL, 249, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromgif", NULL, 250, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(_9, 2)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromjpeg", NULL, 250, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromjpeg", NULL, 251, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(_9, 3)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefrompng", NULL, 251, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefrompng", NULL, 252, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(_9, 15)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromwbmp", NULL, 252, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromwbmp", NULL, 253, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(_9, 16)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromxbm", NULL, 253, _10);
+ ZEPHIR_CALL_FUNCTION(&_11, "imagecreatefromxbm", NULL, 254, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _11 TSRMLS_CC);
break;
@@ -214,7 +214,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) {
} while(0);
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 254, _10, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 255, _10, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
} else {
_16 = !width;
@@ -237,14 +237,14 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, __construct) {
ZVAL_LONG(&_17, width);
ZEPHIR_SINIT_VAR(_18);
ZVAL_LONG(&_18, height);
- ZEPHIR_CALL_FUNCTION(&_3, "imagecreatetruecolor", NULL, 255, &_17, &_18);
+ ZEPHIR_CALL_FUNCTION(&_3, "imagecreatetruecolor", NULL, 256, &_17, &_18);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), _3 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 256, _4, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, _4, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 254, _9, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_15, 255, _9, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_file"), PH_NOISY_CC);
zephir_update_property_this(this_ptr, SL("_realpath"), _10 TSRMLS_CC);
@@ -283,7 +283,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) {
ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION");
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "5.5.0", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 247, _0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1);
zephir_check_call_status();
if (ZEPHIR_LT_LONG(_2, 0)) {
ZEPHIR_OBS_VAR(pre_width);
@@ -331,11 +331,11 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) {
ZVAL_LONG(&_14, 0);
ZEPHIR_SINIT_VAR(_15);
ZVAL_LONG(&_15, 0);
- ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresized", NULL, 257, image, _9, &_12, &_13, &_14, &_15, pre_width, pre_height, _10, _11);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresized", NULL, 258, image, _9, &_12, &_13, &_14, &_15, pre_width, pre_height, _10, _11);
zephir_check_call_status();
if (zephir_is_true(_16)) {
_17 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 258, _17);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _17);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
}
@@ -359,17 +359,17 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) {
ZVAL_LONG(&_15, width);
ZEPHIR_SINIT_VAR(_21);
ZVAL_LONG(&_21, height);
- ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresampled", NULL, 259, image, _9, &_6, &_12, &_13, &_14, &_15, &_21, pre_width, pre_height);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagecopyresampled", NULL, 260, image, _9, &_6, &_12, &_13, &_14, &_15, &_21, pre_width, pre_height);
zephir_check_call_status();
if (zephir_is_true(_16)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 258, _10);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_22, "imagesx", &_23, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_22, "imagesx", &_23, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _22 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_24, "imagesy", &_25, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_24, "imagesy", &_25, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _24 TSRMLS_CC);
}
@@ -379,16 +379,16 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _resize) {
ZVAL_LONG(&_6, width);
ZEPHIR_SINIT_NVAR(_12);
ZVAL_LONG(&_12, height);
- ZEPHIR_CALL_FUNCTION(&image, "imagescale", NULL, 262, _3, &_6, &_12);
+ ZEPHIR_CALL_FUNCTION(&image, "imagescale", NULL, 263, _3, &_6, &_12);
zephir_check_call_status();
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 258, _5);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_18, 259, _5);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_23, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_23, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _16 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_22, "imagesy", &_25, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_22, "imagesy", &_25, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _22 TSRMLS_CC);
}
@@ -415,7 +415,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) {
ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION");
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "5.5.0", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 247, _0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1);
zephir_check_call_status();
if (ZEPHIR_LT_LONG(_2, 0)) {
ZEPHIR_INIT_VAR(_3);
@@ -441,17 +441,17 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) {
ZVAL_LONG(&_11, width);
ZEPHIR_SINIT_VAR(_12);
ZVAL_LONG(&_12, height);
- ZEPHIR_CALL_FUNCTION(&_13, "imagecopyresampled", NULL, 259, image, _5, &_1, &_6, &_7, &_8, &_9, &_10, &_11, &_12);
+ ZEPHIR_CALL_FUNCTION(&_13, "imagecopyresampled", NULL, 260, image, _5, &_1, &_6, &_7, &_8, &_9, &_10, &_11, &_12);
zephir_check_call_status();
if (zephir_is_true(_13)) {
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 258, _14);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 259, _14);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_17, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagesx", &_17, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _16 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_18, "imagesy", &_19, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_18, "imagesy", &_19, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _18 TSRMLS_CC);
}
@@ -471,16 +471,16 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _crop) {
ZVAL_LONG(_3, height);
zephir_array_update_string(&rect, SL("height"), &_3, PH_COPY | PH_SEPARATE);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&image, "imagecrop", NULL, 263, _5, rect);
+ ZEPHIR_CALL_FUNCTION(&image, "imagecrop", NULL, 264, _5, rect);
zephir_check_call_status();
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 258, _14);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_15, 259, _14);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_13, "imagesx", &_17, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_13, "imagesx", &_17, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _13 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_16, "imagesy", &_19, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_16, "imagesy", &_19, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _16 TSRMLS_CC);
}
@@ -508,20 +508,20 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _rotate) {
ZVAL_LONG(&_3, 0);
ZEPHIR_SINIT_VAR(_4);
ZVAL_LONG(&_4, 127);
- ZEPHIR_CALL_FUNCTION(&transparent, "imagecolorallocatealpha", NULL, 264, _0, &_1, &_2, &_3, &_4);
+ ZEPHIR_CALL_FUNCTION(&transparent, "imagecolorallocatealpha", NULL, 265, _0, &_1, &_2, &_3, &_4);
zephir_check_call_status();
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, (360 - degrees));
ZEPHIR_SINIT_NVAR(_2);
ZVAL_LONG(&_2, 1);
- ZEPHIR_CALL_FUNCTION(&image, "imagerotate", NULL, 265, _5, &_1, transparent, &_2);
+ ZEPHIR_CALL_FUNCTION(&image, "imagerotate", NULL, 266, _5, &_1, transparent, &_2);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 254, image, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, image, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&width, "imagesx", NULL, 260, image);
+ ZEPHIR_CALL_FUNCTION(&width, "imagesx", NULL, 261, image);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&height, "imagesy", NULL, 261, image);
+ ZEPHIR_CALL_FUNCTION(&height, "imagesy", NULL, 262, image);
zephir_check_call_status();
_6 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
@@ -534,11 +534,11 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _rotate) {
ZVAL_LONG(&_4, 0);
ZEPHIR_SINIT_VAR(_7);
ZVAL_LONG(&_7, 100);
- ZEPHIR_CALL_FUNCTION(&_8, "imagecopymerge", NULL, 266, _6, image, &_1, &_2, &_3, &_4, width, height, &_7);
+ ZEPHIR_CALL_FUNCTION(&_8, "imagecopymerge", NULL, 267, _6, image, &_1, &_2, &_3, &_4, width, height, &_7);
zephir_check_call_status();
if (zephir_is_true(_8)) {
_9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, _9);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _9);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_width"), width TSRMLS_CC);
@@ -564,7 +564,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) {
ZEPHIR_GET_CONSTANT(_0, "PHP_VERSION");
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "5.5.0", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 247, _0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "version_compare", NULL, 248, _0, &_1);
zephir_check_call_status();
if (ZEPHIR_LT_LONG(_2, 0)) {
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
@@ -592,7 +592,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) {
ZVAL_LONG(&_11, 0);
ZEPHIR_SINIT_NVAR(_12);
ZVAL_LONG(&_12, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, image, _6, &_1, &_9, &_10, &_11, &_12, _8);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, image, _6, &_1, &_9, &_10, &_11, &_12, _8);
zephir_check_call_status();
}
} else {
@@ -616,18 +616,18 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) {
ZVAL_LONG(&_11, ((zephir_get_numberval(_7) - x) - 1));
ZEPHIR_SINIT_NVAR(_12);
ZVAL_LONG(&_12, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, image, _6, &_1, &_9, &_10, &_11, _8, &_12);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, image, _6, &_1, &_9, &_10, &_11, _8, &_12);
zephir_check_call_status();
}
}
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, _5);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _5);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), image TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_14, "imagesx", NULL, 260, image);
+ ZEPHIR_CALL_FUNCTION(&_14, "imagesx", NULL, 261, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _14 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_15, "imagesy", NULL, 261, image);
+ ZEPHIR_CALL_FUNCTION(&_15, "imagesy", NULL, 262, image);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _15 TSRMLS_CC);
} else {
@@ -635,13 +635,13 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _flip) {
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 268, _3, &_1);
+ ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 269, _3, &_1);
zephir_check_call_status();
} else {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 2);
- ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 268, _4, &_1);
+ ZEPHIR_CALL_FUNCTION(NULL, "imageflip", &_16, 269, _4, &_1);
zephir_check_call_status();
}
}
@@ -664,7 +664,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _sharpen) {
ZEPHIR_INIT_VAR(_0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, (-18 + ((amount * 0.08))));
- ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 192, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 2);
@@ -713,15 +713,15 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _sharpen) {
ZVAL_LONG(&_6, (amount - 8));
ZEPHIR_SINIT_VAR(_7);
ZVAL_LONG(&_7, 0);
- ZEPHIR_CALL_FUNCTION(&_8, "imageconvolution", NULL, 269, _5, matrix, &_6, &_7);
+ ZEPHIR_CALL_FUNCTION(&_8, "imageconvolution", NULL, 270, _5, matrix, &_6, &_7);
zephir_check_call_status();
if (zephir_is_true(_8)) {
_9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "imagesx", NULL, 260, _9);
+ ZEPHIR_CALL_FUNCTION(&_10, "imagesx", NULL, 261, _9);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _10 TSRMLS_CC);
_11 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_12, "imagesy", NULL, 261, _11);
+ ZEPHIR_CALL_FUNCTION(&_12, "imagesy", NULL, 262, _11);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _12 TSRMLS_CC);
}
@@ -747,7 +747,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZEPHIR_INIT_VAR(_0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_DOUBLE(&_1, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127)));
- ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "abs", NULL, 192, &_1);
zephir_check_call_status();
zephir_round(_0, _2, NULL, NULL TSRMLS_CC);
opacity = zephir_get_intval(_0);
@@ -773,7 +773,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZVAL_LONG(&_11, 0);
ZEPHIR_SINIT_VAR(_12);
ZVAL_LONG(&_12, 0);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, reflection, _7, &_1, &_10, &_11, &_12, _8, _9);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, reflection, _7, &_1, &_10, &_11, &_12, _8, _9);
zephir_check_call_status();
offset = 0;
while (1) {
@@ -814,7 +814,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZVAL_LONG(&_21, src_y);
ZEPHIR_SINIT_NVAR(_22);
ZVAL_LONG(&_22, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, line, _18, &_11, &_12, &_20, &_21, _19, &_22);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, line, _18, &_11, &_12, &_20, &_21, _19, &_22);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_11);
ZVAL_LONG(&_11, 4);
@@ -826,7 +826,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZVAL_LONG(&_21, 0);
ZEPHIR_SINIT_NVAR(_22);
ZVAL_LONG(&_22, dst_opacity);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_23, 270, line, &_11, &_12, &_20, &_21, &_22);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_23, 271, line, &_11, &_12, &_20, &_21, &_22);
zephir_check_call_status();
_24 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_11);
@@ -839,18 +839,18 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _reflection) {
ZVAL_LONG(&_21, 0);
ZEPHIR_SINIT_NVAR(_22);
ZVAL_LONG(&_22, 1);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 267, reflection, line, &_11, &_12, &_20, &_21, _24, &_22);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopy", &_13, 268, reflection, line, &_11, &_12, &_20, &_21, _24, &_22);
zephir_check_call_status();
offset++;
}
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, _14);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _14);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), reflection TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_25, "imagesx", NULL, 260, reflection);
+ ZEPHIR_CALL_FUNCTION(&_25, "imagesx", NULL, 261, reflection);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_width"), _25 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_26, "imagesy", NULL, 261, reflection);
+ ZEPHIR_CALL_FUNCTION(&_26, "imagesy", NULL, 262, reflection);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_height"), _26 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -872,21 +872,21 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) {
ZEPHIR_CALL_METHOD(&_0, watermark, "render", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&overlay, "imagecreatefromstring", NULL, 271, _0);
+ ZEPHIR_CALL_FUNCTION(&overlay, "imagecreatefromstring", NULL, 272, _0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 254, overlay, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, overlay, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 260, overlay);
+ ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 261, overlay);
zephir_check_call_status();
width = zephir_get_intval(_1);
- ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 261, overlay);
+ ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 262, overlay);
zephir_check_call_status();
height = zephir_get_intval(_2);
if (opacity < 100) {
ZEPHIR_INIT_VAR(_3);
ZEPHIR_SINIT_VAR(_4);
ZVAL_DOUBLE(&_4, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127)));
- ZEPHIR_CALL_FUNCTION(&_5, "abs", NULL, 191, &_4);
+ ZEPHIR_CALL_FUNCTION(&_5, "abs", NULL, 192, &_4);
zephir_check_call_status();
zephir_round(_3, _5, NULL, NULL TSRMLS_CC);
opacity = zephir_get_intval(_3);
@@ -898,11 +898,11 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) {
ZVAL_LONG(&_7, 127);
ZEPHIR_SINIT_VAR(_8);
ZVAL_LONG(&_8, opacity);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 264, overlay, &_4, &_6, &_7, &_8);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 265, overlay, &_4, &_6, &_7, &_8);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_4);
ZVAL_LONG(&_4, 3);
- ZEPHIR_CALL_FUNCTION(NULL, "imagelayereffect", NULL, 272, overlay, &_4);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagelayereffect", NULL, 273, overlay, &_4);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_4);
ZVAL_LONG(&_4, 0);
@@ -912,11 +912,11 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) {
ZVAL_LONG(&_7, width);
ZEPHIR_SINIT_NVAR(_8);
ZVAL_LONG(&_8, height);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", NULL, 273, overlay, &_4, &_6, &_7, &_8, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", NULL, 274, overlay, &_4, &_6, &_7, &_8, color);
zephir_check_call_status();
}
_9 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 256, _9, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, _9, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_4);
@@ -931,10 +931,10 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _watermark) {
ZVAL_LONG(&_11, width);
ZEPHIR_SINIT_VAR(_12);
ZVAL_LONG(&_12, height);
- ZEPHIR_CALL_FUNCTION(&_5, "imagecopy", NULL, 267, _10, overlay, &_4, &_6, &_7, &_8, &_11, &_12);
+ ZEPHIR_CALL_FUNCTION(&_5, "imagecopy", NULL, 268, _10, overlay, &_4, &_6, &_7, &_8, &_11, &_12);
zephir_check_call_status();
if (zephir_is_true(_5)) {
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, overlay);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, overlay);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -966,7 +966,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZEPHIR_INIT_VAR(_0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_DOUBLE(&_1, ((zephir_safe_div_long_long((opacity * 127), 100 TSRMLS_CC)) - (double) (127)));
- ZEPHIR_CALL_FUNCTION(&_2, "abs", &_3, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "abs", &_3, 192, &_1);
zephir_check_call_status();
zephir_round(_0, _2, NULL, NULL TSRMLS_CC);
opacity = zephir_get_intval(_0);
@@ -975,7 +975,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_1, size);
ZEPHIR_SINIT_VAR(_4);
ZVAL_LONG(&_4, 0);
- ZEPHIR_CALL_FUNCTION(&space, "imagettfbbox", NULL, 274, &_1, &_4, fontfile, text);
+ ZEPHIR_CALL_FUNCTION(&space, "imagettfbbox", NULL, 275, &_1, &_4, fontfile, text);
zephir_check_call_status();
if (zephir_array_isset_long(space, 0)) {
ZEPHIR_OBS_VAR(_5);
@@ -1009,12 +1009,12 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, (s4 - s0));
- ZEPHIR_CALL_FUNCTION(&_12, "abs", &_3, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_12, "abs", &_3, 192, &_1);
zephir_check_call_status();
width = (zephir_get_numberval(_12) + 10);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, (s5 - s1));
- ZEPHIR_CALL_FUNCTION(&_13, "abs", &_3, 191, &_1);
+ ZEPHIR_CALL_FUNCTION(&_13, "abs", &_3, 192, &_1);
zephir_check_call_status();
height = (zephir_get_numberval(_13) + 10);
if (offsetX < 0) {
@@ -1034,7 +1034,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_15, b);
ZEPHIR_SINIT_VAR(_16);
ZVAL_LONG(&_16, opacity);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 264, _14, &_1, &_4, &_15, &_16);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 265, _14, &_1, &_4, &_15, &_16);
zephir_check_call_status();
angle = 0;
_18 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
@@ -1046,17 +1046,17 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_15, offsetX);
ZEPHIR_SINIT_NVAR(_16);
ZVAL_LONG(&_16, offsetY);
- ZEPHIR_CALL_FUNCTION(NULL, "imagettftext", NULL, 275, _18, &_1, &_4, &_15, &_16, color, fontfile, text);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagettftext", NULL, 276, _18, &_1, &_4, &_15, &_16, color, fontfile, text);
zephir_check_call_status();
} else {
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, size);
- ZEPHIR_CALL_FUNCTION(&_12, "imagefontwidth", NULL, 276, &_1);
+ ZEPHIR_CALL_FUNCTION(&_12, "imagefontwidth", NULL, 277, &_1);
zephir_check_call_status();
width = (zephir_get_intval(_12) * zephir_fast_strlen_ev(text));
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, size);
- ZEPHIR_CALL_FUNCTION(&_13, "imagefontheight", NULL, 277, &_1);
+ ZEPHIR_CALL_FUNCTION(&_13, "imagefontheight", NULL, 278, &_1);
zephir_check_call_status();
height = zephir_get_intval(_13);
if (offsetX < 0) {
@@ -1076,7 +1076,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_15, b);
ZEPHIR_SINIT_NVAR(_16);
ZVAL_LONG(&_16, opacity);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 264, _14, &_1, &_4, &_15, &_16);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_17, 265, _14, &_1, &_4, &_15, &_16);
zephir_check_call_status();
_19 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
@@ -1085,7 +1085,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _text) {
ZVAL_LONG(&_4, offsetX);
ZEPHIR_SINIT_NVAR(_15);
ZVAL_LONG(&_15, offsetY);
- ZEPHIR_CALL_FUNCTION(NULL, "imagestring", NULL, 278, _19, &_1, &_4, &_15, text, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagestring", NULL, 279, _19, &_1, &_4, &_15, text, color);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -1106,22 +1106,22 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZEPHIR_CALL_METHOD(&_0, mask, "render", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&maskImage, "imagecreatefromstring", NULL, 271, _0);
+ ZEPHIR_CALL_FUNCTION(&maskImage, "imagecreatefromstring", NULL, 272, _0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 260, maskImage);
+ ZEPHIR_CALL_FUNCTION(&_1, "imagesx", NULL, 261, maskImage);
zephir_check_call_status();
mask_width = zephir_get_intval(_1);
- ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 261, maskImage);
+ ZEPHIR_CALL_FUNCTION(&_2, "imagesy", NULL, 262, maskImage);
zephir_check_call_status();
mask_height = zephir_get_intval(_2);
alpha = 127;
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 254, maskImage, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 255, maskImage, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC);
ZEPHIR_CALL_METHOD(&newimage, this_ptr, "_create", NULL, 0, _4, _5);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 254, newimage, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", &_3, 255, newimage, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_6);
ZVAL_LONG(&_6, 0);
@@ -1131,13 +1131,13 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZVAL_LONG(&_8, 0);
ZEPHIR_SINIT_VAR(_9);
ZVAL_LONG(&_9, alpha);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 264, newimage, &_6, &_7, &_8, &_9);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 265, newimage, &_6, &_7, &_8, &_9);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_6);
ZVAL_LONG(&_6, 0);
ZEPHIR_SINIT_NVAR(_7);
ZVAL_LONG(&_7, 0);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefill", NULL, 279, newimage, &_6, &_7, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefill", NULL, 280, newimage, &_6, &_7, color);
zephir_check_call_status();
_11 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
_12 = !ZEPHIR_IS_LONG(_11, mask_width);
@@ -1148,7 +1148,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
if (_12) {
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
_15 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&tempImage, "imagecreatetruecolor", NULL, 255, _14, _15);
+ ZEPHIR_CALL_FUNCTION(&tempImage, "imagecreatetruecolor", NULL, 256, _14, _15);
zephir_check_call_status();
_16 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
_17 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC);
@@ -1164,9 +1164,9 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZVAL_LONG(&_18, mask_width);
ZEPHIR_SINIT_VAR(_19);
ZVAL_LONG(&_19, mask_height);
- ZEPHIR_CALL_FUNCTION(NULL, "imagecopyresampled", NULL, 259, tempImage, maskImage, &_6, &_7, &_8, &_9, _16, _17, &_18, &_19);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagecopyresampled", NULL, 260, tempImage, maskImage, &_6, &_7, &_8, &_9, _16, _17, &_18, &_19);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 258, maskImage);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, maskImage);
zephir_check_call_status();
ZEPHIR_CPY_WRT(maskImage, tempImage);
}
@@ -1186,9 +1186,9 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZVAL_LONG(&_6, x);
ZEPHIR_SINIT_NVAR(_7);
ZVAL_LONG(&_7, y);
- ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 280, maskImage, &_6, &_7);
+ ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 281, maskImage, &_6, &_7);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 281, maskImage, index);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 282, maskImage, index);
zephir_check_call_status();
if (zephir_array_isset_string(color, SS("red"))) {
zephir_array_fetch_string(&_23, color, SL("red"), PH_NOISY | PH_READONLY, "phalcon/image/adapter/gd.zep", 431 TSRMLS_CC);
@@ -1201,10 +1201,10 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
ZVAL_LONG(&_7, x);
ZEPHIR_SINIT_NVAR(_8);
ZVAL_LONG(&_8, y);
- ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 280, _16, &_7, &_8);
+ ZEPHIR_CALL_FUNCTION(&index, "imagecolorat", &_21, 281, _16, &_7, &_8);
zephir_check_call_status();
_17 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 281, _17, index);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorsforindex", &_22, 282, _17, index);
zephir_check_call_status();
ZEPHIR_OBS_NVAR(r);
zephir_array_fetch_string(&r, color, SL("red"), PH_NOISY, "phalcon/image/adapter/gd.zep", 436 TSRMLS_CC);
@@ -1214,22 +1214,22 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _mask) {
zephir_array_fetch_string(&b, color, SL("blue"), PH_NOISY, "phalcon/image/adapter/gd.zep", 436 TSRMLS_CC);
ZEPHIR_SINIT_NVAR(_7);
ZVAL_LONG(&_7, alpha);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 264, newimage, r, g, b, &_7);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", &_10, 265, newimage, r, g, b, &_7);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_7);
ZVAL_LONG(&_7, x);
ZEPHIR_SINIT_NVAR(_8);
ZVAL_LONG(&_8, y);
- ZEPHIR_CALL_FUNCTION(NULL, "imagesetpixel", &_24, 282, newimage, &_7, &_8, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesetpixel", &_24, 283, newimage, &_7, &_8, color);
zephir_check_call_status();
y++;
}
x++;
}
_14 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 258, _14);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, _14);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 258, maskImage);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", &_20, 259, maskImage);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), newimage TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -1263,9 +1263,9 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _background) {
ZVAL_LONG(&_4, b);
ZEPHIR_SINIT_VAR(_5);
ZVAL_LONG(&_5, opacity);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 264, background, &_2, &_3, &_4, &_5);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorallocatealpha", NULL, 265, background, &_2, &_3, &_4, &_5);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 256, background, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, background, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
_6 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_width"), PH_NOISY_CC);
@@ -1278,11 +1278,11 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _background) {
ZVAL_LONG(&_4, 0);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, 0);
- ZEPHIR_CALL_FUNCTION(&_9, "imagecopy", NULL, 267, background, _6, &_2, &_3, &_4, &_5, _7, _8);
+ ZEPHIR_CALL_FUNCTION(&_9, "imagecopy", NULL, 268, background, _6, &_2, &_3, &_4, &_5, _7, _8);
zephir_check_call_status();
if (zephir_is_true(_9)) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, _10);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, _10);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_image"), background TSRMLS_CC);
}
@@ -1310,7 +1310,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _blur) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 7);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_2, 270, _0, &_1);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefilter", &_2, 271, _0, &_1);
zephir_check_call_status();
i++;
}
@@ -1349,7 +1349,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) {
ZVAL_LONG(&_3, x1);
ZEPHIR_SINIT_NVAR(_4);
ZVAL_LONG(&_4, y1);
- ZEPHIR_CALL_FUNCTION(&color, "imagecolorat", &_5, 280, _2, &_3, &_4);
+ ZEPHIR_CALL_FUNCTION(&color, "imagecolorat", &_5, 281, _2, &_3, &_4);
zephir_check_call_status();
x2 = (x + amount);
y2 = (y + amount);
@@ -1362,7 +1362,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _pixelate) {
ZVAL_LONG(&_7, x2);
ZEPHIR_SINIT_NVAR(_8);
ZVAL_LONG(&_8, y2);
- ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", &_9, 273, _6, &_3, &_4, &_7, &_8, color);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagefilledrectangle", &_9, 274, _6, &_3, &_4, &_7, &_8, color);
zephir_check_call_status();
y += amount;
}
@@ -1395,30 +1395,30 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _save) {
zephir_fast_strtolower(ext, _1);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "gif", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_2, 0)) {
ZEPHIR_INIT_ZVAL_NREF(_4);
ZVAL_LONG(_4, 1);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_5, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_5, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _5 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 285, _7, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 286, _7, file);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "jpg", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
_8 = ZEPHIR_IS_LONG(_5, 0);
if (!(_8)) {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "jpeg", 0);
- ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
_8 = ZEPHIR_IS_LONG(_9, 0);
}
@@ -1427,64 +1427,64 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _save) {
ZVAL_LONG(_4, 2);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, quality);
- ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 286, _7, file, &_0);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 287, _7, file, &_0);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "png", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_5, 0)) {
ZEPHIR_INIT_ZVAL_NREF(_4);
ZVAL_LONG(_4, 3);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 287, _7, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 288, _7, file);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "wbmp", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_5, 0)) {
ZEPHIR_INIT_ZVAL_NREF(_4);
ZVAL_LONG(_4, 15);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 288, _7, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 289, _7, file);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "xbm", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 283, ext, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "strcmp", &_3, 284, ext, &_0);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_5, 0)) {
ZEPHIR_INIT_ZVAL_NREF(_4);
ZVAL_LONG(_4, 16);
zephir_update_property_this(this_ptr, SL("_type"), _4 TSRMLS_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_type"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 284, _4);
+ ZEPHIR_CALL_FUNCTION(&_10, "image_type_to_mime_type", &_6, 285, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_mime"), _10 TSRMLS_CC);
_7 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 289, _7, file);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 290, _7, file);
zephir_check_call_status();
RETURN_MM_BOOL(1);
}
@@ -1522,25 +1522,25 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) {
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "gif", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_2, 0)) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 285, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagegif", NULL, 286, _4);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "jpg", 0);
- ZEPHIR_CALL_FUNCTION(&_6, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_6, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
_7 = ZEPHIR_IS_LONG(_6, 0);
if (!(_7)) {
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "jpeg", 0);
- ZEPHIR_CALL_FUNCTION(&_8, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_8, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
_7 = ZEPHIR_IS_LONG(_8, 0);
}
@@ -1548,45 +1548,45 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _render) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, quality);
- ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 286, _4, ZEPHIR_GLOBAL(global_null), &_1);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagejpeg", NULL, 287, _4, ZEPHIR_GLOBAL(global_null), &_1);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "png", 0);
- ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_9, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_9, 0)) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 287, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagepng", NULL, 288, _4);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "wbmp", 0);
- ZEPHIR_CALL_FUNCTION(&_10, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_10, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_10, 0)) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 288, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagewbmp", NULL, 289, _4);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "xbm", 0);
- ZEPHIR_CALL_FUNCTION(&_11, "strcmp", &_3, 283, ext, &_1);
+ ZEPHIR_CALL_FUNCTION(&_11, "strcmp", &_3, 284, ext, &_1);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(_11, 0)) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 289, _4, ZEPHIR_GLOBAL(global_null));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagexbm", NULL, 290, _4, ZEPHIR_GLOBAL(global_null));
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", &_5, 291);
zephir_check_call_status();
RETURN_MM();
}
@@ -1618,11 +1618,11 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, _create) {
ZVAL_LONG(&_0, width);
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, height);
- ZEPHIR_CALL_FUNCTION(&image, "imagecreatetruecolor", NULL, 255, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&image, "imagecreatetruecolor", NULL, 256, &_0, &_1);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 256, image, ZEPHIR_GLOBAL(global_false));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagealphablending", NULL, 257, image, ZEPHIR_GLOBAL(global_false));
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 254, image, ZEPHIR_GLOBAL(global_true));
+ ZEPHIR_CALL_FUNCTION(NULL, "imagesavealpha", NULL, 255, image, ZEPHIR_GLOBAL(global_true));
zephir_check_call_status();
RETURN_CCTOR(image);
@@ -1638,7 +1638,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Gd, __destruct) {
ZEPHIR_OBS_VAR(image);
zephir_read_property_this(&image, this_ptr, SL("_image"), PH_NOISY_CC);
if (Z_TYPE_P(image) == IS_RESOURCE) {
- ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 258, image);
+ ZEPHIR_CALL_FUNCTION(NULL, "imagedestroy", NULL, 259, image);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
diff --git a/ext/phalcon/image/adapter/imagick.zep.c b/ext/phalcon/image/adapter/imagick.zep.c
index 006f9451edb..852942fb404 100644
--- a/ext/phalcon/image/adapter/imagick.zep.c
+++ b/ext/phalcon/image/adapter/imagick.zep.c
@@ -70,12 +70,12 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, check) {
}
ZEPHIR_SINIT_VAR(_2);
ZVAL_STRING(&_2, "Imagick::IMAGICK_EXTNUM", 0);
- ZEPHIR_CALL_FUNCTION(&_3, "defined", NULL, 227, &_2);
+ ZEPHIR_CALL_FUNCTION(&_3, "defined", NULL, 228, &_2);
zephir_check_call_status();
if (zephir_is_true(_3)) {
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "Imagick::IMAGICK_EXTNUM", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 189, &_2);
+ ZEPHIR_CALL_FUNCTION(&_4, "constant", NULL, 190, &_2);
zephir_check_call_status();
zephir_update_static_property_ce(phalcon_image_adapter_imagick_ce, SL("_version"), &_4 TSRMLS_CC);
}
@@ -163,7 +163,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, __construct) {
_12 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_13);
ZVAL_STRING(&_13, "Imagick::ALPHACHANNEL_SET", 0);
- ZEPHIR_CALL_FUNCTION(&_14, "constant", NULL, 189, &_13);
+ ZEPHIR_CALL_FUNCTION(&_14, "constant", NULL, 190, &_13);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, _12, "setimagealphachannel", NULL, 0, _14);
zephir_check_call_status();
@@ -661,7 +661,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
while (1) {
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::COMPOSITE_DSTOUT", 0);
- ZEPHIR_CALL_FUNCTION(&_12, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_12, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_3);
ZVAL_LONG(_3, 0);
@@ -675,11 +675,11 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
}
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::EVALUATE_MULTIPLY", 0);
- ZEPHIR_CALL_FUNCTION(&_17, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_17, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::CHANNEL_ALPHA", 0);
- ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_3);
ZVAL_LONG(_3, opacity);
@@ -722,7 +722,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::ALPHACHANNEL_SET", 0);
- ZEPHIR_CALL_FUNCTION(&_9, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_9, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, image, "setimagealphachannel", &_25, 0, _9);
zephir_check_call_status();
@@ -739,7 +739,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
_30 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::COMPOSITE_SRC", 0);
- ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_18, "constant", &_15, 190, &_14);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_3);
ZVAL_LONG(_3, 0);
@@ -769,7 +769,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _reflection) {
while (1) {
ZEPHIR_SINIT_NVAR(_14);
ZVAL_STRING(&_14, "Imagick::COMPOSITE_OVER", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "constant", &_15, 189, &_14);
+ ZEPHIR_CALL_FUNCTION(&_2, "constant", &_15, 190, &_14);
zephir_check_call_status();
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_height"), PH_NOISY_CC);
ZEPHIR_INIT_NVAR(_3);
@@ -854,7 +854,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _watermark) {
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_4);
ZVAL_STRING(&_4, "Imagick::COMPOSITE_OVER", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "constant", &_6, 189, &_4);
+ ZEPHIR_CALL_FUNCTION(&_5, "constant", &_6, 190, &_4);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_1);
ZVAL_LONG(_1, offsetX);
@@ -920,7 +920,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _text) {
ZVAL_LONG(&_2, g);
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, b);
- ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 186, &_0, &_1, &_2, &_3);
+ ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 187, &_0, &_1, &_2, &_3);
zephir_check_call_status();
ZEPHIR_INIT_VAR(pixel);
object_init_ex(pixel, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC));
@@ -949,23 +949,23 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _text) {
if (offsetX < 0) {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, offsetX);
- ZEPHIR_CALL_FUNCTION(&_5, "abs", &_6, 191, &_0);
+ ZEPHIR_CALL_FUNCTION(&_5, "abs", &_6, 192, &_0);
zephir_check_call_status();
offsetX = zephir_get_numberval(_5);
if (offsetY < 0) {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, offsetY);
- ZEPHIR_CALL_FUNCTION(&_7, "abs", &_6, 191, &_0);
+ ZEPHIR_CALL_FUNCTION(&_7, "abs", &_6, 192, &_0);
zephir_check_call_status();
offsetY = zephir_get_numberval(_7);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::GRAVITY_SOUTHEAST", 0);
- ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 190, &_0);
zephir_check_call_status();
} else {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::GRAVITY_NORTHEAST", 0);
- ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&gravity, "constant", &_8, 190, &_0);
zephir_check_call_status();
}
}
@@ -1039,7 +1039,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _mask) {
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_STRING(&_5, "Imagick::COMPOSITE_DSTIN", 0);
- ZEPHIR_CALL_FUNCTION(&_6, "constant", &_7, 189, &_5);
+ ZEPHIR_CALL_FUNCTION(&_6, "constant", &_7, 190, &_5);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_2);
ZVAL_LONG(_2, 0);
@@ -1092,7 +1092,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) {
ZVAL_LONG(&_2, g);
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, b);
- ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 186, &_0, &_1, &_2, &_3);
+ ZEPHIR_CALL_FUNCTION(&color, "sprintf", NULL, 187, &_0, &_1, &_2, &_3);
zephir_check_call_status();
ZEPHIR_INIT_VAR(pixel1);
object_init_ex(pixel1, zephir_get_internal_ce(SS("imagickpixel") TSRMLS_CC));
@@ -1131,7 +1131,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) {
if (!(zephir_is_true(_9))) {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::ALPHACHANNEL_SET", 0);
- ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 190, &_0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, background, "setimagealphachannel", &_13, 0, _11);
zephir_check_call_status();
@@ -1140,11 +1140,11 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) {
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::EVALUATE_MULTIPLY", 0);
- ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_11, "constant", &_12, 190, &_0);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::CHANNEL_ALPHA", 0);
- ZEPHIR_CALL_FUNCTION(&_15, "constant", &_12, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_15, "constant", &_12, 190, &_0);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_4);
ZVAL_LONG(_4, opacity);
@@ -1158,7 +1158,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _background) {
_20 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::COMPOSITE_DISSOLVE", 0);
- ZEPHIR_CALL_FUNCTION(&_21, "constant", &_12, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_21, "constant", &_12, 190, &_0);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_4);
ZVAL_LONG(_4, 0);
@@ -1325,7 +1325,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) {
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "w", 0);
- ZEPHIR_CALL_FUNCTION(&fp, "fopen", NULL, 291, file, &_0);
+ ZEPHIR_CALL_FUNCTION(&fp, "fopen", NULL, 292, file, &_0);
zephir_check_call_status();
_11 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_CALL_METHOD(NULL, _11, "writeimagesfile", NULL, 0, fp);
@@ -1349,7 +1349,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _save) {
_10 = zephir_fetch_nproperty_this(this_ptr, SL("_image"), PH_NOISY_CC);
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "Imagick::COMPRESSION_JPEG", 0);
- ZEPHIR_CALL_FUNCTION(&_15, "constant", NULL, 189, &_0);
+ ZEPHIR_CALL_FUNCTION(&_15, "constant", NULL, 190, &_0);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, _10, "setimagecompression", NULL, 0, _15);
zephir_check_call_status();
@@ -1424,7 +1424,7 @@ PHP_METHOD(Phalcon_Image_Adapter_Imagick, _render) {
if (_7) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_STRING(&_3, "Imagick::COMPRESSION_JPEG", 0);
- ZEPHIR_CALL_FUNCTION(&_9, "constant", NULL, 189, &_3);
+ ZEPHIR_CALL_FUNCTION(&_9, "constant", NULL, 190, &_3);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, image, "setimagecompression", NULL, 0, _9);
zephir_check_call_status();
diff --git a/ext/phalcon/loader.zep.c b/ext/phalcon/loader.zep.c
index 65026da1bcb..8234b732ddf 100644
--- a/ext/phalcon/loader.zep.c
+++ b/ext/phalcon/loader.zep.c
@@ -360,7 +360,7 @@ PHP_METHOD(Phalcon_Loader, register) {
ZEPHIR_INIT_VAR(_2);
ZVAL_STRING(_2, "autoLoad", 1);
zephir_array_fast_append(_1, _2);
- ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_register", NULL, 292, _1);
+ ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_register", NULL, 293, _1);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_registered"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
}
@@ -387,7 +387,7 @@ PHP_METHOD(Phalcon_Loader, unregister) {
ZEPHIR_INIT_VAR(_2);
ZVAL_STRING(_2, "autoLoad", 1);
zephir_array_fast_append(_1, _2);
- ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_unregister", NULL, 293, _1);
+ ZEPHIR_CALL_FUNCTION(NULL, "spl_autoload_unregister", NULL, 294, _1);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_registered"), (0) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
}
@@ -498,7 +498,7 @@ PHP_METHOD(Phalcon_Loader, autoLoad) {
zephir_check_temp_parameter(_9);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 294, filePath);
+ ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath);
zephir_check_call_status();
if (zephir_is_true(_11)) {
if (Z_TYPE_P(eventsManager) == IS_OBJECT) {
@@ -569,7 +569,7 @@ PHP_METHOD(Phalcon_Loader, autoLoad) {
zephir_check_temp_parameter(_9);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 294, filePath);
+ ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath);
zephir_check_call_status();
if (zephir_is_true(_11)) {
if (Z_TYPE_P(eventsManager) == IS_OBJECT) {
@@ -627,7 +627,7 @@ PHP_METHOD(Phalcon_Loader, autoLoad) {
zephir_check_temp_parameter(_9);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 294, filePath);
+ ZEPHIR_CALL_FUNCTION(&_11, "is_file", &_12, 295, filePath);
zephir_check_call_status();
if (zephir_is_true(_11)) {
if (Z_TYPE_P(eventsManager) == IS_OBJECT) {
diff --git a/ext/phalcon/logger/adapter.zep.c b/ext/phalcon/logger/adapter.zep.c
index 4edfea6d3b6..f4b29aa8295 100644
--- a/ext/phalcon/logger/adapter.zep.c
+++ b/ext/phalcon/logger/adapter.zep.c
@@ -516,11 +516,7 @@ PHP_METHOD(Phalcon_Logger_Adapter, alert) {
}
/**
- * Logs messages to the internal logger. Appends logs to the logger
- * @param mixed type
- * @param mixed message
- * @param mixed context
- * @return Phalcon\Logger\AdapterInterface
+ * Logs messages to the internal logger. Appends logs to the logger
*/
PHP_METHOD(Phalcon_Logger_Adapter, log) {
diff --git a/ext/phalcon/logger/adapter/file.zep.c b/ext/phalcon/logger/adapter/file.zep.c
index a02c620e663..934633a54ac 100644
--- a/ext/phalcon/logger/adapter/file.zep.c
+++ b/ext/phalcon/logger/adapter/file.zep.c
@@ -119,7 +119,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_File, __construct) {
ZEPHIR_INIT_NVAR(mode);
ZVAL_STRING(mode, "ab", 1);
}
- ZEPHIR_CALL_FUNCTION(&handler, "fopen", NULL, 291, name, mode);
+ ZEPHIR_CALL_FUNCTION(&handler, "fopen", NULL, 292, name, mode);
zephir_check_call_status();
if (Z_TYPE_P(handler) != IS_RESOURCE) {
ZEPHIR_INIT_VAR(_0);
@@ -154,7 +154,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_File, getFormatter) {
if (Z_TYPE_P(_0) != IS_OBJECT) {
ZEPHIR_INIT_VAR(_1);
object_init_ex(_1, phalcon_logger_formatter_line_ce);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 295);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 296);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_formatter"), _1 TSRMLS_CC);
}
@@ -169,7 +169,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_File, logInternal) {
zval *context = NULL;
int type, time, ZEPHIR_LAST_CALL_STATUS;
- zval *message_param = NULL, *type_param = NULL, *time_param = NULL, *context_param = NULL, *fileHandler, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3, *_4;
+ zval *message_param = NULL, *type_param = NULL, *time_param = NULL, *context_param = NULL, *fileHandler, *_0 = NULL, *_1 = NULL, *_2, *_3;
zval *message = NULL;
ZEPHIR_MM_GROW();
@@ -195,11 +195,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_File, logInternal) {
ZVAL_LONG(_3, time);
ZEPHIR_CALL_METHOD(&_1, _0, "format", NULL, 0, message, _2, _3, context);
zephir_check_call_status();
- ZEPHIR_INIT_NVAR(_2);
- ZEPHIR_GET_CONSTANT(_2, "PHP_EOL");
- ZEPHIR_INIT_VAR(_4);
- ZEPHIR_CONCAT_VV(_4, _1, _2);
- zephir_fwrite(NULL, fileHandler, _4 TSRMLS_CC);
+ zephir_fwrite(NULL, fileHandler, _1 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
}
@@ -247,7 +243,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_File, __wakeup) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_logger_exception_ce, "Logger must be opened in append or write mode", "phalcon/logger/adapter/file.zep", 152);
return;
}
- ZEPHIR_CALL_FUNCTION(&_1, "fopen", NULL, 291, path, mode);
+ ZEPHIR_CALL_FUNCTION(&_1, "fopen", NULL, 292, path, mode);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_fileHandler"), _1 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
diff --git a/ext/phalcon/logger/adapter/firephp.zep.c b/ext/phalcon/logger/adapter/firephp.zep.c
index d723fa41e01..98754178b0a 100644
--- a/ext/phalcon/logger/adapter/firephp.zep.c
+++ b/ext/phalcon/logger/adapter/firephp.zep.c
@@ -110,15 +110,15 @@ PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) {
if (!ZEPHIR_IS_TRUE_IDENTICAL(_1)) {
ZEPHIR_SINIT_VAR(_2);
ZVAL_STRING(&_2, "X-Wf-Protocol-1: http://meta.wildfirehq.org/Protocol/JsonStream/0.2", 0);
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 244, &_2);
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "X-Wf-1-Plugin-1: http://meta.firephp.org/Wildfire/Plugin/FirePHP/Library-FirePHPCore/0.3", 0);
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 244, &_2);
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "X-Wf-Structure-1: http://meta.firephp.org/Wildfire/Structure/FirePHP/FirebugConsole/0.1", 0);
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 244, &_2);
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, &_2);
zephir_check_call_status();
zephir_update_static_property_ce(phalcon_logger_adapter_firephp_ce, SL("_initialized"), &(ZEPHIR_GLOBAL(global_true)) TSRMLS_CC);
}
@@ -148,7 +148,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_Firephp, logInternal) {
if (zephir_array_isset_long(chunk, (zephir_get_numberval(key) + 1))) {
zephir_concat_self_str(&content, SL("|\\") TSRMLS_CC);
}
- ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 244, content);
+ ZEPHIR_CALL_FUNCTION(NULL, "header", &_3, 245, content);
zephir_check_call_status();
_10 = zephir_fetch_static_property_ce(phalcon_logger_adapter_firephp_ce, SL("_index") TSRMLS_CC);
ZEPHIR_INIT_ZVAL_NREF(_11);
diff --git a/ext/phalcon/logger/adapter/stream.zep.c b/ext/phalcon/logger/adapter/stream.zep.c
index 77967993d6f..7eaa93cebce 100644
--- a/ext/phalcon/logger/adapter/stream.zep.c
+++ b/ext/phalcon/logger/adapter/stream.zep.c
@@ -93,7 +93,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_Stream, __construct) {
ZEPHIR_INIT_NVAR(mode);
ZVAL_STRING(mode, "ab", 1);
}
- ZEPHIR_CALL_FUNCTION(&stream, "fopen", NULL, 291, name, mode);
+ ZEPHIR_CALL_FUNCTION(&stream, "fopen", NULL, 292, name, mode);
zephir_check_call_status();
if (!(zephir_is_true(stream))) {
ZEPHIR_INIT_VAR(_0);
@@ -126,7 +126,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_Stream, getFormatter) {
if (Z_TYPE_P(_0) != IS_OBJECT) {
ZEPHIR_INIT_VAR(_1);
object_init_ex(_1, phalcon_logger_formatter_line_ce);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 295);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 296);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_formatter"), _1 TSRMLS_CC);
}
diff --git a/ext/phalcon/logger/adapter/syslog.zep.c b/ext/phalcon/logger/adapter/syslog.zep.c
index e2c9c3816a0..7a45a2445e3 100644
--- a/ext/phalcon/logger/adapter/syslog.zep.c
+++ b/ext/phalcon/logger/adapter/syslog.zep.c
@@ -76,7 +76,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_Syslog, __construct) {
ZEPHIR_INIT_NVAR(facility);
ZVAL_LONG(facility, 8);
}
- ZEPHIR_CALL_FUNCTION(NULL, "openlog", NULL, 296, name, option, facility);
+ ZEPHIR_CALL_FUNCTION(NULL, "openlog", NULL, 297, name, option, facility);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_opened"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
}
@@ -147,7 +147,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_Syslog, logInternal) {
}
zephir_array_fetch_long(&_3, appliedFormat, 0, PH_NOISY | PH_READONLY, "phalcon/logger/adapter/syslog.zep", 102 TSRMLS_CC);
zephir_array_fetch_long(&_4, appliedFormat, 1, PH_NOISY | PH_READONLY, "phalcon/logger/adapter/syslog.zep", 102 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(NULL, "syslog", NULL, 297, _3, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "syslog", NULL, 298, _3, _4);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -167,7 +167,7 @@ PHP_METHOD(Phalcon_Logger_Adapter_Syslog, close) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_opened"), PH_NOISY_CC);
if (zephir_is_true(_0)) {
- ZEPHIR_CALL_FUNCTION(NULL, "closelog", NULL, 298);
+ ZEPHIR_CALL_FUNCTION(NULL, "closelog", NULL, 299);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
diff --git a/ext/phalcon/logger/formatter/firephp.zep.c b/ext/phalcon/logger/formatter/firephp.zep.c
index 4d4ac60146c..a17c0fbda0a 100644
--- a/ext/phalcon/logger/formatter/firephp.zep.c
+++ b/ext/phalcon/logger/formatter/firephp.zep.c
@@ -188,15 +188,15 @@ PHP_METHOD(Phalcon_Logger_Formatter_Firephp, format) {
ZVAL_STRING(&_3, "5.3.6", 0);
ZEPHIR_SINIT_VAR(_4);
ZVAL_STRING(&_4, "<", 0);
- ZEPHIR_CALL_FUNCTION(&_0, "version_compare", NULL, 247, _1, &_3, &_4);
+ ZEPHIR_CALL_FUNCTION(&_0, "version_compare", NULL, 248, _1, &_3, &_4);
zephir_check_call_status();
if (!(zephir_is_true(_0))) {
param = (2) ? 1 : 0;
}
- ZEPHIR_CALL_FUNCTION(&backtrace, "debug_backtrace", NULL, 149, (param ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_FUNCTION(&backtrace, "debug_backtrace", NULL, 150, (param ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
Z_SET_ISREF_P(backtrace);
- ZEPHIR_CALL_FUNCTION(&lastTrace, "end", NULL, 169, backtrace);
+ ZEPHIR_CALL_FUNCTION(&lastTrace, "end", NULL, 170, backtrace);
Z_UNSET_ISREF_P(backtrace);
zephir_check_call_status();
if (zephir_array_isset_string(lastTrace, SS("file"))) {
diff --git a/ext/phalcon/logger/formatter/json.zep.c b/ext/phalcon/logger/formatter/json.zep.c
index 3d00bb95c1c..68c366d9a73 100644
--- a/ext/phalcon/logger/formatter/json.zep.c
+++ b/ext/phalcon/logger/formatter/json.zep.c
@@ -15,6 +15,7 @@
#include "kernel/memory.h"
#include "kernel/fcall.h"
#include "kernel/operators.h"
+#include "kernel/concat.h"
#include "kernel/string.h"
#include "kernel/array.h"
@@ -44,9 +45,9 @@ ZEPHIR_INIT_CLASS(Phalcon_Logger_Formatter_Json) {
*/
PHP_METHOD(Phalcon_Logger_Formatter_Json, format) {
- zval *_1;
+ zval *_2;
int type, timestamp, ZEPHIR_LAST_CALL_STATUS;
- zval *message_param = NULL, *type_param = NULL, *timestamp_param = NULL, *context = NULL, *_0 = NULL, *_2 = NULL;
+ zval *message_param = NULL, *type_param = NULL, *timestamp_param = NULL, *context = NULL, *_0 = NULL, *_1, *_3 = NULL;
zval *message = NULL;
ZEPHIR_MM_GROW();
@@ -66,17 +67,21 @@ PHP_METHOD(Phalcon_Logger_Formatter_Json, format) {
zephir_get_strval(message, _0);
}
ZEPHIR_INIT_VAR(_1);
- zephir_create_array(_1, 3, 0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_2);
- ZVAL_LONG(_2, type);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "gettypestring", NULL, 0, _2);
+ zephir_create_array(_2, 3, 0 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_3);
+ ZVAL_LONG(_3, type);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "gettypestring", NULL, 0, _3);
zephir_check_call_status();
- zephir_array_update_string(&_1, SL("type"), &_0, PH_COPY | PH_SEPARATE);
- zephir_array_update_string(&_1, SL("message"), &message, PH_COPY | PH_SEPARATE);
- ZEPHIR_INIT_NVAR(_2);
- ZVAL_LONG(_2, timestamp);
- zephir_array_update_string(&_1, SL("timestamp"), &_2, PH_COPY | PH_SEPARATE);
- zephir_json_encode(return_value, &(return_value), _1, 0 TSRMLS_CC);
+ zephir_array_update_string(&_2, SL("type"), &_0, PH_COPY | PH_SEPARATE);
+ zephir_array_update_string(&_2, SL("message"), &message, PH_COPY | PH_SEPARATE);
+ ZEPHIR_INIT_NVAR(_3);
+ ZVAL_LONG(_3, timestamp);
+ zephir_array_update_string(&_2, SL("timestamp"), &_3, PH_COPY | PH_SEPARATE);
+ zephir_json_encode(_1, &(_1), _2, 0 TSRMLS_CC);
+ ZEPHIR_INIT_NVAR(_3);
+ ZEPHIR_GET_CONSTANT(_3, "PHP_EOL");
+ ZEPHIR_CONCAT_VV(return_value, _1, _3);
RETURN_MM();
}
diff --git a/ext/phalcon/logger/formatter/line.zep.c b/ext/phalcon/logger/formatter/line.zep.c
index f32979bdef4..11ada20682b 100644
--- a/ext/phalcon/logger/formatter/line.zep.c
+++ b/ext/phalcon/logger/formatter/line.zep.c
@@ -17,6 +17,7 @@
#include "kernel/operators.h"
#include "kernel/string.h"
#include "kernel/fcall.h"
+#include "kernel/concat.h"
/**
@@ -146,7 +147,7 @@ PHP_METHOD(Phalcon_Logger_Formatter_Line, __construct) {
PHP_METHOD(Phalcon_Logger_Formatter_Line, format) {
int type, timestamp, ZEPHIR_LAST_CALL_STATUS;
- zval *message_param = NULL, *type_param = NULL, *timestamp_param = NULL, *context = NULL, *format = NULL, *_0 = NULL, *_1, _2 = zval_used_for_init, *_3 = NULL, *_4;
+ zval *message_param = NULL, *type_param = NULL, *timestamp_param = NULL, *context = NULL, *format = NULL, *_0 = NULL, *_1, _2 = zval_used_for_init, *_3 = NULL, *_4 = NULL, *_5;
zval *message = NULL;
ZEPHIR_MM_GROW();
@@ -167,7 +168,7 @@ PHP_METHOD(Phalcon_Logger_Formatter_Line, format) {
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_dateFormat"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_2);
ZVAL_LONG(&_2, timestamp);
- ZEPHIR_CALL_FUNCTION(&_3, "date", NULL, 299, _1, &_2);
+ ZEPHIR_CALL_FUNCTION(&_3, "date", NULL, 300, _1, &_2);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "%date%", 0);
@@ -189,7 +190,11 @@ PHP_METHOD(Phalcon_Logger_Formatter_Line, format) {
ZEPHIR_SINIT_NVAR(_2);
ZVAL_STRING(&_2, "%message%", 0);
zephir_fast_str_replace(&_0, &_2, message, format TSRMLS_CC);
- ZEPHIR_CPY_WRT(format, _0);
+ ZEPHIR_INIT_NVAR(_4);
+ ZEPHIR_GET_CONSTANT(_4, "PHP_EOL");
+ ZEPHIR_INIT_VAR(_5);
+ ZEPHIR_CONCAT_VV(_5, _0, _4);
+ ZEPHIR_CPY_WRT(format, _5);
if (Z_TYPE_P(context) == IS_ARRAY) {
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "interpolate", NULL, 0, format, context);
zephir_check_call_status();
diff --git a/ext/phalcon/mvc/collection.zep.c b/ext/phalcon/mvc/collection.zep.c
index 5a00a0db101..428efcd0f1e 100644
--- a/ext/phalcon/mvc/collection.zep.c
+++ b/ext/phalcon/mvc/collection.zep.c
@@ -628,7 +628,7 @@ PHP_METHOD(Phalcon_Mvc_Collection, _getResultset) {
}
ZEPHIR_INIT_VAR(collections);
array_init(collections);
- ZEPHIR_CALL_FUNCTION(&_0, "iterator_to_array", NULL, 300, documentsCursor);
+ ZEPHIR_CALL_FUNCTION(&_0, "iterator_to_array", NULL, 301, documentsCursor);
zephir_check_call_status();
zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/collection.zep", 440);
for (
@@ -1168,7 +1168,7 @@ PHP_METHOD(Phalcon_Mvc_Collection, appendMessage) {
}
/**
- * Creates/Updates a collection based on the values in the atributes
+ * Creates/Updates a collection based on the values in the attributes
*/
PHP_METHOD(Phalcon_Mvc_Collection, save) {
@@ -1211,7 +1211,7 @@ PHP_METHOD(Phalcon_Mvc_Collection, save) {
zephir_update_property_this(this_ptr, SL("_errorMessages"), _1 TSRMLS_CC);
ZEPHIR_OBS_VAR(disableEvents);
zephir_read_static_property_ce(&disableEvents, phalcon_mvc_collection_ce, SL("_disableEvents") TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_2, this_ptr, "_presave", NULL, 301, dependencyInjector, disableEvents, exists);
+ ZEPHIR_CALL_METHOD(&_2, this_ptr, "_presave", NULL, 302, dependencyInjector, disableEvents, exists);
zephir_check_call_status();
if (ZEPHIR_IS_FALSE_IDENTICAL(_2)) {
RETURN_MM_BOOL(0);
@@ -1240,7 +1240,7 @@ PHP_METHOD(Phalcon_Mvc_Collection, save) {
} else {
success = 0;
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_postsave", NULL, 302, disableEvents, (success ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), exists);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_postsave", NULL, 303, disableEvents, (success ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), exists);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/mvc/collection/behavior/timestampable.zep.c b/ext/phalcon/mvc/collection/behavior/timestampable.zep.c
index 79ceb5c5d78..a50a9a9ff3e 100644
--- a/ext/phalcon/mvc/collection/behavior/timestampable.zep.c
+++ b/ext/phalcon/mvc/collection/behavior/timestampable.zep.c
@@ -84,7 +84,7 @@ PHP_METHOD(Phalcon_Mvc_Collection_Behavior_Timestampable, notify) {
ZVAL_NULL(timestamp);
ZEPHIR_OBS_VAR(format);
if (zephir_array_isset_string_fetch(&format, options, SS("format"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 299, format);
+ ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 300, format);
zephir_check_call_status();
} else {
ZEPHIR_OBS_VAR(generator);
diff --git a/ext/phalcon/mvc/micro.zep.c b/ext/phalcon/mvc/micro.zep.c
index 742f95feab7..4fa50b73509 100644
--- a/ext/phalcon/mvc/micro.zep.c
+++ b/ext/phalcon/mvc/micro.zep.c
@@ -484,7 +484,7 @@ PHP_METHOD(Phalcon_Mvc_Micro, mount) {
if (zephir_is_true(_0)) {
ZEPHIR_INIT_VAR(lazyHandler);
object_init_ex(lazyHandler, phalcon_mvc_micro_lazyloader_ce);
- ZEPHIR_CALL_METHOD(NULL, lazyHandler, "__construct", NULL, 303, mainHandler);
+ ZEPHIR_CALL_METHOD(NULL, lazyHandler, "__construct", NULL, 304, mainHandler);
zephir_check_call_status();
} else {
ZEPHIR_CPY_WRT(lazyHandler, mainHandler);
@@ -656,11 +656,11 @@ PHP_METHOD(Phalcon_Mvc_Micro, setService) {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
ZEPHIR_INIT_NVAR(dependencyInjector);
object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce);
- ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 173);
+ ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "set", NULL, 304, serviceName, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "set", NULL, 305, serviceName, definition, (shared ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
@@ -696,11 +696,11 @@ PHP_METHOD(Phalcon_Mvc_Micro, hasService) {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
ZEPHIR_INIT_NVAR(dependencyInjector);
object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce);
- ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 173);
+ ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "has", NULL, 305, serviceName);
+ ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "has", NULL, 306, serviceName);
zephir_check_call_status();
RETURN_MM();
@@ -739,11 +739,11 @@ PHP_METHOD(Phalcon_Mvc_Micro, getService) {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
ZEPHIR_INIT_NVAR(dependencyInjector);
object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce);
- ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 173);
+ ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "get", NULL, 306, serviceName);
+ ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "get", NULL, 307, serviceName);
zephir_check_call_status();
RETURN_MM();
@@ -770,11 +770,11 @@ PHP_METHOD(Phalcon_Mvc_Micro, getSharedService) {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
ZEPHIR_INIT_NVAR(dependencyInjector);
object_init_ex(dependencyInjector, phalcon_di_factorydefault_ce);
- ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 173);
+ ZEPHIR_CALL_METHOD(NULL, dependencyInjector, "__construct", NULL, 174);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
}
- ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "getshared", NULL, 307, serviceName);
+ ZEPHIR_RETURN_CALL_METHOD(dependencyInjector, "getshared", NULL, 308, serviceName);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/mvc/model.zep.c b/ext/phalcon/mvc/model.zep.c
index 50dea4d2b9e..60b78102cb3 100644
--- a/ext/phalcon/mvc/model.zep.c
+++ b/ext/phalcon/mvc/model.zep.c
@@ -1279,12 +1279,12 @@ PHP_METHOD(Phalcon_Mvc_Model, query) {
ZEPHIR_CALL_METHOD(NULL, criteria, "__construct", NULL, 0);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(NULL, criteria, "setdi", NULL, 308, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "setdi", NULL, 309, dependencyInjector);
zephir_check_call_status();
}
ZEPHIR_INIT_NVAR(_2);
zephir_get_called_class(_2 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 309, _2);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 310, _2);
zephir_check_call_status();
RETURN_CCTOR(criteria);
@@ -3069,9 +3069,9 @@ PHP_METHOD(Phalcon_Mvc_Model, _doLowUpdate) {
break;
}
if (ZEPHIR_IS_LONG(bindType, 3) || ZEPHIR_IS_LONG(bindType, 7)) {
- ZEPHIR_CALL_FUNCTION(&_1, "floatval", &_8, 310, snapshotValue);
+ ZEPHIR_CALL_FUNCTION(&_1, "floatval", &_8, 311, snapshotValue);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_9, "floatval", &_8, 310, value);
+ ZEPHIR_CALL_FUNCTION(&_9, "floatval", &_8, 311, value);
zephir_check_call_status();
changed = !ZEPHIR_IS_IDENTICAL(_1, _9);
break;
@@ -3543,7 +3543,7 @@ PHP_METHOD(Phalcon_Mvc_Model, save) {
ZEPHIR_INIT_NVAR(_4);
object_init_ex(_4, phalcon_mvc_model_validationfailed_ce);
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_errorMessages"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 311, this_ptr, _3);
+ ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 312, this_ptr, _3);
zephir_check_call_status();
zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 2877 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -4595,7 +4595,7 @@ PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) {
int ZEPHIR_LAST_CALL_STATUS;
HashTable *_1;
HashPosition _0;
- zval *data_param = NULL, *columnMap = NULL, *key = NULL, *value = NULL, *snapshot, *attribute = NULL, **_2, *_3 = NULL, *_4 = NULL, *_6 = NULL;
+ zval *data_param = NULL, *columnMap = NULL, *key = NULL, *value = NULL, *snapshot, *attribute = NULL, **_2, *_3 = NULL, *_4 = NULL;
zval *data = NULL;
ZEPHIR_MM_GROW();
@@ -4611,7 +4611,7 @@ PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) {
if (Z_TYPE_P(columnMap) == IS_ARRAY) {
ZEPHIR_INIT_VAR(snapshot);
array_init(snapshot);
- zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3606);
+ zephir_is_iterable(data, &_1, &_0, 0, 0, "phalcon/mvc/model.zep", 3605);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -4654,12 +4654,8 @@ PHP_METHOD(Phalcon_Mvc_Model, setSnapshotData) {
continue;
}
}
- ZEPHIR_OBS_NVAR(_6);
- zephir_array_fetch_long(&_6, attribute, 0, PH_NOISY, "phalcon/mvc/model.zep", 3600 TSRMLS_CC);
- zephir_array_update_zval(&snapshot, _6, &value, PH_COPY | PH_SEPARATE);
- } else {
- zephir_array_update_zval(&snapshot, attribute, &value, PH_COPY | PH_SEPARATE);
}
+ zephir_array_update_zval(&snapshot, attribute, &value, PH_COPY | PH_SEPARATE);
}
zephir_update_property_this(this_ptr, SL("_snapshot"), snapshot TSRMLS_CC);
RETURN_MM_NULL();
@@ -4716,12 +4712,12 @@ PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_OBS_VAR(snapshot);
zephir_read_property_this(&snapshot, this_ptr, SL("_snapshot"), PH_NOISY_CC);
if (Z_TYPE_P(snapshot) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3645);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3644);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC);
if (!ZEPHIR_IS_LONG(_0, 0)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3652);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3651);
return;
}
ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0);
@@ -4743,7 +4739,7 @@ PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not part of the model");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3684 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3683 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -4755,7 +4751,7 @@ PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not part of the model");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3688 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3687 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -4768,7 +4764,7 @@ PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_CONCAT_SVS(_2, "The field '", fieldName, "' is not defined on the model");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3696 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3695 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -4780,14 +4776,14 @@ PHP_METHOD(Phalcon_Mvc_Model, hasChanged) {
ZEPHIR_CONCAT_SVS(_3, "The field '", fieldName, "' was not found in the snapshot");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3703 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3702 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
RETURN_MM_BOOL(!ZEPHIR_IS_EQUAL(value, originalValue));
}
ZEPHIR_INIT_NVAR(_1);
- zephir_is_iterable(allAttributes, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 3739);
+ zephir_is_iterable(allAttributes, &_5, &_4, 0, 0, "phalcon/mvc/model.zep", 3738);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
@@ -4825,12 +4821,12 @@ PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) {
ZEPHIR_OBS_VAR(snapshot);
zephir_read_property_this(&snapshot, this_ptr, SL("_snapshot"), PH_NOISY_CC);
if (Z_TYPE_P(snapshot) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3752);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The record doesn't have a valid data snapshot", "phalcon/mvc/model.zep", 3751);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dirtyState"), PH_NOISY_CC);
if (!ZEPHIR_IS_LONG(_0, 0)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3759);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Change checking cannot be performed because the object has not been persisted or is deleted", "phalcon/mvc/model.zep", 3758);
return;
}
ZEPHIR_CALL_METHOD(&metaData, this_ptr, "getmodelsmetadata", NULL, 0);
@@ -4846,7 +4842,7 @@ PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) {
ZEPHIR_INIT_VAR(changed);
array_init(changed);
ZEPHIR_INIT_VAR(_1);
- zephir_is_iterable(allAttributes, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3813);
+ zephir_is_iterable(allAttributes, &_3, &_2, 0, 0, "phalcon/mvc/model.zep", 3812);
for (
; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS
; zephir_hash_move_forward_ex(_3, &_2)
@@ -4854,17 +4850,17 @@ PHP_METHOD(Phalcon_Mvc_Model, getChangedFields) {
ZEPHIR_GET_HMKEY(name, _3, _2);
ZEPHIR_GET_HVALUE(_1, _4);
if (!(zephir_array_isset(snapshot, name))) {
- zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3792);
+ zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3791);
continue;
}
ZEPHIR_OBS_NVAR(value);
if (!(zephir_fetch_property_zval(&value, this_ptr, name, PH_SILENT_CC))) {
- zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3800);
+ zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3799);
continue;
}
- zephir_array_fetch(&_5, snapshot, name, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 3807 TSRMLS_CC);
+ zephir_array_fetch(&_5, snapshot, name, PH_NOISY | PH_READONLY, "phalcon/mvc/model.zep", 3806 TSRMLS_CC);
if (!ZEPHIR_IS_EQUAL(value, _5)) {
- zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3808);
+ zephir_array_append(&changed, name, PH_SEPARATE, "phalcon/mvc/model.zep", 3807);
continue;
}
}
@@ -4944,7 +4940,7 @@ PHP_METHOD(Phalcon_Mvc_Model, getRelated) {
ZEPHIR_CONCAT_SVSVS(_3, "There is no defined relations for the model '", className, "' using alias '", alias, "'");
ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_2, "phalcon/mvc/model.zep", 3855 TSRMLS_CC);
+ zephir_throw_exception_debug(_2, "phalcon/mvc/model.zep", 3854 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -5097,7 +5093,7 @@ PHP_METHOD(Phalcon_Mvc_Model, __call) {
ZEPHIR_CONCAT_SVSVS(_2, "The method '", method, "' doesn't exist on model '", modelName, "'");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3947 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3946 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -5166,7 +5162,7 @@ PHP_METHOD(Phalcon_Mvc_Model, __callStatic) {
ZEPHIR_CONCAT_SVSVS(_2, "The static method '", method, "' doesn't exist on model '", modelName, "'");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3998 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 3997 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -5178,7 +5174,7 @@ PHP_METHOD(Phalcon_Mvc_Model, __callStatic) {
ZEPHIR_CONCAT_SVS(_3, "The static method '", method, "' requires one argument");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4002 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4001 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -5215,7 +5211,7 @@ PHP_METHOD(Phalcon_Mvc_Model, __callStatic) {
ZEPHIR_CONCAT_SVS(_2, "Cannot resolve attribute '", extraMethod, "' in the model");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4036 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/model.zep", 4035 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -5280,7 +5276,7 @@ PHP_METHOD(Phalcon_Mvc_Model, __set) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(related);
array_init(related);
- zephir_is_iterable(value, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4100);
+ zephir_is_iterable(value, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4099);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -5289,7 +5285,7 @@ PHP_METHOD(Phalcon_Mvc_Model, __set) {
ZEPHIR_GET_HVALUE(item, _3);
if (Z_TYPE_P(item) == IS_OBJECT) {
if (zephir_instance_of_ev(item, phalcon_mvc_modelinterface_ce TSRMLS_CC)) {
- zephir_array_append(&related, item, PH_SEPARATE, "phalcon/mvc/model.zep", 4087);
+ zephir_array_append(&related, item, PH_SEPARATE, "phalcon/mvc/model.zep", 4086);
}
} else {
ZEPHIR_INIT_NVAR(lowerKey);
@@ -5491,7 +5487,7 @@ PHP_METHOD(Phalcon_Mvc_Model, unserialize) {
ZEPHIR_CALL_CE_STATIC(&dependencyInjector, phalcon_di_ce, "getdefault", &_0, 1);
zephir_check_call_status();
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 4224);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "A dependency injector container is required to obtain the services related to the ORM", "phalcon/mvc/model.zep", 4223);
return;
}
zephir_update_property_this(this_ptr, SL("_dependencyInjector"), dependencyInjector TSRMLS_CC);
@@ -5502,13 +5498,13 @@ PHP_METHOD(Phalcon_Mvc_Model, unserialize) {
zephir_check_call_status();
ZEPHIR_CPY_WRT(manager, _1);
if (Z_TYPE_P(manager) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 4237);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "The injected service 'modelsManager' is not valid", "phalcon/mvc/model.zep", 4236);
return;
}
zephir_update_property_this(this_ptr, SL("_modelsManager"), manager TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, manager, "initialize", NULL, 0, this_ptr);
zephir_check_call_status();
- zephir_is_iterable(attributes, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 4256);
+ zephir_is_iterable(attributes, &_4, &_3, 0, 0, "phalcon/mvc/model.zep", 4255);
for (
; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS
; zephir_hash_move_forward_ex(_4, &_3)
@@ -5575,7 +5571,7 @@ PHP_METHOD(Phalcon_Mvc_Model, toArray) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_0, metaData, "getattributes", NULL, 0, this_ptr);
zephir_check_call_status();
- zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4320);
+ zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/model.zep", 4319);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -5591,7 +5587,7 @@ PHP_METHOD(Phalcon_Mvc_Model, toArray) {
ZEPHIR_CONCAT_SVS(_5, "Column '", attribute, "' doesn't make part of the column map");
ZEPHIR_CALL_METHOD(NULL, _4, "__construct", &_6, 9, _5);
zephir_check_call_status();
- zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 4298 TSRMLS_CC);
+ zephir_throw_exception_debug(_4, "phalcon/mvc/model.zep", 4297 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
} else {
diff --git a/ext/phalcon/mvc/model/behavior/timestampable.zep.c b/ext/phalcon/mvc/model/behavior/timestampable.zep.c
index 8bb146f6d6c..25fa1f50ad7 100644
--- a/ext/phalcon/mvc/model/behavior/timestampable.zep.c
+++ b/ext/phalcon/mvc/model/behavior/timestampable.zep.c
@@ -84,7 +84,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Behavior_Timestampable, notify) {
ZVAL_NULL(timestamp);
ZEPHIR_OBS_VAR(format);
if (zephir_array_isset_string_fetch(&format, options, SS("format"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 299, format);
+ ZEPHIR_CALL_FUNCTION(×tamp, "date", NULL, 300, format);
zephir_check_call_status();
} else {
ZEPHIR_OBS_VAR(generator);
diff --git a/ext/phalcon/mvc/model/criteria.zep.c b/ext/phalcon/mvc/model/criteria.zep.c
index b31debfcdc9..7cd026776a2 100644
--- a/ext/phalcon/mvc/model/criteria.zep.c
+++ b/ext/phalcon/mvc/model/criteria.zep.c
@@ -826,7 +826,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, inWhere) {
array_init(bindParams);
ZEPHIR_INIT_VAR(bindKeys);
array_init(bindKeys);
- zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 450);
+ zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 451);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -836,7 +836,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, inWhere) {
ZEPHIR_CONCAT_SV(key, "AP", hiddenParam);
ZEPHIR_INIT_NVAR(queryKey);
ZEPHIR_CONCAT_SVS(queryKey, ":", key, ":");
- zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 441);
+ zephir_array_append(&bindKeys, queryKey, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 442);
zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE);
ZEPHIR_SEPARATE(hiddenParam);
zephir_increment(hiddenParam);
@@ -892,7 +892,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, notInWhere) {
array_init(bindParams);
ZEPHIR_INIT_VAR(bindKeys);
array_init(bindKeys);
- zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 487);
+ zephir_is_iterable(values, &_1, &_0, 0, 0, "phalcon/mvc/model/criteria.zep", 488);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -902,7 +902,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, notInWhere) {
ZEPHIR_CONCAT_SV(key, "AP", hiddenParam);
ZEPHIR_INIT_LNVAR(_3);
ZEPHIR_CONCAT_SVS(_3, ":", key, ":");
- zephir_array_append(&bindKeys, _3, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 477);
+ zephir_array_append(&bindKeys, _3, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 478);
zephir_array_update_zval(&bindParams, key, &value, PH_COPY | PH_SEPARATE);
ZEPHIR_SEPARATE(hiddenParam);
zephir_increment(hiddenParam);
@@ -1298,14 +1298,14 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, getParams) {
*/
PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) {
- zend_bool _6;
+ zend_bool _6, _7;
HashTable *_4;
HashPosition _3;
zend_class_entry *_2;
int ZEPHIR_LAST_CALL_STATUS;
zval *data = NULL;
zval *modelName = NULL;
- zval *dependencyInjector, *modelName_param = NULL, *data_param = NULL, *conditions, *field = NULL, *value = NULL, *type = NULL, *metaData = NULL, *model, *dataTypes = NULL, *bind, *criteria, *_0 = NULL, *_1 = NULL, **_5, *_7 = NULL, *_8 = NULL;
+ zval *dependencyInjector, *modelName_param = NULL, *data_param = NULL, *attribute = NULL, *conditions, *field = NULL, *value = NULL, *type = NULL, *metaData = NULL, *model, *dataTypes = NULL, *bind, *criteria, *columnMap = NULL, *_0 = NULL, *_1 = NULL, **_5, *_8 = NULL, *_9 = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 3, 0, &dependencyInjector, &modelName_param, &data_param);
@@ -1343,35 +1343,47 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) {
}
ZEPHIR_CALL_METHOD(&dataTypes, metaData, "getdatatypes", NULL, 0, model);
zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(&columnMap, metaData, "getreversecolumnmap", NULL, 0, model);
+ zephir_check_call_status();
ZEPHIR_INIT_VAR(bind);
array_init(bind);
- zephir_is_iterable(data, &_4, &_3, 0, 0, "phalcon/mvc/model/criteria.zep", 720);
+ zephir_is_iterable(data, &_4, &_3, 0, 0, "phalcon/mvc/model/criteria.zep", 732);
for (
; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS
; zephir_hash_move_forward_ex(_4, &_3)
) {
ZEPHIR_GET_HMKEY(field, _4, _3);
ZEPHIR_GET_HVALUE(value, _5);
+ _6 = Z_TYPE_P(columnMap) == IS_ARRAY;
+ if (_6) {
+ _6 = (zephir_fast_count_int(columnMap TSRMLS_CC)) ? 1 : 0;
+ }
+ if (_6) {
+ ZEPHIR_OBS_NVAR(attribute);
+ zephir_array_fetch(&attribute, columnMap, field, PH_NOISY, "phalcon/mvc/model/criteria.zep", 709 TSRMLS_CC);
+ } else {
+ ZEPHIR_CPY_WRT(attribute, field);
+ }
ZEPHIR_OBS_NVAR(type);
- if (zephir_array_isset_fetch(&type, dataTypes, field, 0 TSRMLS_CC)) {
- _6 = Z_TYPE_P(value) != IS_NULL;
- if (_6) {
- _6 = !ZEPHIR_IS_STRING_IDENTICAL(value, "");
+ if (zephir_array_isset_fetch(&type, dataTypes, attribute, 0 TSRMLS_CC)) {
+ _7 = Z_TYPE_P(value) != IS_NULL;
+ if (_7) {
+ _7 = !ZEPHIR_IS_STRING_IDENTICAL(value, "");
}
- if (_6) {
+ if (_7) {
if (ZEPHIR_IS_LONG(type, 2)) {
- ZEPHIR_INIT_LNVAR(_7);
- ZEPHIR_CONCAT_VSVS(_7, field, " LIKE :", field, ":");
- zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 710);
ZEPHIR_INIT_LNVAR(_8);
- ZEPHIR_CONCAT_SVS(_8, "%", value, "%");
- zephir_array_update_zval(&bind, field, &_8, PH_COPY | PH_SEPARATE);
- } else {
- ZEPHIR_INIT_LNVAR(_7);
- ZEPHIR_CONCAT_VSVS(_7, field, " = :", field, ":");
- zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 715);
- zephir_array_update_zval(&bind, field, &value, PH_COPY | PH_SEPARATE);
+ ZEPHIR_CONCAT_SVSVS(_8, "[", field, "] LIKE :", field, ":");
+ zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 721);
+ ZEPHIR_INIT_LNVAR(_9);
+ ZEPHIR_CONCAT_SVS(_9, "%", value, "%");
+ zephir_array_update_zval(&bind, field, &_9, PH_COPY | PH_SEPARATE);
+ continue;
}
+ ZEPHIR_INIT_LNVAR(_8);
+ ZEPHIR_CONCAT_SVSVS(_8, "[", field, "] = :", field, ":");
+ zephir_array_append(&conditions, _8, PH_SEPARATE, "phalcon/mvc/model/criteria.zep", 728);
+ zephir_array_update_zval(&bind, field, &value, PH_COPY | PH_SEPARATE);
}
}
}
@@ -1385,12 +1397,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, fromInput) {
if (zephir_fast_count_int(conditions TSRMLS_CC)) {
ZEPHIR_INIT_NVAR(_0);
zephir_fast_join_str(_0, SL(" AND "), conditions TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, criteria, "where", NULL, 312, _0);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "where", NULL, 313, _0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, criteria, "bind", NULL, 313, bind);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "bind", NULL, 314, bind);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 309, modelName);
+ ZEPHIR_CALL_METHOD(NULL, criteria, "setmodelname", NULL, 310, modelName);
zephir_check_call_status();
RETURN_CCTOR(criteria);
@@ -1410,7 +1422,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Criteria, execute) {
ZEPHIR_CALL_METHOD(&model, this_ptr, "getmodelname", NULL, 0);
zephir_check_call_status();
if (Z_TYPE_P(model) != IS_STRING) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Model name must be string", "phalcon/mvc/model/criteria.zep", 744);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Model name must be string", "phalcon/mvc/model/criteria.zep", 756);
return;
}
ZEPHIR_CALL_METHOD(&_0, this_ptr, "getparams", NULL, 0);
diff --git a/ext/phalcon/mvc/model/manager.zep.c b/ext/phalcon/mvc/model/manager.zep.c
index 06cf9cf65a2..344cc3406bc 100644
--- a/ext/phalcon/mvc/model/manager.zep.c
+++ b/ext/phalcon/mvc/model/manager.zep.c
@@ -1081,7 +1081,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasOne) {
object_init_ex(relation, phalcon_mvc_model_relation_ce);
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, 1);
- ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 314, _1, referencedModel, fields, referencedFields, options);
+ ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _1, referencedModel, fields, referencedFields, options);
zephir_check_call_status();
ZEPHIR_OBS_VAR(alias);
if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) {
@@ -1168,7 +1168,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, addBelongsTo) {
object_init_ex(relation, phalcon_mvc_model_relation_ce);
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, 0);
- ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 314, _1, referencedModel, fields, referencedFields, options);
+ ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _1, referencedModel, fields, referencedFields, options);
zephir_check_call_status();
ZEPHIR_OBS_VAR(alias);
if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) {
@@ -1255,7 +1255,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasMany) {
object_init_ex(relation, phalcon_mvc_model_relation_ce);
ZEPHIR_INIT_VAR(_0);
ZVAL_LONG(_0, 2);
- ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 314, _0, referencedModel, fields, referencedFields, options);
+ ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _0, referencedModel, fields, referencedFields, options);
zephir_check_call_status();
ZEPHIR_OBS_VAR(alias);
if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) {
@@ -1365,9 +1365,9 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, addHasManyToMany) {
object_init_ex(relation, phalcon_mvc_model_relation_ce);
ZEPHIR_INIT_VAR(_0);
ZVAL_LONG(_0, 4);
- ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 314, _0, referencedModel, fields, referencedFields, options);
+ ZEPHIR_CALL_METHOD(NULL, relation, "__construct", NULL, 315, _0, referencedModel, fields, referencedFields, options);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, relation, "setintermediaterelation", NULL, 315, intermediateFields, intermediateModel, intermediateReferencedFields);
+ ZEPHIR_CALL_METHOD(NULL, relation, "setintermediaterelation", NULL, 316, intermediateFields, intermediateModel, intermediateReferencedFields);
zephir_check_call_status();
ZEPHIR_OBS_VAR(alias);
if (zephir_array_isset_string_fetch(&alias, options, SS("alias"), 0 TSRMLS_CC)) {
@@ -1851,7 +1851,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Not supported", "phalcon/mvc/model/manager.zep", 1245);
return;
}
- ZEPHIR_CALL_METHOD(&_2, this_ptr, "_mergefindparameters", &_3, 316, extraParameters, parameters);
+ ZEPHIR_CALL_METHOD(&_2, this_ptr, "_mergefindparameters", &_3, 317, extraParameters, parameters);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&builder, this_ptr, "createbuilder", NULL, 0, _2);
zephir_check_call_status();
@@ -1916,10 +1916,10 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, getRelationRecords) {
ZEPHIR_CALL_METHOD(&_2, record, "getdi", NULL, 0);
zephir_check_call_status();
zephir_array_update_string(&findParams, SL("di"), &_2, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&findArguments, this_ptr, "_mergefindparameters", &_3, 316, findParams, parameters);
+ ZEPHIR_CALL_METHOD(&findArguments, this_ptr, "_mergefindparameters", &_3, 317, findParams, parameters);
zephir_check_call_status();
if (Z_TYPE_P(extraParameters) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&findParams, this_ptr, "_mergefindparameters", &_3, 316, findArguments, extraParameters);
+ ZEPHIR_CALL_METHOD(&findParams, this_ptr, "_mergefindparameters", &_3, 317, findArguments, extraParameters);
zephir_check_call_status();
} else {
ZEPHIR_CPY_WRT(findParams, findArguments);
@@ -2675,7 +2675,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Manager, createBuilder) {
}
/**
- * Returns the lastest query created or executed in the models manager
+ * Returns the last query created or executed in the models manager
*/
PHP_METHOD(Phalcon_Mvc_Model_Manager, getLastQuery) {
diff --git a/ext/phalcon/mvc/model/managerinterface.zep.c b/ext/phalcon/mvc/model/managerinterface.zep.c
index 2c3916f6ab3..d3d6a96e4ff 100644
--- a/ext/phalcon/mvc/model/managerinterface.zep.c
+++ b/ext/phalcon/mvc/model/managerinterface.zep.c
@@ -300,7 +300,7 @@ ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, notifyEvent);
ZEPHIR_DOC_METHOD(Phalcon_Mvc_Model_ManagerInterface, missingMethod);
/**
- * Returns the last query created or executed in the
+ * Returns the last query created or executed in the models manager
*
* @return Phalcon\Mvc\Model\QueryInterface
*/
diff --git a/ext/phalcon/mvc/model/metadata/libmemcached.zep.c b/ext/phalcon/mvc/model/metadata/libmemcached.zep.c
index c2a0dbde6a4..62d443d61d5 100644
--- a/ext/phalcon/mvc/model/metadata/libmemcached.zep.c
+++ b/ext/phalcon/mvc/model/metadata/libmemcached.zep.c
@@ -104,9 +104,9 @@ PHP_METHOD(Phalcon_Mvc_Model_MetaData_Libmemcached, __construct) {
ZEPHIR_OBS_VAR(_3);
zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC);
zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 317, _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 318, _1, options);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 319, _1, options);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_4);
@@ -214,7 +214,7 @@ PHP_METHOD(Phalcon_Mvc_Model_MetaData_Libmemcached, reset) {
zephir_check_call_status();
}
}
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_libmemcached_ce, this_ptr, "reset", &_5, 319);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_libmemcached_ce, this_ptr, "reset", &_5, 320);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
diff --git a/ext/phalcon/mvc/model/metadata/memcache.zep.c b/ext/phalcon/mvc/model/metadata/memcache.zep.c
index d6ecfb8194a..49478e4c667 100644
--- a/ext/phalcon/mvc/model/metadata/memcache.zep.c
+++ b/ext/phalcon/mvc/model/metadata/memcache.zep.c
@@ -111,9 +111,9 @@ PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memcache, __construct) {
ZEPHIR_OBS_VAR(_3);
zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC);
zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 317, _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 320, _1, options);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 321, _1, options);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_4);
@@ -221,7 +221,7 @@ PHP_METHOD(Phalcon_Mvc_Model_MetaData_Memcache, reset) {
zephir_check_call_status();
}
}
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_memcache_ce, this_ptr, "reset", &_5, 319);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_memcache_ce, this_ptr, "reset", &_5, 320);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
diff --git a/ext/phalcon/mvc/model/metadata/redis.zep.c b/ext/phalcon/mvc/model/metadata/redis.zep.c
new file mode 100644
index 00000000000..06ec581489a
--- /dev/null
+++ b/ext/phalcon/mvc/model/metadata/redis.zep.c
@@ -0,0 +1,229 @@
+
+#ifdef HAVE_CONFIG_H
+#include "../../../../ext_config.h"
+#endif
+
+#include
+#include "../../../../php_ext.h"
+#include "../../../../ext.h"
+
+#include
+#include
+#include
+
+#include "kernel/main.h"
+#include "kernel/memory.h"
+#include "kernel/array.h"
+#include "kernel/object.h"
+#include "kernel/fcall.h"
+#include "ext/spl/spl_exceptions.h"
+#include "kernel/exception.h"
+#include "kernel/operators.h"
+#include "kernel/hash.h"
+#include "kernel/concat.h"
+
+
+/**
+ * Phalcon\Mvc\Model\MetaData\Redis
+ *
+ * Stores model meta-data in the Redis.
+ *
+ * By default meta-data is stored for 48 hours (172800 seconds)
+ *
+ *
+ *
+ * $metaData = new Phalcon\Mvc\Model\Metadata\Redis(array(
+ * 'prefix' => 'my-app-id',
+ * 'lifetime' => 86400,
+ * 'host' => 'localhost',
+ * 'port' => 6379,
+ * 'persistent' => false
+ * ));
+ *
+ */
+ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_MetaData_Redis) {
+
+ ZEPHIR_REGISTER_CLASS_EX(Phalcon\\Mvc\\Model\\MetaData, Redis, phalcon, mvc_model_metadata_redis, phalcon_mvc_model_metadata_ce, phalcon_mvc_model_metadata_redis_method_entry, 0);
+
+ zend_declare_property_long(phalcon_mvc_model_metadata_redis_ce, SL("_ttl"), 172800, ZEND_ACC_PROTECTED TSRMLS_CC);
+
+ zend_declare_property_null(phalcon_mvc_model_metadata_redis_ce, SL("_redis"), ZEND_ACC_PROTECTED TSRMLS_CC);
+
+ zend_class_implements(phalcon_mvc_model_metadata_redis_ce TSRMLS_CC, 1, phalcon_mvc_model_metadatainterface_ce);
+ return SUCCESS;
+
+}
+
+/**
+ * Phalcon\Mvc\Model\MetaData\Redis constructor
+ *
+ * @param array options
+ */
+PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, __construct) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *_2;
+ zval *options = NULL, *ttl, *_0 = NULL, *_1, *_3, *_4;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 0, 1, &options);
+
+ if (!options) {
+ ZEPHIR_CPY_WRT(options, ZEPHIR_GLOBAL(global_null));
+ } else {
+ ZEPHIR_SEPARATE_PARAM(options);
+ }
+
+
+ if (Z_TYPE_P(options) != IS_ARRAY) {
+ ZEPHIR_INIT_NVAR(options);
+ array_init(options);
+ }
+ if (!(zephir_array_isset_string(options, SS("host")))) {
+ ZEPHIR_INIT_VAR(_0);
+ ZVAL_STRING(_0, "127.0.0.1", 1);
+ zephir_array_update_string(&options, SL("host"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("port")))) {
+ ZEPHIR_INIT_NVAR(_0);
+ ZVAL_LONG(_0, 6379);
+ zephir_array_update_string(&options, SL("port"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("persistent")))) {
+ ZEPHIR_INIT_NVAR(_0);
+ ZVAL_LONG(_0, 0);
+ zephir_array_update_string(&options, SL("persistent"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("statsKey")))) {
+ ZEPHIR_INIT_NVAR(_0);
+ ZVAL_STRING(_0, "_PHCM_MM", 1);
+ zephir_array_update_string(&options, SL("statsKey"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (zephir_array_isset_string_fetch(&ttl, options, SS("lifetime"), 1 TSRMLS_CC)) {
+ zephir_update_property_this(this_ptr, SL("_ttl"), ttl TSRMLS_CC);
+ }
+ ZEPHIR_INIT_NVAR(_0);
+ object_init_ex(_0, phalcon_cache_backend_redis_ce);
+ ZEPHIR_INIT_VAR(_1);
+ object_init_ex(_1, phalcon_cache_frontend_data_ce);
+ ZEPHIR_INIT_VAR(_2);
+ zephir_create_array(_2, 1, 0 TSRMLS_CC);
+ ZEPHIR_OBS_VAR(_3);
+ zephir_read_property_this(&_3, this_ptr, SL("_ttl"), PH_NOISY_CC);
+ zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 322, _1, options);
+ zephir_check_call_status();
+ zephir_update_property_this(this_ptr, SL("_redis"), _0 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_4);
+ array_init(_4);
+ zephir_update_property_this(this_ptr, SL("_metaData"), _4 TSRMLS_CC);
+ ZEPHIR_MM_RESTORE();
+
+}
+
+/**
+ * Reads metadata from Redis
+ */
+PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, read) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *key_param = NULL, *data = NULL, *_0;
+ zval *key = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 0, &key_param);
+
+ if (unlikely(Z_TYPE_P(key_param) != IS_STRING && Z_TYPE_P(key_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'key' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(key_param) == IS_STRING)) {
+ zephir_get_strval(key, key_param);
+ } else {
+ ZEPHIR_INIT_VAR(key);
+ ZVAL_EMPTY_STRING(key);
+ }
+
+
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ ZEPHIR_CALL_METHOD(&data, _0, "get", NULL, 0, key);
+ zephir_check_call_status();
+ if (Z_TYPE_P(data) == IS_ARRAY) {
+ RETURN_CCTOR(data);
+ }
+ RETURN_MM_NULL();
+
+}
+
+/**
+ * Writes the metadata to Redis
+ */
+PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, write) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *key_param = NULL, *data, *_0;
+ zval *key = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 2, 0, &key_param, &data);
+
+ if (unlikely(Z_TYPE_P(key_param) != IS_STRING && Z_TYPE_P(key_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'key' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(key_param) == IS_STRING)) {
+ zephir_get_strval(key, key_param);
+ } else {
+ ZEPHIR_INIT_VAR(key);
+ ZVAL_EMPTY_STRING(key);
+ }
+
+
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ ZEPHIR_CALL_METHOD(NULL, _0, "save", NULL, 0, key, data);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+/**
+ * Flush Redis data and resets internal meta-data in order to regenerate it
+ */
+PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, reset) {
+
+ zephir_fcall_cache_entry *_5 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ HashTable *_2;
+ HashPosition _1;
+ zval *meta, *key = NULL, *realKey = NULL, *_0 = NULL, **_3, *_4;
+
+ ZEPHIR_MM_GROW();
+
+ ZEPHIR_OBS_VAR(meta);
+ zephir_read_property_this(&meta, this_ptr, SL("_metaData"), PH_NOISY_CC);
+ if (Z_TYPE_P(meta) == IS_ARRAY) {
+ ZEPHIR_INIT_VAR(_0);
+ zephir_is_iterable(meta, &_2, &_1, 0, 0, "phalcon/mvc/model/metadata/redis.zep", 131);
+ for (
+ ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
+ ; zephir_hash_move_forward_ex(_2, &_1)
+ ) {
+ ZEPHIR_GET_HMKEY(key, _2, _1);
+ ZEPHIR_GET_HVALUE(_0, _3);
+ ZEPHIR_INIT_NVAR(realKey);
+ ZEPHIR_CONCAT_SV(realKey, "meta-", key);
+ _4 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ ZEPHIR_CALL_METHOD(NULL, _4, "delete", NULL, 0, realKey);
+ zephir_check_call_status();
+ }
+ }
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_metadata_redis_ce, this_ptr, "reset", &_5, 320);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
diff --git a/ext/phalcon/mvc/model/metadata/redis.zep.h b/ext/phalcon/mvc/model/metadata/redis.zep.h
new file mode 100644
index 00000000000..2108a3d1fa5
--- /dev/null
+++ b/ext/phalcon/mvc/model/metadata/redis.zep.h
@@ -0,0 +1,30 @@
+
+extern zend_class_entry *phalcon_mvc_model_metadata_redis_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Mvc_Model_MetaData_Redis);
+
+PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, __construct);
+PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, read);
+PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, write);
+PHP_METHOD(Phalcon_Mvc_Model_MetaData_Redis, reset);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_metadata_redis___construct, 0, 0, 0)
+ ZEND_ARG_INFO(0, options)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_metadata_redis_read, 0, 0, 1)
+ ZEND_ARG_INFO(0, key)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_mvc_model_metadata_redis_write, 0, 0, 2)
+ ZEND_ARG_INFO(0, key)
+ ZEND_ARG_INFO(0, data)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_mvc_model_metadata_redis_method_entry) {
+ PHP_ME(Phalcon_Mvc_Model_MetaData_Redis, __construct, arginfo_phalcon_mvc_model_metadata_redis___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Mvc_Model_MetaData_Redis, read, arginfo_phalcon_mvc_model_metadata_redis_read, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Mvc_Model_MetaData_Redis, write, arginfo_phalcon_mvc_model_metadata_redis_write, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Mvc_Model_MetaData_Redis, reset, NULL, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
diff --git a/ext/phalcon/mvc/model/query.zep.c b/ext/phalcon/mvc/model/query.zep.c
index fe19650d653..47e7a4d720e 100644
--- a/ext/phalcon/mvc/model/query.zep.c
+++ b/ext/phalcon/mvc/model/query.zep.c
@@ -421,7 +421,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getCallArgument) {
add_assoc_stringl_ex(return_value, SS("type"), SL("all"), 1);
RETURN_MM();
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getexpression", NULL, 321, argument);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getexpression", NULL, 323, argument);
zephir_check_call_status();
RETURN_MM();
@@ -460,11 +460,11 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) {
zephir_create_array(_4, 3, 0 TSRMLS_CC);
add_assoc_stringl_ex(_4, SS("type"), SL("when"), 1);
zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 344 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 321, _6);
+ ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6);
zephir_check_call_status();
zephir_array_update_string(&_4, SL("expr"), &_5, PH_COPY | PH_SEPARATE);
zephir_array_fetch_string(&_8, whenExpr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 345 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 321, _8);
+ ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _8);
zephir_check_call_status();
zephir_array_update_string(&_4, SL("then"), &_5, PH_COPY | PH_SEPARATE);
zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 346);
@@ -473,7 +473,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) {
zephir_create_array(_4, 2, 0 TSRMLS_CC);
add_assoc_stringl_ex(_4, SS("type"), SL("else"), 1);
zephir_array_fetch_string(&_6, whenExpr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 350 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 321, _6);
+ ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6);
zephir_check_call_status();
zephir_array_update_string(&_4, SL("expr"), &_5, PH_COPY | PH_SEPARATE);
zephir_array_append(&whenClauses, _4, PH_SEPARATE, "phalcon/mvc/model/query.zep", 351);
@@ -482,7 +482,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getCaseExpression) {
zephir_create_array(return_value, 3, 0 TSRMLS_CC);
add_assoc_stringl_ex(return_value, SS("type"), SL("case"), 1);
zephir_array_fetch_string(&_6, expr, SL("left"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 357 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 321, _6);
+ ZEPHIR_CALL_METHOD(&_5, this_ptr, "_getexpression", &_7, 323, _6);
zephir_check_call_status();
zephir_array_update_string(&return_value, SL("expr"), &_5, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&return_value, SL("when-clauses"), &whenClauses, PH_COPY | PH_SEPARATE);
@@ -525,13 +525,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getFunctionCall) {
; zephir_hash_move_forward_ex(_1, &_0)
) {
ZEPHIR_GET_HVALUE(argument, _2);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 322, argument);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 324, argument);
zephir_check_call_status();
zephir_array_append(&functionArgs, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 381);
}
} else {
zephir_create_array(functionArgs, 1, 0 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 322, arguments);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getcallargument", &_4, 324, arguments);
zephir_check_call_status();
zephir_array_fast_append(functionArgs, _3);
}
@@ -601,12 +601,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
if (!ZEPHIR_IS_LONG(exprType, 409)) {
ZEPHIR_OBS_VAR(exprLeft);
if (zephir_array_isset_string_fetch(&exprLeft, expr, SS("left"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&left, this_ptr, "_getexpression", &_0, 321, exprLeft, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&left, this_ptr, "_getexpression", &_0, 323, exprLeft, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
}
ZEPHIR_OBS_VAR(exprRight);
if (zephir_array_isset_string_fetch(&exprRight, expr, SS("right"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&right, this_ptr, "_getexpression", &_0, 321, exprRight, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&right, this_ptr, "_getexpression", &_0, 323, exprRight, (tempNotQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
}
}
@@ -684,7 +684,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
break;
}
if (ZEPHIR_IS_LONG(exprType, 355)) {
- ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getqualified", &_1, 323, expr);
+ ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getqualified", &_1, 325, expr);
zephir_check_call_status();
break;
}
@@ -1129,12 +1129,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
break;
}
if (ZEPHIR_IS_LONG(exprType, 350)) {
- ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getfunctioncall", NULL, 324, expr);
+ ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getfunctioncall", NULL, 326, expr);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(exprType, 409)) {
- ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getcaseexpression", NULL, 325, expr);
+ ZEPHIR_CALL_METHOD(&exprReturn, this_ptr, "_getcaseexpression", NULL, 327, expr);
zephir_check_call_status();
break;
}
@@ -1144,7 +1144,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
add_assoc_stringl_ex(exprReturn, SS("type"), SL("select"), 1);
ZEPHIR_INIT_NVAR(_3);
ZVAL_BOOL(_3, 1);
- ZEPHIR_CALL_METHOD(&_12, this_ptr, "_prepareselect", NULL, 326, expr, _3);
+ ZEPHIR_CALL_METHOD(&_12, this_ptr, "_prepareselect", NULL, 328, expr, _3);
zephir_check_call_status();
zephir_array_update_string(&exprReturn, SL("value"), &_12, PH_COPY | PH_SEPARATE);
break;
@@ -1163,7 +1163,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
RETURN_CCTOR(exprReturn);
}
if (zephir_array_isset_string(expr, SS("domain"))) {
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualified", &_1, 323, expr);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_getqualified", &_1, 325, expr);
zephir_check_call_status();
RETURN_MM();
}
@@ -1176,7 +1176,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getExpression) {
; zephir_hash_move_forward_ex(_14, &_13)
) {
ZEPHIR_GET_HVALUE(exprListItem, _15);
- ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_0, 321, exprListItem);
+ ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_0, 323, exprListItem);
zephir_check_call_status();
zephir_array_append(&listItems, _12, PH_SEPARATE, "phalcon/mvc/model/query.zep", 735);
}
@@ -1285,7 +1285,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getSelectColumn) {
add_assoc_stringl_ex(sqlColumn, SS("type"), SL("scalar"), 1);
ZEPHIR_OBS_VAR(columnData);
zephir_array_fetch_string(&columnData, column, SL("column"), PH_NOISY, "phalcon/mvc/model/query.zep", 838 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&sqlExprColumn, this_ptr, "_getexpression", NULL, 321, columnData);
+ ZEPHIR_CALL_METHOD(&sqlExprColumn, this_ptr, "_getexpression", NULL, 323, columnData);
zephir_check_call_status();
ZEPHIR_OBS_VAR(balias);
if (zephir_array_isset_string_fetch(&balias, sqlExprColumn, SS("balias"), 0 TSRMLS_CC)) {
@@ -1508,7 +1508,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) {
add_assoc_long_ex(_2, SS("type"), 355);
zephir_array_update_string(&_2, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_2, SL("name"), &fields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 323, _2);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _2);
zephir_check_call_status();
zephir_array_update_string(&_0, SL("left"), &_1, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_VAR(_4);
@@ -1516,7 +1516,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) {
add_assoc_stringl_ex(_4, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_4, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 323, _4);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _4);
zephir_check_call_status();
zephir_array_update_string(&_0, SL("right"), &_1, PH_COPY | PH_SEPARATE);
zephir_array_fast_append(sqlJoinConditions, _0);
@@ -1552,7 +1552,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) {
add_assoc_long_ex(_2, SS("type"), 355);
zephir_array_update_string(&_2, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_2, SL("name"), &field, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 323, _2);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _2);
zephir_check_call_status();
zephir_array_update_string(&_0, SL("left"), &_1, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_NVAR(_4);
@@ -1560,7 +1560,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getSingleJoin) {
add_assoc_stringl_ex(_4, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_4, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("name"), &referencedField, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 323, _4);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_getqualified", &_3, 325, _4);
zephir_check_call_status();
zephir_array_update_string(&_0, SL("right"), &_1, PH_COPY | PH_SEPARATE);
zephir_array_append(&sqlJoinPartialConditions, _0, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1041);
@@ -1653,7 +1653,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_long_ex(_8, SS("type"), 355);
zephir_array_update_string(&_8, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_8, SL("name"), &field, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _8);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _8);
zephir_check_call_status();
zephir_array_update_string(&sqlEqualsJoinCondition, SL("left"), &_7, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_NVAR(_10);
@@ -1661,7 +1661,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_stringl_ex(_10, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_10, SL("domain"), &joinAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_10, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _10);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _10);
zephir_check_call_status();
zephir_array_update_string(&sqlEqualsJoinCondition, SL("right"), &_7, PH_COPY | PH_SEPARATE);
}
@@ -1683,7 +1683,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_long_ex(_12, SS("type"), 355);
zephir_array_update_string(&_12, SL("domain"), &modelAlias, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_12, SL("name"), &fields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _12);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _12);
zephir_check_call_status();
zephir_array_update_string(&_11, SL("left"), &_7, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_VAR(_13);
@@ -1691,7 +1691,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_stringl_ex(_13, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_13, SL("domain"), &intermediateModelName, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_13, SL("name"), &intermediateFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _13);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _13);
zephir_check_call_status();
zephir_array_update_string(&_11, SL("right"), &_7, PH_COPY | PH_SEPARATE);
zephir_array_fast_append(_10, _11);
@@ -1712,7 +1712,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_long_ex(_14, SS("type"), 355);
zephir_array_update_string(&_14, SL("domain"), &intermediateModelName, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_14, SL("name"), &intermediateReferencedFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _14);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _14);
zephir_check_call_status();
zephir_array_update_string(&_11, SL("left"), &_7, PH_COPY | PH_SEPARATE);
ZEPHIR_INIT_VAR(_15);
@@ -1720,7 +1720,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getMultiJoin) {
add_assoc_stringl_ex(_15, SS("type"), SL("qualified"), 1);
zephir_array_update_string(&_15, SL("domain"), &referencedModelName, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_15, SL("name"), &referencedFields, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 323, _15);
+ ZEPHIR_CALL_METHOD(&_7, this_ptr, "_getqualified", &_9, 325, _15);
zephir_check_call_status();
zephir_array_update_string(&_11, SL("right"), &_7, PH_COPY | PH_SEPARATE);
zephir_array_fast_append(_10, _11);
@@ -1793,7 +1793,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) {
; zephir_hash_move_forward_ex(_1, &_0)
) {
ZEPHIR_GET_HVALUE(joinItem, _2);
- ZEPHIR_CALL_METHOD(&joinData, this_ptr, "_getjoin", &_3, 327, manager, joinItem);
+ ZEPHIR_CALL_METHOD(&joinData, this_ptr, "_getjoin", &_3, 329, manager, joinItem);
zephir_check_call_status();
ZEPHIR_OBS_NVAR(source);
zephir_array_fetch_string(&source, joinData, SL("source"), PH_NOISY, "phalcon/mvc/model/query.zep", 1273 TSRMLS_CC);
@@ -1807,7 +1807,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) {
zephir_create_array(completeSource, 2, 0 TSRMLS_CC);
zephir_array_fast_append(completeSource, source);
zephir_array_fast_append(completeSource, schema);
- ZEPHIR_CALL_METHOD(&joinType, this_ptr, "_getjointype", &_4, 328, joinItem);
+ ZEPHIR_CALL_METHOD(&joinType, this_ptr, "_getjointype", &_4, 330, joinItem);
zephir_check_call_status();
ZEPHIR_OBS_NVAR(aliasExpr);
if (zephir_array_isset_string_fetch(&aliasExpr, joinItem, SS("alias"), 0 TSRMLS_CC)) {
@@ -1875,7 +1875,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) {
ZEPHIR_GET_HVALUE(joinItem, _11);
ZEPHIR_OBS_NVAR(joinExpr);
if (zephir_array_isset_string_fetch(&joinExpr, joinItem, SS("conditions"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_13, 321, joinExpr);
+ ZEPHIR_CALL_METHOD(&_12, this_ptr, "_getexpression", &_13, 323, joinExpr);
zephir_check_call_status();
zephir_array_update_zval(&joinPreCondition, joinAliasName, &_12, PH_COPY | PH_SEPARATE);
}
@@ -1933,10 +1933,10 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getJoins) {
ZEPHIR_CALL_METHOD(&_12, relation, "isthrough", NULL, 0);
zephir_check_call_status();
if (!(zephir_is_true(_12))) {
- ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getsinglejoin", &_23, 329, joinType, joinSource, modelAlias, joinAlias, relation);
+ ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getsinglejoin", &_23, 331, joinType, joinSource, modelAlias, joinAlias, relation);
zephir_check_call_status();
} else {
- ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getmultijoin", &_24, 330, joinType, joinSource, modelAlias, joinAlias, relation);
+ ZEPHIR_CALL_METHOD(&sqlJoin, this_ptr, "_getmultijoin", &_24, 332, joinType, joinSource, modelAlias, joinAlias, relation);
zephir_check_call_status();
}
if (zephir_array_isset_long(sqlJoin, 0)) {
@@ -2013,7 +2013,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getOrderClause) {
) {
ZEPHIR_GET_HVALUE(orderItem, _2);
zephir_array_fetch_string(&_3, orderItem, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 1560 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&orderPartExpr, this_ptr, "_getexpression", &_4, 321, _3);
+ ZEPHIR_CALL_METHOD(&orderPartExpr, this_ptr, "_getexpression", &_4, 323, _3);
zephir_check_call_status();
if (zephir_array_isset_string_fetch(&orderSort, orderItem, SS("sort"), 1 TSRMLS_CC)) {
ZEPHIR_INIT_NVAR(orderPartSort);
@@ -2069,13 +2069,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getGroupClause) {
; zephir_hash_move_forward_ex(_1, &_0)
) {
ZEPHIR_GET_HVALUE(groupItem, _2);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 321, groupItem);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 323, groupItem);
zephir_check_call_status();
zephir_array_append(&groupParts, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1594);
}
} else {
zephir_create_array(groupParts, 1, 0 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 321, group);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_4, 323, group);
zephir_check_call_status();
zephir_array_fast_append(groupParts, _3);
}
@@ -2104,13 +2104,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getLimitClause) {
ZEPHIR_OBS_VAR(number);
if (zephir_array_isset_string_fetch(&number, limitClause, SS("number"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 321, number);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 323, number);
zephir_check_call_status();
zephir_array_update_string(&limit, SL("number"), &_0, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(offset);
if (zephir_array_isset_string_fetch(&offset, limitClause, SS("offset"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 321, offset);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_1, 323, offset);
zephir_check_call_status();
zephir_array_update_string(&limit, SL("offset"), &_0, PH_COPY | PH_SEPARATE);
}
@@ -2317,7 +2317,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) {
ZEPHIR_OBS_VAR(joins);
if (zephir_array_isset_string_fetch(&joins, select, SS("joins"), 0 TSRMLS_CC)) {
if (zephir_fast_count_int(joins TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", NULL, 331, select);
+ ZEPHIR_CALL_METHOD(&sqlJoins, this_ptr, "_getjoins", NULL, 333, select);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(sqlJoins);
@@ -2343,7 +2343,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) {
; zephir_hash_move_forward_ex(_23, &_22)
) {
ZEPHIR_GET_HVALUE(column, _24);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getselectcolumn", &_25, 332, column);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getselectcolumn", &_25, 334, column);
zephir_check_call_status();
zephir_is_iterable(_3, &_27, &_26, 0, 0, "phalcon/mvc/model/query.zep", 1856);
for (
@@ -2392,31 +2392,31 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareSelect) {
}
ZEPHIR_OBS_VAR(where);
if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_31, 321, where);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_31, 323, where);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("where"), &_3, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(groupBy);
if (zephir_array_isset_string_fetch(&groupBy, ast, SS("groupBy"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getgroupclause", NULL, 333, groupBy);
+ ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getgroupclause", NULL, 335, groupBy);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("group"), &_32, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(having);
if (zephir_array_isset_string_fetch(&having, ast, SS("having"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getexpression", &_31, 321, having);
+ ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getexpression", &_31, 323, having);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("having"), &_32, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(order);
if (zephir_array_isset_string_fetch(&order, ast, SS("orderBy"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getorderclause", NULL, 334, order);
+ ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getorderclause", NULL, 336, order);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("order"), &_32, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(limit);
if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getlimitclause", NULL, 335, limit);
+ ZEPHIR_CALL_METHOD(&_32, this_ptr, "_getlimitclause", NULL, 337, limit);
zephir_check_call_status();
zephir_array_update_string(&sqlSelect, SL("limit"), &_32, PH_COPY | PH_SEPARATE);
}
@@ -2503,7 +2503,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareInsert) {
ZEPHIR_OBS_NVAR(_8);
zephir_array_fetch_string(&_8, exprValue, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 1960 TSRMLS_CC);
zephir_array_update_string(&_7, SL("type"), &_8, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_9, 321, exprValue, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "_getexpression", &_9, 323, exprValue, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_array_update_string(&_7, SL("value"), &_0, PH_COPY | PH_SEPARATE);
zephir_array_append(&exprValues, _7, PH_SEPARATE, "phalcon/mvc/model/query.zep", 1962);
@@ -2681,7 +2681,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) {
) {
ZEPHIR_GET_HVALUE(updateValue, _11);
zephir_array_fetch_string(&_4, updateValue, SL("column"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/query.zep", 2110 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_12, 321, _4, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", &_12, 323, _4, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_array_append(&sqlFields, _3, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2110);
ZEPHIR_OBS_NVAR(exprColumn);
@@ -2691,7 +2691,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) {
ZEPHIR_OBS_NVAR(_14);
zephir_array_fetch_string(&_14, exprColumn, SL("type"), PH_NOISY, "phalcon/mvc/model/query.zep", 2113 TSRMLS_CC);
zephir_array_update_string(&_13, SL("type"), &_14, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 321, exprColumn, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 323, exprColumn, (notQuoting ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_array_update_string(&_13, SL("value"), &_15, PH_COPY | PH_SEPARATE);
zephir_array_append(&sqlValues, _13, PH_SEPARATE, "phalcon/mvc/model/query.zep", 2115);
@@ -2706,13 +2706,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareUpdate) {
if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) {
ZEPHIR_SINIT_VAR(_16);
ZVAL_BOOL(&_16, 1);
- ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 321, where, &_16);
+ ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getexpression", &_12, 323, where, &_16);
zephir_check_call_status();
zephir_array_update_string(&sqlUpdate, SL("where"), &_15, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(limit);
if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getlimitclause", NULL, 335, limit);
+ ZEPHIR_CALL_METHOD(&_15, this_ptr, "_getlimitclause", NULL, 337, limit);
zephir_check_call_status();
zephir_array_update_string(&sqlUpdate, SL("limit"), &_15, PH_COPY | PH_SEPARATE);
}
@@ -2834,13 +2834,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _prepareDelete) {
if (zephir_array_isset_string_fetch(&where, ast, SS("where"), 0 TSRMLS_CC)) {
ZEPHIR_SINIT_VAR(_9);
ZVAL_BOOL(&_9, 1);
- ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", NULL, 321, where, &_9);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "_getexpression", NULL, 323, where, &_9);
zephir_check_call_status();
zephir_array_update_string(&sqlDelete, SL("where"), &_3, PH_COPY | PH_SEPARATE);
}
ZEPHIR_OBS_VAR(limit);
if (zephir_array_isset_string_fetch(&limit, ast, SS("limit"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_10, this_ptr, "_getlimitclause", NULL, 335, limit);
+ ZEPHIR_CALL_METHOD(&_10, this_ptr, "_getlimitclause", NULL, 337, limit);
zephir_check_call_status();
zephir_array_update_string(&sqlDelete, SL("limit"), &_10, PH_COPY | PH_SEPARATE);
}
@@ -2892,22 +2892,22 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, parse) {
zephir_update_property_this(this_ptr, SL("_type"), type TSRMLS_CC);
do {
if (ZEPHIR_IS_LONG(type, 309)) {
- ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareselect", NULL, 326);
+ ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareselect", NULL, 328);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 306)) {
- ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareinsert", NULL, 336);
+ ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareinsert", NULL, 338);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 300)) {
- ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareupdate", NULL, 337);
+ ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_prepareupdate", NULL, 339);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 303)) {
- ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_preparedelete", NULL, 338);
+ ZEPHIR_CALL_METHOD(&irPhql, this_ptr, "_preparedelete", NULL, 340);
zephir_check_call_status();
break;
}
@@ -3300,12 +3300,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeSelect) {
isKeepingSnapshots = zephir_get_boolval(_40);
}
object_init_ex(return_value, phalcon_mvc_model_resultset_simple_ce);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 339, simpleColumnMap, resultObject, resultData, cache, (isKeepingSnapshots ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 341, simpleColumnMap, resultObject, resultData, cache, (isKeepingSnapshots ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
RETURN_MM();
}
object_init_ex(return_value, phalcon_mvc_model_resultset_complex_ce);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 340, columns1, resultData, cache);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 342, columns1, resultData, cache);
zephir_check_call_status();
RETURN_MM();
@@ -3473,7 +3473,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeInsert) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_CALL_METHOD(&_15, insertModel, "create", NULL, 0, insertValues);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 341, _15, insertModel);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 343, _15, insertModel);
zephir_check_call_status();
RETURN_MM();
@@ -3612,13 +3612,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) {
zephir_array_update_zval(&updateValues, fieldName, &updateValue, PH_COPY | PH_SEPARATE);
}
- ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 342, model, intermediate, selectBindParams, selectBindTypes);
+ ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 344, model, intermediate, selectBindParams, selectBindTypes);
zephir_check_call_status();
if (!(zephir_fast_count_int(records TSRMLS_CC))) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_11);
ZVAL_BOOL(_11, 1);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 341, _11);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11);
zephir_check_call_status();
RETURN_MM();
}
@@ -3651,7 +3651,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_11);
ZVAL_BOOL(_11, 0);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 341, _11, record);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11, record);
zephir_check_call_status();
RETURN_MM();
}
@@ -3662,7 +3662,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeUpdate) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_11);
ZVAL_BOOL(_11, 1);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 341, _11);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_16, 343, _11);
zephir_check_call_status();
RETURN_MM();
@@ -3703,13 +3703,13 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) {
ZEPHIR_CALL_METHOD(&model, _1, "load", NULL, 0, modelName);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 342, model, intermediate, bindParams, bindTypes);
+ ZEPHIR_CALL_METHOD(&records, this_ptr, "_getrelatedrecords", NULL, 344, model, intermediate, bindParams, bindTypes);
zephir_check_call_status();
if (!(zephir_fast_count_int(records TSRMLS_CC))) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_VAR(_2);
ZVAL_BOOL(_2, 1);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 341, _2);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2);
zephir_check_call_status();
RETURN_MM();
}
@@ -3742,7 +3742,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_2);
ZVAL_BOOL(_2, 0);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 341, _2, record);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2, record);
zephir_check_call_status();
RETURN_MM();
}
@@ -3753,7 +3753,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _executeDelete) {
object_init_ex(return_value, phalcon_mvc_model_query_status_ce);
ZEPHIR_INIT_NVAR(_2);
ZVAL_BOOL(_2, 1);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 341, _2);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", &_3, 343, _2);
zephir_check_call_status();
RETURN_MM();
@@ -3810,18 +3810,18 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, _getRelatedRecords) {
}
ZEPHIR_INIT_VAR(query);
object_init_ex(query, phalcon_mvc_model_query_ce);
- ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 343);
+ ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 345);
zephir_check_call_status();
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, query, "setdi", NULL, 344, _5);
+ ZEPHIR_CALL_METHOD(NULL, query, "setdi", NULL, 346, _5);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_2);
ZVAL_LONG(_2, 309);
- ZEPHIR_CALL_METHOD(NULL, query, "settype", NULL, 345, _2);
+ ZEPHIR_CALL_METHOD(NULL, query, "settype", NULL, 347, _2);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, query, "setintermediate", NULL, 346, selectIr);
+ ZEPHIR_CALL_METHOD(NULL, query, "setintermediate", NULL, 348, selectIr);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_METHOD(query, "execute", NULL, 347, bindParams, bindTypes);
+ ZEPHIR_RETURN_CALL_METHOD(query, "execute", NULL, 349, bindParams, bindTypes);
zephir_check_call_status();
RETURN_MM();
@@ -3949,22 +3949,22 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, execute) {
zephir_read_property_this(&type, this_ptr, SL("_type"), PH_NOISY_CC);
do {
if (ZEPHIR_IS_LONG(type, 309)) {
- ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeselect", NULL, 348, intermediate, mergedParams, mergedTypes);
+ ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeselect", NULL, 350, intermediate, mergedParams, mergedTypes);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 306)) {
- ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeinsert", NULL, 349, intermediate, mergedParams, mergedTypes);
+ ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeinsert", NULL, 351, intermediate, mergedParams, mergedTypes);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 300)) {
- ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeupdate", NULL, 350, intermediate, mergedParams, mergedTypes);
+ ZEPHIR_CALL_METHOD(&result, this_ptr, "_executeupdate", NULL, 352, intermediate, mergedParams, mergedTypes);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 303)) {
- ZEPHIR_CALL_METHOD(&result, this_ptr, "_executedelete", NULL, 351, intermediate, mergedParams, mergedTypes);
+ ZEPHIR_CALL_METHOD(&result, this_ptr, "_executedelete", NULL, 353, intermediate, mergedParams, mergedTypes);
zephir_check_call_status();
break;
}
@@ -4026,7 +4026,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, getSingleResult) {
zephir_check_call_status();
RETURN_MM();
}
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "execute", NULL, 347, bindParams, bindTypes);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "execute", NULL, 349, bindParams, bindTypes);
zephir_check_call_status();
ZEPHIR_RETURN_CALL_METHOD(_1, "getfirst", NULL, 0);
zephir_check_call_status();
@@ -4239,7 +4239,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query, getSql) {
_2 = zephir_fetch_nproperty_this(this_ptr, SL("_bindTypes"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_3);
ZVAL_BOOL(&_3, 1);
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_executeselect", NULL, 348, intermediate, _1, _2, &_3);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_executeselect", NULL, 350, intermediate, _1, _2, &_3);
zephir_check_call_status();
RETURN_MM();
}
diff --git a/ext/phalcon/mvc/model/query/builder.zep.c b/ext/phalcon/mvc/model/query/builder.zep.c
index 4fe6a8cfd73..800059ee19c 100644
--- a/ext/phalcon/mvc/model/query/builder.zep.c
+++ b/ext/phalcon/mvc/model/query/builder.zep.c
@@ -1780,7 +1780,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getPhql) {
}
}
}
- if (zephir_is_numeric(limit)) {
+ if (zephir_is_numeric(number)) {
ZEPHIR_OBS_VAR(hiddenParam);
zephir_read_property_this(&hiddenParam, this_ptr, SL("_hiddenParamNumber"), PH_NOISY_CC);
ZEPHIR_INIT_LNVAR(_4);
@@ -1844,21 +1844,21 @@ PHP_METHOD(Phalcon_Mvc_Model_Query_Builder, getQuery) {
ZEPHIR_INIT_VAR(query);
object_init_ex(query, phalcon_mvc_model_query_ce);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "getphql", NULL, 352);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "getphql", NULL, 354);
zephir_check_call_status();
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 343, _0, _1);
+ ZEPHIR_CALL_METHOD(NULL, query, "__construct", NULL, 345, _0, _1);
zephir_check_call_status();
ZEPHIR_OBS_VAR(bindParams);
zephir_read_property_this(&bindParams, this_ptr, SL("_bindParams"), PH_NOISY_CC);
if (Z_TYPE_P(bindParams) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, query, "setbindparams", NULL, 353, bindParams);
+ ZEPHIR_CALL_METHOD(NULL, query, "setbindparams", NULL, 355, bindParams);
zephir_check_call_status();
}
ZEPHIR_OBS_VAR(bindTypes);
zephir_read_property_this(&bindTypes, this_ptr, SL("_bindTypes"), PH_NOISY_CC);
if (Z_TYPE_P(bindTypes) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, query, "setbindtypes", NULL, 354, bindTypes);
+ ZEPHIR_CALL_METHOD(NULL, query, "setbindtypes", NULL, 356, bindTypes);
zephir_check_call_status();
}
RETURN_CCTOR(query);
diff --git a/ext/phalcon/mvc/model/resultset.zep.c b/ext/phalcon/mvc/model/resultset.zep.c
index f65814fe7c7..1c8ff514649 100644
--- a/ext/phalcon/mvc/model/resultset.zep.c
+++ b/ext/phalcon/mvc/model/resultset.zep.c
@@ -721,6 +721,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset, delete) {
*/
PHP_METHOD(Phalcon_Mvc_Model_Resultset, filter) {
+ zend_bool _1;
int ZEPHIR_LAST_CALL_STATUS;
zend_object_iterator *_0;
zval *filter, *records, *record = NULL, *parameters, *processedRecord = NULL;
@@ -746,12 +747,14 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset, filter) {
ZEPHIR_INIT_NVAR(processedRecord);
ZEPHIR_CALL_USER_FUNC_ARRAY(processedRecord, filter, parameters);
zephir_check_call_status();
- if (Z_TYPE_P(processedRecord) != IS_OBJECT) {
- if (Z_TYPE_P(processedRecord) != IS_ARRAY) {
- continue;
- }
+ _1 = Z_TYPE_P(processedRecord) != IS_OBJECT;
+ if (_1) {
+ _1 = Z_TYPE_P(processedRecord) != IS_ARRAY;
+ }
+ if (_1) {
+ continue;
}
- zephir_array_append(&records, processedRecord, PH_SEPARATE, "phalcon/mvc/model/resultset.zep", 558);
+ zephir_array_append(&records, processedRecord, PH_SEPARATE, "phalcon/mvc/model/resultset.zep", 556);
}
_0->funcs->dtor(_0 TSRMLS_CC);
RETURN_CCTOR(records);
diff --git a/ext/phalcon/mvc/model/resultset/complex.zep.c b/ext/phalcon/mvc/model/resultset/complex.zep.c
index 2e78355d74d..240d0d834da 100644
--- a/ext/phalcon/mvc/model/resultset/complex.zep.c
+++ b/ext/phalcon/mvc/model/resultset/complex.zep.c
@@ -72,7 +72,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Complex, __construct) {
zephir_update_property_this(this_ptr, SL("_columnTypes"), columnTypes TSRMLS_CC);
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_complex_ce, this_ptr, "__construct", &_0, 355, result, cache);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_complex_ce, this_ptr, "__construct", &_0, 357, result, cache);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
diff --git a/ext/phalcon/mvc/model/resultset/simple.zep.c b/ext/phalcon/mvc/model/resultset/simple.zep.c
index 03ca238e5f5..af6a4ebb6be 100644
--- a/ext/phalcon/mvc/model/resultset/simple.zep.c
+++ b/ext/phalcon/mvc/model/resultset/simple.zep.c
@@ -78,7 +78,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, __construct) {
zephir_update_property_this(this_ptr, SL("_model"), model TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_columnMap"), columnMap TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_keepSnapshots"), keepSnapshots TSRMLS_CC);
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_simple_ce, this_ptr, "__construct", &_0, 355, result, cache);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_model_resultset_simple_ce, this_ptr, "__construct", &_0, 357, result, cache);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -136,12 +136,12 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, current) {
_6 = zephir_fetch_nproperty_this(this_ptr, SL("_keepSnapshots"), PH_NOISY_CC);
ZEPHIR_INIT_NVAR(_3);
ZVAL_LONG(_3, 0);
- ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmap", &_5, 356, _2, row, columnMap, _3, _6);
+ ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmap", &_5, 358, _2, row, columnMap, _3, _6);
zephir_check_call_status();
}
break;
}
- ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_7, 357, row, columnMap, hydrateMode);
+ ZEPHIR_CALL_CE_STATIC(&activeRow, phalcon_mvc_model_ce, "cloneresultmaphydrate", &_7, 359, row, columnMap, hydrateMode);
zephir_check_call_status();
break;
} while(0);
@@ -162,7 +162,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, toArray) {
HashTable *_2, *_5;
HashPosition _1, _4;
int ZEPHIR_LAST_CALL_STATUS;
- zval *renameColumns_param = NULL, *result, *records = NULL, *record = NULL, *renamed = NULL, *renamedKey = NULL, *key = NULL, *value = NULL, *renamedRecords, *columnMap, *_0, **_3, **_6, *_7 = NULL, *_8 = NULL, *_10 = NULL;
+ zval *renameColumns_param = NULL, *result, *records = NULL, *record = NULL, *renamed = NULL, *renamedKey = NULL, *key = NULL, *value = NULL, *renamedRecords, *columnMap, *_0, **_3, **_6, *_7 = NULL, *_8 = NULL;
zend_bool renameColumns;
ZEPHIR_MM_GROW();
@@ -199,7 +199,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, toArray) {
ZEPHIR_INIT_VAR(renamedRecords);
array_init(renamedRecords);
if (Z_TYPE_P(records) == IS_ARRAY) {
- zephir_is_iterable(records, &_2, &_1, 0, 0, "phalcon/mvc/model/resultset/simple.zep", 220);
+ zephir_is_iterable(records, &_2, &_1, 0, 0, "phalcon/mvc/model/resultset/simple.zep", 218);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -207,7 +207,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, toArray) {
ZEPHIR_GET_HVALUE(record, _3);
ZEPHIR_INIT_NVAR(renamed);
array_init(renamed);
- zephir_is_iterable(record, &_5, &_4, 0, 0, "phalcon/mvc/model/resultset/simple.zep", 218);
+ zephir_is_iterable(record, &_5, &_4, 0, 0, "phalcon/mvc/model/resultset/simple.zep", 216);
for (
; zephir_hash_get_current_data_ex(_5, (void**) &_6, &_4) == SUCCESS
; zephir_hash_move_forward_ex(_5, &_4)
@@ -239,14 +239,10 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, toArray) {
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_OBS_NVAR(_10);
- zephir_array_fetch_long(&_10, renamedKey, 0, PH_NOISY, "phalcon/mvc/model/resultset/simple.zep", 209 TSRMLS_CC);
- zephir_array_update_zval(&renamed, _10, &value, PH_COPY | PH_SEPARATE);
- } else {
- zephir_array_update_zval(&renamed, renamedKey, &value, PH_COPY | PH_SEPARATE);
}
+ zephir_array_update_zval(&renamed, renamedKey, &value, PH_COPY | PH_SEPARATE);
}
- zephir_array_append(&renamedRecords, renamed, PH_SEPARATE, "phalcon/mvc/model/resultset/simple.zep", 218);
+ zephir_array_append(&renamedRecords, renamed, PH_SEPARATE, "phalcon/mvc/model/resultset/simple.zep", 216);
}
}
RETURN_CCTOR(renamedRecords);
@@ -319,22 +315,22 @@ PHP_METHOD(Phalcon_Mvc_Model_Resultset_Simple, unserialize) {
ZEPHIR_CALL_FUNCTION(&resultset, "unserialize", NULL, 72, data);
zephir_check_call_status();
if (Z_TYPE_P(resultset) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/simple.zep", 254);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_model_exception_ce, "Invalid serialization data", "phalcon/mvc/model/resultset/simple.zep", 252);
return;
}
- zephir_array_fetch_string(&_0, resultset, SL("model"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 257 TSRMLS_CC);
+ zephir_array_fetch_string(&_0, resultset, SL("model"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 255 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_model"), _0 TSRMLS_CC);
- zephir_array_fetch_string(&_1, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 258 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 256 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_rows"), _1 TSRMLS_CC);
- zephir_array_fetch_string(&_2, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 259 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, resultset, SL("rows"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 257 TSRMLS_CC);
ZEPHIR_INIT_ZVAL_NREF(_3);
ZVAL_LONG(_3, zephir_fast_count_int(_2 TSRMLS_CC));
zephir_update_property_this(this_ptr, SL("_count"), _3 TSRMLS_CC);
- zephir_array_fetch_string(&_4, resultset, SL("cache"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 260 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, resultset, SL("cache"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 258 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_cache"), _4 TSRMLS_CC);
- zephir_array_fetch_string(&_5, resultset, SL("columnMap"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 261 TSRMLS_CC);
+ zephir_array_fetch_string(&_5, resultset, SL("columnMap"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 259 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_columnMap"), _5 TSRMLS_CC);
- zephir_array_fetch_string(&_6, resultset, SL("hydrateMode"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 262 TSRMLS_CC);
+ zephir_array_fetch_string(&_6, resultset, SL("hydrateMode"), PH_NOISY | PH_READONLY, "phalcon/mvc/model/resultset/simple.zep", 260 TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_hydrateMode"), _6 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
diff --git a/ext/phalcon/mvc/model/transaction.zep.c b/ext/phalcon/mvc/model/transaction.zep.c
index a2b1da82114..71e55d30a2b 100644
--- a/ext/phalcon/mvc/model/transaction.zep.c
+++ b/ext/phalcon/mvc/model/transaction.zep.c
@@ -248,7 +248,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Transaction, rollback) {
ZEPHIR_INIT_NVAR(_0);
object_init_ex(_0, phalcon_mvc_model_transaction_failed_ce);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_rollbackRecord"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 358, rollbackMessage, _5);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 360, rollbackMessage, _5);
zephir_check_call_status();
zephir_throw_exception_debug(_0, "phalcon/mvc/model/transaction.zep", 160 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
@@ -270,7 +270,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Transaction, getConnection) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_rollbackOnAbort"), PH_NOISY_CC);
if (zephir_is_true(_0)) {
- ZEPHIR_CALL_FUNCTION(&_1, "connection_aborted", NULL, 359);
+ ZEPHIR_CALL_FUNCTION(&_1, "connection_aborted", NULL, 361);
zephir_check_call_status();
if (zephir_is_true(_1)) {
ZEPHIR_INIT_VAR(_2);
diff --git a/ext/phalcon/mvc/model/transaction/manager.zep.c b/ext/phalcon/mvc/model/transaction/manager.zep.c
index b55b7cea6b4..6258406d207 100644
--- a/ext/phalcon/mvc/model/transaction/manager.zep.c
+++ b/ext/phalcon/mvc/model/transaction/manager.zep.c
@@ -259,7 +259,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Transaction_Manager, get) {
ZEPHIR_INIT_VAR(_3);
ZVAL_STRING(_3, "rollbackPendent", 1);
zephir_array_fast_append(_2, _3);
- ZEPHIR_CALL_FUNCTION(NULL, "register_shutdown_function", NULL, 360, _2);
+ ZEPHIR_CALL_FUNCTION(NULL, "register_shutdown_function", NULL, 362, _2);
zephir_check_call_status();
}
zephir_update_property_this(this_ptr, SL("_initialized"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
@@ -321,9 +321,9 @@ PHP_METHOD(Phalcon_Mvc_Model_Transaction_Manager, getOrCreateTransaction) {
ZEPHIR_INIT_VAR(transaction);
object_init_ex(transaction, phalcon_mvc_model_transaction_ce);
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_service"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, transaction, "__construct", NULL, 361, dependencyInjector, (autoBegin ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), _5);
+ ZEPHIR_CALL_METHOD(NULL, transaction, "__construct", NULL, 363, dependencyInjector, (autoBegin ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)), _5);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, transaction, "settransactionmanager", NULL, 362, this_ptr);
+ ZEPHIR_CALL_METHOD(NULL, transaction, "settransactionmanager", NULL, 364, this_ptr);
zephir_check_call_status();
zephir_update_property_array_append(this_ptr, SL("_transactions"), transaction TSRMLS_CC);
RETURN_ON_FAILURE(zephir_property_incr(this_ptr, SL("_number") TSRMLS_CC));
diff --git a/ext/phalcon/mvc/model/validator/email.zep.c b/ext/phalcon/mvc/model/validator/email.zep.c
index 8f836c00885..1310b0b385c 100644
--- a/ext/phalcon/mvc/model/validator/email.zep.c
+++ b/ext/phalcon/mvc/model/validator/email.zep.c
@@ -94,7 +94,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Email, validate) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 274);
- ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 190, value, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_0);
diff --git a/ext/phalcon/mvc/model/validator/inclusionin.zep.c b/ext/phalcon/mvc/model/validator/inclusionin.zep.c
index 99e13c2c019..4f12dea9dce 100644
--- a/ext/phalcon/mvc/model/validator/inclusionin.zep.c
+++ b/ext/phalcon/mvc/model/validator/inclusionin.zep.c
@@ -131,7 +131,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Inclusionin, validate) {
zephir_check_temp_parameter(_0);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_5, "in_array", NULL, 363, value, domain, strict);
+ ZEPHIR_CALL_FUNCTION(&_5, "in_array", NULL, 365, value, domain, strict);
zephir_check_call_status();
if (!(zephir_is_true(_5))) {
ZEPHIR_INIT_NVAR(_0);
diff --git a/ext/phalcon/mvc/model/validator/ip.zep.c b/ext/phalcon/mvc/model/validator/ip.zep.c
index 64488ac97cd..0b864431c2f 100644
--- a/ext/phalcon/mvc/model/validator/ip.zep.c
+++ b/ext/phalcon/mvc/model/validator/ip.zep.c
@@ -26,7 +26,7 @@
* Validates that a value is ipv4 address in valid range
*
*
- *use Phalcon\Mvc\Model\Validator\CardNumber;
+ *use Phalcon\Mvc\Model\Validator\Ip;
*
*class Data extends Phalcon\Mvc\Model
*{
@@ -34,7 +34,7 @@
* public function validation()
* {
* // Any pubic IP
- * $this->validate(new IPv4(array(
+ * $this->validate(new IP(array(
* 'field' => 'server_ip',
* 'version' => IP::VERSION_4 | IP::VERSION_6, // v6 and v4. The same if not specified
* 'allowReserved' => false, // False if not specified. Ignored for v6
@@ -148,7 +148,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Ip, validate) {
zephir_array_update_string(&options, SL("flags"), &_6, PH_COPY | PH_SEPARATE);
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, 275);
- ZEPHIR_CALL_FUNCTION(&_7, "filter_var", NULL, 190, value, &_5, options);
+ ZEPHIR_CALL_FUNCTION(&_7, "filter_var", NULL, 191, value, &_5, options);
zephir_check_call_status();
if (!(zephir_is_true(_7))) {
ZEPHIR_INIT_NVAR(_0);
diff --git a/ext/phalcon/mvc/model/validator/stringlength.zep.c b/ext/phalcon/mvc/model/validator/stringlength.zep.c
index de827a0a9d0..8f216356fe1 100644
--- a/ext/phalcon/mvc/model/validator/stringlength.zep.c
+++ b/ext/phalcon/mvc/model/validator/stringlength.zep.c
@@ -118,7 +118,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_StringLength, validate) {
RETURN_MM_BOOL(1);
}
if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 364, value);
+ ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, value);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(length);
diff --git a/ext/phalcon/mvc/model/validator/uniqueness.zep.c b/ext/phalcon/mvc/model/validator/uniqueness.zep.c
index fe9d488be4e..84c87ea1e19 100644
--- a/ext/phalcon/mvc/model/validator/uniqueness.zep.c
+++ b/ext/phalcon/mvc/model/validator/uniqueness.zep.c
@@ -39,7 +39,8 @@
* public function validation()
* {
* $this->validate(new Uniqueness(array(
- * "field" => 'email'
+ * "field" => "email",
+ * "message" => "Value of field 'email' is already present in another record"
* )));
* if ($this->validationHasFailed() == true) {
* return false;
@@ -105,7 +106,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
zephir_check_temp_parameter(_0);
zephir_check_call_status();
if (Z_TYPE_P(field) == IS_ARRAY) {
- zephir_is_iterable(field, &_2, &_1, 0, 0, "phalcon/mvc/model/validator/uniqueness.zep", 119);
+ zephir_is_iterable(field, &_2, &_1, 0, 0, "phalcon/mvc/model/validator/uniqueness.zep", 120);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -120,7 +121,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_4, "Column '", composeField, "' isn't part of the column map");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _4);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 96 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 97 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -135,7 +136,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_4, "Column '", columnField, "' isn't part of the table columns");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _4);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 106 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 107 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -143,11 +144,11 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZVAL_LONG(&_6, number);
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVSV(_7, "[", composeField, "] = ?", &_6);
- zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 112);
+ zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 113);
ZEPHIR_CALL_METHOD(&_8, record, "readattribute", &_9, 0, composeField);
zephir_check_call_status();
- zephir_array_append(&bindParams, _8, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 113);
- zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 114);
+ zephir_array_append(&bindParams, _8, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 114);
+ zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 115);
number++;
}
} else {
@@ -160,7 +161,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_7, "Column '", field, "' isn't part of the column map");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _7);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 126 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 127 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -175,17 +176,17 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_7, "Column '", columnField, "' isn't part of the table columns");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _7);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 136 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 137 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SVS(_7, "[", field, "] = ?0");
- zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 142);
+ zephir_array_append(&conditions, _7, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 143);
ZEPHIR_CALL_METHOD(&_8, record, "readattribute", NULL, 0, field);
zephir_check_call_status();
- zephir_array_append(&bindParams, _8, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 143);
- zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 144);
+ zephir_array_append(&bindParams, _8, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 144);
+ zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 145);
number++;
}
ZEPHIR_CALL_METHOD(&_10, record, "getoperationmade", NULL, 0);
@@ -200,7 +201,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
}
ZEPHIR_CALL_METHOD(&_8, metaData, "getprimarykeyattributes", NULL, 0, record);
zephir_check_call_status();
- zephir_is_iterable(_8, &_12, &_11, 0, 0, "phalcon/mvc/model/validator/uniqueness.zep", 189);
+ zephir_is_iterable(_8, &_12, &_11, 0, 0, "phalcon/mvc/model/validator/uniqueness.zep", 190);
for (
; zephir_hash_get_current_data_ex(_12, (void**) &_13, &_11) == SUCCESS
; zephir_hash_move_forward_ex(_12, &_11)
@@ -214,7 +215,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_7, "Column '", primaryField, "' isn't part of the table columns");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _7);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 166 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 167 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -227,7 +228,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZEPHIR_CONCAT_SVS(_14, "Column '", primaryField, "' isn't part of the column map");
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_5, 9, _14);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 174 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/model/validator/uniqueness.zep", 175 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -238,11 +239,11 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Uniqueness, validate) {
ZVAL_LONG(&_6, number);
ZEPHIR_INIT_LNVAR(_4);
ZEPHIR_CONCAT_SVSV(_4, "[", attributeField, "] <> ?", &_6);
- zephir_array_append(&conditions, _4, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 183);
+ zephir_array_append(&conditions, _4, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 184);
ZEPHIR_CALL_METHOD(&_15, record, "readattribute", &_16, 0, primaryField);
zephir_check_call_status();
- zephir_array_append(&bindParams, _15, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 184);
- zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 185);
+ zephir_array_append(&bindParams, _15, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 185);
+ zephir_array_append(&bindTypes, bindType, PH_SEPARATE, "phalcon/mvc/model/validator/uniqueness.zep", 186);
number++;
}
}
diff --git a/ext/phalcon/mvc/model/validator/url.zep.c b/ext/phalcon/mvc/model/validator/url.zep.c
index fd18aa7583b..8e65df396c1 100644
--- a/ext/phalcon/mvc/model/validator/url.zep.c
+++ b/ext/phalcon/mvc/model/validator/url.zep.c
@@ -95,7 +95,7 @@ PHP_METHOD(Phalcon_Mvc_Model_Validator_Url, validate) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 273);
- ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 190, value, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_0);
diff --git a/ext/phalcon/mvc/router/annotations.zep.c b/ext/phalcon/mvc/router/annotations.zep.c
index a6932690c4d..9677e5f25af 100644
--- a/ext/phalcon/mvc/router/annotations.zep.c
+++ b/ext/phalcon/mvc/router/annotations.zep.c
@@ -326,7 +326,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Annotations, handle) {
}
zephir_update_property_this(this_ptr, SL("_processed"), (1) ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false) TSRMLS_CC);
}
- ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_router_annotations_ce, this_ptr, "handle", &_18, 365, realUri);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_mvc_router_annotations_ce, this_ptr, "handle", &_18, 367, realUri);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
diff --git a/ext/phalcon/mvc/router/group.zep.c b/ext/phalcon/mvc/router/group.zep.c
index 618f6a84608..a15ae5de74d 100644
--- a/ext/phalcon/mvc/router/group.zep.c
+++ b/ext/phalcon/mvc/router/group.zep.c
@@ -85,6 +85,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_Router_Group) {
PHP_METHOD(Phalcon_Mvc_Router_Group, __construct) {
int ZEPHIR_LAST_CALL_STATUS;
+ zend_bool _0;
zval *paths = NULL;
ZEPHIR_MM_GROW();
@@ -95,12 +96,12 @@ PHP_METHOD(Phalcon_Mvc_Router_Group, __construct) {
}
- if (Z_TYPE_P(paths) == IS_ARRAY) {
+ _0 = Z_TYPE_P(paths) == IS_ARRAY;
+ if (!(_0)) {
+ _0 = Z_TYPE_P(paths) == IS_STRING;
+ }
+ if (_0) {
zephir_update_property_this(this_ptr, SL("_paths"), paths TSRMLS_CC);
- } else {
- if (Z_TYPE_P(paths) == IS_STRING) {
- zephir_update_property_this(this_ptr, SL("_paths"), paths TSRMLS_CC);
- }
}
if ((zephir_method_exists_ex(this_ptr, SS("initialize") TSRMLS_CC) == SUCCESS)) {
ZEPHIR_CALL_METHOD(NULL, this_ptr, "initialize", NULL, 0, paths);
@@ -634,7 +635,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Group, _addRoute) {
ZEPHIR_CALL_METHOD(NULL, route, "__construct", NULL, 74, _2, mergedPaths, httpMethods);
zephir_check_call_status();
zephir_update_property_array_append(this_ptr, SL("_routes"), route TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, route, "setgroup", NULL, 366, this_ptr);
+ ZEPHIR_CALL_METHOD(NULL, route, "setgroup", NULL, 368, this_ptr);
zephir_check_call_status();
RETURN_CCTOR(route);
diff --git a/ext/phalcon/mvc/router/route.zep.c b/ext/phalcon/mvc/router/route.zep.c
index 0b5a2f4d56a..f468fe23aa7 100644
--- a/ext/phalcon/mvc/router/route.zep.c
+++ b/ext/phalcon/mvc/router/route.zep.c
@@ -226,7 +226,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Route, extractNamedParams) {
int tmp, cursor, cursorVar, marker, bracketCount = 0, parenthesesCount = 0, foundPattern = 0, intermediate = 0, numberMatches = 0;
char ch;
zval *pattern_param = NULL, *matches, _1 = zval_used_for_init, _2 = zval_used_for_init, *_3 = NULL, _18 = zval_used_for_init, _19 = zval_used_for_init, *_20 = NULL, _22 = zval_used_for_init, *_23 = NULL;
- zval *pattern = NULL, *route, *item = NULL, *variable = NULL, *regexp = NULL, *_4 = NULL, *_21 = NULL, *_24 = NULL;
+ zval *pattern = NULL, *route, *item = NULL, *variable = NULL, *regexp = NULL, *_4 = NULL, *_21 = NULL, *_24 = NULL, *_26 = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 0, &pattern_param);
@@ -386,9 +386,9 @@ PHP_METHOD(Phalcon_Mvc_Router_Route, extractNamedParams) {
}
}
if (foundPattern != 2) {
- zephir_concat_self_str(&route, "(", sizeof("(")-1 TSRMLS_CC);
- zephir_concat_self(&route, regexp TSRMLS_CC);
- zephir_concat_self_str(&route, ")", sizeof(")")-1 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_26);
+ ZEPHIR_CONCAT_SVS(_26, "(", regexp, ")");
+ zephir_concat_self(&route, _26 TSRMLS_CC);
} else {
zephir_concat_self(&route, regexp TSRMLS_CC);
}
@@ -402,9 +402,9 @@ PHP_METHOD(Phalcon_Mvc_Router_Route, extractNamedParams) {
zephir_array_update_zval(&matches, item, &_23, PH_COPY | PH_SEPARATE);
}
} else {
- zephir_concat_self_str(&route, "{", sizeof("{")-1 TSRMLS_CC);
- zephir_concat_self(&route, item TSRMLS_CC);
- zephir_concat_self_str(&route, "}", sizeof("}")-1 TSRMLS_CC);
+ ZEPHIR_INIT_LNVAR(_26);
+ ZEPHIR_CONCAT_SVS(_26, "{", item, "}");
+ zephir_concat_self(&route, _26 TSRMLS_CC);
}
continue;
}
@@ -468,13 +468,13 @@ PHP_METHOD(Phalcon_Mvc_Router_Route, reConfigure) {
ZEPHIR_CALL_SELF(&routePaths, "getroutepaths", NULL, 0, paths);
zephir_check_call_status();
if (!(zephir_start_with_str(pattern, SL("#")))) {
- if (zephir_memnstr_str(pattern, SL("{"), "phalcon/mvc/router/route.zep", 299)) {
+ if (zephir_memnstr_str(pattern, SL("{"), "phalcon/mvc/router/route.zep", 295)) {
ZEPHIR_CALL_METHOD(&extracted, this_ptr, "extractnamedparams", NULL, 0, pattern);
zephir_check_call_status();
ZEPHIR_OBS_VAR(pcrePattern);
- zephir_array_fetch_long(&pcrePattern, extracted, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 304 TSRMLS_CC);
+ zephir_array_fetch_long(&pcrePattern, extracted, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 300 TSRMLS_CC);
ZEPHIR_INIT_VAR(_0);
- zephir_array_fetch_long(&_1, extracted, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/router/route.zep", 305 TSRMLS_CC);
+ zephir_array_fetch_long(&_1, extracted, 1, PH_NOISY | PH_READONLY, "phalcon/mvc/router/route.zep", 301 TSRMLS_CC);
zephir_fast_array_merge(_0, &(routePaths), &(_1) TSRMLS_CC);
ZEPHIR_CPY_WRT(routePaths, _0);
} else {
@@ -522,23 +522,23 @@ PHP_METHOD(Phalcon_Mvc_Router_Route, getRoutePaths) {
_0 = zephir_fast_count_int(parts TSRMLS_CC);
if (_0 == 3) {
ZEPHIR_OBS_NVAR(moduleName);
- zephir_array_fetch_long(&moduleName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 357 TSRMLS_CC);
+ zephir_array_fetch_long(&moduleName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 353 TSRMLS_CC);
ZEPHIR_OBS_NVAR(controllerName);
- zephir_array_fetch_long(&controllerName, parts, 1, PH_NOISY, "phalcon/mvc/router/route.zep", 358 TSRMLS_CC);
+ zephir_array_fetch_long(&controllerName, parts, 1, PH_NOISY, "phalcon/mvc/router/route.zep", 354 TSRMLS_CC);
ZEPHIR_OBS_NVAR(actionName);
- zephir_array_fetch_long(&actionName, parts, 2, PH_NOISY, "phalcon/mvc/router/route.zep", 359 TSRMLS_CC);
+ zephir_array_fetch_long(&actionName, parts, 2, PH_NOISY, "phalcon/mvc/router/route.zep", 355 TSRMLS_CC);
break;
}
if (_0 == 2) {
ZEPHIR_OBS_NVAR(controllerName);
- zephir_array_fetch_long(&controllerName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 363 TSRMLS_CC);
+ zephir_array_fetch_long(&controllerName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 359 TSRMLS_CC);
ZEPHIR_OBS_NVAR(actionName);
- zephir_array_fetch_long(&actionName, parts, 1, PH_NOISY, "phalcon/mvc/router/route.zep", 364 TSRMLS_CC);
+ zephir_array_fetch_long(&actionName, parts, 1, PH_NOISY, "phalcon/mvc/router/route.zep", 360 TSRMLS_CC);
break;
}
if (_0 == 1) {
ZEPHIR_OBS_NVAR(controllerName);
- zephir_array_fetch_long(&controllerName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 368 TSRMLS_CC);
+ zephir_array_fetch_long(&controllerName, parts, 0, PH_NOISY, "phalcon/mvc/router/route.zep", 364 TSRMLS_CC);
break;
}
} while(0);
@@ -549,7 +549,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Route, getRoutePaths) {
zephir_array_update_string(&routePaths, SL("module"), &moduleName, PH_COPY | PH_SEPARATE);
}
if (Z_TYPE_P(controllerName) != IS_NULL) {
- if (zephir_memnstr_str(controllerName, SL("\\"), "phalcon/mvc/router/route.zep", 383)) {
+ if (zephir_memnstr_str(controllerName, SL("\\"), "phalcon/mvc/router/route.zep", 379)) {
ZEPHIR_INIT_VAR(realClassName);
zephir_get_class_ns(realClassName, controllerName, 0 TSRMLS_CC);
ZEPHIR_INIT_VAR(namespaceName);
@@ -575,7 +575,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Route, getRoutePaths) {
array_init(routePaths);
}
if (Z_TYPE_P(routePaths) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_router_exception_ce, "The route contains invalid paths", "phalcon/mvc/router/route.zep", 415);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_router_exception_ce, "The route contains invalid paths", "phalcon/mvc/router/route.zep", 411);
return;
}
RETURN_CCTOR(routePaths);
@@ -699,7 +699,7 @@ PHP_METHOD(Phalcon_Mvc_Router_Route, getReversedPaths) {
ZEPHIR_INIT_VAR(reversed);
array_init(reversed);
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_paths"), PH_NOISY_CC);
- zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/router/route.zep", 506);
+ zephir_is_iterable(_0, &_2, &_1, 0, 0, "phalcon/mvc/router/route.zep", 502);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
diff --git a/ext/phalcon/mvc/url.zep.c b/ext/phalcon/mvc/url.zep.c
index 583bf6d7ac1..fe1ff0a43eb 100644
--- a/ext/phalcon/mvc/url.zep.c
+++ b/ext/phalcon/mvc/url.zep.c
@@ -265,9 +265,11 @@ PHP_METHOD(Phalcon_Mvc_Url, getBasePath) {
*/
PHP_METHOD(Phalcon_Mvc_Url, get) {
+ unsigned char _10, _12;
int ZEPHIR_LAST_CALL_STATUS;
- zend_bool _0, _1;
- zval *uri = NULL, *args = NULL, *local = NULL, *baseUri = NULL, *router = NULL, *dependencyInjector = NULL, *routeName, *route = NULL, *queryString = NULL, *_2, *_3 = NULL, _4 = zval_used_for_init, *_5, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_9;
+ zend_bool _0, _1, _11;
+ zval *strUri = NULL, *_9 = NULL;
+ zval *uri = NULL, *args = NULL, *local = NULL, *baseUri = NULL, *router = NULL, *dependencyInjector = NULL, *routeName, *route = NULL, *queryString = NULL, *_2, *_3 = NULL, _4 = zval_used_for_init, *_5, *_6 = NULL, *_7 = NULL, *_8 = NULL, *_13;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 0, 4, &uri, &args, &local, &baseUri);
@@ -295,9 +297,9 @@ PHP_METHOD(Phalcon_Mvc_Url, get) {
if (Z_TYPE_P(local) == IS_NULL) {
_0 = Z_TYPE_P(uri) == IS_STRING;
if (_0) {
- _1 = zephir_memnstr_str(uri, SL("//"), "phalcon/mvc/url.zep", 178);
+ _1 = zephir_memnstr_str(uri, SL("//"), "phalcon/mvc/url.zep", 181);
if (!(_1)) {
- _1 = zephir_memnstr_str(uri, SL(":"), "phalcon/mvc/url.zep", 178);
+ _1 = zephir_memnstr_str(uri, SL(":"), "phalcon/mvc/url.zep", 181);
}
_0 = _1;
}
@@ -325,7 +327,7 @@ PHP_METHOD(Phalcon_Mvc_Url, get) {
if (Z_TYPE_P(uri) == IS_ARRAY) {
ZEPHIR_OBS_VAR(routeName);
if (!(zephir_array_isset_string_fetch(&routeName, uri, SS("for"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_url_exception_ce, "It's necessary to define the route name with the parameter 'for'", "phalcon/mvc/url.zep", 196);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_url_exception_ce, "It's necessary to define the route name with the parameter 'for'", "phalcon/mvc/url.zep", 199);
return;
}
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_router"), PH_NOISY_CC);
@@ -334,7 +336,7 @@ PHP_METHOD(Phalcon_Mvc_Url, get) {
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
ZEPHIR_CPY_WRT(dependencyInjector, _5);
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_url_exception_ce, "A dependency injector container is required to obtain the 'router' service", "phalcon/mvc/url.zep", 208);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_url_exception_ce, "A dependency injector container is required to obtain the 'router' service", "phalcon/mvc/url.zep", 211);
return;
}
ZEPHIR_INIT_NVAR(_3);
@@ -355,7 +357,7 @@ PHP_METHOD(Phalcon_Mvc_Url, get) {
ZEPHIR_CONCAT_SVS(_7, "Cannot obtain a route using the name '", routeName, "'");
ZEPHIR_CALL_METHOD(NULL, _3, "__construct", NULL, 9, _7);
zephir_check_call_status();
- zephir_throw_exception_debug(_3, "phalcon/mvc/url.zep", 220 TSRMLS_CC);
+ zephir_throw_exception_debug(_3, "phalcon/mvc/url.zep", 223 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -368,12 +370,35 @@ PHP_METHOD(Phalcon_Mvc_Url, get) {
ZEPHIR_CPY_WRT(uri, _3);
}
if (zephir_is_true(local)) {
- ZEPHIR_INIT_LNVAR(_7);
- ZEPHIR_CONCAT_VV(_7, baseUri, uri);
- ZEPHIR_CPY_WRT(uri, _7);
+ zephir_get_strval(_9, uri);
+ ZEPHIR_CPY_WRT(strUri, _9);
+ _0 = ZEPHIR_IS_STRING(baseUri, "/");
+ if (_0) {
+ _0 = zephir_fast_strlen_ev(strUri) > 2;
+ }
+ _1 = _0;
+ if (_1) {
+ _10 = ZEPHIR_STRING_OFFSET(strUri, 0);
+ _1 = _10 == '/';
+ }
+ _11 = _1;
+ if (_11) {
+ _12 = ZEPHIR_STRING_OFFSET(strUri, 1);
+ _11 = _12 != '/';
+ }
+ ZEPHIR_INIT_NVAR(uri);
+ if (_11) {
+ ZEPHIR_SINIT_NVAR(_4);
+ ZVAL_LONG(&_4, 1);
+ ZEPHIR_INIT_NVAR(_3);
+ zephir_substr(_3, strUri, 1 , 0, ZEPHIR_SUBSTR_NO_LENGTH);
+ ZEPHIR_CONCAT_VV(uri, baseUri, _3);
+ } else {
+ ZEPHIR_CONCAT_VV(uri, baseUri, strUri);
+ }
}
if (zephir_is_true(args)) {
- ZEPHIR_CALL_FUNCTION(&queryString, "http_build_query", NULL, 367, args);
+ ZEPHIR_CALL_FUNCTION(&queryString, "http_build_query", NULL, 369, args);
zephir_check_call_status();
_0 = Z_TYPE_P(queryString) == IS_STRING;
if (_0) {
@@ -389,9 +414,9 @@ PHP_METHOD(Phalcon_Mvc_Url, get) {
ZEPHIR_CONCAT_SV(_7, "&", queryString);
zephir_concat_self(&uri, _7 TSRMLS_CC);
} else {
- ZEPHIR_INIT_VAR(_9);
- ZEPHIR_CONCAT_SV(_9, "?", queryString);
- zephir_concat_self(&uri, _9 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_13);
+ ZEPHIR_CONCAT_SV(_13, "?", queryString);
+ zephir_concat_self(&uri, _13 TSRMLS_CC);
}
}
}
diff --git a/ext/phalcon/mvc/view.zep.c b/ext/phalcon/mvc/view.zep.c
index 433267f608b..ccfaf7524d6 100644
--- a/ext/phalcon/mvc/view.zep.c
+++ b/ext/phalcon/mvc/view.zep.c
@@ -79,6 +79,9 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_View) {
zend_declare_property_bool(phalcon_mvc_view_ce, SL("_engines"), 0, ZEND_ACC_PROTECTED TSRMLS_CC);
+ /**
+ * @var array
+ */
zend_declare_property_null(phalcon_mvc_view_ce, SL("_registeredEngines"), ZEND_ACC_PROTECTED TSRMLS_CC);
zend_declare_property_string(phalcon_mvc_view_ce, SL("_mainView"), "index", ZEND_ACC_PROTECTED TSRMLS_CC);
@@ -112,7 +115,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_View) {
zend_declare_class_constant_long(phalcon_mvc_view_ce, SL("LEVEL_AFTER_TEMPLATE"), 4 TSRMLS_CC);
/**
- * Render Level: Hasta el layout del controlador
+ * Render Level: To the controller layout
*
*/
zend_declare_class_constant_long(phalcon_mvc_view_ce, SL("LEVEL_LAYOUT"), 3 TSRMLS_CC);
@@ -136,7 +139,6 @@ ZEPHIR_INIT_CLASS(Phalcon_Mvc_View) {
/**
* Cache Mode
- *
*/
zend_declare_class_constant_long(phalcon_mvc_view_ce, SL("CACHE_MODE_NONE"), 0 TSRMLS_CC);
@@ -161,6 +163,9 @@ PHP_METHOD(Phalcon_Mvc_View, getCurrentRenderLevel) {
}
+/**
+ * @var array
+ */
PHP_METHOD(Phalcon_Mvc_View, getRegisteredEngines) {
@@ -332,7 +337,7 @@ PHP_METHOD(Phalcon_Mvc_View, getBasePath) {
*
*
* //Render the view related to the controller only
- * $this->view->setRenderLevel(View::LEVEL_VIEW);
+ * $this->view->setRenderLevel(View::LEVEL_LAYOUT);
*
*/
PHP_METHOD(Phalcon_Mvc_View, setRenderLevel) {
@@ -769,19 +774,19 @@ PHP_METHOD(Phalcon_Mvc_View, _loadTemplateEngines) {
if (Z_TYPE_P(registeredEngines) != IS_ARRAY) {
ZEPHIR_INIT_VAR(_1);
object_init_ex(_1, phalcon_mvc_view_engine_php_ce);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 368, this_ptr, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 370, this_ptr, dependencyInjector);
zephir_check_call_status();
zephir_array_update_string(&engines, SL(".phtml"), &_1, PH_COPY | PH_SEPARATE);
} else {
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "A dependency injector container is required to obtain the application services", "phalcon/mvc/view.zep", 524);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "A dependency injector container is required to obtain the application services", "phalcon/mvc/view.zep", 526);
return;
}
ZEPHIR_INIT_VAR(arguments);
zephir_create_array(arguments, 2, 0 TSRMLS_CC);
zephir_array_fast_append(arguments, this_ptr);
zephir_array_fast_append(arguments, dependencyInjector);
- zephir_is_iterable(registeredEngines, &_3, &_2, 0, 0, "phalcon/mvc/view.zep", 553);
+ zephir_is_iterable(registeredEngines, &_3, &_2, 0, 0, "phalcon/mvc/view.zep", 555);
for (
; zephir_hash_get_current_data_ex(_3, (void**) &_4, &_2) == SUCCESS
; zephir_hash_move_forward_ex(_3, &_2)
@@ -805,7 +810,7 @@ PHP_METHOD(Phalcon_Mvc_View, _loadTemplateEngines) {
ZEPHIR_CONCAT_SV(_6, "Invalid template engine registration for extension: ", extension);
ZEPHIR_CALL_METHOD(NULL, _5, "__construct", &_7, 9, _6);
zephir_check_call_status();
- zephir_throw_exception_debug(_5, "phalcon/mvc/view.zep", 547 TSRMLS_CC);
+ zephir_throw_exception_debug(_5, "phalcon/mvc/view.zep", 549 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -908,7 +913,7 @@ PHP_METHOD(Phalcon_Mvc_View, _engineRender) {
zephir_read_property_this(&viewParams, this_ptr, SL("_viewParams"), PH_NOISY_CC);
_4 = zephir_fetch_nproperty_this(this_ptr, SL("_eventsManager"), PH_NOISY_CC);
ZEPHIR_CPY_WRT(eventsManager, _4);
- zephir_is_iterable(engines, &_6, &_5, 0, 0, "phalcon/mvc/view.zep", 671);
+ zephir_is_iterable(engines, &_6, &_5, 0, 0, "phalcon/mvc/view.zep", 673);
for (
; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS
; zephir_hash_move_forward_ex(_6, &_5)
@@ -958,7 +963,7 @@ PHP_METHOD(Phalcon_Mvc_View, _engineRender) {
ZEPHIR_CONCAT_SVS(_11, "View '", viewsDirPath, "' was not found in the views directory");
ZEPHIR_CALL_METHOD(NULL, _8, "__construct", NULL, 9, _11);
zephir_check_call_status();
- zephir_throw_exception_debug(_8, "phalcon/mvc/view.zep", 682 TSRMLS_CC);
+ zephir_throw_exception_debug(_8, "phalcon/mvc/view.zep", 684 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -1037,7 +1042,7 @@ PHP_METHOD(Phalcon_Mvc_View, exists) {
}
exists = 0;
ZEPHIR_INIT_NVAR(_0);
- zephir_is_iterable(engines, &_2, &_1, 0, 0, "phalcon/mvc/view.zep", 730);
+ zephir_is_iterable(engines, &_2, &_1, 0, 0, "phalcon/mvc/view.zep", 732);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -1143,7 +1148,7 @@ PHP_METHOD(Phalcon_Mvc_View, render) {
ZEPHIR_CPY_WRT(renderView, _3);
} else {
ZEPHIR_OBS_NVAR(renderView);
- zephir_array_fetch_long(&renderView, pickView, 0, PH_NOISY, "phalcon/mvc/view.zep", 803 TSRMLS_CC);
+ zephir_array_fetch_long(&renderView, pickView, 0, PH_NOISY, "phalcon/mvc/view.zep", 805 TSRMLS_CC);
ZEPHIR_OBS_VAR(pickViewAction);
if (zephir_array_isset_long_fetch(&pickViewAction, pickView, 1, 0 TSRMLS_CC)) {
ZEPHIR_CPY_WRT(layoutName, pickViewAction);
@@ -1201,7 +1206,7 @@ PHP_METHOD(Phalcon_Mvc_View, render) {
zephir_read_property_this(&templatesBefore, this_ptr, SL("_templatesBefore"), PH_NOISY_CC);
if (Z_TYPE_P(templatesBefore) == IS_ARRAY) {
silence = 0;
- zephir_is_iterable(templatesBefore, &_11, &_10, 0, 0, "phalcon/mvc/view.zep", 879);
+ zephir_is_iterable(templatesBefore, &_11, &_10, 0, 0, "phalcon/mvc/view.zep", 881);
for (
; zephir_hash_get_current_data_ex(_11, (void**) &_12, &_10) == SUCCESS
; zephir_hash_move_forward_ex(_11, &_10)
@@ -1236,7 +1241,7 @@ PHP_METHOD(Phalcon_Mvc_View, render) {
zephir_read_property_this(&templatesAfter, this_ptr, SL("_templatesAfter"), PH_NOISY_CC);
if (Z_TYPE_P(templatesAfter) == IS_ARRAY) {
silence = 0;
- zephir_is_iterable(templatesAfter, &_15, &_14, 0, 0, "phalcon/mvc/view.zep", 910);
+ zephir_is_iterable(templatesAfter, &_15, &_14, 0, 0, "phalcon/mvc/view.zep", 912);
for (
; zephir_hash_get_current_data_ex(_15, (void**) &_16, &_14) == SUCCESS
; zephir_hash_move_forward_ex(_15, &_14)
@@ -1329,17 +1334,17 @@ PHP_METHOD(Phalcon_Mvc_View, pick) {
} else {
ZEPHIR_INIT_VAR(layout);
ZVAL_NULL(layout);
- if (zephir_memnstr_str(renderView, SL("/"), "phalcon/mvc/view.zep", 983)) {
+ if (zephir_memnstr_str(renderView, SL("/"), "phalcon/mvc/view.zep", 985)) {
ZEPHIR_INIT_VAR(parts);
zephir_fast_explode_str(parts, SL("/"), renderView, LONG_MAX TSRMLS_CC);
ZEPHIR_OBS_NVAR(layout);
- zephir_array_fetch_long(&layout, parts, 0, PH_NOISY, "phalcon/mvc/view.zep", 984 TSRMLS_CC);
+ zephir_array_fetch_long(&layout, parts, 0, PH_NOISY, "phalcon/mvc/view.zep", 986 TSRMLS_CC);
}
ZEPHIR_INIT_NVAR(pickView);
zephir_create_array(pickView, 1, 0 TSRMLS_CC);
zephir_array_fast_append(pickView, renderView);
if (Z_TYPE_P(layout) != IS_NULL) {
- zephir_array_append(&pickView, layout, PH_SEPARATE, "phalcon/mvc/view.zep", 989);
+ zephir_array_append(&pickView, layout, PH_SEPARATE, "phalcon/mvc/view.zep", 991);
}
}
zephir_update_property_this(this_ptr, SL("_pickView"), pickView TSRMLS_CC);
@@ -1393,7 +1398,7 @@ PHP_METHOD(Phalcon_Mvc_View, getPartial) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, this_ptr, "partial", NULL, 0, partialPath, params);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", NULL, 290);
+ ZEPHIR_RETURN_CALL_FUNCTION("ob_get_clean", NULL, 291);
zephir_check_call_status();
RETURN_MM();
@@ -1583,7 +1588,7 @@ PHP_METHOD(Phalcon_Mvc_View, _createCache) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
ZEPHIR_CPY_WRT(dependencyInjector, _0);
if (Z_TYPE_P(dependencyInjector) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "A dependency injector container is required to obtain the view cache services", "phalcon/mvc/view.zep", 1163);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "A dependency injector container is required to obtain the view cache services", "phalcon/mvc/view.zep", 1165);
return;
}
ZEPHIR_INIT_VAR(cacheService);
@@ -1595,7 +1600,7 @@ PHP_METHOD(Phalcon_Mvc_View, _createCache) {
if (zephir_array_isset_string_fetch(&cacheOptions, viewOptions, SS("cache"), 0 TSRMLS_CC)) {
if (zephir_array_isset_string(cacheOptions, SS("service"))) {
ZEPHIR_OBS_NVAR(cacheService);
- zephir_array_fetch_string(&cacheService, cacheOptions, SL("service"), PH_NOISY, "phalcon/mvc/view.zep", 1172 TSRMLS_CC);
+ zephir_array_fetch_string(&cacheService, cacheOptions, SL("service"), PH_NOISY, "phalcon/mvc/view.zep", 1174 TSRMLS_CC);
}
}
}
@@ -1603,7 +1608,7 @@ PHP_METHOD(Phalcon_Mvc_View, _createCache) {
zephir_check_call_status();
ZEPHIR_CPY_WRT(viewCache, _1);
if (Z_TYPE_P(viewCache) != IS_OBJECT) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "The injected caching service is invalid", "phalcon/mvc/view.zep", 1182);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "The injected caching service is invalid", "phalcon/mvc/view.zep", 1184);
return;
}
RETURN_CCTOR(viewCache);
@@ -1687,7 +1692,7 @@ PHP_METHOD(Phalcon_Mvc_View, cache) {
ZEPHIR_INIT_NVAR(cacheOptions);
array_init(cacheOptions);
}
- zephir_is_iterable(options, &_1, &_0, 0, 0, "phalcon/mvc/view.zep", 1250);
+ zephir_is_iterable(options, &_1, &_0, 0, 0, "phalcon/mvc/view.zep", 1252);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
diff --git a/ext/phalcon/mvc/view/engine/php.zep.c b/ext/phalcon/mvc/view/engine/php.zep.c
index 49f445e7999..76c29eeae33 100644
--- a/ext/phalcon/mvc/view/engine/php.zep.c
+++ b/ext/phalcon/mvc/view/engine/php.zep.c
@@ -70,7 +70,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Php, render) {
if (mustClean == 1) {
- ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 369);
+ ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 371);
zephir_check_call_status();
}
if (Z_TYPE_P(params) == IS_ARRAY) {
diff --git a/ext/phalcon/mvc/view/engine/volt.zep.c b/ext/phalcon/mvc/view/engine/volt.zep.c
index 5bf895cfb61..1c698719a4c 100644
--- a/ext/phalcon/mvc/view/engine/volt.zep.c
+++ b/ext/phalcon/mvc/view/engine/volt.zep.c
@@ -89,18 +89,18 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, getCompiler) {
ZEPHIR_INIT_NVAR(compiler);
object_init_ex(compiler, phalcon_mvc_view_engine_volt_compiler_ce);
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_view"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, compiler, "__construct", NULL, 370, _0);
+ ZEPHIR_CALL_METHOD(NULL, compiler, "__construct", NULL, 372, _0);
zephir_check_call_status();
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_dependencyInjector"), PH_NOISY_CC);
ZEPHIR_CPY_WRT(dependencyInjector, _1);
if (Z_TYPE_P(dependencyInjector) == IS_OBJECT) {
- ZEPHIR_CALL_METHOD(NULL, compiler, "setdi", NULL, 371, dependencyInjector);
+ ZEPHIR_CALL_METHOD(NULL, compiler, "setdi", NULL, 373, dependencyInjector);
zephir_check_call_status();
}
ZEPHIR_OBS_VAR(options);
zephir_read_property_this(&options, this_ptr, SL("_options"), PH_NOISY_CC);
if (Z_TYPE_P(options) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(NULL, compiler, "setoptions", NULL, 372, options);
+ ZEPHIR_CALL_METHOD(NULL, compiler, "setoptions", NULL, 374, options);
zephir_check_call_status();
}
zephir_update_property_this(this_ptr, SL("_compiler"), compiler TSRMLS_CC);
@@ -143,7 +143,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, render) {
if (mustClean) {
- ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 369);
+ ZEPHIR_CALL_FUNCTION(NULL, "ob_clean", NULL, 371);
zephir_check_call_status();
}
ZEPHIR_CALL_METHOD(&compiler, this_ptr, "getcompiler", NULL, 0);
@@ -186,6 +186,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, render) {
PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, length) {
int ZEPHIR_LAST_CALL_STATUS;
+ zend_bool _0;
zval *item, *length = NULL;
ZEPHIR_MM_GROW();
@@ -195,21 +196,20 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, length) {
ZEPHIR_INIT_VAR(length);
ZVAL_LONG(length, 0);
- if (Z_TYPE_P(item) == IS_OBJECT) {
+ _0 = Z_TYPE_P(item) == IS_OBJECT;
+ if (!(_0)) {
+ _0 = Z_TYPE_P(item) == IS_ARRAY;
+ }
+ if (_0) {
ZEPHIR_INIT_NVAR(length);
ZVAL_LONG(length, zephir_fast_count_int(item TSRMLS_CC));
} else {
- if (Z_TYPE_P(item) == IS_ARRAY) {
- ZEPHIR_INIT_NVAR(length);
- ZVAL_LONG(length, zephir_fast_count_int(item TSRMLS_CC));
+ if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) {
+ ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, item);
+ zephir_check_call_status();
} else {
- if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 364, item);
- zephir_check_call_status();
- } else {
- ZEPHIR_INIT_NVAR(length);
- ZVAL_LONG(length, zephir_fast_strlen_ev(item));
- }
+ ZEPHIR_INIT_NVAR(length);
+ ZVAL_LONG(length, zephir_fast_strlen_ev(item));
}
}
RETURN_CCTOR(length);
@@ -234,7 +234,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, isIncluded) {
}
if (Z_TYPE_P(haystack) == IS_STRING) {
if ((zephir_function_exists_ex(SS("mb_strpos") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_CALL_FUNCTION(&_0, "mb_strpos", NULL, 373, haystack, needle);
+ ZEPHIR_CALL_FUNCTION(&_0, "mb_strpos", NULL, 375, haystack, needle);
zephir_check_call_status();
RETURN_MM_BOOL(!ZEPHIR_IS_FALSE_IDENTICAL(_0));
}
@@ -242,7 +242,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, isIncluded) {
zephir_fast_strpos(_1, haystack, needle, 0 );
RETURN_MM_BOOL(!ZEPHIR_IS_FALSE_IDENTICAL(_1));
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Invalid haystack", "phalcon/mvc/view/engine/volt.zep", 170);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Invalid haystack", "phalcon/mvc/view/engine/volt.zep", 166);
return;
}
@@ -290,7 +290,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, convertEncoding) {
_0 = ZEPHIR_IS_STRING(to, "utf8");
}
if (_0) {
- ZEPHIR_RETURN_CALL_FUNCTION("utf8_encode", NULL, 374, text);
+ ZEPHIR_RETURN_CALL_FUNCTION("utf8_encode", NULL, 376, text);
zephir_check_call_status();
RETURN_MM();
}
@@ -299,21 +299,21 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, convertEncoding) {
_1 = ZEPHIR_IS_STRING(from, "utf8");
}
if (_1) {
- ZEPHIR_RETURN_CALL_FUNCTION("utf8_decode", NULL, 375, text);
+ ZEPHIR_RETURN_CALL_FUNCTION("utf8_decode", NULL, 377, text);
zephir_check_call_status();
RETURN_MM();
}
if ((zephir_function_exists_ex(SS("mb_convert_encoding") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 179, text, from, to);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_convert_encoding", NULL, 180, text, from, to);
zephir_check_call_status();
RETURN_MM();
}
if ((zephir_function_exists_ex(SS("iconv") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("iconv", NULL, 376, from, to, text);
+ ZEPHIR_RETURN_CALL_FUNCTION("iconv", NULL, 378, from, to, text);
zephir_check_call_status();
RETURN_MM();
}
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Any of 'mbstring' or 'iconv' is required to perform the charset conversion", "phalcon/mvc/view/engine/volt.zep", 209);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Any of 'mbstring' or 'iconv' is required to perform the charset conversion", "phalcon/mvc/view/engine/volt.zep", 205);
return;
}
@@ -366,7 +366,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) {
if (_1) {
ZEPHIR_CALL_METHOD(&_2, value, "current", &_3, 0);
zephir_check_call_status();
- zephir_array_append(&slice, _2, PH_SEPARATE, "phalcon/mvc/view/engine/volt.zep", 235);
+ zephir_array_append(&slice, _2, PH_SEPARATE, "phalcon/mvc/view/engine/volt.zep", 231);
}
ZEPHIR_CALL_METHOD(NULL, value, "next", &_4, 0);
zephir_check_call_status();
@@ -383,7 +383,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) {
if (Z_TYPE_P(value) == IS_ARRAY) {
ZEPHIR_SINIT_VAR(_5);
ZVAL_LONG(&_5, start);
- ZEPHIR_RETURN_CALL_FUNCTION("array_slice", NULL, 377, value, &_5, length);
+ ZEPHIR_RETURN_CALL_FUNCTION("array_slice", NULL, 379, value, &_5, length);
zephir_check_call_status();
RETURN_MM();
}
@@ -391,13 +391,13 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, slice) {
if (Z_TYPE_P(length) != IS_NULL) {
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, start);
- ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 378, value, &_5, length);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 380, value, &_5, length);
zephir_check_call_status();
RETURN_MM();
}
ZEPHIR_SINIT_NVAR(_5);
ZVAL_LONG(&_5, start);
- ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 378, value, &_5);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_substr", &_6, 380, value, &_5);
zephir_check_call_status();
RETURN_MM();
}
@@ -430,7 +430,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, sort) {
Z_SET_ISREF_P(value);
- ZEPHIR_CALL_FUNCTION(NULL, "asort", NULL, 379, value);
+ ZEPHIR_CALL_FUNCTION(NULL, "asort", NULL, 381, value);
Z_UNSET_ISREF_P(value);
zephir_check_call_status();
RETURN_CTOR(value);
@@ -473,11 +473,11 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt, callMacro) {
ZEPHIR_CONCAT_SVS(_2, "Macro '", name, "' does not exist");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt.zep", 297 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt.zep", 293 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_RETURN_CALL_FUNCTION("call_user_func", NULL, 380, macro, arguments);
+ ZEPHIR_RETURN_CALL_FUNCTION("call_user_func", NULL, 382, macro, arguments);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/mvc/view/engine/volt/compiler.zep.c b/ext/phalcon/mvc/view/engine/volt/compiler.zep.c
index c72d05807b8..869c971f7f4 100644
--- a/ext/phalcon/mvc/view/engine/volt/compiler.zep.c
+++ b/ext/phalcon/mvc/view/engine/volt/compiler.zep.c
@@ -545,7 +545,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) {
}
}
} else {
- ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_4, 381, left);
+ ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_4, 383, left);
zephir_check_call_status();
ZEPHIR_OBS_VAR(leftType);
zephir_array_fetch_string(&leftType, left, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 339 TSRMLS_CC);
@@ -567,7 +567,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, attributeReader) {
zephir_array_fetch_string(&_7, right, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 352 TSRMLS_CC);
zephir_concat_self(&exprCode, _7 TSRMLS_CC);
} else {
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_4, 381, right);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_4, 383, right);
zephir_check_call_status();
zephir_concat_self(&exprCode, _1 TSRMLS_CC);
}
@@ -599,7 +599,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
ZVAL_NULL(funcArguments);
ZEPHIR_OBS_NVAR(funcArguments);
if (zephir_array_isset_string_fetch(&funcArguments, expr, SS("arguments"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", &_0, 381, funcArguments);
+ ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", &_0, 383, funcArguments);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(arguments);
@@ -622,7 +622,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
zephir_array_fast_append(_1, funcArguments);
ZEPHIR_INIT_VAR(_2);
ZVAL_STRING(_2, "compileFunction", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 382, _2, _1);
+ ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 384, _2, _1);
zephir_check_temp_parameter(_2);
zephir_check_call_status();
if (Z_TYPE_P(code) == IS_STRING) {
@@ -689,7 +689,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
ZEPHIR_OBS_VAR(exprLevel);
zephir_read_property_this(&exprLevel, this_ptr, SL("_exprLevel"), PH_NOISY_CC);
if (Z_TYPE_P(block) == IS_ARRAY) {
- ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlistorextends", NULL, 383, block);
+ ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlistorextends", NULL, 385, block);
zephir_check_call_status();
if (ZEPHIR_IS_LONG(exprLevel, 1)) {
ZEPHIR_CPY_WRT(escapedCode, code);
@@ -725,7 +725,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
zephir_read_property_this(&arrayHelpers, this_ptr, SL("_arrayHelpers"), PH_NOISY_CC);
if (Z_TYPE_P(arrayHelpers) != IS_ARRAY) {
ZEPHIR_INIT_NVAR(arrayHelpers);
- zephir_create_array(arrayHelpers, 17, 0 TSRMLS_CC);
+ zephir_create_array(arrayHelpers, 18, 0 TSRMLS_CC);
zephir_array_update_string(&arrayHelpers, SL("link_to"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("image"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("form"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
@@ -741,6 +741,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
zephir_array_update_string(&arrayHelpers, SL("text_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("email_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("date_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
+ zephir_array_update_string(&arrayHelpers, SL("tel_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("numeric_field"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_array_update_string(&arrayHelpers, SL("image_input"), &ZEPHIR_GLOBAL(global_true), PH_COPY | PH_SEPARATE);
zephir_update_property_this(this_ptr, SL("_arrayHelpers"), arrayHelpers TSRMLS_CC);
@@ -783,17 +784,17 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, functionCall) {
}
ZEPHIR_INIT_NVAR(_2);
object_init_ex(_2, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_3, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 572 TSRMLS_CC);
- zephir_array_fetch_string(&_4, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 572 TSRMLS_CC);
+ zephir_array_fetch_string(&_3, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVSVSV(_5, "Undefined function '", name, "' in ", _3, " on line ", _4);
ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 9, _5);
zephir_check_call_status();
- zephir_throw_exception_debug(_2, "phalcon/mvc/view/engine/volt/compiler.zep", 572 TSRMLS_CC);
+ zephir_throw_exception_debug(_2, "phalcon/mvc/view/engine/volt/compiler.zep", 573 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_CALL_METHOD(&_8, this_ptr, "expression", &_0, 381, nameExpr);
+ ZEPHIR_CALL_METHOD(&_8, this_ptr, "expression", &_0, 383, nameExpr);
zephir_check_call_status();
ZEPHIR_CONCAT_VSVS(return_value, _8, "(", arguments, ")");
RETURN_MM();
@@ -820,10 +821,10 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveTest) {
ZEPHIR_OBS_VAR(type);
- zephir_array_fetch_string(&type, test, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 585 TSRMLS_CC);
+ zephir_array_fetch_string(&type, test, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 586 TSRMLS_CC);
if (ZEPHIR_IS_LONG(type, 265)) {
ZEPHIR_OBS_VAR(name);
- zephir_array_fetch_string(&name, test, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 592 TSRMLS_CC);
+ zephir_array_fetch_string(&name, test, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 593 TSRMLS_CC);
if (ZEPHIR_IS_STRING(name, "empty")) {
ZEPHIR_CONCAT_SVS(return_value, "empty(", left, ")");
RETURN_MM();
@@ -851,33 +852,33 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveTest) {
}
if (ZEPHIR_IS_LONG(type, 350)) {
ZEPHIR_OBS_VAR(testName);
- zephir_array_fetch_string(&testName, test, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 643 TSRMLS_CC);
+ zephir_array_fetch_string(&testName, test, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 644 TSRMLS_CC);
ZEPHIR_OBS_NVAR(name);
if (zephir_array_isset_string_fetch(&name, testName, SS("value"), 0 TSRMLS_CC)) {
if (ZEPHIR_IS_STRING(name, "divisibleby")) {
- zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 647 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 381, _1);
+ zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 648 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "(((", left, ") % (", _0, ")) == 0)");
RETURN_MM();
}
if (ZEPHIR_IS_STRING(name, "sameas")) {
- zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 654 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 381, _1);
+ zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 655 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "(", left, ") === (", _0, ")");
RETURN_MM();
}
if (ZEPHIR_IS_STRING(name, "type")) {
- zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 661 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 381, _1);
+ zephir_array_fetch_string(&_1, test, SL("arguments"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 662 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, _1);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "gettype(", left, ") === (", _0, ")");
RETURN_MM();
}
}
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 381, test);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", &_2, 383, test);
zephir_check_call_status();
ZEPHIR_CONCAT_VSV(return_value, left, " == ", _0);
RETURN_MM();
@@ -906,28 +907,28 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
ZEPHIR_INIT_VAR(code);
ZVAL_NULL(code);
ZEPHIR_OBS_VAR(type);
- zephir_array_fetch_string(&type, filter, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 680 TSRMLS_CC);
+ zephir_array_fetch_string(&type, filter, SL("type"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 681 TSRMLS_CC);
if (ZEPHIR_IS_LONG(type, 265)) {
ZEPHIR_OBS_VAR(name);
- zephir_array_fetch_string(&name, filter, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 686 TSRMLS_CC);
+ zephir_array_fetch_string(&name, filter, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 687 TSRMLS_CC);
} else {
if (!ZEPHIR_IS_LONG(type, 350)) {
ZEPHIR_INIT_VAR(_0);
object_init_ex(_0, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 694 TSRMLS_CC);
- zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 694 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC);
ZEPHIR_INIT_VAR(_3);
ZEPHIR_CONCAT_SVSV(_3, "Unknown filter type in ", _1, " on line ", _2);
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 694 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 695 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
ZEPHIR_OBS_VAR(functionName);
- zephir_array_fetch_string(&functionName, filter, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 697 TSRMLS_CC);
+ zephir_array_fetch_string(&functionName, filter, SL("name"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 698 TSRMLS_CC);
ZEPHIR_OBS_NVAR(name);
- zephir_array_fetch_string(&name, functionName, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 698 TSRMLS_CC);
+ zephir_array_fetch_string(&name, functionName, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 699 TSRMLS_CC);
}
ZEPHIR_INIT_VAR(funcArguments);
ZVAL_NULL(funcArguments);
@@ -937,9 +938,9 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
if (zephir_array_isset_string_fetch(&funcArguments, filter, SS("arguments"), 0 TSRMLS_CC)) {
if (!ZEPHIR_IS_STRING(name, "default")) {
ZEPHIR_OBS_VAR(file);
- zephir_array_fetch_string(&file, filter, SL("file"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 713 TSRMLS_CC);
+ zephir_array_fetch_string(&file, filter, SL("file"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 714 TSRMLS_CC);
ZEPHIR_OBS_VAR(line);
- zephir_array_fetch_string(&line, filter, SL("line"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 713 TSRMLS_CC);
+ zephir_array_fetch_string(&line, filter, SL("line"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 714 TSRMLS_CC);
ZEPHIR_INIT_VAR(_4);
zephir_create_array(_4, 3, 0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_5);
@@ -952,11 +953,11 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
zephir_array_update_string(&_4, SL("file"), &file, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("line"), &line, PH_COPY | PH_SEPARATE);
Z_SET_ISREF_P(funcArguments);
- ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 384, funcArguments, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 386, funcArguments, _4);
Z_UNSET_ISREF_P(funcArguments);
zephir_check_call_status();
}
- ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", NULL, 381, funcArguments);
+ ZEPHIR_CALL_METHOD(&arguments, this_ptr, "expression", NULL, 383, funcArguments);
zephir_check_call_status();
} else {
ZEPHIR_CPY_WRT(arguments, left);
@@ -971,7 +972,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
zephir_array_fast_append(_4, funcArguments);
ZEPHIR_INIT_NVAR(_0);
ZVAL_STRING(_0, "compileFilter", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 382, _0, _4);
+ ZEPHIR_CALL_METHOD(&code, this_ptr, "fireextensionevent", NULL, 384, _0, _4);
zephir_check_temp_parameter(_0);
zephir_check_call_status();
if (Z_TYPE_P(code) == IS_STRING) {
@@ -1000,13 +1001,13 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
}
ZEPHIR_INIT_NVAR(_0);
object_init_ex(_0, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 776 TSRMLS_CC);
- zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 776 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_3);
ZEPHIR_CONCAT_SVSVSV(_3, "Invalid definition for user filter '", name, "' in ", _1, " on line ", _2);
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 776 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 777 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -1129,13 +1130,13 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, resolveFilter) {
}
ZEPHIR_INIT_NVAR(_0);
object_init_ex(_0, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 965 TSRMLS_CC);
- zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 965 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, filter, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, filter, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_3);
ZEPHIR_CONCAT_SVSVSV(_3, "Unknown filter \"", name, "\" in ", _1, " on line ", _2);
ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 9, _3);
zephir_check_call_status();
- zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 965 TSRMLS_CC);
+ zephir_throw_exception_debug(_0, "phalcon/mvc/view/engine/volt/compiler.zep", 966 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
@@ -1172,7 +1173,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
zephir_array_fast_append(_0, expr);
ZEPHIR_INIT_NVAR(_1);
ZVAL_STRING(_1, "resolveExpression", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "fireextensionevent", &_2, 382, _1, _0);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "fireextensionevent", &_2, 384, _1, _0);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
if (Z_TYPE_P(exprCode) == IS_STRING) {
@@ -1183,22 +1184,22 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
if (!(zephir_array_isset_string_fetch(&type, expr, SS("type"), 0 TSRMLS_CC))) {
ZEPHIR_INIT_NVAR(items);
array_init(items);
- zephir_is_iterable(expr, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1006);
+ zephir_is_iterable(expr, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1007);
for (
; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS
; zephir_hash_move_forward_ex(_4, &_3)
) {
ZEPHIR_GET_HVALUE(singleExpr, _5);
- zephir_array_fetch_string(&_6, singleExpr, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 999 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&singleExprCode, this_ptr, "expression", &_7, 381, _6);
+ zephir_array_fetch_string(&_6, singleExpr, SL("expr"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1000 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&singleExprCode, this_ptr, "expression", &_7, 383, _6);
zephir_check_call_status();
ZEPHIR_OBS_NVAR(name);
if (zephir_array_isset_string_fetch(&name, singleExpr, SS("name"), 0 TSRMLS_CC)) {
ZEPHIR_INIT_LNVAR(_8);
ZEPHIR_CONCAT_SVSV(_8, "'", name, "' => ", singleExprCode);
- zephir_array_append(&items, _8, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1001);
+ zephir_array_append(&items, _8, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1002);
} else {
- zephir_array_append(&items, singleExprCode, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1003);
+ zephir_array_append(&items, singleExprCode, PH_SEPARATE, "phalcon/mvc/view/engine/volt/compiler.zep", 1004);
}
}
ZEPHIR_INIT_NVAR(exprCode);
@@ -1212,24 +1213,24 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
}
ZEPHIR_OBS_NVAR(left);
if (zephir_array_isset_string_fetch(&left, expr, SS("left"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_7, 381, left);
+ ZEPHIR_CALL_METHOD(&leftCode, this_ptr, "expression", &_7, 383, left);
zephir_check_call_status();
}
if (ZEPHIR_IS_LONG(type, 311)) {
- zephir_array_fetch_string(&_6, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1029 TSRMLS_CC);
+ zephir_array_fetch_string(&_6, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1030 TSRMLS_CC);
ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvetest", &_10, 0, _6, leftCode);
zephir_check_call_status();
break;
}
if (ZEPHIR_IS_LONG(type, 124)) {
- zephir_array_fetch_string(&_11, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1037 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvefilter", &_12, 385, _11, leftCode);
+ zephir_array_fetch_string(&_11, expr, SL("right"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1038 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "resolvefilter", &_12, 387, _11, leftCode);
zephir_check_call_status();
break;
}
ZEPHIR_OBS_NVAR(right);
if (zephir_array_isset_string_fetch(&right, expr, SS("right"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&rightCode, this_ptr, "expression", &_7, 381, right);
+ ZEPHIR_CALL_METHOD(&rightCode, this_ptr, "expression", &_7, 383, right);
zephir_check_call_status();
}
ZEPHIR_INIT_NVAR(exprCode);
@@ -1301,17 +1302,17 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
}
if (ZEPHIR_IS_LONG(type, 258)) {
ZEPHIR_OBS_NVAR(exprCode);
- zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1104 TSRMLS_CC);
+ zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1105 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(type, 259)) {
ZEPHIR_OBS_NVAR(exprCode);
- zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1108 TSRMLS_CC);
+ zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1109 TSRMLS_CC);
break;
}
if (ZEPHIR_IS_LONG(type, 260)) {
ZEPHIR_INIT_NVAR(_1);
- zephir_array_fetch_string(&_6, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1112 TSRMLS_CC);
+ zephir_array_fetch_string(&_6, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1113 TSRMLS_CC);
ZEPHIR_SINIT_NVAR(_13);
ZVAL_STRING(&_13, "'", 0);
ZEPHIR_SINIT_NVAR(_14);
@@ -1337,7 +1338,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
break;
}
if (ZEPHIR_IS_LONG(type, 265)) {
- zephir_array_fetch_string(&_11, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1128 TSRMLS_CC);
+ zephir_array_fetch_string(&_11, expr, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1129 TSRMLS_CC);
ZEPHIR_INIT_NVAR(exprCode);
ZEPHIR_CONCAT_SV(exprCode, "$", _11);
break;
@@ -1405,7 +1406,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
if (ZEPHIR_IS_LONG(type, 365)) {
ZEPHIR_OBS_NVAR(start);
if (zephir_array_isset_string_fetch(&start, expr, SS("start"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&startCode, this_ptr, "expression", &_7, 381, start);
+ ZEPHIR_CALL_METHOD(&startCode, this_ptr, "expression", &_7, 383, start);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(startCode);
@@ -1413,7 +1414,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
}
ZEPHIR_OBS_NVAR(end);
if (zephir_array_isset_string_fetch(&end, expr, SS("end"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&endCode, this_ptr, "expression", &_7, 381, end);
+ ZEPHIR_CALL_METHOD(&endCode, this_ptr, "expression", &_7, 383, end);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(endCode);
@@ -1504,8 +1505,8 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
break;
}
if (ZEPHIR_IS_LONG(type, 366)) {
- zephir_array_fetch_string(&_6, expr, SL("ternary"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1267 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_16, this_ptr, "expression", &_7, 381, _6);
+ zephir_array_fetch_string(&_6, expr, SL("ternary"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1268 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_16, this_ptr, "expression", &_7, 383, _6);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(exprCode);
ZEPHIR_CONCAT_SVSVSVS(exprCode, "(", _16, " ? ", leftCode, " : ", rightCode, ")");
@@ -1523,18 +1524,18 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, expression) {
}
if (ZEPHIR_IS_LONG(type, 364)) {
ZEPHIR_OBS_NVAR(exprCode);
- zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1279 TSRMLS_CC);
+ zephir_array_fetch_string(&exprCode, expr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1280 TSRMLS_CC);
break;
}
ZEPHIR_INIT_NVAR(_1);
object_init_ex(_1, phalcon_mvc_view_exception_ce);
- zephir_array_fetch_string(&_11, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1283 TSRMLS_CC);
- zephir_array_fetch_string(&_17, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1283 TSRMLS_CC);
+ zephir_array_fetch_string(&_11, expr, SL("file"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC);
+ zephir_array_fetch_string(&_17, expr, SL("line"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_8);
ZEPHIR_CONCAT_SVSVSV(_8, "Unknown expression ", type, " in ", _11, " on line ", _17);
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", &_18, 9, _8);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1283 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1284 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
} while(0);
@@ -1571,7 +1572,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, _statementListOrExtends) {
}
isStatementList = 1;
if (!(zephir_array_isset_string(statements, SS("type")))) {
- zephir_is_iterable(statements, &_1, &_0, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1323);
+ zephir_is_iterable(statements, &_1, &_0, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1324);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
@@ -1584,7 +1585,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, _statementListOrExtends) {
}
}
if (isStatementList == 1) {
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_statementlist", NULL, 386, statements);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "_statementlist", NULL, 388, statements);
zephir_check_call_status();
RETURN_MM();
}
@@ -1619,7 +1620,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
if (!(zephir_array_isset_string(statement, SS("expr")))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1351);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1352);
return;
}
ZEPHIR_INIT_VAR(compilation);
@@ -1634,15 +1635,15 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
ZEPHIR_INIT_VAR(prefixLevel);
ZEPHIR_CONCAT_VV(prefixLevel, prefix, level);
ZEPHIR_OBS_VAR(expr);
- zephir_array_fetch_string(&expr, statement, SL("expr"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1369 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 381, expr);
+ zephir_array_fetch_string(&expr, statement, SL("expr"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1370 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 383, expr);
zephir_check_call_status();
ZEPHIR_OBS_VAR(blockStatements);
- zephir_array_fetch_string(&blockStatements, statement, SL("block_statements"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1375 TSRMLS_CC);
+ zephir_array_fetch_string(&blockStatements, statement, SL("block_statements"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1376 TSRMLS_CC);
ZEPHIR_INIT_NVAR(forElse);
ZVAL_BOOL(forElse, 0);
if (Z_TYPE_P(blockStatements) == IS_ARRAY) {
- zephir_is_iterable(blockStatements, &_2, &_1, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1401);
+ zephir_is_iterable(blockStatements, &_2, &_1, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1402);
for (
; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
; zephir_hash_move_forward_ex(_2, &_1)
@@ -1665,7 +1666,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
}
}
}
- ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlist", NULL, 386, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&code, this_ptr, "_statementlist", NULL, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
ZEPHIR_OBS_VAR(loopContext);
zephir_read_property_this(&loopContext, this_ptr, SL("_loopPointers"), PH_NOISY_CC);
@@ -1700,7 +1701,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
ZEPHIR_CPY_WRT(iterator, exprCode);
}
ZEPHIR_OBS_VAR(variable);
- zephir_array_fetch_string(&variable, statement, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1430 TSRMLS_CC);
+ zephir_array_fetch_string(&variable, statement, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1431 TSRMLS_CC);
ZEPHIR_OBS_VAR(key);
if (zephir_array_isset_string_fetch(&key, statement, SS("key"), 0 TSRMLS_CC)) {
ZEPHIR_INIT_LNVAR(_5);
@@ -1713,7 +1714,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileForeach) {
}
ZEPHIR_OBS_VAR(ifExpr);
if (zephir_array_isset_string_fetch(&ifExpr, statement, SS("if_expr"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_12, this_ptr, "expression", &_0, 381, ifExpr);
+ ZEPHIR_CALL_METHOD(&_12, this_ptr, "expression", &_0, 383, ifExpr);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVS(_5, "if (", _12, ") { ?>");
@@ -1814,19 +1815,19 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileIf) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1521);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1522);
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 381, expr);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr);
zephir_check_call_status();
- zephir_array_fetch_string(&_2, statement, SL("true_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1527 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "_statementlist", &_3, 386, _2, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ zephir_array_fetch_string(&_2, statement, SL("true_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1528 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "_statementlist", &_3, 388, _2, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
ZEPHIR_INIT_VAR(compilation);
ZEPHIR_CONCAT_SVSV(compilation, "", _1);
ZEPHIR_OBS_VAR(blockStatements);
if (zephir_array_isset_string_fetch(&blockStatements, statement, SS("false_statements"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_4, this_ptr, "_statementlist", &_3, 386, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_4, this_ptr, "_statementlist", &_3, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZEPHIR_CONCAT_SV(_5, "", _4);
@@ -1855,10 +1856,10 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileElseIf) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1556);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1557);
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 381, expr);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr);
zephir_check_call_status();
ZEPHIR_CONCAT_SVS(return_value, "");
RETURN_MM();
@@ -1890,12 +1891,12 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1576);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1577);
return;
}
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 381, expr);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", &_0, 383, expr);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_0, 381, expr);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_0, 383, expr);
zephir_check_call_status();
ZEPHIR_INIT_VAR(compilation);
ZEPHIR_CONCAT_SVS(compilation, "di->get('viewCache'); ");
@@ -1904,14 +1905,14 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) {
ZEPHIR_INIT_VAR(_2);
ZEPHIR_CONCAT_SVS(_2, "$_cacheKey[", exprCode, "]");
zephir_concat_self(&compilation, _2 TSRMLS_CC);
- zephir_array_fetch_string(&_3, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1586 TSRMLS_CC);
+ zephir_array_fetch_string(&_3, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1587 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_3, 265)) {
- zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1587 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1588 TSRMLS_CC);
ZEPHIR_INIT_VAR(_5);
ZEPHIR_CONCAT_SVSVSVS(_5, " = $_cache[", exprCode, "]->start(", exprCode, ", $", _4, "); ");
zephir_concat_self(&compilation, _5 TSRMLS_CC);
} else {
- zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1589 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1590 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVSVSVS(_5, " = $_cache[", exprCode, "]->start(", exprCode, ", ", _4, "); ");
zephir_concat_self(&compilation, _5 TSRMLS_CC);
@@ -1924,20 +1925,20 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileCache) {
ZEPHIR_INIT_LNVAR(_2);
ZEPHIR_CONCAT_SVS(_2, "if ($_cacheKey[", exprCode, "] === null) { ?>");
zephir_concat_self(&compilation, _2 TSRMLS_CC);
- zephir_array_fetch_string(&_3, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1599 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&_6, this_ptr, "_statementlist", NULL, 386, _3, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ zephir_array_fetch_string(&_3, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1600 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&_6, this_ptr, "_statementlist", NULL, 388, _3, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_concat_self(&compilation, _6 TSRMLS_CC);
ZEPHIR_OBS_NVAR(lifetime);
if (zephir_array_isset_string_fetch(&lifetime, statement, SS("lifetime"), 0 TSRMLS_CC)) {
- zephir_array_fetch_string(&_4, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1605 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, lifetime, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1606 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_4, 265)) {
- zephir_array_fetch_string(&_7, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1606 TSRMLS_CC);
+ zephir_array_fetch_string(&_7, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1607 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVSVSVS(_5, "save(", exprCode, ", null, $", _7, "); ");
zephir_concat_self(&compilation, _5 TSRMLS_CC);
} else {
- zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1608 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, lifetime, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1609 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_5);
ZEPHIR_CONCAT_SVSVSVS(_5, "save(", exprCode, ", null, ", _4, "); ");
zephir_concat_self(&compilation, _5 TSRMLS_CC);
@@ -1975,24 +1976,24 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileSet) {
ZEPHIR_OBS_VAR(assignments);
if (!(zephir_array_isset_string_fetch(&assignments, statement, SS("assignments"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1629);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1630);
return;
}
ZEPHIR_INIT_VAR(compilation);
ZVAL_STRING(compilation, "");
RETURN_MM();
@@ -2076,10 +2077,10 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileReturn) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1710);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1711);
return;
}
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 381, expr);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "expression", NULL, 383, expr);
zephir_check_call_status();
ZEPHIR_CONCAT_SVS(return_value, "");
RETURN_MM();
@@ -2106,14 +2107,14 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileAutoEscape) {
ZEPHIR_OBS_VAR(autoescape);
if (!(zephir_array_isset_string_fetch(&autoescape, statement, SS("enable"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1730);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1731);
return;
}
ZEPHIR_OBS_VAR(oldAutoescape);
zephir_read_property_this(&oldAutoescape, this_ptr, SL("_autoescape"), PH_NOISY_CC);
zephir_update_property_this(this_ptr, SL("_autoescape"), autoescape TSRMLS_CC);
- zephir_array_fetch_string(&_0, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1739 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(&compilation, this_ptr, "_statementlist", NULL, 386, _0, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ zephir_array_fetch_string(&_0, statement, SL("block_statements"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1740 TSRMLS_CC);
+ ZEPHIR_CALL_METHOD(&compilation, this_ptr, "_statementlist", NULL, 388, _0, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_autoescape"), oldAutoescape TSRMLS_CC);
RETURN_CCTOR(compilation);
@@ -2142,17 +2143,17 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileEcho) {
ZEPHIR_OBS_VAR(expr);
if (!(zephir_array_isset_string_fetch(&expr, statement, SS("expr"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1760);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupt statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1761);
return;
}
- ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", NULL, 381, expr);
+ ZEPHIR_CALL_METHOD(&exprCode, this_ptr, "expression", NULL, 383, expr);
zephir_check_call_status();
- zephir_array_fetch_string(&_0, expr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1768 TSRMLS_CC);
+ zephir_array_fetch_string(&_0, expr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1769 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_0, 350)) {
- zephir_array_fetch_string(&name, expr, SL("name"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1770 TSRMLS_CC);
- zephir_array_fetch_string(&_1, name, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1772 TSRMLS_CC);
+ zephir_array_fetch_string(&name, expr, SL("name"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1771 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, name, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1773 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_1, 265)) {
- zephir_array_fetch_string(&_2, name, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1777 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, name, SL("value"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1778 TSRMLS_CC);
if (ZEPHIR_IS_STRING(_2, "super")) {
RETURN_CCTOR(exprCode);
}
@@ -2187,14 +2188,14 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileInclude) {
ZEPHIR_OBS_VAR(pathExpr);
if (!(zephir_array_isset_string_fetch(&pathExpr, statement, SS("path"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1805);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1806);
return;
}
- zephir_array_fetch_string(&_0, pathExpr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1812 TSRMLS_CC);
+ zephir_array_fetch_string(&_0, pathExpr, SL("type"), PH_NOISY | PH_READONLY, "phalcon/mvc/view/engine/volt/compiler.zep", 1813 TSRMLS_CC);
if (ZEPHIR_IS_LONG(_0, 260)) {
if (!(zephir_array_isset_string(statement, SS("params")))) {
ZEPHIR_OBS_VAR(path);
- zephir_array_fetch_string(&path, pathExpr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1822 TSRMLS_CC);
+ zephir_array_fetch_string(&path, pathExpr, SL("value"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1823 TSRMLS_CC);
ZEPHIR_OBS_VAR(view);
zephir_read_property_this(&view, this_ptr, SL("_view"), PH_NOISY_CC);
if (Z_TYPE_P(view) == IS_OBJECT) {
@@ -2222,14 +2223,14 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileInclude) {
RETURN_CCTOR(compilation);
}
}
- ZEPHIR_CALL_METHOD(&path, this_ptr, "expression", &_3, 381, pathExpr);
+ ZEPHIR_CALL_METHOD(&path, this_ptr, "expression", &_3, 383, pathExpr);
zephir_check_call_status();
ZEPHIR_OBS_VAR(params);
if (!(zephir_array_isset_string_fetch(¶ms, statement, SS("params"), 0 TSRMLS_CC))) {
ZEPHIR_CONCAT_SVS(return_value, "partial(", path, "); ?>");
RETURN_MM();
}
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_3, 381, params);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "expression", &_3, 383, params);
zephir_check_call_status();
ZEPHIR_CONCAT_SVSVS(return_value, "partial(", path, ", ", _1, "); ?>");
RETURN_MM();
@@ -2259,7 +2260,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
ZEPHIR_OBS_VAR(name);
if (!(zephir_array_isset_string_fetch(&name, statement, SS("name"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1877);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_mvc_view_exception_ce, "Corrupted statement", "phalcon/mvc/view/engine/volt/compiler.zep", 1878);
return;
}
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_macros"), PH_NOISY_CC);
@@ -2270,7 +2271,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
ZEPHIR_CONCAT_SVS(_2, "Macro '", name, "' is already defined");
ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1884 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/mvc/view/engine/volt/compiler.zep", 1885 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
@@ -2288,7 +2289,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
ZEPHIR_INIT_LNVAR(_2);
ZEPHIR_CONCAT_VS(_2, macroName, " = function($__p = null) { ");
zephir_concat_self(&code, _2 TSRMLS_CC);
- zephir_is_iterable(parameters, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1922);
+ zephir_is_iterable(parameters, &_4, &_3, 0, 0, "phalcon/mvc/view/engine/volt/compiler.zep", 1923);
for (
; zephir_hash_get_current_data_ex(_4, (void**) &_5, &_3) == SUCCESS
; zephir_hash_move_forward_ex(_4, &_3)
@@ -2296,7 +2297,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
ZEPHIR_GET_HMKEY(position, _4, _3);
ZEPHIR_GET_HVALUE(parameter, _5);
ZEPHIR_OBS_NVAR(variableName);
- zephir_array_fetch_string(&variableName, parameter, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1906 TSRMLS_CC);
+ zephir_array_fetch_string(&variableName, parameter, SL("variable"), PH_NOISY, "phalcon/mvc/view/engine/volt/compiler.zep", 1907 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_6);
ZEPHIR_CONCAT_SVS(_6, "if (isset($__p[", position, "])) { ");
zephir_concat_self(&code, _6 TSRMLS_CC);
@@ -2313,7 +2314,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
zephir_concat_self_str(&code, SL(" } else { ") TSRMLS_CC);
ZEPHIR_OBS_NVAR(defaultValue);
if (zephir_array_isset_string_fetch(&defaultValue, parameter, SS("default"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_10, this_ptr, "expression", &_11, 381, defaultValue);
+ ZEPHIR_CALL_METHOD(&_10, this_ptr, "expression", &_11, 383, defaultValue);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_12);
ZEPHIR_CONCAT_SVSVS(_12, "$", variableName, " = ", _10, ";");
@@ -2329,7 +2330,7 @@ PHP_METHOD(Phalcon_Mvc_View_Engine_Volt_Compiler, compileMacro) {
}
ZEPHIR_OBS_VAR(blockStatements);
if (zephir_array_isset_string_fetch(&blockStatements, statement, SS("block_statements"), 0 TSRMLS_CC)) {
- ZEPHIR_CALL_METHOD(&_10, this_ptr, "_statementlist", NULL, 386, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_METHOD(&_10, this_ptr, "_statementlist", NULL, 388, blockStatements, (extendsMode ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_2);
ZEPHIR_CONCAT_VS(_2, _10, "
- * $paginator = new \Phalcon\Paginator\Adapter\Model(
+ * $paginator = new \Phalcon\Paginator\Adapter\NativeArray(
* array(
* "data" => array(
* array('id' => 1, 'name' => 'Artichoke'),
@@ -112,7 +112,7 @@ PHP_METHOD(Phalcon_Paginator_Adapter_NativeArray, getPaginate) {
number = zephir_fast_count_int(items TSRMLS_CC);
ZEPHIR_SINIT_VAR(_2);
ZVAL_LONG(&_2, show);
- ZEPHIR_CALL_FUNCTION(&_3, "floatval", NULL, 310, &_2);
+ ZEPHIR_CALL_FUNCTION(&_3, "floatval", NULL, 311, &_2);
zephir_check_call_status();
roundedTotal = zephir_safe_div_long_zval(number, _3 TSRMLS_CC);
totalPages = (int) (roundedTotal);
@@ -123,7 +123,7 @@ PHP_METHOD(Phalcon_Paginator_Adapter_NativeArray, getPaginate) {
ZVAL_LONG(&_2, (show * ((pageNumber - 1))));
ZEPHIR_SINIT_VAR(_4);
ZVAL_LONG(&_4, show);
- ZEPHIR_CALL_FUNCTION(&_5, "array_slice", NULL, 377, items, &_2, &_4);
+ ZEPHIR_CALL_FUNCTION(&_5, "array_slice", NULL, 379, items, &_2, &_4);
zephir_check_call_status();
ZEPHIR_CPY_WRT(items, _5);
if (pageNumber < totalPages) {
diff --git a/ext/phalcon/queue/beanstalk.zep.c b/ext/phalcon/queue/beanstalk.zep.c
index f88723f6b8d..5ca5af366ba 100644
--- a/ext/phalcon/queue/beanstalk.zep.c
+++ b/ext/phalcon/queue/beanstalk.zep.c
@@ -107,7 +107,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, connect) {
ZEPHIR_INIT_VAR(_3);
ZVAL_NULL(_3);
Z_SET_ISREF_P(_2);
- ZEPHIR_CALL_FUNCTION(&connection, "fsockopen", NULL, 388, _0, _1, _2, _3);
+ ZEPHIR_CALL_FUNCTION(&connection, "fsockopen", NULL, 390, _0, _1, _2, _3);
Z_UNSET_ISREF_P(_2);
zephir_check_call_status();
if (Z_TYPE_P(connection) != IS_RESOURCE) {
@@ -116,7 +116,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, connect) {
}
ZEPHIR_SINIT_VAR(_4);
ZVAL_LONG(&_4, -1);
- ZEPHIR_CALL_FUNCTION(NULL, "stream_set_timeout", NULL, 389, connection, &_4, ZEPHIR_GLOBAL(global_null));
+ ZEPHIR_CALL_FUNCTION(NULL, "stream_set_timeout", NULL, 391, connection, &_4, ZEPHIR_GLOBAL(global_null));
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_connection"), connection TSRMLS_CC);
RETURN_CCTOR(connection);
@@ -169,7 +169,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, put) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", &_1, 0, serialized);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 390);
+ ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392);
zephir_check_call_status();
zephir_array_fetch_long(&status, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 128 TSRMLS_CC);
_2 = !ZEPHIR_IS_STRING(status, "INSERTED");
@@ -208,7 +208,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, reserve) {
}
ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, command);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 390);
+ ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392);
zephir_check_call_status();
zephir_array_fetch_long(&_0, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 153 TSRMLS_CC);
if (!ZEPHIR_IS_STRING(_0, "RESERVED")) {
@@ -221,7 +221,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, reserve) {
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&_4, "unserialize", NULL, 72, _2);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 391, this_ptr, _1, _4);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 393, this_ptr, _1, _4);
zephir_check_call_status();
RETURN_MM();
@@ -256,7 +256,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, choose) {
ZEPHIR_CONCAT_SV(_0, "use ", tube);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 390);
+ ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392);
zephir_check_call_status();
zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 176 TSRMLS_CC);
if (!ZEPHIR_IS_STRING(_1, "USING")) {
@@ -296,7 +296,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, watch) {
ZEPHIR_CONCAT_SV(_0, "watch ", tube);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 390);
+ ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392);
zephir_check_call_status();
zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 193 TSRMLS_CC);
if (!ZEPHIR_IS_STRING(_1, "WATCHING")) {
@@ -322,7 +322,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, stats) {
ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0);
zephir_check_temp_parameter(_0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 392);
+ ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 394);
zephir_check_call_status();
zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 210 TSRMLS_CC);
if (!ZEPHIR_IS_STRING(_1, "OK")) {
@@ -362,7 +362,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, statsTube) {
ZEPHIR_CONCAT_SV(_0, "stats-tube ", tube);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 392);
+ ZEPHIR_CALL_METHOD(&response, this_ptr, "readyaml", NULL, 394);
zephir_check_call_status();
zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 227 TSRMLS_CC);
if (!ZEPHIR_IS_STRING(_1, "OK")) {
@@ -388,7 +388,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, peekReady) {
ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0);
zephir_check_temp_parameter(_0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 390);
+ ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392);
zephir_check_call_status();
zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 244 TSRMLS_CC);
if (!ZEPHIR_IS_STRING(_1, "FOUND")) {
@@ -401,7 +401,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, peekReady) {
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 72, _3);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 391, this_ptr, _2, _5);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 393, this_ptr, _2, _5);
zephir_check_call_status();
RETURN_MM();
@@ -422,7 +422,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, peekBuried) {
ZEPHIR_CALL_METHOD(NULL, this_ptr, "write", NULL, 0, _0);
zephir_check_temp_parameter(_0);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 390);
+ ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392);
zephir_check_call_status();
zephir_array_fetch_long(&_1, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 261 TSRMLS_CC);
if (!ZEPHIR_IS_STRING(_1, "FOUND")) {
@@ -435,7 +435,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, peekBuried) {
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&_5, "unserialize", NULL, 72, _3);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 391, this_ptr, _2, _5);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 393, this_ptr, _2, _5);
zephir_check_call_status();
RETURN_MM();
@@ -447,13 +447,17 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, peekBuried) {
PHP_METHOD(Phalcon_Queue_Beanstalk, readStatus) {
int ZEPHIR_LAST_CALL_STATUS;
- zval *_0 = NULL;
+ zval *status = NULL;
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&_0, this_ptr, "read", NULL, 0);
+ ZEPHIR_CALL_METHOD(&status, this_ptr, "read", NULL, 0);
zephir_check_call_status();
- zephir_fast_explode_str(return_value, SL(" "), _0, LONG_MAX TSRMLS_CC);
+ if (ZEPHIR_IS_FALSE_IDENTICAL(status)) {
+ array_init(return_value);
+ RETURN_MM();
+ }
+ zephir_fast_explode_str(return_value, SL(" "), status, LONG_MAX TSRMLS_CC);
RETURN_MM();
}
@@ -468,13 +472,13 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, readYaml) {
ZEPHIR_MM_GROW();
- ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 390);
+ ZEPHIR_CALL_METHOD(&response, this_ptr, "readstatus", NULL, 392);
zephir_check_call_status();
ZEPHIR_OBS_VAR(status);
- zephir_array_fetch_long(&status, response, 0, PH_NOISY, "phalcon/queue/beanstalk.zep", 285 TSRMLS_CC);
+ zephir_array_fetch_long(&status, response, 0, PH_NOISY, "phalcon/queue/beanstalk.zep", 290 TSRMLS_CC);
if (zephir_fast_count_int(response TSRMLS_CC) > 1) {
ZEPHIR_OBS_VAR(numberOfBytes);
- zephir_array_fetch_long(&numberOfBytes, response, 1, PH_NOISY, "phalcon/queue/beanstalk.zep", 288 TSRMLS_CC);
+ zephir_array_fetch_long(&numberOfBytes, response, 1, PH_NOISY, "phalcon/queue/beanstalk.zep", 293 TSRMLS_CC);
ZEPHIR_CALL_METHOD(&response, this_ptr, "read", NULL, 0);
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&data, "yaml_parse", NULL, 0, response);
@@ -530,13 +534,13 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, read) {
}
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, (length + 2));
- ZEPHIR_CALL_FUNCTION(&data, "fread", NULL, 393, connection, &_0);
+ ZEPHIR_CALL_FUNCTION(&data, "fread", NULL, 395, connection, &_0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_1, "stream_get_meta_data", NULL, 394, connection);
+ ZEPHIR_CALL_FUNCTION(&_1, "stream_get_meta_data", NULL, 396, connection);
zephir_check_call_status();
- zephir_array_fetch_string(&_2, _1, SL("timed_out"), PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 332 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, _1, SL("timed_out"), PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk.zep", 337 TSRMLS_CC);
if (zephir_is_true(_2)) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_exception_ce, "Connection timed out", "phalcon/queue/beanstalk.zep", 333);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_exception_ce, "Connection timed out", "phalcon/queue/beanstalk.zep", 338);
return;
}
ZEPHIR_SINIT_NVAR(_0);
@@ -548,7 +552,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, read) {
ZVAL_LONG(&_0, 16384);
ZEPHIR_SINIT_VAR(_3);
ZVAL_STRING(&_3, "\r\n", 0);
- ZEPHIR_RETURN_CALL_FUNCTION("stream_get_line", NULL, 395, connection, &_0, &_3);
+ ZEPHIR_RETURN_CALL_FUNCTION("stream_get_line", NULL, 397, connection, &_0, &_3);
zephir_check_call_status();
RETURN_MM();
@@ -583,7 +587,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk, write) {
ZEPHIR_CPY_WRT(packet, _0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, zephir_fast_strlen_ev(packet));
- ZEPHIR_RETURN_CALL_FUNCTION("fwrite", NULL, 396, connection, packet, &_1);
+ ZEPHIR_RETURN_CALL_FUNCTION("fwrite", NULL, 398, connection, packet, &_1);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/queue/beanstalk/job.zep.c b/ext/phalcon/queue/beanstalk/job.zep.c
index c0b87398450..34ed78a9cec 100644
--- a/ext/phalcon/queue/beanstalk/job.zep.c
+++ b/ext/phalcon/queue/beanstalk/job.zep.c
@@ -13,19 +13,19 @@
#include "kernel/main.h"
#include "kernel/object.h"
+#include "kernel/operators.h"
#include "kernel/memory.h"
#include "kernel/fcall.h"
#include "kernel/concat.h"
#include "kernel/array.h"
-#include "kernel/operators.h"
#include "kernel/exception.h"
/**
-* Phalcon\Queue\Beanstalk\Job
-*
-* Represents a job in a beanstalk queue
-*/
+ * Phalcon\Queue\Beanstalk\Job
+ *
+ * Represents a job in a beanstalk queue
+ */
ZEPHIR_INIT_CLASS(Phalcon_Queue_Beanstalk_Job) {
ZEPHIR_REGISTER_CLASS(Phalcon\\Queue\\Beanstalk, Job, phalcon, queue_beanstalk_job, phalcon_queue_beanstalk_job_method_entry, 0);
@@ -56,22 +56,22 @@ PHP_METHOD(Phalcon_Queue_Beanstalk_Job, getBody) {
/**
* Phalcon\Queue\Beanstalk\Job
- *
- * @param Phalcon\Queue\Beanstalk queue
- * @param string id
- * @param string body
*/
PHP_METHOD(Phalcon_Queue_Beanstalk_Job, __construct) {
- zval *queue, *id, *body;
+ zval *id = NULL;
+ zval *queue, *id_param = NULL, *body;
- zephir_fetch_params(0, 3, 0, &queue, &id, &body);
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 3, 0, &queue, &id_param, &body);
+ zephir_get_strval(id, id_param);
zephir_update_property_this(this_ptr, SL("_queue"), queue TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_id"), id TSRMLS_CC);
zephir_update_property_this(this_ptr, SL("_body"), body TSRMLS_CC);
+ ZEPHIR_MM_RESTORE();
}
@@ -94,7 +94,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk_Job, delete) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 59 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 57 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_3, "DELETED"));
}
@@ -137,7 +137,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk_Job, release) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_4, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_5, _4, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 73 TSRMLS_CC);
+ zephir_array_fetch_long(&_5, _4, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 71 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_5, "RELEASED"));
}
@@ -173,7 +173,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk_Job, bury) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_3, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_4, _3, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 87 TSRMLS_CC);
+ zephir_array_fetch_long(&_4, _3, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 85 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_4, "BURIED"));
}
@@ -202,7 +202,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk_Job, touch) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 104 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 102 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_3, "TOUCHED"));
}
@@ -226,7 +226,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk_Job, kick) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&_2, queue, "readstatus", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 116 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, _2, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 114 TSRMLS_CC);
RETURN_MM_BOOL(ZEPHIR_IS_STRING(_3, "KICKED"));
}
@@ -250,11 +250,11 @@ PHP_METHOD(Phalcon_Queue_Beanstalk_Job, stats) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&response, queue, "readyaml", NULL, 0);
zephir_check_call_status();
- zephir_array_fetch_long(&_2, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 130 TSRMLS_CC);
+ zephir_array_fetch_long(&_2, response, 0, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 128 TSRMLS_CC);
if (ZEPHIR_IS_STRING(_2, "NOT_FOUND")) {
RETURN_MM_BOOL(0);
}
- zephir_array_fetch_long(&_3, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 134 TSRMLS_CC);
+ zephir_array_fetch_long(&_3, response, 2, PH_NOISY | PH_READONLY, "phalcon/queue/beanstalk/job.zep", 132 TSRMLS_CC);
RETURN_CTOR(_3);
}
@@ -282,7 +282,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk_Job, __wakeup) {
zephir_check_temp_parameter(_2);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
- zephir_throw_exception_debug(_1, "phalcon/queue/beanstalk/job.zep", 143 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/queue/beanstalk/job.zep", 141 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
diff --git a/ext/phalcon/queue/beanstalk/job.zep.h b/ext/phalcon/queue/beanstalk/job.zep.h
index 4398f96640b..3988e79e1dd 100644
--- a/ext/phalcon/queue/beanstalk/job.zep.h
+++ b/ext/phalcon/queue/beanstalk/job.zep.h
@@ -15,7 +15,7 @@ PHP_METHOD(Phalcon_Queue_Beanstalk_Job, stats);
PHP_METHOD(Phalcon_Queue_Beanstalk_Job, __wakeup);
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_queue_beanstalk_job___construct, 0, 0, 3)
- ZEND_ARG_INFO(0, queue)
+ ZEND_ARG_OBJ_INFO(0, queue, Phalcon\\Queue\\Beanstalk, 0)
ZEND_ARG_INFO(0, id)
ZEND_ARG_INFO(0, body)
ZEND_END_ARG_INFO()
diff --git a/ext/phalcon/registry.zep.c b/ext/phalcon/registry.zep.c
index 1d9c4e45c0a..06cda532de3 100644
--- a/ext/phalcon/registry.zep.c
+++ b/ext/phalcon/registry.zep.c
@@ -244,7 +244,7 @@ PHP_METHOD(Phalcon_Registry, next) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_CALL_FUNCTION(NULL, "next", NULL, 397, _0);
+ ZEPHIR_CALL_FUNCTION(NULL, "next", NULL, 399, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -263,7 +263,7 @@ PHP_METHOD(Phalcon_Registry, key) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_RETURN_CALL_FUNCTION("key", NULL, 398, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("key", NULL, 400, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
RETURN_MM();
@@ -282,7 +282,7 @@ PHP_METHOD(Phalcon_Registry, rewind) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_CALL_FUNCTION(NULL, "reset", NULL, 399, _0);
+ ZEPHIR_CALL_FUNCTION(NULL, "reset", NULL, 401, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -301,7 +301,7 @@ PHP_METHOD(Phalcon_Registry, valid) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_CALL_FUNCTION(&_1, "key", NULL, 398, _0);
+ ZEPHIR_CALL_FUNCTION(&_1, "key", NULL, 400, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
RETURN_MM_BOOL(Z_TYPE_P(_1) != IS_NULL);
@@ -320,7 +320,7 @@ PHP_METHOD(Phalcon_Registry, current) {
_0 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
Z_SET_ISREF_P(_0);
- ZEPHIR_RETURN_CALL_FUNCTION("current", NULL, 400, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("current", NULL, 402, _0);
Z_UNSET_ISREF_P(_0);
zephir_check_call_status();
RETURN_MM();
@@ -352,7 +352,7 @@ PHP_METHOD(Phalcon_Registry, __set) {
}
- ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetset", NULL, 401, key, value);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetset", NULL, 403, key, value);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -383,7 +383,7 @@ PHP_METHOD(Phalcon_Registry, __get) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetget", NULL, 402, key);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetget", NULL, 404, key);
zephir_check_call_status();
RETURN_MM();
@@ -411,7 +411,7 @@ PHP_METHOD(Phalcon_Registry, __isset) {
}
- ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetexists", NULL, 403, key);
+ ZEPHIR_RETURN_CALL_METHOD(this_ptr, "offsetexists", NULL, 405, key);
zephir_check_call_status();
RETURN_MM();
@@ -439,7 +439,7 @@ PHP_METHOD(Phalcon_Registry, __unset) {
}
- ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetunset", NULL, 404, key);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "offsetunset", NULL, 406, key);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
diff --git a/ext/phalcon/security.zep.c b/ext/phalcon/security.zep.c
index 98a52479ea4..dc0e834861e 100644
--- a/ext/phalcon/security.zep.c
+++ b/ext/phalcon/security.zep.c
@@ -191,7 +191,7 @@ PHP_METHOD(Phalcon_Security, getSaltBytes) {
ZEPHIR_INIT_NVAR(safeBytes);
ZEPHIR_INIT_NVAR(_1);
ZVAL_LONG(_1, numberBytes);
- ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", &_3, 405, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", &_3, 407, _1);
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&_4, "base64_encode", &_5, 112, _2);
zephir_check_call_status();
@@ -286,7 +286,7 @@ PHP_METHOD(Phalcon_Security, hash) {
}
ZEPHIR_INIT_VAR(_3);
ZEPHIR_CONCAT_SVSV(_3, "$", variant, "$", saltBytes);
- ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 406, password, _3);
+ ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 408, password, _3);
zephir_check_call_status();
RETURN_MM();
}
@@ -309,11 +309,11 @@ PHP_METHOD(Phalcon_Security, hash) {
ZVAL_STRING(&_5, "%02s", 0);
ZEPHIR_SINIT_VAR(_6);
ZVAL_LONG(&_6, workFactor);
- ZEPHIR_CALL_FUNCTION(&_7, "sprintf", NULL, 186, &_5, &_6);
+ ZEPHIR_CALL_FUNCTION(&_7, "sprintf", NULL, 187, &_5, &_6);
zephir_check_call_status();
ZEPHIR_INIT_LNVAR(_3);
ZEPHIR_CONCAT_SVSVSV(_3, "$2", variant, "$", _7, "$", saltBytes);
- ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 406, password, _3);
+ ZEPHIR_RETURN_CALL_FUNCTION("crypt", &_4, 408, password, _3);
zephir_check_call_status();
RETURN_MM();
} while(0);
@@ -356,7 +356,7 @@ PHP_METHOD(Phalcon_Security, checkHash) {
RETURN_MM_BOOL(0);
}
}
- ZEPHIR_CALL_FUNCTION(&_1, "crypt", NULL, 406, password, passwordHash);
+ ZEPHIR_CALL_FUNCTION(&_1, "crypt", NULL, 408, password, passwordHash);
zephir_check_call_status();
zephir_get_strval(_2, _1);
ZEPHIR_CPY_WRT(cryptedHash, _2);
@@ -426,7 +426,7 @@ PHP_METHOD(Phalcon_Security, getTokenKey) {
ZEPHIR_INIT_VAR(safeBytes);
ZEPHIR_INIT_VAR(_1);
ZVAL_LONG(_1, numberBytes);
- ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", NULL, 405, _1);
+ ZEPHIR_CALL_FUNCTION(&_2, "openssl_random_pseudo_bytes", NULL, 407, _1);
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&_3, "base64_encode", NULL, 112, _2);
zephir_check_call_status();
@@ -471,7 +471,7 @@ PHP_METHOD(Phalcon_Security, getToken) {
}
ZEPHIR_INIT_VAR(_0);
ZVAL_LONG(_0, numberBytes);
- ZEPHIR_CALL_FUNCTION(&token, "openssl_random_pseudo_bytes", NULL, 405, _0);
+ ZEPHIR_CALL_FUNCTION(&token, "openssl_random_pseudo_bytes", NULL, 407, _0);
zephir_check_call_status();
ZEPHIR_CALL_FUNCTION(&_1, "base64_encode", NULL, 112, token);
zephir_check_call_status();
@@ -661,7 +661,7 @@ PHP_METHOD(Phalcon_Security, computeHmac) {
}
- ZEPHIR_CALL_FUNCTION(&hmac, "hash_hmac", NULL, 407, algo, data, key, (raw ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
+ ZEPHIR_CALL_FUNCTION(&hmac, "hash_hmac", NULL, 409, algo, data, key, (raw ? ZEPHIR_GLOBAL(global_true) : ZEPHIR_GLOBAL(global_false)));
zephir_check_call_status();
if (!(zephir_is_true(hmac))) {
ZEPHIR_INIT_VAR(_0);
diff --git a/ext/phalcon/session/adapter/libmemcached.zep.c b/ext/phalcon/session/adapter/libmemcached.zep.c
index db9e67f2bcf..8171d74085d 100644
--- a/ext/phalcon/session/adapter/libmemcached.zep.c
+++ b/ext/phalcon/session/adapter/libmemcached.zep.c
@@ -123,7 +123,7 @@ PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) {
ZEPHIR_OBS_VAR(_3);
zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC);
zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 317, _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_4);
zephir_create_array(_4, 4, 0 TSRMLS_CC);
@@ -131,7 +131,7 @@ PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) {
zephir_array_update_string(&_4, SL("client"), &client, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("prefix"), &prefix, PH_COPY | PH_SEPARATE);
zephir_array_update_string(&_4, SL("statsKey"), &statsKey, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 318, _1, _4);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 319, _1, _4);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_libmemcached"), _0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_5);
@@ -170,9 +170,9 @@ PHP_METHOD(Phalcon_Session_Adapter_Libmemcached, __construct) {
ZEPHIR_INIT_NVAR(_6);
ZVAL_STRING(_6, "gc", 1);
zephir_array_fast_append(_11, _6);
- ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 408, _5, _7, _8, _9, _10, _11);
+ ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _5, _7, _8, _9, _10, _11);
zephir_check_call_status();
- ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_libmemcached_ce, this_ptr, "__construct", &_12, 409, options);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_libmemcached_ce, this_ptr, "__construct", &_12, 411, options);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
diff --git a/ext/phalcon/session/adapter/memcache.zep.c b/ext/phalcon/session/adapter/memcache.zep.c
index d1dab54d27d..3ecaa7bcaec 100644
--- a/ext/phalcon/session/adapter/memcache.zep.c
+++ b/ext/phalcon/session/adapter/memcache.zep.c
@@ -26,10 +26,10 @@
*
*
* $session = new \Phalcon\Session\Adapter\Memcache(array(
- * 'uniqueId' => 'my-private-app'
+ * 'uniqueId' => 'my-private-app',
* 'host' => '127.0.0.1',
* 'port' => 11211,
- * 'persistent' => TRUE,
+ * 'persistent' => true,
* 'lifetime' => 3600,
* 'prefix' => 'my_'
* ));
@@ -117,9 +117,9 @@ PHP_METHOD(Phalcon_Session_Adapter_Memcache, __construct) {
ZEPHIR_OBS_VAR(_3);
zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC);
zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 317, _2);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 320, _1, options);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 321, _1, options);
zephir_check_call_status();
zephir_update_property_this(this_ptr, SL("_memcache"), _0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_4);
@@ -158,9 +158,9 @@ PHP_METHOD(Phalcon_Session_Adapter_Memcache, __construct) {
ZEPHIR_INIT_NVAR(_5);
ZVAL_STRING(_5, "gc", 1);
zephir_array_fast_append(_10, _5);
- ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 408, _4, _6, _7, _8, _9, _10);
+ ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _4, _6, _7, _8, _9, _10);
zephir_check_call_status();
- ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_memcache_ce, this_ptr, "__construct", &_11, 409, options);
+ ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_memcache_ce, this_ptr, "__construct", &_11, 411, options);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
diff --git a/ext/phalcon/session/adapter/redis.zep.c b/ext/phalcon/session/adapter/redis.zep.c
new file mode 100644
index 00000000000..693ad0d21e2
--- /dev/null
+++ b/ext/phalcon/session/adapter/redis.zep.c
@@ -0,0 +1,271 @@
+
+#ifdef HAVE_CONFIG_H
+#include "../../../ext_config.h"
+#endif
+
+#include
+#include "../../../php_ext.h"
+#include "../../../ext.h"
+
+#include
+#include
+#include
+
+#include "kernel/main.h"
+#include "kernel/object.h"
+#include "kernel/array.h"
+#include "kernel/memory.h"
+#include "kernel/fcall.h"
+#include "kernel/operators.h"
+
+
+/**
+ * Phalcon\Session\Adapter\Redis
+ *
+ * This adapter store sessions in Redis
+ *
+ *
+ * $session = new \Phalcon\Session\Adapter\Redis(array(
+ * 'uniqueId' => 'my-private-app',
+ * 'host' => 'localhost',
+ * 'port' => 6379,
+ * 'auth' => 'foobared',
+ * 'persistent' => false,
+ * 'lifetime' => 3600,
+ * 'prefix' => 'my_'
+ * ));
+ *
+ * $session->start();
+ *
+ * $session->set('var', 'some-value');
+ *
+ * echo $session->get('var');
+ *
+ */
+ZEPHIR_INIT_CLASS(Phalcon_Session_Adapter_Redis) {
+
+ ZEPHIR_REGISTER_CLASS_EX(Phalcon\\Session\\Adapter, Redis, phalcon, session_adapter_redis, phalcon_session_adapter_ce, phalcon_session_adapter_redis_method_entry, 0);
+
+ zend_declare_property_null(phalcon_session_adapter_redis_ce, SL("_redis"), ZEND_ACC_PROTECTED TSRMLS_CC);
+
+ zend_declare_property_long(phalcon_session_adapter_redis_ce, SL("_lifetime"), 8600, ZEND_ACC_PROTECTED TSRMLS_CC);
+
+ zend_class_implements(phalcon_session_adapter_redis_ce TSRMLS_CC, 1, phalcon_session_adapterinterface_ce);
+ return SUCCESS;
+
+}
+
+PHP_METHOD(Phalcon_Session_Adapter_Redis, getRedis) {
+
+
+ RETURN_MEMBER(this_ptr, "_redis");
+
+}
+
+PHP_METHOD(Phalcon_Session_Adapter_Redis, getLifetime) {
+
+
+ RETURN_MEMBER(this_ptr, "_lifetime");
+
+}
+
+/**
+ * Phalcon\Session\Adapter\Redis constructor
+ */
+PHP_METHOD(Phalcon_Session_Adapter_Redis, __construct) {
+
+ zephir_fcall_cache_entry *_11 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *options_param = NULL, *lifetime, *_0 = NULL, *_1, *_3, *_5 = NULL;
+ zval *options = NULL, *_2, *_4, *_6, *_7, *_8, *_9, *_10;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 0, 1, &options_param);
+
+ if (!options_param) {
+ ZEPHIR_INIT_VAR(options);
+ array_init(options);
+ } else {
+ zephir_get_arrval(options, options_param);
+ }
+
+
+ if (!(zephir_array_isset_string(options, SS("host")))) {
+ ZEPHIR_INIT_VAR(_0);
+ ZVAL_STRING(_0, "127.0.0.1", 1);
+ zephir_array_update_string(&options, SL("host"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("port")))) {
+ ZEPHIR_INIT_NVAR(_0);
+ ZVAL_LONG(_0, 6379);
+ zephir_array_update_string(&options, SL("port"), &_0, PH_COPY | PH_SEPARATE);
+ }
+ if (!(zephir_array_isset_string(options, SS("persistent")))) {
+ zephir_array_update_string(&options, SL("persistent"), &ZEPHIR_GLOBAL(global_false), PH_COPY | PH_SEPARATE);
+ }
+ ZEPHIR_OBS_VAR(lifetime);
+ if (zephir_array_isset_string_fetch(&lifetime, options, SS("lifetime"), 0 TSRMLS_CC)) {
+ zephir_update_property_this(this_ptr, SL("_lifetime"), lifetime TSRMLS_CC);
+ }
+ ZEPHIR_INIT_NVAR(_0);
+ object_init_ex(_0, phalcon_cache_backend_redis_ce);
+ ZEPHIR_INIT_VAR(_1);
+ object_init_ex(_1, phalcon_cache_frontend_data_ce);
+ ZEPHIR_INIT_VAR(_2);
+ zephir_create_array(_2, 1, 0 TSRMLS_CC);
+ ZEPHIR_OBS_VAR(_3);
+ zephir_read_property_this(&_3, this_ptr, SL("_lifetime"), PH_NOISY_CC);
+ zephir_array_update_string(&_2, SL("lifetime"), &_3, PH_COPY | PH_SEPARATE);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 318, _2);
+ zephir_check_call_status();
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 322, _1, options);
+ zephir_check_call_status();
+ zephir_update_property_this(this_ptr, SL("_redis"), _0 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_4);
+ zephir_create_array(_4, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_4, this_ptr);
+ ZEPHIR_INIT_VAR(_5);
+ ZVAL_STRING(_5, "open", 1);
+ zephir_array_fast_append(_4, _5);
+ ZEPHIR_INIT_VAR(_6);
+ zephir_create_array(_6, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_6, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "close", 1);
+ zephir_array_fast_append(_6, _5);
+ ZEPHIR_INIT_VAR(_7);
+ zephir_create_array(_7, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_7, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "read", 1);
+ zephir_array_fast_append(_7, _5);
+ ZEPHIR_INIT_VAR(_8);
+ zephir_create_array(_8, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_8, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "write", 1);
+ zephir_array_fast_append(_8, _5);
+ ZEPHIR_INIT_VAR(_9);
+ zephir_create_array(_9, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_9, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "destroy", 1);
+ zephir_array_fast_append(_9, _5);
+ ZEPHIR_INIT_VAR(_10);
+ zephir_create_array(_10, 2, 0 TSRMLS_CC);
+ zephir_array_fast_append(_10, this_ptr);
+ ZEPHIR_INIT_NVAR(_5);
+ ZVAL_STRING(_5, "gc", 1);
+ zephir_array_fast_append(_10, _5);
+ ZEPHIR_CALL_FUNCTION(NULL, "session_set_save_handler", NULL, 410, _4, _6, _7, _8, _9, _10);
+ zephir_check_call_status();
+ ZEPHIR_CALL_PARENT(NULL, phalcon_session_adapter_redis_ce, this_ptr, "__construct", &_11, 411, options);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+PHP_METHOD(Phalcon_Session_Adapter_Redis, open) {
+
+
+ RETURN_BOOL(1);
+
+}
+
+PHP_METHOD(Phalcon_Session_Adapter_Redis, close) {
+
+
+ RETURN_BOOL(1);
+
+}
+
+/**
+ * {@inheritdoc}
+ *
+ * @param string sessionId
+ * @return mixed
+ */
+PHP_METHOD(Phalcon_Session_Adapter_Redis, read) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *sessionId, *_0, *_1;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 0, &sessionId);
+
+
+
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ _1 = zephir_fetch_nproperty_this(this_ptr, SL("_lifetime"), PH_NOISY_CC);
+ ZEPHIR_RETURN_CALL_METHOD(_0, "get", NULL, 0, sessionId, _1);
+ zephir_check_call_status();
+ RETURN_MM();
+
+}
+
+/**
+ * {@inheritdoc}
+ *
+ * @param string sessionId
+ * @param string data
+ */
+PHP_METHOD(Phalcon_Session_Adapter_Redis, write) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *sessionId, *data, *_0, *_1;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 2, 0, &sessionId, &data);
+
+
+
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ _1 = zephir_fetch_nproperty_this(this_ptr, SL("_lifetime"), PH_NOISY_CC);
+ ZEPHIR_CALL_METHOD(NULL, _0, "save", NULL, 0, sessionId, data, _1);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+/**
+ * {@inheritdoc}
+ *
+ * @param string sessionId
+ * @return boolean
+ */
+PHP_METHOD(Phalcon_Session_Adapter_Redis, destroy) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *sessionId = NULL, *_0;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 0, 1, &sessionId);
+
+ if (!sessionId) {
+ ZEPHIR_CPY_WRT(sessionId, ZEPHIR_GLOBAL(global_null));
+ } else {
+ ZEPHIR_SEPARATE_PARAM(sessionId);
+ }
+
+
+ if (Z_TYPE_P(sessionId) == IS_NULL) {
+ ZEPHIR_CALL_METHOD(&sessionId, this_ptr, "getid", NULL, 0);
+ zephir_check_call_status();
+ }
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_redis"), PH_NOISY_CC);
+ ZEPHIR_RETURN_CALL_METHOD(_0, "delete", NULL, 0, sessionId);
+ zephir_check_call_status();
+ RETURN_MM();
+
+}
+
+/**
+ * {@inheritdoc}
+ */
+PHP_METHOD(Phalcon_Session_Adapter_Redis, gc) {
+
+
+ RETURN_BOOL(1);
+
+}
+
diff --git a/ext/phalcon/session/adapter/redis.zep.h b/ext/phalcon/session/adapter/redis.zep.h
new file mode 100644
index 00000000000..364db3eaf6b
--- /dev/null
+++ b/ext/phalcon/session/adapter/redis.zep.h
@@ -0,0 +1,44 @@
+
+extern zend_class_entry *phalcon_session_adapter_redis_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Session_Adapter_Redis);
+
+PHP_METHOD(Phalcon_Session_Adapter_Redis, getRedis);
+PHP_METHOD(Phalcon_Session_Adapter_Redis, getLifetime);
+PHP_METHOD(Phalcon_Session_Adapter_Redis, __construct);
+PHP_METHOD(Phalcon_Session_Adapter_Redis, open);
+PHP_METHOD(Phalcon_Session_Adapter_Redis, close);
+PHP_METHOD(Phalcon_Session_Adapter_Redis, read);
+PHP_METHOD(Phalcon_Session_Adapter_Redis, write);
+PHP_METHOD(Phalcon_Session_Adapter_Redis, destroy);
+PHP_METHOD(Phalcon_Session_Adapter_Redis, gc);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_redis___construct, 0, 0, 0)
+ ZEND_ARG_ARRAY_INFO(0, options, 1)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_redis_read, 0, 0, 1)
+ ZEND_ARG_INFO(0, sessionId)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_redis_write, 0, 0, 2)
+ ZEND_ARG_INFO(0, sessionId)
+ ZEND_ARG_INFO(0, data)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_session_adapter_redis_destroy, 0, 0, 0)
+ ZEND_ARG_INFO(0, sessionId)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_session_adapter_redis_method_entry) {
+ PHP_ME(Phalcon_Session_Adapter_Redis, getRedis, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, getLifetime, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, __construct, arginfo_phalcon_session_adapter_redis___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Session_Adapter_Redis, open, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, close, NULL, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, read, arginfo_phalcon_session_adapter_redis_read, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, write, arginfo_phalcon_session_adapter_redis_write, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, destroy, arginfo_phalcon_session_adapter_redis_destroy, ZEND_ACC_PUBLIC)
+ PHP_ME(Phalcon_Session_Adapter_Redis, gc, NULL, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
diff --git a/ext/phalcon/session/bag.zep.c b/ext/phalcon/session/bag.zep.c
index 41dfcef91ba..1f06cc53a86 100644
--- a/ext/phalcon/session/bag.zep.c
+++ b/ext/phalcon/session/bag.zep.c
@@ -551,7 +551,7 @@ PHP_METHOD(Phalcon_Session_Bag, getIterator) {
}
object_init_ex(return_value, zephir_get_internal_ce(SS("arrayiterator") TSRMLS_CC));
_1 = zephir_fetch_nproperty_this(this_ptr, SL("_data"), PH_NOISY_CC);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 410, _1);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 412, _1);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/tag.zep.c b/ext/phalcon/tag.zep.c
index 04e9f71bfcf..fed496f7155 100644
--- a/ext/phalcon/tag.zep.c
+++ b/ext/phalcon/tag.zep.c
@@ -869,7 +869,7 @@ PHP_METHOD(Phalcon_Tag, colorField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "color", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -899,7 +899,7 @@ PHP_METHOD(Phalcon_Tag, textField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "text", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -929,7 +929,7 @@ PHP_METHOD(Phalcon_Tag, numericField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "number", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -955,7 +955,7 @@ PHP_METHOD(Phalcon_Tag, rangeField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "range", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -985,7 +985,7 @@ PHP_METHOD(Phalcon_Tag, emailField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "email", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1015,7 +1015,7 @@ PHP_METHOD(Phalcon_Tag, dateField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "date", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1041,7 +1041,7 @@ PHP_METHOD(Phalcon_Tag, dateTimeField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "datetime", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1067,7 +1067,7 @@ PHP_METHOD(Phalcon_Tag, dateTimeLocalField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "datetime-local", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1093,7 +1093,7 @@ PHP_METHOD(Phalcon_Tag, monthField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "month", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1119,7 +1119,7 @@ PHP_METHOD(Phalcon_Tag, timeField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "time", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1145,7 +1145,7 @@ PHP_METHOD(Phalcon_Tag, weekField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "week", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1175,7 +1175,7 @@ PHP_METHOD(Phalcon_Tag, passwordField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "password", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1205,7 +1205,7 @@ PHP_METHOD(Phalcon_Tag, hiddenField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "hidden", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1235,7 +1235,7 @@ PHP_METHOD(Phalcon_Tag, fileField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "file", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1261,7 +1261,7 @@ PHP_METHOD(Phalcon_Tag, searchField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "search", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1287,7 +1287,7 @@ PHP_METHOD(Phalcon_Tag, telField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "tel", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1313,7 +1313,7 @@ PHP_METHOD(Phalcon_Tag, urlField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "url", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1343,7 +1343,7 @@ PHP_METHOD(Phalcon_Tag, checkField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "checkbox", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 412, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 414, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1378,7 +1378,7 @@ PHP_METHOD(Phalcon_Tag, radioField) {
ZEPHIR_INIT_VAR(_1);
ZVAL_STRING(_1, "radio", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 412, _1, parameters);
+ ZEPHIR_RETURN_CALL_SELF("_inputfieldchecked", &_0, 414, _1, parameters);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1415,7 +1415,7 @@ PHP_METHOD(Phalcon_Tag, imageInput) {
ZVAL_STRING(_1, "image", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_2);
ZVAL_BOOL(_2, 1);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters, _2);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters, _2);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1452,7 +1452,7 @@ PHP_METHOD(Phalcon_Tag, submitButton) {
ZVAL_STRING(_1, "submit", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_INIT_VAR(_2);
ZVAL_BOOL(_2, 1);
- ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 411, _1, parameters, _2);
+ ZEPHIR_RETURN_CALL_SELF("_inputfield", &_0, 413, _1, parameters, _2);
zephir_check_temp_parameter(_1);
zephir_check_call_status();
RETURN_MM();
@@ -1484,7 +1484,7 @@ PHP_METHOD(Phalcon_Tag, selectStatic) {
}
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 205, parameters, data);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, parameters, data);
zephir_check_call_status();
RETURN_MM();
@@ -1524,7 +1524,7 @@ PHP_METHOD(Phalcon_Tag, select) {
}
- ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 205, parameters, data);
+ ZEPHIR_RETURN_CALL_CE_STATIC(phalcon_tag_select_ce, "selectfield", &_0, 206, parameters, data);
zephir_check_call_status();
RETURN_MM();
@@ -2139,7 +2139,7 @@ PHP_METHOD(Phalcon_Tag, image) {
* @param string separator
* @param boolean lowercase
* @param mixed replace
- * @return text
+ * @return string
*/
PHP_METHOD(Phalcon_Tag, friendlyTitle) {
@@ -2180,13 +2180,13 @@ PHP_METHOD(Phalcon_Tag, friendlyTitle) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_VAR(_3);
ZVAL_STRING(&_3, "en_US.UTF-8", 0);
- ZEPHIR_CALL_FUNCTION(&locale, "setlocale", &_4, 413, &_0, &_3);
+ ZEPHIR_CALL_FUNCTION(&locale, "setlocale", &_4, 415, &_0, &_3);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "UTF-8", 0);
ZEPHIR_SINIT_NVAR(_3);
ZVAL_STRING(&_3, "ASCII//TRANSLIT", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "iconv", NULL, 376, &_0, &_3, text);
+ ZEPHIR_CALL_FUNCTION(&_5, "iconv", NULL, 378, &_0, &_3, text);
zephir_check_call_status();
zephir_get_strval(text, _5);
}
@@ -2249,7 +2249,7 @@ PHP_METHOD(Phalcon_Tag, friendlyTitle) {
if (zephir_is_true(_5)) {
ZEPHIR_SINIT_NVAR(_3);
ZVAL_LONG(&_3, 0);
- ZEPHIR_CALL_FUNCTION(NULL, "setlocale", &_4, 413, &_3, locale);
+ ZEPHIR_CALL_FUNCTION(NULL, "setlocale", &_4, 415, &_3, locale);
zephir_check_call_status();
}
RETURN_CCTOR(friendly);
diff --git a/ext/phalcon/tag/select.zep.c b/ext/phalcon/tag/select.zep.c
index 09574294bec..0c2cea8b4e6 100644
--- a/ext/phalcon/tag/select.zep.c
+++ b/ext/phalcon/tag/select.zep.c
@@ -151,7 +151,7 @@ PHP_METHOD(Phalcon_Tag_Select, selectField) {
ZEPHIR_GET_CONSTANT(_6, "PHP_EOL");
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SV(_7, "", _6);
- ZEPHIR_CALL_SELF(&_8, "_optionsfromresultset", &_9, 414, options, using, value, _7);
+ ZEPHIR_CALL_SELF(&_8, "_optionsfromresultset", &_9, 416, options, using, value, _7);
zephir_check_call_status();
zephir_concat_self(&code, _8 TSRMLS_CC);
} else {
@@ -160,7 +160,7 @@ PHP_METHOD(Phalcon_Tag_Select, selectField) {
ZEPHIR_GET_CONSTANT(_6, "PHP_EOL");
ZEPHIR_INIT_LNVAR(_7);
ZEPHIR_CONCAT_SV(_7, "", _6);
- ZEPHIR_CALL_SELF(&_8, "_optionsfromarray", &_10, 415, options, value, _7);
+ ZEPHIR_CALL_SELF(&_8, "_optionsfromarray", &_10, 417, options, value, _7);
zephir_check_call_status();
zephir_concat_self(&code, _8 TSRMLS_CC);
} else {
@@ -313,12 +313,12 @@ PHP_METHOD(Phalcon_Tag_Select, _optionsFromArray) {
) {
ZEPHIR_GET_HMKEY(optionValue, _1, _0);
ZEPHIR_GET_HVALUE(optionText, _2);
- ZEPHIR_CALL_FUNCTION(&escaped, "htmlspecialchars", &_3, 180, optionValue);
+ ZEPHIR_CALL_FUNCTION(&escaped, "htmlspecialchars", &_3, 181, optionValue);
zephir_check_call_status();
if (Z_TYPE_P(optionText) == IS_ARRAY) {
ZEPHIR_INIT_NVAR(_4);
ZEPHIR_GET_CONSTANT(_4, "PHP_EOL");
- ZEPHIR_CALL_SELF(&_5, "_optionsfromarray", &_6, 415, optionText, value, closeOption);
+ ZEPHIR_CALL_SELF(&_5, "_optionsfromarray", &_6, 417, optionText, value, closeOption);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_7);
ZEPHIR_GET_CONSTANT(_7, "PHP_EOL");
diff --git a/ext/phalcon/text.zep.c b/ext/phalcon/text.zep.c
index b2d7ec6d311..9385cabfdb2 100644
--- a/ext/phalcon/text.zep.c
+++ b/ext/phalcon/text.zep.c
@@ -126,24 +126,21 @@ PHP_METHOD(Phalcon_Text, uncamelize) {
*/
PHP_METHOD(Phalcon_Text, increment) {
- zval *str_param = NULL, *separator = NULL, *parts, *number = NULL, *_0;
- zval *str = NULL;
+ zval *str_param = NULL, *separator_param = NULL, *parts, *number = NULL, *_0;
+ zval *str = NULL, *separator = NULL;
ZEPHIR_MM_GROW();
- zephir_fetch_params(1, 1, 1, &str_param, &separator);
+ zephir_fetch_params(1, 1, 1, &str_param, &separator_param);
zephir_get_strval(str, str_param);
- if (!separator) {
- ZEPHIR_CPY_WRT(separator, ZEPHIR_GLOBAL(global_null));
+ if (!separator_param) {
+ ZEPHIR_INIT_VAR(separator);
+ ZVAL_STRING(separator, "_", 1);
} else {
- ZEPHIR_SEPARATE_PARAM(separator);
+ zephir_get_strval(separator, separator_param);
}
- if (Z_TYPE_P(separator) == IS_NULL) {
- ZEPHIR_INIT_NVAR(separator);
- ZVAL_STRING(separator, "_", 1);
- }
ZEPHIR_INIT_VAR(parts);
zephir_fast_explode(parts, separator, str, LONG_MAX TSRMLS_CC);
ZEPHIR_OBS_VAR(number);
@@ -154,7 +151,7 @@ PHP_METHOD(Phalcon_Text, increment) {
ZEPHIR_INIT_NVAR(number);
ZVAL_LONG(number, 1);
}
- zephir_array_fetch_long(&_0, parts, 0, PH_NOISY | PH_READONLY, "phalcon/text.zep", 88 TSRMLS_CC);
+ zephir_array_fetch_long(&_0, parts, 0, PH_NOISY | PH_READONLY, "phalcon/text.zep", 84 TSRMLS_CC);
ZEPHIR_CONCAT_VVV(return_value, _0, separator, number);
RETURN_MM();
@@ -197,13 +194,13 @@ PHP_METHOD(Phalcon_Text, random) {
ZVAL_STRING(&_0, "a", 0);
ZEPHIR_SINIT_VAR(_1);
ZVAL_STRING(&_1, "z", 0);
- ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "A", 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "Z", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_INIT_VAR(pool);
zephir_fast_array_merge(pool, &(_2), &(_4) TSRMLS_CC);
@@ -214,13 +211,13 @@ PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 9);
- ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "a", 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "f", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_INIT_NVAR(pool);
zephir_fast_array_merge(pool, &(_2), &(_4) TSRMLS_CC);
@@ -231,7 +228,7 @@ PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 9);
- ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
break;
}
@@ -240,7 +237,7 @@ PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 1);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 9);
- ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&pool, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
break;
}
@@ -248,21 +245,21 @@ PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, 9);
- ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_2, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "a", 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "z", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_4, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "A", 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_STRING(&_1, "Z", 0);
- ZEPHIR_CALL_FUNCTION(&_5, "range", &_3, 416, &_0, &_1);
+ ZEPHIR_CALL_FUNCTION(&_5, "range", &_3, 418, &_0, &_1);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&pool, "array_merge", &_6, 417, _2, _4, _5);
+ ZEPHIR_CALL_FUNCTION(&pool, "array_merge", &_6, 419, _2, _4, _5);
zephir_check_call_status();
break;
} while(0);
@@ -276,7 +273,7 @@ PHP_METHOD(Phalcon_Text, random) {
ZVAL_LONG(&_0, 0);
ZEPHIR_SINIT_NVAR(_1);
ZVAL_LONG(&_1, end);
- zephir_array_fetch_long(&_7, pool, zephir_mt_rand(zephir_get_intval(&_0), zephir_get_intval(&_1) TSRMLS_CC), PH_NOISY | PH_READONLY, "phalcon/text.zep", 130 TSRMLS_CC);
+ zephir_array_fetch_long(&_7, pool, zephir_mt_rand(zephir_get_intval(&_0), zephir_get_intval(&_1) TSRMLS_CC), PH_NOISY | PH_READONLY, "phalcon/text.zep", 126 TSRMLS_CC);
zephir_concat_self(&str, _7 TSRMLS_CC);
}
RETURN_CCTOR(str);
@@ -391,7 +388,7 @@ PHP_METHOD(Phalcon_Text, lower) {
if ((zephir_function_exists_ex(SS("mb_strtolower") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 193, str, encoding);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_strtolower", NULL, 194, str, encoding);
zephir_check_call_status();
RETURN_MM();
}
@@ -446,7 +443,7 @@ PHP_METHOD(Phalcon_Text, upper) {
if ((zephir_function_exists_ex(SS("mb_strtoupper") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 194, str, encoding);
+ ZEPHIR_RETURN_CALL_FUNCTION("mb_strtoupper", NULL, 195, str, encoding);
zephir_check_call_status();
RETURN_MM();
}
@@ -512,26 +509,26 @@ PHP_METHOD(Phalcon_Text, concat) {
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, 0);
- ZEPHIR_CALL_FUNCTION(&separator, "func_get_arg", &_1, 418, &_0);
+ ZEPHIR_CALL_FUNCTION(&separator, "func_get_arg", &_1, 420, &_0);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, 1);
- ZEPHIR_CALL_FUNCTION(&a, "func_get_arg", &_1, 418, &_0);
+ ZEPHIR_CALL_FUNCTION(&a, "func_get_arg", &_1, 420, &_0);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, 2);
- ZEPHIR_CALL_FUNCTION(&b, "func_get_arg", &_1, 418, &_0);
+ ZEPHIR_CALL_FUNCTION(&b, "func_get_arg", &_1, 420, &_0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_2, "func_num_args", NULL, 419);
+ ZEPHIR_CALL_FUNCTION(&_2, "func_num_args", NULL, 421);
zephir_check_call_status();
if (ZEPHIR_GT_LONG(_2, 3)) {
- ZEPHIR_CALL_FUNCTION(&_3, "func_get_args", NULL, 165);
+ ZEPHIR_CALL_FUNCTION(&_3, "func_get_args", NULL, 166);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, 3);
- ZEPHIR_CALL_FUNCTION(&_4, "array_slice", NULL, 377, _3, &_0);
+ ZEPHIR_CALL_FUNCTION(&_4, "array_slice", NULL, 379, _3, &_0);
zephir_check_call_status();
- zephir_is_iterable(_4, &_6, &_5, 0, 0, "phalcon/text.zep", 246);
+ zephir_is_iterable(_4, &_6, &_5, 0, 0, "phalcon/text.zep", 242);
for (
; zephir_hash_get_current_data_ex(_6, (void**) &_7, &_5) == SUCCESS
; zephir_hash_move_forward_ex(_6, &_5)
@@ -635,36 +632,36 @@ PHP_METHOD(Phalcon_Text, dynamic) {
}
- ZEPHIR_CALL_FUNCTION(&_0, "substr_count", &_1, 420, text, leftDelimiter);
+ ZEPHIR_CALL_FUNCTION(&_0, "substr_count", &_1, 422, text, leftDelimiter);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_2, "substr_count", &_1, 420, text, rightDelimiter);
+ ZEPHIR_CALL_FUNCTION(&_2, "substr_count", &_1, 422, text, rightDelimiter);
zephir_check_call_status();
if (!ZEPHIR_IS_IDENTICAL(_0, _2)) {
ZEPHIR_INIT_VAR(_3);
object_init_ex(_3, spl_ce_RuntimeException);
ZEPHIR_INIT_VAR(_4);
ZEPHIR_CONCAT_SVS(_4, "Syntax error in string \"", text, "\"");
- ZEPHIR_CALL_METHOD(NULL, _3, "__construct", NULL, 421, _4);
+ ZEPHIR_CALL_METHOD(NULL, _3, "__construct", NULL, 423, _4);
zephir_check_call_status();
- zephir_throw_exception_debug(_3, "phalcon/text.zep", 265 TSRMLS_CC);
+ zephir_throw_exception_debug(_3, "phalcon/text.zep", 261 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
- ZEPHIR_CALL_FUNCTION(&ld_s, "preg_quote", &_5, 422, leftDelimiter);
+ ZEPHIR_CALL_FUNCTION(&ld_s, "preg_quote", &_5, 424, leftDelimiter);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&rd_s, "preg_quote", &_5, 422, rightDelimiter);
+ ZEPHIR_CALL_FUNCTION(&rd_s, "preg_quote", &_5, 424, rightDelimiter);
zephir_check_call_status();
ZEPHIR_INIT_VAR(pattern);
ZEPHIR_CONCAT_SVSVVSVS(pattern, "/", ld_s, "([^", ld_s, rd_s, "]+)", rd_s, "/");
ZEPHIR_CPY_WRT(result, text);
while (1) {
- if (!(zephir_memnstr(result, leftDelimiter, "phalcon/text.zep", 273))) {
+ if (!(zephir_memnstr(result, leftDelimiter, "phalcon/text.zep", 269))) {
break;
}
ZEPHIR_INIT_NVAR(_3);
ZEPHIR_INIT_NVAR(_3);
zephir_create_closure_ex(_3, NULL, phalcon_0__closure_ce, SS("__invoke") TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_6, "preg_replace_callback", &_7, 423, pattern, _3, result);
+ ZEPHIR_CALL_FUNCTION(&_6, "preg_replace_callback", &_7, 425, pattern, _3, result);
zephir_check_call_status();
ZEPHIR_CPY_WRT(result, _6);
}
diff --git a/ext/phalcon/translate/adapter.zep.c b/ext/phalcon/translate/adapter.zep.c
index 63f3fc71cc0..e9b995e8ca4 100644
--- a/ext/phalcon/translate/adapter.zep.c
+++ b/ext/phalcon/translate/adapter.zep.c
@@ -12,14 +12,13 @@
#include
#include "kernel/main.h"
+#include "kernel/array.h"
+#include "kernel/memory.h"
#include "kernel/fcall.h"
#include "ext/spl/spl_exceptions.h"
#include "kernel/exception.h"
+#include "kernel/object.h"
#include "kernel/operators.h"
-#include "kernel/memory.h"
-#include "kernel/hash.h"
-#include "kernel/string.h"
-#include "kernel/concat.h"
/**
@@ -31,10 +30,56 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter) {
ZEPHIR_REGISTER_CLASS(Phalcon\\Translate, Adapter, phalcon, translate_adapter, phalcon_translate_adapter_method_entry, ZEND_ACC_EXPLICIT_ABSTRACT_CLASS);
+ /**
+ * @var Phalcon\Translate\InterpolatorInterface
+ */
+ zend_declare_property_null(phalcon_translate_adapter_ce, SL("_interpolator"), ZEND_ACC_PROTECTED TSRMLS_CC);
+
return SUCCESS;
}
+PHP_METHOD(Phalcon_Translate_Adapter, __construct) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *options_param = NULL, *interpolator = NULL;
+ zval *options = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 0, &options_param);
+
+ options = options_param;
+
+
+
+ ZEPHIR_OBS_VAR(interpolator);
+ if (!(zephir_array_isset_string_fetch(&interpolator, options, SS("interpolator"), 0 TSRMLS_CC))) {
+ ZEPHIR_INIT_NVAR(interpolator);
+ object_init_ex(interpolator, phalcon_translate_interpolator_associativearray_ce);
+ if (zephir_has_constructor(interpolator TSRMLS_CC)) {
+ ZEPHIR_CALL_METHOD(NULL, interpolator, "__construct", NULL, 0);
+ zephir_check_call_status();
+ }
+ }
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "setinterpolator", NULL, 0, interpolator);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+PHP_METHOD(Phalcon_Translate_Adapter, setInterpolator) {
+
+ zval *interpolator;
+
+ zephir_fetch_params(0, 1, 0, &interpolator);
+
+
+
+ zephir_update_property_this(this_ptr, SL("_interpolator"), interpolator TSRMLS_CC);
+ RETURN_THISW();
+
+}
+
/**
* Returns the translation string of the given key
*
@@ -125,7 +170,7 @@ PHP_METHOD(Phalcon_Translate_Adapter, offsetSet) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_translate_exception_ce, "Translate is an immutable ArrayAccess object", "phalcon/translate/adapter.zep", 64);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_translate_exception_ce, "Translate is an immutable ArrayAccess object", "phalcon/translate/adapter.zep", 86);
return;
}
@@ -174,7 +219,7 @@ PHP_METHOD(Phalcon_Translate_Adapter, offsetUnset) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_translate_exception_ce, "Translate is an immutable ArrayAccess object", "phalcon/translate/adapter.zep", 82);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_translate_exception_ce, "Translate is an immutable ArrayAccess object", "phalcon/translate/adapter.zep", 104);
return;
}
@@ -216,13 +261,12 @@ PHP_METHOD(Phalcon_Translate_Adapter, offsetGet) {
}
/**
- * Replaces placeholders by the values passed
+ * Replaces placeholders by the values passed
*/
PHP_METHOD(Phalcon_Translate_Adapter, replacePlaceholders) {
- HashTable *_1;
- HashPosition _0;
- zval *translation_param = NULL, *placeholders = NULL, *key = NULL, *value = NULL, **_2, *_3 = NULL, *_4 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *translation_param = NULL, *placeholders = NULL, *_0;
zval *translation = NULL;
ZEPHIR_MM_GROW();
@@ -244,24 +288,10 @@ PHP_METHOD(Phalcon_Translate_Adapter, replacePlaceholders) {
}
- if (Z_TYPE_P(placeholders) == IS_ARRAY) {
- if (zephir_fast_count_int(placeholders TSRMLS_CC)) {
- zephir_is_iterable(placeholders, &_1, &_0, 0, 0, "phalcon/translate/adapter.zep", 108);
- for (
- ; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
- ; zephir_hash_move_forward_ex(_1, &_0)
- ) {
- ZEPHIR_GET_HMKEY(key, _1, _0);
- ZEPHIR_GET_HVALUE(value, _2);
- ZEPHIR_INIT_NVAR(_3);
- ZEPHIR_INIT_LNVAR(_4);
- ZEPHIR_CONCAT_SVS(_4, "%", key, "%");
- zephir_fast_str_replace(&_3, _4, value, translation TSRMLS_CC);
- zephir_get_strval(translation, _3);
- }
- }
- }
- RETURN_CTOR(translation);
+ _0 = zephir_fetch_nproperty_this(this_ptr, SL("_interpolator"), PH_NOISY_CC);
+ ZEPHIR_RETURN_CALL_METHOD(_0, "replaceplaceholders", NULL, 0, translation, placeholders);
+ zephir_check_call_status();
+ RETURN_MM();
}
diff --git a/ext/phalcon/translate/adapter.zep.h b/ext/phalcon/translate/adapter.zep.h
index f979c8d22aa..b91a67dfd5e 100644
--- a/ext/phalcon/translate/adapter.zep.h
+++ b/ext/phalcon/translate/adapter.zep.h
@@ -3,6 +3,8 @@ extern zend_class_entry *phalcon_translate_adapter_ce;
ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter);
+PHP_METHOD(Phalcon_Translate_Adapter, __construct);
+PHP_METHOD(Phalcon_Translate_Adapter, setInterpolator);
PHP_METHOD(Phalcon_Translate_Adapter, t);
PHP_METHOD(Phalcon_Translate_Adapter, _);
PHP_METHOD(Phalcon_Translate_Adapter, offsetSet);
@@ -11,6 +13,14 @@ PHP_METHOD(Phalcon_Translate_Adapter, offsetUnset);
PHP_METHOD(Phalcon_Translate_Adapter, offsetGet);
PHP_METHOD(Phalcon_Translate_Adapter, replacePlaceholders);
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter___construct, 0, 0, 1)
+ ZEND_ARG_ARRAY_INFO(0, options, 0)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_setinterpolator, 0, 0, 1)
+ ZEND_ARG_OBJ_INFO(0, interpolator, Phalcon\\Translate\\InterpolatorInterface, 0)
+ZEND_END_ARG_INFO()
+
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_t, 0, 0, 1)
ZEND_ARG_INFO(0, translateKey)
ZEND_ARG_INFO(0, placeholders)
@@ -44,6 +54,8 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_replaceplaceholders, 0,
ZEND_END_ARG_INFO()
ZEPHIR_INIT_FUNCS(phalcon_translate_adapter_method_entry) {
+ PHP_ME(Phalcon_Translate_Adapter, __construct, arginfo_phalcon_translate_adapter___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Translate_Adapter, setInterpolator, arginfo_phalcon_translate_adapter_setinterpolator, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Translate_Adapter, t, arginfo_phalcon_translate_adapter_t, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Translate_Adapter, _, arginfo_phalcon_translate_adapter__, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Translate_Adapter, offsetSet, arginfo_phalcon_translate_adapter_offsetset, ZEND_ACC_PUBLIC)
diff --git a/ext/phalcon/translate/adapter/csv.zep.c b/ext/phalcon/translate/adapter/csv.zep.c
index 58db51f7d63..cf2107d5cb2 100644
--- a/ext/phalcon/translate/adapter/csv.zep.c
+++ b/ext/phalcon/translate/adapter/csv.zep.c
@@ -12,16 +12,16 @@
#include
#include "kernel/main.h"
+#include "kernel/fcall.h"
#include "kernel/array.h"
#include "kernel/exception.h"
#include "kernel/memory.h"
-#include "kernel/fcall.h"
+#include "ext/spl/spl_exceptions.h"
#include "kernel/concat.h"
#include "kernel/operators.h"
#include "kernel/string.h"
#include "kernel/object.h"
#include "kernel/file.h"
-#include "ext/spl/spl_exceptions.h"
/**
@@ -48,11 +48,10 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter_Csv) {
*/
PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct) {
- zend_bool _12;
- zephir_fcall_cache_entry *_9 = NULL;
int ZEPHIR_LAST_CALL_STATUS;
- zval *options_param = NULL, *data = NULL, *file = NULL, *_0, *_2, _3 = zval_used_for_init, *_4 = NULL, *_5, *_6, *_7, *_8, *_10, _11 = zval_used_for_init, *_13, *_14 = NULL;
- zval *options = NULL, *_1;
+ zephir_fcall_cache_entry *_0 = NULL;
+ zval *options_param = NULL, *_1, *_2, *_3, *_4;
+ zval *options = NULL;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 1, 0, &options_param);
@@ -61,64 +60,88 @@ PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct) {
+ ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_csv_ce, this_ptr, "__construct", &_0, 426, options);
+ zephir_check_call_status();
if (!(zephir_array_isset_string(options, SS("content")))) {
ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter 'content' is required", "phalcon/translate/adapter/csv.zep", 43);
return;
}
- ZEPHIR_INIT_VAR(_0);
- ZEPHIR_INIT_VAR(_1);
- zephir_create_array(_1, 3, 0 TSRMLS_CC);
- add_assoc_stringl_ex(_1, SS("delimiter"), SL(";"), 1);
- add_assoc_long_ex(_1, SS("length"), 0);
- add_assoc_stringl_ex(_1, SS("enclosure"), SL("\""), 1);
- zephir_fast_array_merge(_0, &(_1), &(options) TSRMLS_CC);
- ZEPHIR_CPY_WRT(options, _0);
- zephir_array_fetch_string(&_2, options, SL("content"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 52 TSRMLS_CC);
- ZEPHIR_SINIT_VAR(_3);
- ZVAL_STRING(&_3, "rb", 0);
- ZEPHIR_CALL_FUNCTION(&file, "fopen", NULL, 291, _2, &_3);
+ zephir_array_fetch_string(&_1, options, SL("content"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 46 TSRMLS_CC);
+ ZEPHIR_INIT_VAR(_2);
+ ZVAL_LONG(_2, 0);
+ ZEPHIR_INIT_VAR(_3);
+ ZVAL_STRING(_3, ";", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_INIT_VAR(_4);
+ ZVAL_STRING(_4, "\"", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(NULL, this_ptr, "_load", NULL, 427, _1, _2, _3, _4);
+ zephir_check_temp_parameter(_3);
+ zephir_check_temp_parameter(_4);
+ zephir_check_call_status();
+ ZEPHIR_MM_RESTORE();
+
+}
+
+/**
+ * Load translates from file
+ *
+ * @param string file
+ * @param int length
+ * @param string delimiter
+ * @param string enclosure
+ */
+PHP_METHOD(Phalcon_Translate_Adapter_Csv, _load) {
+
+ zend_bool _6;
+ zephir_fcall_cache_entry *_3 = NULL;
+ int ZEPHIR_LAST_CALL_STATUS;
+ zval *file, *length, *delimiter, *enclosure, *data = NULL, *fileHandler = NULL, _0 = zval_used_for_init, *_1 = NULL, *_2, *_4, _5 = zval_used_for_init, *_7, *_8 = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 4, 0, &file, &length, &delimiter, &enclosure);
+
+
+
+ ZEPHIR_SINIT_VAR(_0);
+ ZVAL_STRING(&_0, "rb", 0);
+ ZEPHIR_CALL_FUNCTION(&fileHandler, "fopen", NULL, 292, file, &_0);
zephir_check_call_status();
- if (Z_TYPE_P(file) != IS_RESOURCE) {
- ZEPHIR_INIT_VAR(_4);
- object_init_ex(_4, phalcon_translate_exception_ce);
- zephir_array_fetch_string(&_5, options, SL("content"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 55 TSRMLS_CC);
- ZEPHIR_INIT_VAR(_6);
- ZEPHIR_CONCAT_SVS(_6, "Error opening translation file '", _5, "'");
- ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 9, _6);
+ if (Z_TYPE_P(fileHandler) != IS_RESOURCE) {
+ ZEPHIR_INIT_VAR(_1);
+ object_init_ex(_1, phalcon_translate_exception_ce);
+ ZEPHIR_INIT_VAR(_2);
+ ZEPHIR_CONCAT_SVS(_2, "Error opening translation file '", file, "'");
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 9, _2);
zephir_check_call_status();
- zephir_throw_exception_debug(_4, "phalcon/translate/adapter/csv.zep", 55 TSRMLS_CC);
+ zephir_throw_exception_debug(_1, "phalcon/translate/adapter/csv.zep", 64 TSRMLS_CC);
ZEPHIR_MM_RESTORE();
return;
}
while (1) {
- zephir_array_fetch_string(&_5, options, SL("length"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 60 TSRMLS_CC);
- zephir_array_fetch_string(&_7, options, SL("delimiter"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 60 TSRMLS_CC);
- zephir_array_fetch_string(&_8, options, SL("enclosure"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 60 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&data, "fgetcsv", &_9, 424, file, _5, _7, _8);
+ ZEPHIR_CALL_FUNCTION(&data, "fgetcsv", &_3, 428, fileHandler, length, delimiter, enclosure);
zephir_check_call_status();
if (ZEPHIR_IS_FALSE_IDENTICAL(data)) {
break;
}
- zephir_array_fetch_long(&_10, data, 0, PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 65 TSRMLS_CC);
- ZEPHIR_SINIT_NVAR(_3);
- ZVAL_LONG(&_3, 0);
- ZEPHIR_SINIT_NVAR(_11);
- ZVAL_LONG(&_11, 1);
- ZEPHIR_INIT_NVAR(_4);
- zephir_substr(_4, _10, 0 , 1 , 0);
- _12 = ZEPHIR_IS_STRING_IDENTICAL(_4, "#");
- if (!(_12)) {
- _12 = !(zephir_array_isset_long(data, 1));
+ zephir_array_fetch_long(&_4, data, 0, PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 74 TSRMLS_CC);
+ ZEPHIR_SINIT_NVAR(_0);
+ ZVAL_LONG(&_0, 0);
+ ZEPHIR_SINIT_NVAR(_5);
+ ZVAL_LONG(&_5, 1);
+ ZEPHIR_INIT_NVAR(_1);
+ zephir_substr(_1, _4, 0 , 1 , 0);
+ _6 = ZEPHIR_IS_STRING_IDENTICAL(_1, "#");
+ if (!(_6)) {
+ _6 = !(zephir_array_isset_long(data, 1));
}
- if (_12) {
+ if (_6) {
continue;
}
- zephir_array_fetch_long(&_13, data, 1, PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 69 TSRMLS_CC);
- ZEPHIR_OBS_NVAR(_14);
- zephir_array_fetch_long(&_14, data, 0, PH_NOISY, "phalcon/translate/adapter/csv.zep", 69 TSRMLS_CC);
- zephir_update_property_array(this_ptr, SL("_translate"), _14, _13 TSRMLS_CC);
+ zephir_array_fetch_long(&_7, data, 1, PH_NOISY | PH_READONLY, "phalcon/translate/adapter/csv.zep", 78 TSRMLS_CC);
+ ZEPHIR_OBS_NVAR(_8);
+ zephir_array_fetch_long(&_8, data, 0, PH_NOISY, "phalcon/translate/adapter/csv.zep", 78 TSRMLS_CC);
+ zephir_update_property_array(this_ptr, SL("_translate"), _8, _7 TSRMLS_CC);
}
- zephir_fclose(file TSRMLS_CC);
+ zephir_fclose(fileHandler TSRMLS_CC);
ZEPHIR_MM_RESTORE();
}
diff --git a/ext/phalcon/translate/adapter/csv.zep.h b/ext/phalcon/translate/adapter/csv.zep.h
index 3ceba7c1bd6..9bd3de4c46d 100644
--- a/ext/phalcon/translate/adapter/csv.zep.h
+++ b/ext/phalcon/translate/adapter/csv.zep.h
@@ -4,6 +4,7 @@ extern zend_class_entry *phalcon_translate_adapter_csv_ce;
ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter_Csv);
PHP_METHOD(Phalcon_Translate_Adapter_Csv, __construct);
+PHP_METHOD(Phalcon_Translate_Adapter_Csv, _load);
PHP_METHOD(Phalcon_Translate_Adapter_Csv, query);
PHP_METHOD(Phalcon_Translate_Adapter_Csv, exists);
static zend_object_value zephir_init_properties_Phalcon_Translate_Adapter_Csv(zend_class_entry *class_type TSRMLS_DC);
@@ -12,6 +13,13 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_csv___construct, 0, 0,
ZEND_ARG_ARRAY_INFO(0, options, 0)
ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_csv__load, 0, 0, 4)
+ ZEND_ARG_INFO(0, file)
+ ZEND_ARG_INFO(0, length)
+ ZEND_ARG_INFO(0, delimiter)
+ ZEND_ARG_INFO(0, enclosure)
+ZEND_END_ARG_INFO()
+
ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_adapter_csv_query, 0, 0, 1)
ZEND_ARG_INFO(0, index)
ZEND_ARG_INFO(0, placeholders)
@@ -23,6 +31,7 @@ ZEND_END_ARG_INFO()
ZEPHIR_INIT_FUNCS(phalcon_translate_adapter_csv_method_entry) {
PHP_ME(Phalcon_Translate_Adapter_Csv, __construct, arginfo_phalcon_translate_adapter_csv___construct, ZEND_ACC_PUBLIC|ZEND_ACC_CTOR)
+ PHP_ME(Phalcon_Translate_Adapter_Csv, _load, arginfo_phalcon_translate_adapter_csv__load, ZEND_ACC_PRIVATE)
PHP_ME(Phalcon_Translate_Adapter_Csv, query, arginfo_phalcon_translate_adapter_csv_query, ZEND_ACC_PUBLIC)
PHP_ME(Phalcon_Translate_Adapter_Csv, exists, arginfo_phalcon_translate_adapter_csv_exists, ZEND_ACC_PUBLIC)
PHP_FE_END
diff --git a/ext/phalcon/translate/adapter/gettext.zep.c b/ext/phalcon/translate/adapter/gettext.zep.c
index 0d94c3cd9bb..737cd1872ea 100644
--- a/ext/phalcon/translate/adapter/gettext.zep.c
+++ b/ext/phalcon/translate/adapter/gettext.zep.c
@@ -65,6 +65,7 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter_Gettext) {
PHP_METHOD(Phalcon_Translate_Adapter_Gettext, __construct) {
int ZEPHIR_LAST_CALL_STATUS;
+ zephir_fcall_cache_entry *_0 = NULL;
zval *options_param = NULL;
zval *options = NULL;
@@ -75,6 +76,8 @@ PHP_METHOD(Phalcon_Translate_Adapter_Gettext, __construct) {
+ ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_gettext_ce, this_ptr, "__construct", &_0, 426, options);
+ zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, this_ptr, "prepareoptions", NULL, 0, options);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
@@ -114,22 +117,22 @@ PHP_METHOD(Phalcon_Translate_Adapter_Gettext, query) {
}
- ZEPHIR_CALL_FUNCTION(&_0, "func_num_args", NULL, 419);
+ ZEPHIR_CALL_FUNCTION(&_0, "func_num_args", NULL, 421);
zephir_check_call_status();
if (ZEPHIR_GT_LONG(_0, 2)) {
ZEPHIR_SINIT_VAR(_1);
ZVAL_LONG(&_1, 2);
- ZEPHIR_CALL_FUNCTION(&domain, "func_get_arg", NULL, 418, &_1);
+ ZEPHIR_CALL_FUNCTION(&domain, "func_get_arg", NULL, 420, &_1);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(domain);
ZVAL_NULL(domain);
}
if (!(zephir_is_true(domain))) {
- ZEPHIR_CALL_FUNCTION(&translation, "gettext", NULL, 425, index);
+ ZEPHIR_CALL_FUNCTION(&translation, "gettext", NULL, 429, index);
zephir_check_call_status();
} else {
- ZEPHIR_CALL_FUNCTION(&translation, "dgettext", NULL, 426, domain, index);
+ ZEPHIR_CALL_FUNCTION(&translation, "dgettext", NULL, 430, domain, index);
zephir_check_call_status();
}
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "replaceplaceholders", NULL, 0, translation, placeholders);
@@ -242,12 +245,12 @@ PHP_METHOD(Phalcon_Translate_Adapter_Gettext, nquery) {
if (!(domain && Z_STRLEN_P(domain))) {
ZEPHIR_SINIT_VAR(_0);
ZVAL_LONG(&_0, count);
- ZEPHIR_CALL_FUNCTION(&translation, "ngettext", NULL, 427, msgid1, msgid2, &_0);
+ ZEPHIR_CALL_FUNCTION(&translation, "ngettext", NULL, 431, msgid1, msgid2, &_0);
zephir_check_call_status();
} else {
ZEPHIR_SINIT_NVAR(_0);
ZVAL_LONG(&_0, count);
- ZEPHIR_CALL_FUNCTION(&translation, "dngettext", NULL, 428, domain, msgid1, msgid2, &_0);
+ ZEPHIR_CALL_FUNCTION(&translation, "dngettext", NULL, 432, domain, msgid1, msgid2, &_0);
zephir_check_call_status();
}
ZEPHIR_RETURN_CALL_METHOD(this_ptr, "replaceplaceholders", NULL, 0, translation, placeholders);
@@ -287,7 +290,7 @@ PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setDomain) {
}
- ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 429, domain);
+ ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 433, domain);
zephir_check_call_status();
RETURN_MM();
@@ -307,7 +310,7 @@ PHP_METHOD(Phalcon_Translate_Adapter_Gettext, resetDomain) {
ZEPHIR_CALL_METHOD(&_0, this_ptr, "getdefaultdomain", NULL, 0);
zephir_check_call_status();
- ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 429, _0);
+ ZEPHIR_RETURN_CALL_FUNCTION("textdomain", NULL, 433, _0);
zephir_check_call_status();
RETURN_MM();
@@ -371,21 +374,21 @@ PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setDirectory) {
zephir_update_property_this(this_ptr, SL("_directory"), directory TSRMLS_CC);
if (Z_TYPE_P(directory) == IS_ARRAY) {
if (zephir_fast_count_int(directory TSRMLS_CC)) {
- zephir_is_iterable(directory, &_1, &_0, 0, 0, "phalcon/translate/adapter/gettext.zep", 180);
+ zephir_is_iterable(directory, &_1, &_0, 0, 0, "phalcon/translate/adapter/gettext.zep", 181);
for (
; zephir_hash_get_current_data_ex(_1, (void**) &_2, &_0) == SUCCESS
; zephir_hash_move_forward_ex(_1, &_0)
) {
ZEPHIR_GET_HMKEY(key, _1, _0);
ZEPHIR_GET_HVALUE(value, _2);
- ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 430, key, value);
+ ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 434, key, value);
zephir_check_call_status();
}
}
} else {
ZEPHIR_CALL_METHOD(&_4, this_ptr, "getdefaultdomain", NULL, 0);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 430, _4, directory);
+ ZEPHIR_CALL_FUNCTION(NULL, "bindtextdomain", &_3, 434, _4, directory);
zephir_check_call_status();
}
ZEPHIR_MM_RESTORE();
@@ -434,7 +437,7 @@ PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setLocale) {
ZEPHIR_INIT_VAR(_0);
- ZEPHIR_CALL_FUNCTION(&_1, "func_get_args", NULL, 165);
+ ZEPHIR_CALL_FUNCTION(&_1, "func_get_args", NULL, 166);
zephir_check_call_status();
ZEPHIR_SINIT_VAR(_2);
ZVAL_STRING(&_2, "setlocale", 0);
@@ -447,12 +450,12 @@ PHP_METHOD(Phalcon_Translate_Adapter_Gettext, setLocale) {
_3 = zephir_fetch_nproperty_this(this_ptr, SL("_locale"), PH_NOISY_CC);
ZEPHIR_INIT_VAR(_4);
ZEPHIR_CONCAT_SV(_4, "LC_ALL=", _3);
- ZEPHIR_CALL_FUNCTION(NULL, "putenv", NULL, 431, _4);
+ ZEPHIR_CALL_FUNCTION(NULL, "putenv", NULL, 435, _4);
zephir_check_call_status();
_5 = zephir_fetch_nproperty_this(this_ptr, SL("_locale"), PH_NOISY_CC);
ZEPHIR_SINIT_VAR(_6);
ZVAL_LONG(&_6, 0);
- ZEPHIR_CALL_FUNCTION(NULL, "setlocale", NULL, 413, &_6, _5);
+ ZEPHIR_CALL_FUNCTION(NULL, "setlocale", NULL, 415, &_6, _5);
zephir_check_call_status();
RETURN_MM_MEMBER(this_ptr, "_locale");
@@ -495,11 +498,11 @@ PHP_METHOD(Phalcon_Translate_Adapter_Gettext, prepareOptions) {
if (!(zephir_array_isset_string(options, SS("locale")))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter \"locale\" is required", "phalcon/translate/adapter/gettext.zep", 230);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter \"locale\" is required", "phalcon/translate/adapter/gettext.zep", 231);
return;
}
if (!(zephir_array_isset_string(options, SS("directory")))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter \"directory\" is required", "phalcon/translate/adapter/gettext.zep", 234);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Parameter \"directory\" is required", "phalcon/translate/adapter/gettext.zep", 235);
return;
}
ZEPHIR_INIT_VAR(_0);
@@ -507,17 +510,17 @@ PHP_METHOD(Phalcon_Translate_Adapter_Gettext, prepareOptions) {
zephir_check_call_status();
zephir_fast_array_merge(_0, &(_1), &(options) TSRMLS_CC);
ZEPHIR_CPY_WRT(options, _0);
- zephir_array_fetch_string(&_2, options, SL("category"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 239 TSRMLS_CC);
- zephir_array_fetch_string(&_3, options, SL("locale"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 239 TSRMLS_CC);
+ zephir_array_fetch_string(&_2, options, SL("category"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 240 TSRMLS_CC);
+ zephir_array_fetch_string(&_3, options, SL("locale"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 240 TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "setlocale", NULL, 0, _2, _3);
zephir_check_call_status();
- zephir_array_fetch_string(&_4, options, SL("defaultDomain"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 240 TSRMLS_CC);
+ zephir_array_fetch_string(&_4, options, SL("defaultDomain"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 241 TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "setdefaultdomain", NULL, 0, _4);
zephir_check_call_status();
- zephir_array_fetch_string(&_5, options, SL("directory"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 241 TSRMLS_CC);
+ zephir_array_fetch_string(&_5, options, SL("directory"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 242 TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "setdirectory", NULL, 0, _5);
zephir_check_call_status();
- zephir_array_fetch_string(&_6, options, SL("defaultDomain"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 242 TSRMLS_CC);
+ zephir_array_fetch_string(&_6, options, SL("defaultDomain"), PH_NOISY | PH_READONLY, "phalcon/translate/adapter/gettext.zep", 243 TSRMLS_CC);
ZEPHIR_CALL_METHOD(NULL, this_ptr, "setdomain", NULL, 0, _6);
zephir_check_call_status();
ZEPHIR_MM_RESTORE();
diff --git a/ext/phalcon/translate/adapter/nativearray.zep.c b/ext/phalcon/translate/adapter/nativearray.zep.c
index b51cc68c1e8..6745ed198df 100644
--- a/ext/phalcon/translate/adapter/nativearray.zep.c
+++ b/ext/phalcon/translate/adapter/nativearray.zep.c
@@ -12,12 +12,12 @@
#include
#include "kernel/main.h"
+#include "kernel/fcall.h"
#include "kernel/array.h"
#include "kernel/memory.h"
#include "kernel/exception.h"
#include "kernel/object.h"
#include "ext/spl/spl_exceptions.h"
-#include "kernel/fcall.h"
#include "kernel/operators.h"
@@ -43,6 +43,8 @@ ZEPHIR_INIT_CLASS(Phalcon_Translate_Adapter_NativeArray) {
*/
PHP_METHOD(Phalcon_Translate_Adapter_NativeArray, __construct) {
+ int ZEPHIR_LAST_CALL_STATUS;
+ zephir_fcall_cache_entry *_0 = NULL;
zval *options_param = NULL, *data;
zval *options = NULL;
@@ -53,13 +55,15 @@ PHP_METHOD(Phalcon_Translate_Adapter_NativeArray, __construct) {
+ ZEPHIR_CALL_PARENT(NULL, phalcon_translate_adapter_nativearray_ce, this_ptr, "__construct", &_0, 426, options);
+ zephir_check_call_status();
ZEPHIR_OBS_VAR(data);
if (!(zephir_array_isset_string_fetch(&data, options, SS("content"), 0 TSRMLS_CC))) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Translation content was not provided", "phalcon/translate/adapter/nativearray.zep", 44);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Translation content was not provided", "phalcon/translate/adapter/nativearray.zep", 46);
return;
}
if (Z_TYPE_P(data) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Translation data must be an array", "phalcon/translate/adapter/nativearray.zep", 48);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_translate_exception_ce, "Translation data must be an array", "phalcon/translate/adapter/nativearray.zep", 50);
return;
}
zephir_update_property_this(this_ptr, SL("_translate"), data TSRMLS_CC);
diff --git a/ext/phalcon/translate/interpolator/associativearray.zep.c b/ext/phalcon/translate/interpolator/associativearray.zep.c
new file mode 100644
index 00000000000..bf1c739ed94
--- /dev/null
+++ b/ext/phalcon/translate/interpolator/associativearray.zep.c
@@ -0,0 +1,85 @@
+
+#ifdef HAVE_CONFIG_H
+#include "../../../ext_config.h"
+#endif
+
+#include
+#include "../../../php_ext.h"
+#include "../../../ext.h"
+
+#include
+#include
+#include
+
+#include "kernel/main.h"
+#include "kernel/hash.h"
+#include "kernel/memory.h"
+#include "kernel/string.h"
+#include "kernel/concat.h"
+#include "kernel/operators.h"
+#include "ext/spl/spl_exceptions.h"
+#include "kernel/exception.h"
+
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_Interpolator_AssociativeArray) {
+
+ ZEPHIR_REGISTER_CLASS(Phalcon\\Translate\\Interpolator, AssociativeArray, phalcon, translate_interpolator_associativearray, phalcon_translate_interpolator_associativearray_method_entry, 0);
+
+ zend_class_implements(phalcon_translate_interpolator_associativearray_ce TSRMLS_CC, 1, phalcon_translate_interpolatorinterface_ce);
+ return SUCCESS;
+
+}
+
+/**
+ * Replaces placeholders by the values passed
+ */
+PHP_METHOD(Phalcon_Translate_Interpolator_AssociativeArray, replacePlaceholders) {
+
+ HashTable *_2;
+ HashPosition _1;
+ zend_bool _0;
+ zval *translation_param = NULL, *placeholders = NULL, *key = NULL, *value = NULL, **_3, *_4 = NULL, *_5 = NULL;
+ zval *translation = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 1, &translation_param, &placeholders);
+
+ if (unlikely(Z_TYPE_P(translation_param) != IS_STRING && Z_TYPE_P(translation_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'translation' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(translation_param) == IS_STRING)) {
+ zephir_get_strval(translation, translation_param);
+ } else {
+ ZEPHIR_INIT_VAR(translation);
+ ZVAL_EMPTY_STRING(translation);
+ }
+ if (!placeholders) {
+ placeholders = ZEPHIR_GLOBAL(global_null);
+ }
+
+
+ _0 = Z_TYPE_P(placeholders) == IS_ARRAY;
+ if (_0) {
+ _0 = (zephir_fast_count_int(placeholders TSRMLS_CC)) ? 1 : 0;
+ }
+ if (_0) {
+ zephir_is_iterable(placeholders, &_2, &_1, 0, 0, "phalcon/translate/interpolator/associativearray.zep", 38);
+ for (
+ ; zephir_hash_get_current_data_ex(_2, (void**) &_3, &_1) == SUCCESS
+ ; zephir_hash_move_forward_ex(_2, &_1)
+ ) {
+ ZEPHIR_GET_HMKEY(key, _2, _1);
+ ZEPHIR_GET_HVALUE(value, _3);
+ ZEPHIR_INIT_NVAR(_4);
+ ZEPHIR_INIT_LNVAR(_5);
+ ZEPHIR_CONCAT_SVS(_5, "%", key, "%");
+ zephir_fast_str_replace(&_4, _5, value, translation TSRMLS_CC);
+ zephir_get_strval(translation, _4);
+ }
+ }
+ RETURN_CTOR(translation);
+
+}
+
diff --git a/ext/phalcon/translate/interpolator/associativearray.zep.h b/ext/phalcon/translate/interpolator/associativearray.zep.h
new file mode 100644
index 00000000000..8412f998f8b
--- /dev/null
+++ b/ext/phalcon/translate/interpolator/associativearray.zep.h
@@ -0,0 +1,16 @@
+
+extern zend_class_entry *phalcon_translate_interpolator_associativearray_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_Interpolator_AssociativeArray);
+
+PHP_METHOD(Phalcon_Translate_Interpolator_AssociativeArray, replacePlaceholders);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_interpolator_associativearray_replaceplaceholders, 0, 0, 1)
+ ZEND_ARG_INFO(0, translation)
+ ZEND_ARG_INFO(0, placeholders)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_translate_interpolator_associativearray_method_entry) {
+ PHP_ME(Phalcon_Translate_Interpolator_AssociativeArray, replacePlaceholders, arginfo_phalcon_translate_interpolator_associativearray_replaceplaceholders, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
diff --git a/ext/phalcon/translate/interpolator/indexedarray.zep.c b/ext/phalcon/translate/interpolator/indexedarray.zep.c
new file mode 100644
index 00000000000..29590926052
--- /dev/null
+++ b/ext/phalcon/translate/interpolator/indexedarray.zep.c
@@ -0,0 +1,78 @@
+
+#ifdef HAVE_CONFIG_H
+#include "../../../ext_config.h"
+#endif
+
+#include
+#include "../../../php_ext.h"
+#include "../../../ext.h"
+
+#include
+#include
+#include
+
+#include "kernel/main.h"
+#include "kernel/fcall.h"
+#include "kernel/memory.h"
+#include "ext/spl/spl_exceptions.h"
+#include "kernel/exception.h"
+#include "kernel/operators.h"
+
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_Interpolator_IndexedArray) {
+
+ ZEPHIR_REGISTER_CLASS(Phalcon\\Translate\\Interpolator, IndexedArray, phalcon, translate_interpolator_indexedarray, phalcon_translate_interpolator_indexedarray_method_entry, 0);
+
+ zend_class_implements(phalcon_translate_interpolator_indexedarray_ce TSRMLS_CC, 1, phalcon_translate_interpolatorinterface_ce);
+ return SUCCESS;
+
+}
+
+/**
+ * Replaces placeholders by the values passed
+ */
+PHP_METHOD(Phalcon_Translate_Interpolator_IndexedArray, replacePlaceholders) {
+
+ int ZEPHIR_LAST_CALL_STATUS;
+ zend_bool _0;
+ zval *translation_param = NULL, *placeholders = NULL, _1;
+ zval *translation = NULL;
+
+ ZEPHIR_MM_GROW();
+ zephir_fetch_params(1, 1, 1, &translation_param, &placeholders);
+
+ if (unlikely(Z_TYPE_P(translation_param) != IS_STRING && Z_TYPE_P(translation_param) != IS_NULL)) {
+ zephir_throw_exception_string(spl_ce_InvalidArgumentException, SL("Parameter 'translation' must be a string") TSRMLS_CC);
+ RETURN_MM_NULL();
+ }
+
+ if (likely(Z_TYPE_P(translation_param) == IS_STRING)) {
+ zephir_get_strval(translation, translation_param);
+ } else {
+ ZEPHIR_INIT_VAR(translation);
+ ZVAL_EMPTY_STRING(translation);
+ }
+ if (!placeholders) {
+ placeholders = ZEPHIR_GLOBAL(global_null);
+ }
+
+
+ _0 = Z_TYPE_P(placeholders) == IS_ARRAY;
+ if (_0) {
+ _0 = (zephir_fast_count_int(placeholders TSRMLS_CC)) ? 1 : 0;
+ }
+ if (_0) {
+ Z_SET_ISREF_P(placeholders);
+ ZEPHIR_CALL_FUNCTION(NULL, "array_unshift", NULL, 386, placeholders, translation);
+ Z_UNSET_ISREF_P(placeholders);
+ zephir_check_call_status();
+ ZEPHIR_SINIT_VAR(_1);
+ ZVAL_STRING(&_1, "sprintf", 0);
+ ZEPHIR_CALL_USER_FUNC_ARRAY(return_value, &_1, placeholders);
+ zephir_check_call_status();
+ RETURN_MM();
+ }
+ RETURN_CTOR(translation);
+
+}
+
diff --git a/ext/phalcon/translate/interpolator/indexedarray.zep.h b/ext/phalcon/translate/interpolator/indexedarray.zep.h
new file mode 100644
index 00000000000..88e1c2391e6
--- /dev/null
+++ b/ext/phalcon/translate/interpolator/indexedarray.zep.h
@@ -0,0 +1,16 @@
+
+extern zend_class_entry *phalcon_translate_interpolator_indexedarray_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_Interpolator_IndexedArray);
+
+PHP_METHOD(Phalcon_Translate_Interpolator_IndexedArray, replacePlaceholders);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_interpolator_indexedarray_replaceplaceholders, 0, 0, 1)
+ ZEND_ARG_INFO(0, translation)
+ ZEND_ARG_INFO(0, placeholders)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_translate_interpolator_indexedarray_method_entry) {
+ PHP_ME(Phalcon_Translate_Interpolator_IndexedArray, replacePlaceholders, arginfo_phalcon_translate_interpolator_indexedarray_replaceplaceholders, ZEND_ACC_PUBLIC)
+ PHP_FE_END
+};
diff --git a/ext/phalcon/translate/interpolatorinterface.zep.c b/ext/phalcon/translate/interpolatorinterface.zep.c
new file mode 100644
index 00000000000..c71588faeb8
--- /dev/null
+++ b/ext/phalcon/translate/interpolatorinterface.zep.c
@@ -0,0 +1,32 @@
+
+#ifdef HAVE_CONFIG_H
+#include "../../ext_config.h"
+#endif
+
+#include
+#include "../../php_ext.h"
+#include "../../ext.h"
+
+#include
+
+#include "kernel/main.h"
+
+
+/**
+ * Phalcon\Translate\AdapterInterface
+ *
+ * Interface for Phalcon\Translate adapters
+ */
+ZEPHIR_INIT_CLASS(Phalcon_Translate_InterpolatorInterface) {
+
+ ZEPHIR_REGISTER_INTERFACE(Phalcon\\Translate, InterpolatorInterface, phalcon, translate_interpolatorinterface, phalcon_translate_interpolatorinterface_method_entry);
+
+ return SUCCESS;
+
+}
+
+/**
+ * Replaces placeholders by the values passed
+ */
+ZEPHIR_DOC_METHOD(Phalcon_Translate_InterpolatorInterface, replacePlaceholders);
+
diff --git a/ext/phalcon/translate/interpolatorinterface.zep.h b/ext/phalcon/translate/interpolatorinterface.zep.h
new file mode 100644
index 00000000000..cb7afbebf50
--- /dev/null
+++ b/ext/phalcon/translate/interpolatorinterface.zep.h
@@ -0,0 +1,14 @@
+
+extern zend_class_entry *phalcon_translate_interpolatorinterface_ce;
+
+ZEPHIR_INIT_CLASS(Phalcon_Translate_InterpolatorInterface);
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_phalcon_translate_interpolatorinterface_replaceplaceholders, 0, 0, 1)
+ ZEND_ARG_INFO(0, translation)
+ ZEND_ARG_INFO(0, placeholders)
+ZEND_END_ARG_INFO()
+
+ZEPHIR_INIT_FUNCS(phalcon_translate_interpolatorinterface_method_entry) {
+ PHP_ABSTRACT_ME(Phalcon_Translate_InterpolatorInterface, replacePlaceholders, arginfo_phalcon_translate_interpolatorinterface_replaceplaceholders)
+ PHP_FE_END
+};
diff --git a/ext/phalcon/validation/message.zep.c b/ext/phalcon/validation/message.zep.c
index 87b488acef2..c3bf0de402d 100644
--- a/ext/phalcon/validation/message.zep.c
+++ b/ext/phalcon/validation/message.zep.c
@@ -231,7 +231,7 @@ PHP_METHOD(Phalcon_Validation_Message, __set_state) {
zephir_array_fetch_string(&_0, message, SL("_message"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC);
zephir_array_fetch_string(&_1, message, SL("_field"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC);
zephir_array_fetch_string(&_2, message, SL("_type"), PH_NOISY | PH_READONLY, "phalcon/validation/message.zep", 118 TSRMLS_CC);
- ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 432, _0, _1, _2);
+ ZEPHIR_CALL_METHOD(NULL, return_value, "__construct", NULL, 436, _0, _1, _2);
zephir_check_call_status();
RETURN_MM();
diff --git a/ext/phalcon/validation/validator.zep.c b/ext/phalcon/validation/validator.zep.c
index d571664f39b..f292a9bba68 100644
--- a/ext/phalcon/validation/validator.zep.c
+++ b/ext/phalcon/validation/validator.zep.c
@@ -56,7 +56,7 @@ PHP_METHOD(Phalcon_Validation_Validator, __construct) {
_0 = Z_TYPE_P(options) != IS_NULL;
}
if (_0) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_validation_exception_ce, "Options must be an array", "phalcon/validation/validator.zep", 39);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STRW(phalcon_validation_exception_ce, "Options must be an array", "phalcon/validation/validator.zep", 40);
return;
} else {
zephir_update_property_this(this_ptr, SL("_options"), options TSRMLS_CC);
diff --git a/ext/phalcon/validation/validator/alnum.zep.c b/ext/phalcon/validation/validator/alnum.zep.c
index 3d56f8d670d..1c63067adcf 100644
--- a/ext/phalcon/validation/validator/alnum.zep.c
+++ b/ext/phalcon/validation/validator/alnum.zep.c
@@ -81,7 +81,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Alnum, validate) {
if (_2) {
RETURN_MM_BOOL(1);
}
- ZEPHIR_CALL_FUNCTION(&_3, "ctype_alnum", NULL, 433, value);
+ ZEPHIR_CALL_FUNCTION(&_3, "ctype_alnum", NULL, 437, value);
zephir_check_call_status();
if (!(zephir_is_true(_3))) {
ZEPHIR_INIT_NVAR(_1);
@@ -114,7 +114,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Alnum, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZVAL_STRING(_5, "Alnum", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _4, field, _5);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5);
zephir_check_temp_parameter(_5);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
diff --git a/ext/phalcon/validation/validator/alpha.zep.c b/ext/phalcon/validation/validator/alpha.zep.c
index 3f6b0f96eeb..6cdd687f104 100644
--- a/ext/phalcon/validation/validator/alpha.zep.c
+++ b/ext/phalcon/validation/validator/alpha.zep.c
@@ -81,7 +81,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Alpha, validate) {
if (_2) {
RETURN_MM_BOOL(1);
}
- ZEPHIR_CALL_FUNCTION(&_3, "ctype_alpha", NULL, 434, value);
+ ZEPHIR_CALL_FUNCTION(&_3, "ctype_alpha", NULL, 438, value);
zephir_check_call_status();
if (!(zephir_is_true(_3))) {
ZEPHIR_INIT_NVAR(_1);
@@ -114,7 +114,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Alpha, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZVAL_STRING(_5, "Alpha", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _4, field, _5);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5);
zephir_check_temp_parameter(_5);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
diff --git a/ext/phalcon/validation/validator/between.zep.c b/ext/phalcon/validation/validator/between.zep.c
index 722476b8db6..e0f09236a67 100644
--- a/ext/phalcon/validation/validator/between.zep.c
+++ b/ext/phalcon/validation/validator/between.zep.c
@@ -131,7 +131,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Between, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZVAL_STRING(_5, "Between", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 432, _4, field, _5);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _4, field, _5);
zephir_check_temp_parameter(_5);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
diff --git a/ext/phalcon/validation/validator/confirmation.zep.c b/ext/phalcon/validation/validator/confirmation.zep.c
index e806c8c7f76..39800ffd200 100644
--- a/ext/phalcon/validation/validator/confirmation.zep.c
+++ b/ext/phalcon/validation/validator/confirmation.zep.c
@@ -77,7 +77,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Confirmation, validate) {
zephir_check_call_status();
ZEPHIR_CALL_METHOD(&valueWith, validation, "getvalue", NULL, 0, fieldWith);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "compare", NULL, 435, value, valueWith);
+ ZEPHIR_CALL_METHOD(&_1, this_ptr, "compare", NULL, 439, value, valueWith);
zephir_check_call_status();
if (!(zephir_is_true(_1))) {
ZEPHIR_INIT_NVAR(_0);
@@ -120,7 +120,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Confirmation, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_3);
ZVAL_STRING(_3, "Confirmation", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 432, _2, field, _3);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _2, field, _3);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -162,12 +162,12 @@ PHP_METHOD(Phalcon_Validation_Validator_Confirmation, compare) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_STRING(&_3, "utf-8", 0);
- ZEPHIR_CALL_FUNCTION(&_4, "mb_strtolower", &_5, 193, a, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "mb_strtolower", &_5, 194, a, &_3);
zephir_check_call_status();
zephir_get_strval(a, _4);
ZEPHIR_SINIT_NVAR(_3);
ZVAL_STRING(&_3, "utf-8", 0);
- ZEPHIR_CALL_FUNCTION(&_6, "mb_strtolower", &_5, 193, b, &_3);
+ ZEPHIR_CALL_FUNCTION(&_6, "mb_strtolower", &_5, 194, b, &_3);
zephir_check_call_status();
zephir_get_strval(b, _6);
}
diff --git a/ext/phalcon/validation/validator/digit.zep.c b/ext/phalcon/validation/validator/digit.zep.c
index 20a519b1a04..6f27efe29b0 100644
--- a/ext/phalcon/validation/validator/digit.zep.c
+++ b/ext/phalcon/validation/validator/digit.zep.c
@@ -81,7 +81,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Digit, validate) {
if (_2) {
RETURN_MM_BOOL(1);
}
- ZEPHIR_CALL_FUNCTION(&_3, "ctype_digit", NULL, 436, value);
+ ZEPHIR_CALL_FUNCTION(&_3, "ctype_digit", NULL, 440, value);
zephir_check_call_status();
if (!(zephir_is_true(_3))) {
ZEPHIR_INIT_NVAR(_1);
@@ -114,7 +114,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Digit, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_5);
ZVAL_STRING(_5, "Digit", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _4, field, _5);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _4, field, _5);
zephir_check_temp_parameter(_5);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
diff --git a/ext/phalcon/validation/validator/email.zep.c b/ext/phalcon/validation/validator/email.zep.c
index c2c3d3aa575..9f6a43b745b 100644
--- a/ext/phalcon/validation/validator/email.zep.c
+++ b/ext/phalcon/validation/validator/email.zep.c
@@ -83,7 +83,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Email, validate) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 274);
- ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 190, value, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_1);
@@ -116,7 +116,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Email, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_6);
ZVAL_STRING(_6, "Email", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _5, field, _6);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6);
zephir_check_temp_parameter(_6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
diff --git a/ext/phalcon/validation/validator/exclusionin.zep.c b/ext/phalcon/validation/validator/exclusionin.zep.c
index 533b1c27649..444d2732d85 100644
--- a/ext/phalcon/validation/validator/exclusionin.zep.c
+++ b/ext/phalcon/validation/validator/exclusionin.zep.c
@@ -89,7 +89,7 @@ PHP_METHOD(Phalcon_Validation_Validator_ExclusionIn, validate) {
zephir_check_temp_parameter(_1);
zephir_check_call_status();
if (Z_TYPE_P(domain) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'domain' must be an array", "phalcon/validation/validator/exclusionin.zep", 59);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'domain' must be an array", "phalcon/validation/validator/exclusionin.zep", 62);
return;
}
if (zephir_fast_in_array(value, domain TSRMLS_CC)) {
@@ -126,7 +126,7 @@ PHP_METHOD(Phalcon_Validation_Validator_ExclusionIn, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_4);
ZVAL_STRING(_4, "ExclusionIn", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _3, field, _4);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _3, field, _4);
zephir_check_temp_parameter(_4);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
diff --git a/ext/phalcon/validation/validator/file.zep.c b/ext/phalcon/validation/validator/file.zep.c
index fd7fd26aa1d..18bdf39ca9a 100644
--- a/ext/phalcon/validation/validator/file.zep.c
+++ b/ext/phalcon/validation/validator/file.zep.c
@@ -91,7 +91,7 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
ZEPHIR_CALL_METHOD(&label, validation, "getlabel", NULL, 0, field);
zephir_check_call_status();
}
- zephir_array_fetch_string(&_1, _SERVER, SL("REQUEST_METHOD"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 61 TSRMLS_CC);
+ zephir_array_fetch_string(&_1, _SERVER, SL("REQUEST_METHOD"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 62 TSRMLS_CC);
_2 = ZEPHIR_IS_STRING(_1, "POST");
if (_2) {
_2 = ZEPHIR_IS_EMPTY(_POST);
@@ -102,14 +102,14 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
}
_4 = _3;
if (_4) {
- zephir_array_fetch_string(&_5, _SERVER, SL("CONTENT_LENGTH"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 61 TSRMLS_CC);
+ zephir_array_fetch_string(&_5, _SERVER, SL("CONTENT_LENGTH"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 62 TSRMLS_CC);
_4 = ZEPHIR_GT_LONG(_5, 0);
}
_6 = _4;
if (!(_6)) {
_7 = zephir_array_isset_string(value, SS("error"));
if (_7) {
- zephir_array_fetch_string(&_8, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 61 TSRMLS_CC);
+ zephir_array_fetch_string(&_8, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 62 TSRMLS_CC);
_7 = ZEPHIR_IS_LONG_IDENTICAL(_8, 1);
}
_6 = _7;
@@ -136,7 +136,7 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_11);
ZVAL_STRING(_11, "FileIniSize", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_12, 432, _9, field, _11);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_12, 436, _9, field, _11);
zephir_check_temp_parameter(_11);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -154,7 +154,7 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
if (!(_14)) {
_15 = zephir_array_isset_string(value, SS("error"));
if (_15) {
- zephir_array_fetch_string(&_16, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 73 TSRMLS_CC);
+ zephir_array_fetch_string(&_16, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 75 TSRMLS_CC);
_15 = ZEPHIR_IS_LONG_IDENTICAL(_16, 4);
}
_14 = _15;
@@ -170,13 +170,13 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
}
_18 = _17;
if (!(_18)) {
- zephir_array_fetch_string(&_19, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 77 TSRMLS_CC);
+ zephir_array_fetch_string(&_19, value, SL("error"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 79 TSRMLS_CC);
_18 = !ZEPHIR_IS_LONG_IDENTICAL(_19, 0);
}
_20 = _18;
if (!(_20)) {
- zephir_array_fetch_string(&_21, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 77 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_9, "is_uploaded_file", NULL, 231, _21);
+ zephir_array_fetch_string(&_21, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 79 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&_9, "is_uploaded_file", NULL, 232, _21);
zephir_check_call_status();
_20 = !zephir_is_true(_9);
}
@@ -202,7 +202,7 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_23);
ZVAL_STRING(_23, "FileEmpty", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 432, _22, field, _23);
+ ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _22, field, _23);
zephir_check_temp_parameter(_23);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11);
@@ -239,7 +239,7 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_23);
ZVAL_STRING(_23, "FileValid", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 432, _9, field, _23);
+ ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _9, field, _23);
zephir_check_temp_parameter(_23);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11);
@@ -282,22 +282,22 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_preg_match(_11, _27, maxSize, matches, 0, 0 , 0 TSRMLS_CC);
if (zephir_array_isset_long(matches, 2)) {
ZEPHIR_OBS_NVAR(unit);
- zephir_array_fetch_long(&unit, matches, 2, PH_NOISY, "phalcon/validation/validator/file.zep", 110 TSRMLS_CC);
+ zephir_array_fetch_long(&unit, matches, 2, PH_NOISY, "phalcon/validation/validator/file.zep", 115 TSRMLS_CC);
}
- zephir_array_fetch_long(&_28, matches, 1, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 113 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 310, _28);
+ zephir_array_fetch_long(&_28, matches, 1, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 118 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 311, _28);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_30);
- zephir_array_fetch(&_31, byteUnits, unit, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 113 TSRMLS_CC);
+ zephir_array_fetch(&_31, byteUnits, unit, PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 118 TSRMLS_CC);
ZEPHIR_SINIT_VAR(_32);
ZVAL_LONG(&_32, 2);
zephir_pow_function(_30, &_32, _31);
ZEPHIR_INIT_VAR(bytes);
mul_function(bytes, _22, _30 TSRMLS_CC);
- zephir_array_fetch_string(&_33, value, SL("size"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 115 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 310, _33);
+ zephir_array_fetch_string(&_33, value, SL("size"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 120 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&_22, "floatval", &_29, 311, _33);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(&_34, "floatval", &_29, 310, bytes);
+ ZEPHIR_CALL_FUNCTION(&_34, "floatval", &_29, 311, bytes);
zephir_check_call_status();
if (ZEPHIR_GT(_22, _34)) {
ZEPHIR_INIT_NVAR(_30);
@@ -322,7 +322,7 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_36);
ZVAL_STRING(_36, "FileSize", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _30, "__construct", &_12, 432, _35, field, _36);
+ ZEPHIR_CALL_METHOD(NULL, _30, "__construct", &_12, 436, _35, field, _36);
zephir_check_temp_parameter(_36);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _30);
@@ -342,22 +342,22 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_temp_parameter(_11);
zephir_check_call_status();
if (Z_TYPE_P(types) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'allowedTypes' must be an array", "phalcon/validation/validator/file.zep", 132);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'allowedTypes' must be an array", "phalcon/validation/validator/file.zep", 138);
return;
}
if ((zephir_function_exists_ex(SS("finfo_open") TSRMLS_CC) == SUCCESS)) {
ZEPHIR_SINIT_NVAR(_32);
ZVAL_LONG(&_32, 16);
- ZEPHIR_CALL_FUNCTION(&tmp, "finfo_open", NULL, 228, &_32);
+ ZEPHIR_CALL_FUNCTION(&tmp, "finfo_open", NULL, 229, &_32);
zephir_check_call_status();
- zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 137 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 229, tmp, _28);
+ zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 143 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&mime, "finfo_file", NULL, 230, tmp, _28);
zephir_check_call_status();
- ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 230, tmp);
+ ZEPHIR_CALL_FUNCTION(NULL, "finfo_close", NULL, 231, tmp);
zephir_check_call_status();
} else {
ZEPHIR_OBS_NVAR(mime);
- zephir_array_fetch_string(&mime, value, SL("type"), PH_NOISY, "phalcon/validation/validator/file.zep", 141 TSRMLS_CC);
+ zephir_array_fetch_string(&mime, value, SL("type"), PH_NOISY, "phalcon/validation/validator/file.zep", 147 TSRMLS_CC);
}
if (!(zephir_fast_in_array(mime, types TSRMLS_CC))) {
ZEPHIR_INIT_NVAR(_11);
@@ -384,7 +384,7 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_23);
ZVAL_STRING(_23, "FileType", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 432, _22, field, _23);
+ ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _22, field, _23);
zephir_check_temp_parameter(_23);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11);
@@ -407,13 +407,13 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
_37 = zephir_is_true(_22);
}
if (_37) {
- zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 158 TSRMLS_CC);
- ZEPHIR_CALL_FUNCTION(&tmp, "getimagesize", NULL, 248, _28);
+ zephir_array_fetch_string(&_28, value, SL("tmp_name"), PH_NOISY | PH_READONLY, "phalcon/validation/validator/file.zep", 164 TSRMLS_CC);
+ ZEPHIR_CALL_FUNCTION(&tmp, "getimagesize", NULL, 249, _28);
zephir_check_call_status();
ZEPHIR_OBS_VAR(width);
- zephir_array_fetch_long(&width, tmp, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 159 TSRMLS_CC);
+ zephir_array_fetch_long(&width, tmp, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 165 TSRMLS_CC);
ZEPHIR_OBS_VAR(height);
- zephir_array_fetch_long(&height, tmp, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 160 TSRMLS_CC);
+ zephir_array_fetch_long(&height, tmp, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 166 TSRMLS_CC);
ZEPHIR_INIT_NVAR(_11);
ZVAL_STRING(_11, "minResolution", ZEPHIR_TEMP_PARAM_COPY);
ZEPHIR_CALL_METHOD(&_34, this_ptr, "issetoption", NULL, 0, _11);
@@ -428,9 +428,9 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
ZEPHIR_INIT_VAR(minResolution);
zephir_fast_explode_str(minResolution, SL("x"), _35, LONG_MAX TSRMLS_CC);
ZEPHIR_OBS_VAR(minWidth);
- zephir_array_fetch_long(&minWidth, minResolution, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 164 TSRMLS_CC);
+ zephir_array_fetch_long(&minWidth, minResolution, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 170 TSRMLS_CC);
ZEPHIR_OBS_VAR(minHeight);
- zephir_array_fetch_long(&minHeight, minResolution, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 165 TSRMLS_CC);
+ zephir_array_fetch_long(&minHeight, minResolution, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 171 TSRMLS_CC);
} else {
ZEPHIR_INIT_NVAR(minWidth);
ZVAL_LONG(minWidth, 1);
@@ -469,7 +469,7 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_23);
ZVAL_STRING(_23, "FileMinResolution", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 432, _35, field, _23);
+ ZEPHIR_CALL_METHOD(NULL, _11, "__construct", &_12, 436, _35, field, _23);
zephir_check_temp_parameter(_23);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _11);
@@ -490,9 +490,9 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
ZEPHIR_INIT_VAR(maxResolution);
zephir_fast_explode_str(maxResolution, SL("x"), _39, LONG_MAX TSRMLS_CC);
ZEPHIR_OBS_VAR(maxWidth);
- zephir_array_fetch_long(&maxWidth, maxResolution, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 186 TSRMLS_CC);
+ zephir_array_fetch_long(&maxWidth, maxResolution, 0, PH_NOISY, "phalcon/validation/validator/file.zep", 192 TSRMLS_CC);
ZEPHIR_OBS_VAR(maxHeight);
- zephir_array_fetch_long(&maxHeight, maxResolution, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 187 TSRMLS_CC);
+ zephir_array_fetch_long(&maxHeight, maxResolution, 1, PH_NOISY, "phalcon/validation/validator/file.zep", 193 TSRMLS_CC);
_40 = ZEPHIR_GT(width, maxWidth);
if (!(_40)) {
_40 = ZEPHIR_GT(height, maxHeight);
@@ -525,7 +525,7 @@ PHP_METHOD(Phalcon_Validation_Validator_File, validate) {
zephir_check_call_status();
ZEPHIR_INIT_NVAR(_26);
ZVAL_STRING(_26, "FileMaxResolution", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _23, "__construct", &_12, 432, _41, field, _26);
+ ZEPHIR_CALL_METHOD(NULL, _23, "__construct", &_12, 436, _41, field, _26);
zephir_check_temp_parameter(_26);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _23);
diff --git a/ext/phalcon/validation/validator/identical.zep.c b/ext/phalcon/validation/validator/identical.zep.c
index c83d8a949cd..26c223d9528 100644
--- a/ext/phalcon/validation/validator/identical.zep.c
+++ b/ext/phalcon/validation/validator/identical.zep.c
@@ -12,8 +12,8 @@
#include
#include "kernel/main.h"
-#include "kernel/memory.h"
#include "kernel/fcall.h"
+#include "kernel/memory.h"
#include "kernel/operators.h"
#include "kernel/array.h"
#include "ext/spl/spl_exceptions.h"
@@ -49,8 +49,9 @@ ZEPHIR_INIT_CLASS(Phalcon_Validation_Validator_Identical) {
PHP_METHOD(Phalcon_Validation_Validator_Identical, validate) {
int ZEPHIR_LAST_CALL_STATUS;
+ zend_bool valid;
zval *field = NULL;
- zval *validation, *field_param = NULL, *message = NULL, *label = NULL, *replacePairs, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4;
+ zval *validation, *field_param = NULL, *message = NULL, *label = NULL, *replacePairs, *value = NULL, *_0 = NULL, *_1 = NULL, *_2 = NULL, *_3 = NULL, *_4;
ZEPHIR_MM_GROW();
zephir_fetch_params(1, 2, 0, &validation, &field_param);
@@ -68,48 +69,70 @@ PHP_METHOD(Phalcon_Validation_Validator_Identical, validate) {
}
- ZEPHIR_CALL_METHOD(&_0, validation, "getvalue", NULL, 0, field);
+ ZEPHIR_CALL_METHOD(&value, validation, "getvalue", NULL, 0, field);
zephir_check_call_status();
- ZEPHIR_INIT_VAR(_2);
- ZVAL_STRING(_2, "accepted", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&_1, this_ptr, "getoption", NULL, 0, _2);
- zephir_check_temp_parameter(_2);
+ ZEPHIR_INIT_VAR(_1);
+ ZVAL_STRING(_1, "accepted", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&_0, this_ptr, "hasoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
zephir_check_call_status();
- if (!ZEPHIR_IS_EQUAL(_0, _1)) {
- ZEPHIR_INIT_NVAR(_2);
- ZVAL_STRING(_2, "label", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&label, this_ptr, "getoption", NULL, 0, _2);
- zephir_check_temp_parameter(_2);
+ if (zephir_is_true(_0)) {
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "accepted", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&_2, this_ptr, "getoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
+ zephir_check_call_status();
+ valid = ZEPHIR_IS_EQUAL(value, _2);
+ } else {
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "value", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&_2, this_ptr, "hasoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
+ zephir_check_call_status();
+ if (zephir_is_true(_2)) {
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "value", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&_3, this_ptr, "getoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
+ zephir_check_call_status();
+ valid = ZEPHIR_IS_EQUAL(value, _3);
+ }
+ }
+ if (!(valid)) {
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "label", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&label, this_ptr, "getoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
zephir_check_call_status();
if (ZEPHIR_IS_EMPTY(label)) {
ZEPHIR_CALL_METHOD(&label, validation, "getlabel", NULL, 0, field);
zephir_check_call_status();
}
- ZEPHIR_INIT_NVAR(_2);
- ZVAL_STRING(_2, "message", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&message, this_ptr, "getoption", NULL, 0, _2);
- zephir_check_temp_parameter(_2);
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "message", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&message, this_ptr, "getoption", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
zephir_check_call_status();
ZEPHIR_INIT_VAR(replacePairs);
zephir_create_array(replacePairs, 1, 0 TSRMLS_CC);
zephir_array_update_string(&replacePairs, SL(":field"), &label, PH_COPY | PH_SEPARATE);
if (ZEPHIR_IS_EMPTY(message)) {
- ZEPHIR_INIT_NVAR(_2);
- ZVAL_STRING(_2, "Identical", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(&message, validation, "getdefaultmessage", NULL, 0, _2);
- zephir_check_temp_parameter(_2);
+ ZEPHIR_INIT_NVAR(_1);
+ ZVAL_STRING(_1, "Identical", ZEPHIR_TEMP_PARAM_COPY);
+ ZEPHIR_CALL_METHOD(&message, validation, "getdefaultmessage", NULL, 0, _1);
+ zephir_check_temp_parameter(_1);
zephir_check_call_status();
}
- ZEPHIR_INIT_NVAR(_2);
- object_init_ex(_2, phalcon_validation_message_ce);
- ZEPHIR_CALL_FUNCTION(&_3, "strtr", NULL, 53, message, replacePairs);
+ ZEPHIR_INIT_NVAR(_1);
+ object_init_ex(_1, phalcon_validation_message_ce);
+ ZEPHIR_CALL_FUNCTION(&_2, "strtr", NULL, 53, message, replacePairs);
zephir_check_call_status();
ZEPHIR_INIT_VAR(_4);
ZVAL_STRING(_4, "Identical", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _2, "__construct", NULL, 432, _3, field, _4);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _2, field, _4);
zephir_check_temp_parameter(_4);
zephir_check_call_status();
- ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _2);
+ ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
zephir_check_call_status();
RETURN_MM_BOOL(0);
}
diff --git a/ext/phalcon/validation/validator/inclusionin.zep.c b/ext/phalcon/validation/validator/inclusionin.zep.c
index e7725b21acd..156ee27a7d3 100644
--- a/ext/phalcon/validation/validator/inclusionin.zep.c
+++ b/ext/phalcon/validation/validator/inclusionin.zep.c
@@ -89,7 +89,7 @@ PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) {
zephir_check_temp_parameter(_1);
zephir_check_call_status();
if (Z_TYPE_P(domain) != IS_ARRAY) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'domain' must be an array", "phalcon/validation/validator/inclusionin.zep", 61);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'domain' must be an array", "phalcon/validation/validator/inclusionin.zep", 62);
return;
}
ZEPHIR_INIT_VAR(strict);
@@ -101,7 +101,7 @@ PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) {
zephir_check_call_status();
if (zephir_is_true(_3)) {
if (Z_TYPE_P(strict) != IS_BOOL) {
- ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'strict' must be a boolean", "phalcon/validation/validator/inclusionin.zep", 67);
+ ZEPHIR_THROW_EXCEPTION_DEBUG_STR(phalcon_validation_exception_ce, "Option 'strict' must be a boolean", "phalcon/validation/validator/inclusionin.zep", 68);
return;
}
ZEPHIR_INIT_NVAR(_1);
@@ -110,7 +110,7 @@ PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) {
zephir_check_temp_parameter(_1);
zephir_check_call_status();
}
- ZEPHIR_CALL_FUNCTION(&_4, "in_array", NULL, 363, value, domain, strict);
+ ZEPHIR_CALL_FUNCTION(&_4, "in_array", NULL, 365, value, domain, strict);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_1);
@@ -146,7 +146,7 @@ PHP_METHOD(Phalcon_Validation_Validator_InclusionIn, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_6);
ZVAL_STRING(_6, "InclusionIn", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _5, field, _6);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6);
zephir_check_temp_parameter(_6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
diff --git a/ext/phalcon/validation/validator/numericality.zep.c b/ext/phalcon/validation/validator/numericality.zep.c
index d59f5b392dc..a7524f4a31f 100644
--- a/ext/phalcon/validation/validator/numericality.zep.c
+++ b/ext/phalcon/validation/validator/numericality.zep.c
@@ -118,7 +118,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Numericality, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_7);
ZVAL_STRING(_7, "Numericality", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 432, _6, field, _7);
+ ZEPHIR_CALL_METHOD(NULL, _5, "__construct", NULL, 436, _6, field, _7);
zephir_check_temp_parameter(_7);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _5);
diff --git a/ext/phalcon/validation/validator/presenceof.zep.c b/ext/phalcon/validation/validator/presenceof.zep.c
index e12a65280a1..1619501438f 100644
--- a/ext/phalcon/validation/validator/presenceof.zep.c
+++ b/ext/phalcon/validation/validator/presenceof.zep.c
@@ -104,7 +104,7 @@ PHP_METHOD(Phalcon_Validation_Validator_PresenceOf, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_3);
ZVAL_STRING(_3, "PresenceOf", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _2, field, _3);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _2, field, _3);
zephir_check_temp_parameter(_3);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
diff --git a/ext/phalcon/validation/validator/regex.zep.c b/ext/phalcon/validation/validator/regex.zep.c
index ee1099e90b0..aa3271fb729 100644
--- a/ext/phalcon/validation/validator/regex.zep.c
+++ b/ext/phalcon/validation/validator/regex.zep.c
@@ -129,7 +129,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Regex, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_7);
ZVAL_STRING(_7, "Regex", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 432, _6, field, _7);
+ ZEPHIR_CALL_METHOD(NULL, _4, "__construct", NULL, 436, _6, field, _7);
zephir_check_temp_parameter(_7);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _4);
diff --git a/ext/phalcon/validation/validator/stringlength.zep.c b/ext/phalcon/validation/validator/stringlength.zep.c
index 9e1822b6429..52a9b1d59f1 100644
--- a/ext/phalcon/validation/validator/stringlength.zep.c
+++ b/ext/phalcon/validation/validator/stringlength.zep.c
@@ -117,7 +117,7 @@ PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) {
zephir_check_call_status();
}
if ((zephir_function_exists_ex(SS("mb_strlen") TSRMLS_CC) == SUCCESS)) {
- ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 364, value);
+ ZEPHIR_CALL_FUNCTION(&length, "mb_strlen", NULL, 366, value);
zephir_check_call_status();
} else {
ZEPHIR_INIT_NVAR(length);
@@ -152,7 +152,7 @@ PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_6);
ZVAL_STRING(_6, "TooLong", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_7, 432, _4, field, _6);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", &_7, 436, _4, field, _6);
zephir_check_temp_parameter(_6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
@@ -189,7 +189,7 @@ PHP_METHOD(Phalcon_Validation_Validator_StringLength, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_8);
ZVAL_STRING(_8, "TooShort", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_7, 432, _4, field, _8);
+ ZEPHIR_CALL_METHOD(NULL, _6, "__construct", &_7, 436, _4, field, _8);
zephir_check_temp_parameter(_8);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _6);
diff --git a/ext/phalcon/validation/validator/uniqueness.zep.c b/ext/phalcon/validation/validator/uniqueness.zep.c
index 08088d0b7f6..8198331542e 100644
--- a/ext/phalcon/validation/validator/uniqueness.zep.c
+++ b/ext/phalcon/validation/validator/uniqueness.zep.c
@@ -107,7 +107,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Uniqueness, validate) {
ZEPHIR_INIT_VAR(_1);
zephir_create_array(_1, 2, 0 TSRMLS_CC);
ZEPHIR_INIT_VAR(_2);
- ZEPHIR_CONCAT_VSVS(_2, attribute, "=:value: AND ", attribute, "!= :except:");
+ ZEPHIR_CONCAT_VSVS(_2, attribute, " = :value: AND ", attribute, " != :except:");
zephir_array_fast_append(_1, _2);
ZEPHIR_INIT_VAR(_3);
zephir_create_array(_3, 2, 0 TSRMLS_CC);
@@ -121,7 +121,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Uniqueness, validate) {
ZEPHIR_INIT_NVAR(_1);
zephir_create_array(_1, 2, 0 TSRMLS_CC);
ZEPHIR_INIT_LNVAR(_2);
- ZEPHIR_CONCAT_VS(_2, attribute, "=:value:");
+ ZEPHIR_CONCAT_VS(_2, attribute, " = :value:");
zephir_array_fast_append(_1, _2);
ZEPHIR_INIT_NVAR(_3);
zephir_create_array(_3, 1, 0 TSRMLS_CC);
@@ -162,7 +162,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Uniqueness, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_7);
ZVAL_STRING(_7, "Uniqueness", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 432, _6, field, _7);
+ ZEPHIR_CALL_METHOD(NULL, _0, "__construct", NULL, 436, _6, field, _7);
zephir_check_temp_parameter(_7);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _0);
diff --git a/ext/phalcon/validation/validator/url.zep.c b/ext/phalcon/validation/validator/url.zep.c
index 42597bc434a..146817f487f 100644
--- a/ext/phalcon/validation/validator/url.zep.c
+++ b/ext/phalcon/validation/validator/url.zep.c
@@ -83,7 +83,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Url, validate) {
}
ZEPHIR_SINIT_VAR(_3);
ZVAL_LONG(&_3, 273);
- ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 190, value, &_3);
+ ZEPHIR_CALL_FUNCTION(&_4, "filter_var", NULL, 191, value, &_3);
zephir_check_call_status();
if (!(zephir_is_true(_4))) {
ZEPHIR_INIT_NVAR(_1);
@@ -116,7 +116,7 @@ PHP_METHOD(Phalcon_Validation_Validator_Url, validate) {
zephir_check_call_status();
ZEPHIR_INIT_VAR(_6);
ZVAL_STRING(_6, "Url", ZEPHIR_TEMP_PARAM_COPY);
- ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 432, _5, field, _6);
+ ZEPHIR_CALL_METHOD(NULL, _1, "__construct", NULL, 436, _5, field, _6);
zephir_check_temp_parameter(_6);
zephir_check_call_status();
ZEPHIR_CALL_METHOD(NULL, validation, "appendmessage", NULL, 0, _1);
diff --git a/ext/phalcon/version.zep.c b/ext/phalcon/version.zep.c
index 8db3406a433..71dcb4d95d5 100644
--- a/ext/phalcon/version.zep.c
+++ b/ext/phalcon/version.zep.c
@@ -97,7 +97,7 @@ PHP_METHOD(Phalcon_Version, _getVersion) {
ZVAL_LONG(_0, 0);
zephir_array_fast_append(return_value, _0);
ZEPHIR_INIT_NVAR(_0);
- ZVAL_LONG(_0, 5);
+ ZVAL_LONG(_0, 6);
zephir_array_fast_append(return_value, _0);
ZEPHIR_INIT_NVAR(_0);
ZVAL_LONG(_0, 4);
@@ -178,7 +178,7 @@ PHP_METHOD(Phalcon_Version, get) {
zephir_array_fetch_long(&specialNumber, version, 4, PH_NOISY, "phalcon/version.zep", 128 TSRMLS_CC);
ZEPHIR_INIT_VAR(result);
ZEPHIR_CONCAT_VSVSVS(result, major, ".", medium, ".", minor, " ");
- ZEPHIR_CALL_STATIC(&suffix, "_getspecial", &_0, 437, special);
+ ZEPHIR_CALL_STATIC(&suffix, "_getspecial", &_0, 441, special);
zephir_check_call_status();
if (!ZEPHIR_IS_STRING(suffix, "")) {
ZEPHIR_INIT_VAR(_1);
@@ -219,11 +219,11 @@ PHP_METHOD(Phalcon_Version, getId) {
zephir_array_fetch_long(&specialNumber, version, 4, PH_NOISY, "phalcon/version.zep", 158 TSRMLS_CC);
ZEPHIR_SINIT_VAR(_0);
ZVAL_STRING(&_0, "%02s", 0);
- ZEPHIR_CALL_FUNCTION(&_1, "sprintf", &_2, 186, &_0, medium);
+ ZEPHIR_CALL_FUNCTION(&_1, "sprintf", &_2, 187, &_0, medium);
zephir_check_call_status();
ZEPHIR_SINIT_NVAR(_0);
ZVAL_STRING(&_0, "%02s", 0);
- ZEPHIR_CALL_FUNCTION(&_3, "sprintf", &_2, 186, &_0, minor);
+ ZEPHIR_CALL_FUNCTION(&_3, "sprintf", &_2, 187, &_0, minor);
zephir_check_call_status();
ZEPHIR_CONCAT_VVVVV(return_value, major, _1, _3, special, specialNumber);
RETURN_MM();
@@ -260,7 +260,7 @@ PHP_METHOD(Phalcon_Version, getPart) {
}
if (part == 3) {
zephir_array_fetch_long(&_1, version, 3, PH_NOISY | PH_READONLY, "phalcon/version.zep", 187 TSRMLS_CC);
- ZEPHIR_CALL_STATIC(&result, "_getspecial", &_0, 437, _1);
+ ZEPHIR_CALL_STATIC(&result, "_getspecial", &_0, 441, _1);
zephir_check_call_status();
break;
}
diff --git a/ext/php_phalcon.h b/ext/php_phalcon.h
index 2579deef728..6b975e6aad3 100644
--- a/ext/php_phalcon.h
+++ b/ext/php_phalcon.h
@@ -11,7 +11,7 @@
#include "kernel/globals.h"
#define PHP_PHALCON_NAME "phalcon"
-#define PHP_PHALCON_VERSION "2.0.5"
+#define PHP_PHALCON_VERSION "2.0.6"
#define PHP_PHALCON_EXTNAME "phalcon"
#define PHP_PHALCON_AUTHOR "Phalcon Team and contributors"
#define PHP_PHALCON_ZEPVERSION "0.7.1b"
diff --git a/phalcon/cache/backend/libmemcached.zep b/phalcon/cache/backend/libmemcached.zep
index f8ccf782637..bee8a9b3be8 100644
--- a/phalcon/cache/backend/libmemcached.zep
+++ b/phalcon/cache/backend/libmemcached.zep
@@ -220,7 +220,7 @@ class Libmemcached extends Backend implements BackendInterface
}
if !success {
- throw new Exception("Failed storing data in memcached");
+ throw new Exception("Failed storing data in memcached, error code: " . memcache->getResultCode());
}
let options = this->_options;
diff --git a/phalcon/cli/router.zep b/phalcon/cli/router.zep
index 1248563d590..29746f9c893 100644
--- a/phalcon/cli/router.zep
+++ b/phalcon/cli/router.zep
@@ -22,7 +22,7 @@ namespace Phalcon\Cli;
use Phalcon\DiInterface;
use Phalcon\Cli\Router\Route;
-use Phalcon\CLi\Router\Exception;
+use Phalcon\Cli\Router\Exception;
/**
* Phalcon\Cli\Router
diff --git a/phalcon/crypt.zep b/phalcon/crypt.zep
index ed06616fb5e..bd674fec93b 100644
--- a/phalcon/crypt.zep
+++ b/phalcon/crypt.zep
@@ -64,10 +64,10 @@ class Crypt implements CryptInterface
const PADDING_SPACE = 6;
/**
- * @brief Phalcon\CryptInterface Phalcon\Crypt::setPadding(int $scheme)
- *
- * @param int scheme Padding scheme
- */
+ * Changes the padding scheme used
+ *
+ * @param int scheme
+ */
public function setPadding(int! scheme) ->
{
let this->_padding = scheme;
@@ -126,13 +126,8 @@ class Crypt implements CryptInterface
}
/**
- * Adds padding @a padding_type to @a text
+ * Pads texts before encryption
*
- * @param return_value Result, possibly padded
- * @param text Message to be padded
- * @param mode Encryption mode; padding is applied only in CBC or ECB mode
- * @param block_size Cipher block size
- * @param padding_type Padding scheme
* @see http://www.di-mgt.com.au/cryptopad.html
*/
protected function _cryptPadText(string text, string! mode, int! blockSize, int! paddingType)
diff --git a/phalcon/db/adapter.zep b/phalcon/db/adapter.zep
index 3d329e61698..6a2ecb8f3ab 100644
--- a/phalcon/db/adapter.zep
+++ b/phalcon/db/adapter.zep
@@ -180,14 +180,8 @@ abstract class Adapter implements EventsAwareInterface
* $robot = $connection->fecthOne("SELECT * FROM robots", Phalcon\Db::FETCH_ASSOC);
* print_r($robot);
*
- *
- * @param string sqlQuery
- * @param int fetchMode
- * @param array bindParams
- * @param array bindTypes
- * @return array
*/
- public function fetchOne(string! sqlQuery, var fetchMode = Db::FETCH_ASSOC, var bindParams = null, var bindTypes = null)
+ public function fetchOne(string! sqlQuery, var fetchMode = Db::FETCH_ASSOC, var bindParams = null, var bindTypes = null) -> array
{
var result;
@@ -280,6 +274,7 @@ abstract class Adapter implements EventsAwareInterface
if !empty row && fetch columnValue, row[column] {
return columnValue;
}
+
return false;
}
@@ -458,7 +453,7 @@ abstract class Adapter implements EventsAwareInterface
* @param array dataTypes
* @return boolean
*/
- public function update(var table, fields, values, whereCondition = null, dataTypes = null) -> boolean
+ public function update(var table, var fields, var values, var whereCondition = null, var dataTypes = null) -> boolean
{
var placeholders, updateValues, position, value,
field, bindDataTypes, escapedField, bindType, escapedTable,
@@ -587,7 +582,7 @@ abstract class Adapter implements EventsAwareInterface
* @param array dataTypes
* @return boolean
*/
- public function updateAsDict(var table, data, whereCondition = null, dataTypes = null) -> boolean
+ public function updateAsDict(var table, var data, var whereCondition = null, var dataTypes = null) -> boolean
{
var values = [], fields = [];
var field, value;
@@ -624,7 +619,7 @@ abstract class Adapter implements EventsAwareInterface
* @param array dataTypes
* @return boolean
*/
- public function delete(var table, whereCondition = null, placeholders = null, dataTypes = null) -> boolean
+ public function delete(var table, var whereCondition = null, var placeholders = null, var dataTypes = null) -> boolean
{
var sql, escapedTable;
@@ -672,9 +667,9 @@ abstract class Adapter implements EventsAwareInterface
/**
* Generates SQL checking for the existence of a schema.table
*
- *
+ *
* var_dump($connection->tableExists("blog", "posts"));
- *
+ *
*/
public function tableExists(string! tableName, string! schemaName = null) -> boolean
{
@@ -736,14 +731,9 @@ abstract class Adapter implements EventsAwareInterface
}
/**
- * Creates a view
- *
- * @param string tableName
- * @param array definition
- * @param string schemaName
- * @return boolean
+ * Creates a view
*/
- public function createView(string! viewName, array! definition, schemaName = null) -> boolean
+ public function createView(string! viewName, array! definition, var schemaName = null) -> boolean
{
if !isset definition["sql"] {
throw new Exception("The table must contain at least one column");
diff --git a/phalcon/db/dialect.zep b/phalcon/db/dialect.zep
index ed58b48b9c8..ef0190b08bd 100644
--- a/phalcon/db/dialect.zep
+++ b/phalcon/db/dialect.zep
@@ -827,9 +827,9 @@ abstract class Dialect implements DialectInterface
for filed in expression {
if unlikely typeof filed != "array" {
throw new Exception("Invalid SQL-GROUP-BY expression");
- } else {
- let fields[] = this->getSqlExpression(filed, escapeChar, bindCounts);
}
+
+ let fields[] = this->getSqlExpression(filed, escapeChar, bindCounts);
}
let fields = join(", ", fields);
@@ -838,7 +838,7 @@ abstract class Dialect implements DialectInterface
let fields = expression;
}
- return "GROUP BY " . fields;
+ return "GROUP BY " . fields;
}
/**
@@ -868,10 +868,10 @@ abstract class Dialect implements DialectInterface
if unlikely typeof filed != "array" {
throw new Exception("Invalid SQL-ORDER-BY expression");
- } else {
- let fieldSql = this->getSqlExpression(filed[0], escapeChar, bindCounts);
}
+ let fieldSql = this->getSqlExpression(filed[0], escapeChar, bindCounts);
+
/**
* In the numeric 1 position could be a ASC/DESC clause
*/
@@ -888,7 +888,7 @@ abstract class Dialect implements DialectInterface
let fields = expression;
}
- return "ORDER BY " . fields;
+ return "ORDER BY " . fields;
}
/**
diff --git a/phalcon/db/dialect/mysql.zep b/phalcon/db/dialect/mysql.zep
index 118b01d0dd2..1dfaaa6473c 100644
--- a/phalcon/db/dialect/mysql.zep
+++ b/phalcon/db/dialect/mysql.zep
@@ -118,12 +118,11 @@ class MySQL extends Dialect
}
let size = column->getSize();
if size {
- let scale = column->getScale(),
- columnSql .= "(" . size;
+ let scale = column->getScale();
if scale {
- let columnSql .= "," . scale . ")";
+ let columnSql .= "(" . size . "," . scale . ")";
} else {
- let columnSql .= ")";
+ let columnSql .= "(" . size . ")";
}
}
if column->isUnsigned() {
@@ -217,13 +216,7 @@ class MySQL extends Dialect
{
var afterPosition, sql, defaultValue;
- if schemaName {
- let sql = "ALTER TABLE `" . schemaName . "`.`" . tableName . "` ADD ";
- } else {
- let sql = "ALTER TABLE `" . tableName . "` ADD ";
- }
-
- let sql .= "`" . column->getName() . "` " . this->getColumnDefinition(column);
+ let sql = "ALTER TABLE " . this->prepareTable(tableName, schemaName) . " ADD `" . column->getName() . "` " . this->getColumnDefinition(column);
let defaultValue = column->getDefault();
if ! empty defaultValue {
@@ -252,13 +245,7 @@ class MySQL extends Dialect
{
var sql, defaultValue;
- if schemaName {
- let sql = "ALTER TABLE `" . schemaName . "`.`" . tableName . "` MODIFY ";
- } else {
- let sql = "ALTER TABLE `" . tableName . "` MODIFY ";
- }
-
- let sql .= "`" . column->getName() . "` " . this->getColumnDefinition(column);
+ let sql = "ALTER TABLE " . this->prepareTable(tableName, schemaName) . " MODIFY `" . column->getName() . "` " . this->getColumnDefinition(column);
let defaultValue = column->getDefault();
if ! empty defaultValue {
@@ -276,16 +263,7 @@ class MySQL extends Dialect
*/
public function dropColumn(string! tableName, string! schemaName, string! columnName) -> string
{
- var sql;
-
- if schemaName {
- let sql = "ALTER TABLE `" . schemaName . "`.`" . tableName . "` DROP COLUMN ";
- } else {
- let sql = "ALTER TABLE `" . tableName . "` DROP COLUMN ";
- }
-
- let sql .= "`".columnName."`";
- return sql;
+ return "ALTER TABLE " . this->prepareTable(tableName, schemaName) . " DROP COLUMN `" . columnName . "`";
}
/**
@@ -295,17 +273,13 @@ class MySQL extends Dialect
{
var sql, indexType;
- if schemaName {
- let sql = "ALTER TABLE `" . schemaName . "`.`" . tableName;
- } else {
- let sql = "ALTER TABLE `" . tableName;
- }
+ let sql = "ALTER TABLE " . this->prepareTable(tableName, schemaName);
let indexType = index->getType();
if !empty indexType {
- let sql .= "` ADD " . indexType . " INDEX ";
+ let sql .= " ADD " . indexType . " INDEX ";
} else {
- let sql .= "` ADD INDEX ";
+ let sql .= " ADD INDEX ";
}
let sql .= "`" . index->getName() . "` (" . this->getColumnList(index->getColumns()) . ")";
@@ -317,14 +291,7 @@ class MySQL extends Dialect
*/
public function dropIndex(string! tableName, string! schemaName, string! indexName) -> string
{
- var sql;
- if schemaName {
- let sql = "ALTER TABLE `" . schemaName . "`.`" . tableName . "` DROP INDEX ";
- } else {
- let sql = "ALTER TABLE `" . tableName . "` DROP INDEX ";
- }
- let sql .= "`" . indexName . "`";
- return sql;
+ return "ALTER TABLE " . this->prepareTable(tableName, schemaName) . " DROP INDEX `" . indexName . "`";
}
/**
@@ -332,15 +299,7 @@ class MySQL extends Dialect
*/
public function addPrimaryKey(string! tableName, string! schemaName, index) -> string
{
- var sql;
-
- if schemaName {
- let sql = "ALTER TABLE `" . schemaName . "`.`" . tableName . "` ADD PRIMARY KEY ";
- } else {
- let sql = "ALTER TABLE `" . tableName . "` ADD PRIMARY KEY ";
- }
- let sql .= "(" . this->getColumnList(index->getColumns()) . ")";
- return sql;
+ return "ALTER TABLE " . this->prepareTable(tableName, schemaName) . " ADD PRIMARY KEY (" . this->getColumnList(index->getColumns()) . ")";
}
/**
@@ -348,14 +307,7 @@ class MySQL extends Dialect
*/
public function dropPrimaryKey(string! tableName, string! schemaName) -> string
{
- var sql;
-
- if schemaName {
- let sql = "ALTER TABLE `" . schemaName . "`.`" . tableName . "` DROP PRIMARY KEY";
- } else {
- let sql = "ALTER TABLE `" . tableName . "` DROP PRIMARY KEY";
- }
- return sql;
+ return "ALTER TABLE " . this->prepareTable(tableName, schemaName) . " DROP PRIMARY KEY";
}
/**
@@ -363,25 +315,9 @@ class MySQL extends Dialect
*/
public function addForeignKey(string! tableName, string! schemaName, reference) -> string
{
- var sql, referencedSchema, onDelete, onUpdate;
-
- if schemaName {
- let sql = "ALTER TABLE `" . schemaName . "`.`" . tableName . "` ADD FOREIGN KEY ";
- } else {
- let sql = "ALTER TABLE `" . tableName . "` ADD FOREIGN KEY ";
- }
-
- let sql .= "`" . reference->getName() . "`(" . this->getColumnList(reference->getColumns()) . ") REFERENCES ";
+ var sql, onDelete, onUpdate;
- /**
- * Add the schema
- */
- let referencedSchema = reference->getReferencedSchema();
- if referencedSchema {
- let sql .= "`" . referencedSchema . "`.";
- }
-
- let sql .= "`" . reference->getReferencedTable() . "`(" . this->getColumnList(reference->getReferencedColumns()) . ")";
+ let sql = "ALTER TABLE " . this->prepareTable(tableName, schemaName) . " ADD FOREIGN KEY `" . reference->getName() . "`(" . this->getColumnList(reference->getColumns()) . ") REFERENCES " . this->prepareTable(reference->getReferencedTable(), reference->getReferencedSchema()) . "(" . this->getColumnList(reference->getReferencedColumns()) . ")";
let onDelete = reference->getOnDelete();
if !empty onDelete {
@@ -401,13 +337,7 @@ class MySQL extends Dialect
*/
public function dropForeignKey(string! tableName, string! schemaName, string! referenceName) -> string
{
- var sql;
- if schemaName {
- let sql = "ALTER TABLE `" . schemaName . "`.`" . tableName . "` DROP FOREIGN KEY ";
- } else {
- let sql = "ALTER TABLE `" . tableName . "` DROP FOREIGN KEY ";
- }
- return sql . "`" . referenceName . "`";
+ return "ALTER TABLE " . this->prepareTable(tableName, schemaName) . " DROP FOREIGN KEY `" . referenceName . "`";
}
/**
@@ -424,11 +354,7 @@ class MySQL extends Dialect
throw new Exception("The index 'columns' is required in the definition array");
}
- if schemaName {
- let table = "`" . schemaName . "`.`" . tableName . "`";
- } else {
- let table = "`" . tableName . "`";
- }
+ let table = this->prepareTable(tableName, schemaName);
let temporary = false;
if fetch options, definition["options"] {
@@ -545,11 +471,7 @@ class MySQL extends Dialect
{
var sql, table;
- if schemaName {
- let table = "`" . schemaName . "`.`" . tableName . "`";
- } else {
- let table = "`" . tableName . "`";
- }
+ let table = this->prepareTable(tableName, schemaName);
if ifExists {
let sql = "DROP TABLE IF EXISTS " . table;
@@ -565,19 +487,13 @@ class MySQL extends Dialect
*/
public function createView(string! viewName, array! definition, string schemaName = null) -> string
{
- var view, viewSql;
+ var viewSql;
if !fetch viewSql, definition["sql"] {
throw new Exception("The index 'sql' is required in the definition array");
}
- if schemaName {
- let view = "`". schemaName . "`.`" . viewName . "`";
- } else {
- let view = "`". viewName . "`";
- }
-
- return "CREATE VIEW " . view . " AS " . viewSql;
+ return "CREATE VIEW " . this->prepareTable(viewName, schemaName) . " AS " . viewSql;
}
/**
@@ -587,11 +503,7 @@ class MySQL extends Dialect
{
var sql, view;
- if schemaName {
- let view = schemaName . "." . viewName;
- } else {
- let view = viewName;
- }
+ let view = this->prepareTable(viewName, schemaName);
if ifExists {
let sql = "DROP VIEW IF EXISTS " . view;
@@ -638,10 +550,7 @@ class MySQL extends Dialect
*/
public function describeColumns(string! table, string schema = null) -> string
{
- if schema {
- return "DESCRIBE `" . schema . "`.`" . table . "`";
- }
- return "DESCRIBE `" . table . "`";
+ return "DESCRIBE " . this->prepareTable(table, schema);
}
/**
@@ -675,10 +584,7 @@ class MySQL extends Dialect
*/
public function describeIndexes(string! table, string schema = null) -> string
{
- if schema {
- return "SHOW INDEXES FROM `" . schema . "`.`" . table . "`";
- }
- return "SHOW INDEXES FROM `" . table . "`";
+ return "SHOW INDEXES FROM " . this->prepareTable(table, schema);
}
/**
diff --git a/phalcon/db/dialect/oracle.zep b/phalcon/db/dialect/oracle.zep
index c2924aec00b..69a4cdd3c50 100644
--- a/phalcon/db/dialect/oracle.zep
+++ b/phalcon/db/dialect/oracle.zep
@@ -210,11 +210,7 @@ class Oracle extends Dialect
{
var table;
- if schemaName {
- let table = this->escape(Text::upper(schemaName)) . "." . this->escape(Text::upper(tableName));
- } else {
- let table = this->escape(Text::upper(tableName));
- }
+ let table = this->prepareTable(tableName, schemaName);
if ifExists {
return "DROP TABLE IF EXISTS " . table;
@@ -228,19 +224,13 @@ class Oracle extends Dialect
*/
public function createView(string! viewName, array! definition, string schemaName = null) -> string
{
- var view, viewSql;
+ var viewSql;
if !fetch viewSql, definition["sql"] {
throw new Exception("The index 'sql' is required in the definition array");
}
- if schemaName {
- let view = this->escape(Text::upper(schemaName) . "." . Text::upper(viewName));
- } else {
- let view = this->escape(Text::upper(viewName));
- }
-
- return "CREATE VIEW " . view . " AS " . viewSql;
+ return "CREATE VIEW " . this->prepareTable(viewName, schemaName) . " AS " . viewSql;
}
/**
@@ -250,11 +240,7 @@ class Oracle extends Dialect
{
var view;
- if schemaName {
- let view = this->escape(Text::upper(schemaName) . "." . Text::upper(viewName));
- } else {
- let view = this->escape(Text::upper(viewName));
- }
+ let view = this->prepareTable(viewName, schemaName);
if ifExists {
return "DROP VIEW IF EXISTS " . view;
@@ -388,4 +374,17 @@ class Oracle extends Dialect
{
return false;
}
+
+ /**
+ * Prepares table for this RDBMS
+ */
+ protected function prepareTable(string! table, string schema = null, string alias = null, string escapeChar = null) -> string
+ {
+ return parent::prepareTable(
+ Text::upper(table),
+ Text::upper(schema),
+ alias,
+ escapeChar
+ );
+ }
}
diff --git a/phalcon/db/dialect/postgresql.zep b/phalcon/db/dialect/postgresql.zep
index 50b398f442d..744d8a0f34f 100644
--- a/phalcon/db/dialect/postgresql.zep
+++ b/phalcon/db/dialect/postgresql.zep
@@ -168,11 +168,7 @@ class Postgresql extends Dialect
{
var sql, defaultValue;
- if schemaName {
- let sql = "ALTER TABLE \"" . schemaName . "\".\"" . tableName . "\" ADD COLUMN ";
- } else {
- let sql = "ALTER TABLE \"" . tableName . "\" ADD COLUMN ";
- }
+ let sql = "ALTER TABLE " . this->prepareTable(tableName, schemaName) . " ADD COLUMN ";
let sql .= "\"" . column->getName() . "\" " . this->getColumnDefinition(column);
@@ -195,11 +191,7 @@ class Postgresql extends Dialect
{
var sql = "", sqlAlterTable, defaultValue;
- if schemaName {
- let sqlAlterTable = "ALTER TABLE \"" . schemaName . "\".\"" . tableName . "\"";
- } else {
- let sqlAlterTable = "ALTER TABLE \"" . tableName . "\"";
- }
+ let sqlAlterTable = "ALTER TABLE " . this->prepareTable(tableName, schemaName);
//Rename
if column->getName() != currentColumn->getName() {
@@ -239,17 +231,7 @@ class Postgresql extends Dialect
*/
public function dropColumn(string! tableName, string! schemaName, string! columnName) -> string
{
- var sql;
-
- if schemaName {
- let sql = "ALTER TABLE \"" . schemaName . "\".\"" . tableName."\" ";
- } else {
- let sql = "ALTER TABLE \"" . tableName . "\" ";
- }
-
- let sql .= " DROP COLUMN \"".columnName."\"";
-
- return sql;
+ return "ALTER TABLE " . this->prepareTable(tableName, schemaName) . " DROP COLUMN \"" . columnName . "\"";
}
/**
@@ -269,13 +251,7 @@ class Postgresql extends Dialect
if !empty indexType {
let sql .= " " . indexType;
}
- let sql .= " INDEX \"" . index->getName() . "\" ON";
-
- if schemaName {
- let sql .= " \"" . schemaName . "\".\"" . tableName."\"";
- } else {
- let sql .= " \"" . tableName . "\"";
- }
+ let sql .= " INDEX \"" . index->getName() . "\" ON " . this->prepareTable(tableName, schemaName);
let sql .= " (" . this->getColumnList(index->getColumns()) . ")";
return sql;
@@ -294,16 +270,7 @@ class Postgresql extends Dialect
*/
public function addPrimaryKey(string! tableName, string! schemaName, index) -> string
{
- var sql;
-
- if schemaName {
- let sql = "ALTER TABLE \"" . schemaName . "\".\"" . tableName . "\"";
- } else {
- let sql = "ALTER TABLE \"" . tableName . "\"";
- }
- let sql .= " ADD CONSTRAINT \"PRIMARY\" PRIMARY KEY (" . this->getColumnList(index->getColumns()) . ")";
-
- return sql;
+ return "ALTER TABLE " . this->prepareTable(tableName, schemaName) . " ADD CONSTRAINT \"PRIMARY\" PRIMARY KEY (" . this->getColumnList(index->getColumns()) . ")";
}
/**
@@ -311,16 +278,7 @@ class Postgresql extends Dialect
*/
public function dropPrimaryKey(string! tableName, string! schemaName) -> string
{
- var sql;
-
- if schemaName {
- let sql = "ALTER TABLE \"" . schemaName . "\".\"" . tableName . "\"";
- } else {
- let sql = "ALTER TABLE \"" . tableName . "\"";
- }
- let sql .= " DROP CONSTRAINT \"PRIMARY\"";
-
- return sql;
+ return "ALTER TABLE " . this->prepareTable(tableName, schemaName) . " DROP CONSTRAINT \"PRIMARY\"";
}
/**
@@ -330,12 +288,8 @@ class Postgresql extends Dialect
{
var sql, onDelete, onUpdate;
- if schemaName {
- let sql = "ALTER TABLE \"" . schemaName . "\".\"" . tableName . "\" ";
- } else {
- let sql = "ALTER TABLE \"" . tableName . "\" ";
- }
- let sql .= "ADD CONSTRAINT \"" . reference->getName() . "\" FOREIGN KEY (" . this->getColumnList(reference->getColumns()) . ")"
+ let sql = "ALTER TABLE " . this->prepareTable(tableName, schemaName)
+ . " ADD CONSTRAINT \"" . reference->getName() . "\" FOREIGN KEY (" . this->getColumnList(reference->getColumns()) . ")"
. " REFERENCES \"" . reference->getReferencedTable() . "\" (" . this->getColumnList(reference->getReferencedColumns()) . ")";
let onDelete = reference->getOnDelete();
@@ -356,17 +310,7 @@ class Postgresql extends Dialect
*/
public function dropForeignKey(string! tableName, string! schemaName, string! referenceName) -> string
{
- var sql;
-
- if schemaName {
- let sql = "ALTER TABLE \"" . schemaName . "\".\"" . tableName . "\"";
- } else {
- let sql = "ALTER TABLE \"" . tableName . "\"";
- }
-
- let sql .= " DROP CONSTRAINT \"" . referenceName . "\"" ;
-
- return sql;
+ return "ALTER TABLE " . this->prepareTable(tableName, schemaName) . " DROP CONSTRAINT \"" . referenceName . "\"";
}
/**
@@ -383,11 +327,7 @@ class Postgresql extends Dialect
throw new Exception("The index 'columns' is required in the definition array");
}
- if schemaName {
- let table = "\"" . schemaName . "\".\"" . tableName . "\"";
- } else {
- let table = "\"" . tableName . "\"";
- }
+ let table = this->prepareTable(tableName, schemaName);
let temporary = false;
if fetch options, definition["options"] {
@@ -466,13 +406,7 @@ class Postgresql extends Dialect
let indexSql = "CONSTRAINT \"" . indexName . "\" " . indexType . " (" . this->getColumnList(index->getColumns()) . ")";
} else {
- let indexSqlAfterCreate .= "CREATE INDEX \"" . index->getName() . "\" ON ";
-
- if schemaName {
- let indexSqlAfterCreate .= "\"" . schemaName . "\".\"" . tableName . "\"";
- } else {
- let indexSqlAfterCreate .= "\"" . tableName . "\"";
- }
+ let indexSqlAfterCreate .= "CREATE INDEX \"" . index->getName() . "\" ON " . this->prepareTable(tableName, schemaName);
let indexSqlAfterCreate .= " (" . this->getColumnList(index->getColumns()) . ");";
}
@@ -490,13 +424,9 @@ class Postgresql extends Dialect
let referenceSql = "CONSTRAINT \"" . reference->getName() . "\" FOREIGN KEY (" . this->getColumnList(reference->getColumns()) . ") REFERENCES ";
- if schemaName {
- let referenceSql .= "\"" . schemaName . "\".\"" . reference->getReferencedTable() . "\" ";
- } else {
- let referenceSql .= "\"" . reference->getReferencedTable() . "\" ";
- }
+ let referenceSql .= this->prepareTable(reference->getReferencedTable(), schemaName);
- let referenceSql .= "(" . this->getColumnList(reference->getReferencedColumns()) . ")";
+ let referenceSql .= " (" . this->getColumnList(reference->getReferencedColumns()) . ")";
let onDelete = reference->getOnDelete();
if !empty onDelete {
@@ -528,16 +458,12 @@ class Postgresql extends Dialect
{
var table, sql;
- if schemaName {
- let table = "\"" . schemaName . "\".\"" . tableName . "\"";
- } else {
- let table = "\"" . tableName . "\"";
- }
+ let table = this->prepareTable(tableName, schemaName);
if ifExists {
- let sql = "DROP TABLE IF EXISTS \"" . table . "\"";
+ let sql = "DROP TABLE IF EXISTS " . table;
} else {
- let sql = "DROP TABLE \"" . table . "\"";
+ let sql = "DROP TABLE " . table;
}
return sql;
@@ -548,19 +474,13 @@ class Postgresql extends Dialect
*/
public function createView(string! viewName, array! definition, string schemaName = null) -> string
{
- var viewSql, view;
+ var viewSql;
if !fetch viewSql, definition["sql"] {
throw new Exception("The index 'sql' is required in the definition array");
}
- if schemaName {
- let view = "\"" . schemaName . "\".\"" . viewName . "\"";
- } else {
- let view = "\"" . viewName . "\"";
- }
-
- return "CREATE VIEW " . view . " AS " . viewSql;
+ return "CREATE VIEW " . this->prepareTable(viewName, schemaName) . " AS " . viewSql;
}
/**
@@ -570,16 +490,12 @@ class Postgresql extends Dialect
{
var view, sql;
- if schemaName {
- let view = "\"" . schemaName . "\".\"" . viewName . "\"";
- } else {
- let view = "\"" . viewName . "\"";
- }
+ let view = this->prepareTable(viewName, schemaName);
if ifExists {
- let sql = "DROP VIEW IF EXISTS " . view . "";
+ let sql = "DROP VIEW IF EXISTS " . view;
} else {
- let sql = "DROP VIEW " . view . "";
+ let sql = "DROP VIEW " . view;
}
return sql;
diff --git a/phalcon/db/dialect/sqlite.zep b/phalcon/db/dialect/sqlite.zep
index 10c828fdf78..dbc13c7e80c 100644
--- a/phalcon/db/dialect/sqlite.zep
+++ b/phalcon/db/dialect/sqlite.zep
@@ -137,11 +137,7 @@ class Sqlite extends Dialect
{
var sql, defaultValue;
- if schemaName {
- let sql = "ALTER TABLE \"" . schemaName . "\".\"" . tableName . "\" ADD COLUMN ";
- } else {
- let sql = "ALTER TABLE \"" . tableName . "\" ADD COLUMN ";
- }
+ let sql = "ALTER TABLE " . this->prepareTable(tableName, schemaName) . " ADD COLUMN ";
let sql .= "\"" . column->getName() . "\" " . this->getColumnDefinition(column);
@@ -260,16 +256,12 @@ class Sqlite extends Dialect
{
var sql, table;
- if schemaName {
- let table = schemaName . "\".\"" . tableName;
- } else {
- let table = tableName;
- }
+ let table = this->prepareTable(tableName, schemaName);
if ifExists {
- let sql = "DROP TABLE IF EXISTS \"" . table . "\"";
+ let sql = "DROP TABLE IF EXISTS " . table;
} else {
- let sql = "DROP TABLE \"" . table . "\"";
+ let sql = "DROP TABLE " . table;
}
return sql;
@@ -280,19 +272,13 @@ class Sqlite extends Dialect
*/
public function createView(string! viewName, array! definition, string schemaName = null) -> string
{
- var view, viewSql;
+ var viewSql;
if !fetch viewSql, definition["sql"] {
throw new Exception("The index 'sql' is required in the definition array");
}
- if schemaName {
- let view = schemaName . "\".\"" . viewName;
- } else {
- let view = viewName;
- }
-
- return "CREATE VIEW \"" . view . "\" AS " . viewSql;
+ return "CREATE VIEW " . this->prepareTable(viewName, schemaName) . " AS " . viewSql;
}
/**
@@ -302,16 +288,12 @@ class Sqlite extends Dialect
{
var view;
- if schemaName {
- let view = schemaName . "\".\"" . viewName;
- } else {
- let view = viewName;
- }
+ let view = this->prepareTable(viewName, schemaName);
if ifExists {
- return "DROP VIEW IF EXISTS \"" . view . "\"";
+ return "DROP VIEW IF EXISTS " . view;
}
- return "DROP VIEW \"" . view . "\"";
+ return "DROP VIEW " . view;
}
/**
diff --git a/phalcon/db/profiler.zep b/phalcon/db/profiler.zep
index 94362e2e30c..552bce75c5c 100644
--- a/phalcon/db/profiler.zep
+++ b/phalcon/db/profiler.zep
@@ -60,7 +60,7 @@ class Profiler
/**
* All the Phalcon\Db\Profiler\Item in the active profile
*
- * @var array
+ * @var \Phalcon\Db\Profiler\Item[]
*/
protected _allProfiles;
@@ -174,4 +174,4 @@ class Profiler
{
return this->_activeProfile;
}
-}
\ No newline at end of file
+}
diff --git a/phalcon/db/rawvalue.zep b/phalcon/db/rawvalue.zep
index 9f23a90d0cd..4842e94dc2d 100644
--- a/phalcon/db/rawvalue.zep
+++ b/phalcon/db/rawvalue.zep
@@ -24,7 +24,7 @@ namespace Phalcon\Db;
*
* This class allows to insert/update raw data without quoting or formating.
*
- *The next example shows how to use the MySQL now() function as a field value.
+ * The next example shows how to use the MySQL now() function as a field value.
*
*
* $subscriber = new Subscribers();
diff --git a/phalcon/debug.zep b/phalcon/debug.zep
index 437b235920e..0b14739478b 100644
--- a/phalcon/debug.zep
+++ b/phalcon/debug.zep
@@ -52,7 +52,7 @@ class Debug
}
/**
- * Sets if files the exception"s backtrace must be showed
+ * Sets if files the exception's backtrace must be showed
*/
public function setShowBackTrace(boolean showBackTrace) ->
{
@@ -205,7 +205,7 @@ class Debug
*/
protected function _getVarDump(var variable) -> string
{
- var className, dumpedObject, dump;
+ var className, dumpedObject;
if is_scalar(variable) {
@@ -248,15 +248,14 @@ class Debug
/**
* dump() must return an array, generate a recursive representation using getArrayDump
*/
- let dump = "Object(" . className . ": " . this->_getArrayDump(dumpedObject) . ")";
+ return "Object(" . className . ": " . this->_getArrayDump(dumpedObject) . ")";
} else {
/**
* If dump() is not available just print the class name
*/
- let dump = "Object(" . className . ")";
+ return "Object(" . className . ")";
}
- return dump;
}
/**
@@ -334,26 +333,17 @@ class Debug
*/
protected final function showTraceItem(int n, array! trace)
{
- var space, twoSpaces, underscore, minus, className,
- prepareInternalClass, preparedFunctionName, html, classReflection, prepareUriClass,
+ var className, prepareInternalClass, preparedFunctionName, html, classReflection, prepareUriClass,
functionName, functionReflection, traceArgs, arguments, argument,
filez, line, showFiles, lines, numberLines, showFileFragment,
- beforeLine, firstLine, afterLine, lastLine, commentPattern, utf8, entCompat, tab,
- comment, i, linePosition, currentLine;
-
- let space = " ";
- let twoSpaces = " ";
- let underscore = "_";
- let minus = "-";
+ beforeLine, firstLine, afterLine, lastLine, i, linePosition, currentLine;
/**
* Every trace in the backtrace have a unique number
*/
let html = "#" . n . " | ";
- if isset trace["class"] {
-
- let className = trace["class"];
+ if fetch className, trace["class"] {
/**
* We assume that classes starting by Phalcon are framework's classes
@@ -378,7 +368,7 @@ class Debug
*/
if classReflection->isInternal() {
- let prepareInternalClass = str_replace(underscore, minus, strtolower(className));
+ let prepareInternalClass = str_replace("_", "-", strtolower(className));
/**
* Generate a link to the official docs
@@ -415,9 +405,9 @@ class Debug
*/
if functionReflection->isInternal() {
/**
- * Prepare function"s name according to the conventions in the docs
+ * Prepare function's name according to the conventions in the docs
*/
- let preparedFunctionName = str_replace(underscore, minus, functionName);
+ let preparedFunctionName = str_replace("_", "-", functionName);
let html .= "" . functionName . "";
} else {
let html .= "" . functionName . "";
@@ -430,16 +420,15 @@ class Debug
/**
* Check for arguments in the function
*/
- if isset trace["args"] {
+ if fetch traceArgs, trace["args"] {
- let traceArgs = trace["args"];
if count(traceArgs) {
let arguments = [];
for argument in traceArgs {
/**
* Every argument is generated using _getVarDump
- * Append the HTML generated to the argument"s list
+ * Append the HTML generated to the argument's list
*/
let arguments[] = "" . this->_getVarDump(argument) . "";
}
@@ -520,21 +509,6 @@ class Debug
let html .= "";
}
- let commentPattern = "#\\*\\/#";
-
- /**
- * We assume the file is utf-8 encoded, @TODO add an option for this
- */
- let utf8 = "UTF-8";
-
- /**
- * Don't escape quotes
- */
- let entCompat = ENT_COMPAT;
-
- let tab = "\t";
- let comment = "* /";
-
let i = firstLine;
while i <= lastLine {
@@ -553,8 +527,8 @@ class Debug
*/
if showFileFragment {
if i == firstLine {
- if preg_match(commentPattern, rtrim(currentLine)) {
- let currentLine = str_replace(comment, space, currentLine);
+ if preg_match("#\\*\\/#", rtrim(currentLine)) {
+ let currentLine = str_replace("* /", " ", currentLine);
}
}
}
@@ -562,14 +536,14 @@ class Debug
/**
* Print a non break space if the current line is a line break, this allows to show the html zebra properly
*/
- if currentLine == "\n" {
+ if currentLine == "\n" || currentLine == "\r\n" {
let html .= " \n";
} else {
- if currentLine == "\r\n" {
- let html .= " \n";
- } else {
- let html .= htmlentities(str_replace(tab, twoSpaces, currentLine), entCompat, utf8);
- }
+ /**
+ * Don't escape quotes
+ * We assume the file is utf-8 encoded, @TODO add an option for this
+ */
+ let html .= htmlentities(str_replace("\t", " ", currentLine), ENT_COMPAT, "UTF-8");
}
let i++;
@@ -729,7 +703,7 @@ class Debug
/**
* Print extra variables passed to the component
*/
- if typeof dataVars == "array" {
+ if typeof dataVars == "array" {
let html .= "";
let html .= "Key | Value | ";
for keyVar, dataVar in dataVars {
@@ -744,7 +718,7 @@ class Debug
/**
* Get Javascript sources
*/
- let html .= this->getJsSources() . " | | | | |