3v4l.org

run code in 300+ PHP versions simultaneously
<?php /** * @xmlNamespace http://www.webservices.nl/soap/ * @xmlType * @xmlName RiskAddress */ class Address { /** * @xmlType string * @xmlRender value * @xmlName postcode * @xmlNamespace http://www.webservices.nl/soap/ */ protected $_postcode; /** * @xmlType string * @xmlRender value * @xmlName building * @xmlNamespace http://www.webservices.nl/soap/ */ protected $_building; /** * @xmlType string * @xmlRender value * @xmlName street * @xmlNamespace http://www.webservices.nl/soap/ */ protected $_street; /** * @xmlType integer * @xmlRender value * @xmlName house_number * @xmlNamespace http://www.webservices.nl/soap/ */ protected $_house_number; /** * @xmlType string * @xmlRender value * @xmlName house_number_addition * @xmlNamespace http://www.webservices.nl/soap/ */ protected $_house_number_addition; /** * @xmlType string * @xmlRender value * @xmlName city * @xmlNamespace http://www.webservices.nl/soap/ */ protected $_city; /** * @xmlType string * @xmlRender value * @xmlName municipality * @xmlNamespace http://www.webservices.nl/soap/ */ protected $_municipality; /** * @xmlType string * @xmlRender value * @xmlName state * @xmlNamespace http://www.webservices.nl/soap/ */ protected $_state; /** * @xmlType string * @xmlRender value * @xmlName country * @xmlNamespace http://www.webservices.nl/soap/ */ protected $_country; /** * @return string */ public function getPostcode() { return $this->_postcode; } /** * @param string $postcode */ public function setPostcode($postcode) { $this->_postcode = (string) $postcode; } /** * @return string */ public function getBuilding() { return $this->_building; } /** * @param string $building */ public function setBuilding($building) { $this->_building = (string) $building; } /** * @return string */ public function getStreet() { return $this->_street; } /** * @param string $street */ public function setStreet($street) { $this->_street = (string) $street; } /** * @return integer */ public function getHouseNumber() { return $this->_house_number; } /** * @param (integer) $houseNumber */ public function setHouseNumber($houseNumber) { $this->_house_number = (integer) $houseNumber; } /** * @return string */ public function getHouseNumberAddition() { return $this->_house_number_addition; } /** * @param string $houseNumberAddition */ public function setHouseNumberAddition($houseNumberAddition) { $this->_house_number_addition = (string) $houseNumberAddition; } /** * @return string */ public function getCity() { return $this->_city; } /** * @param string $city */ public function setCity($city) { $this->_city = (string) $city; } /** * @return string */ public function getMunicipality() { return $this->_municipality; } /** * @param string $municipality */ public function setMunicipality($municipality) { $this->_municipality = $municipality; } /** * @return string */ public function getState() { return $this->_state; } /** * @param string $state */ public function setState($state) { $this->_state = (string) $state; } /** * @return string */ public function getCountry() { return $this->_country; } /** * @param string $country */ public function setCountry($country) { $this->_country = (string) $country; } } class AddressHelper { public static function parse(Address $address, $parts) { $parts = func_get_args(); $address = array_shift($parts); $format = '~^(.*?\n)??' . '(?<street>[^0-9].*|.*?[^0-9])[\b\s]*?' . '(?<number>[0-9]{1,5}?)[\b\s\-]*?' . '(?<addition>[^\s]*?)[\b\s,]*?' . '(?<postcode>[0-9]{4}\s?[A-Z]{2})[\b\s,]*?' . '(?<city>[\w][\w\s]*?)' . '(\n.*)??$~msiU'; if (preg_match($format, implode(PHP_EOL, $parts), $args)) { $street = $number = $postcode = $city = $addition = null; extract($args, EXTR_OVERWRITE); $address->setStreet($street); $address->setHouseNumber($number); $address->setHouseNumberAddition($addition); $address->setPostcode($postcode); $address->setCity(strtoupper(trim($city))); } return $address; } } class Marshaller { protected $_includeNilValues = true; public function __construct($includeNilValues = true) { $this->_includeNilValues = $includeNilValues; } public function marshall($object) { return $this->_marshallObject($object); } protected function _marshallObject($object) { $output = array(); $refClass = new ReflectionClass($object); foreach ($refClass->getProperties(ReflectionProperty::IS_PROTECTED | ReflectionProperty::IS_PUBLIC) as $refProp) { $propValue = $object->{$this->_getPropertyAccessor($refProp->getName())}(); $this->_marshallProperty($refProp->getName(), $propValue, $output); } return $output; } protected function _marshallProperty($propName, &$propValue, array &$output) { if (($propValue === null || $propValue === '') && $this->_includeNilValues === false) return; if (is_object($propValue)) { $this->_assignArrayValue($output, $this->_getPropertyArrayKey($propName), $this->_marshallObject($propValue)); } elseif (is_array($propValue)) { $arrayOutput = array(); foreach ($propValue as $nestedPropVal) { $array = array(); $this->_marshallProperty($this->_getPropertyArrayKey($propName), $nestedPropVal, $array); $arrayOutput = array_merge_recursive($arrayOutput, array(array_shift($array))); } if ('' !== implode('', $arrayOutput)) $output[$this->_getPropertyArrayKey($propName)] = $arrayOutput; } else { $this->_assignArrayValue($output, $this->_getPropertyArrayKey($propName), $propValue); } } protected function _assignArrayValue(array &$output, $key, $value) { // remove empty arrays when include nilvalues is set to true if (false === $this->_includeNilValues && is_array($value) && empty($value) && '' == implode('', $value)) { return; } if (false === $this->_includeNilValues && (is_null($value) || $value === '')) { return; } $output[$key] = $value; } /** * Convert a class property name to an array key * @param string $propName * @return string */ protected function _getPropertyArrayKey($propName) { return ltrim($propName, '_'); } /** * Get the accessor for a class property name * @param string $propName * @return string */ protected function _getPropertyAccessor($propName) { $propName = ltrim($propName, '_'); $propParts = explode('_', $propName); foreach ($propParts as &$propPart) { $propPart = ucfirst($propPart); } return 'get' . implode('', $propParts); } public function includeNilValues() { $this->_includeNilValues = true; } public function excludeNilValues() { $this->_includeNilValues = false; } } //$parsedAddress = AddressHelper::parse(new Address(), null, null, null, null, null)); $address = new Address(); $marshaller = new Marshaller(true); $marshaller->marshall($address); $marshaller->marshall($address); var_dump($marshaller->marshall($address));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  (null)
number of ops:  20
compiled vars:  !0 = $address, !1 = $marshaller
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  372     0  E >   NEW                                              $2      'Address'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $2
  374     3        NEW                                              $5      'Marshaller'
          4        SEND_VAL_EX                                              <true>
          5        DO_FCALL                                      0          
          6        ASSIGN                                                   !1, $5
  376     7        INIT_METHOD_CALL                                         !1, 'marshall'
          8        SEND_VAR_EX                                              !0
          9        DO_FCALL                                      0          
  377    10        INIT_METHOD_CALL                                         !1, 'marshall'
         11        SEND_VAR_EX                                              !0
         12        DO_FCALL                                      0          
  378    13        INIT_FCALL                                               'var_dump'
         14        INIT_METHOD_CALL                                         !1, 'marshall'
         15        SEND_VAR_EX                                              !0
         16        DO_FCALL                                      0  $10     
         17        SEND_VAR                                                 $10
         18        DO_ICALL                                                 
         19      > RETURN                                                   1

Class Address:
Function getpostcode:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  getPostcode
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   88     0  E >   FETCH_OBJ_R                                      ~0      '_postcode'
          1      > RETURN                                                   ~0
   89     2*     > RETURN                                                   null

End of function getpostcode

Function setpostcode:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  setPostcode
number of ops:  5
compiled vars:  !0 = $postcode
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   94     0  E >   RECV                                             !0      
   96     1        CAST                                          6  ~2      !0
          2        ASSIGN_OBJ                                               '_postcode'
          3        OP_DATA                                                  ~2
   97     4      > RETURN                                                   null

End of function setpostcode

Function getbuilding:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  getBuilding
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  104     0  E >   FETCH_OBJ_R                                      ~0      '_building'
          1      > RETURN                                                   ~0
  105     2*     > RETURN                                                   null

End of function getbuilding

Function setbuilding:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  setBuilding
number of ops:  5
compiled vars:  !0 = $building
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  110     0  E >   RECV                                             !0      
  112     1        CAST                                          6  ~2      !0
          2        ASSIGN_OBJ                                               '_building'
          3        OP_DATA                                                  ~2
  113     4      > RETURN                                                   null

End of function setbuilding

Function getstreet:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  getStreet
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  120     0  E >   FETCH_OBJ_R                                      ~0      '_street'
          1      > RETURN                                                   ~0
  121     2*     > RETURN                                                   null

End of function getstreet

Function setstreet:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  setStreet
number of ops:  5
compiled vars:  !0 = $street
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  126     0  E >   RECV                                             !0      
  128     1        CAST                                          6  ~2      !0
          2        ASSIGN_OBJ                                               '_street'
          3        OP_DATA                                                  ~2
  129     4      > RETURN                                                   null

End of function setstreet

Function gethousenumber:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  getHouseNumber
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  136     0  E >   FETCH_OBJ_R                                      ~0      '_house_number'
          1      > RETURN                                                   ~0
  137     2*     > RETURN                                                   null

End of function gethousenumber

Function sethousenumber:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  setHouseNumber
number of ops:  5
compiled vars:  !0 = $houseNumber
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  142     0  E >   RECV                                             !0      
  144     1        CAST                                          4  ~2      !0
          2        ASSIGN_OBJ                                               '_house_number'
          3        OP_DATA                                                  ~2
  145     4      > RETURN                                                   null

End of function sethousenumber

Function gethousenumberaddition:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  getHouseNumberAddition
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  152     0  E >   FETCH_OBJ_R                                      ~0      '_house_number_addition'
          1      > RETURN                                                   ~0
  153     2*     > RETURN                                                   null

End of function gethousenumberaddition

Function sethousenumberaddition:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  setHouseNumberAddition
number of ops:  5
compiled vars:  !0 = $houseNumberAddition
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  158     0  E >   RECV                                             !0      
  160     1        CAST                                          6  ~2      !0
          2        ASSIGN_OBJ                                               '_house_number_addition'
          3        OP_DATA                                                  ~2
  161     4      > RETURN                                                   null

End of function sethousenumberaddition

Function getcity:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  getCity
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  168     0  E >   FETCH_OBJ_R                                      ~0      '_city'
          1      > RETURN                                                   ~0
  169     2*     > RETURN                                                   null

End of function getcity

Function setcity:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  setCity
number of ops:  5
compiled vars:  !0 = $city
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  174     0  E >   RECV                                             !0      
  176     1        CAST                                          6  ~2      !0
          2        ASSIGN_OBJ                                               '_city'
          3        OP_DATA                                                  ~2
  177     4      > RETURN                                                   null

End of function setcity

Function getmunicipality:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  getMunicipality
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  184     0  E >   FETCH_OBJ_R                                      ~0      '_municipality'
          1      > RETURN                                                   ~0
  185     2*     > RETURN                                                   null

End of function getmunicipality

Function setmunicipality:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  setMunicipality
number of ops:  4
compiled vars:  !0 = $municipality
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  190     0  E >   RECV                                             !0      
  192     1        ASSIGN_OBJ                                               '_municipality'
          2        OP_DATA                                                  !0
  193     3      > RETURN                                                   null

End of function setmunicipality

Function getstate:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  getState
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  200     0  E >   FETCH_OBJ_R                                      ~0      '_state'
          1      > RETURN                                                   ~0
  201     2*     > RETURN                                                   null

End of function getstate

Function setstate:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  setState
number of ops:  5
compiled vars:  !0 = $state
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  206     0  E >   RECV                                             !0      
  208     1        CAST                                          6  ~2      !0
          2        ASSIGN_OBJ                                               '_state'
          3        OP_DATA                                                  ~2
  209     4      > RETURN                                                   null

End of function setstate

Function getcountry:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  getCountry
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  216     0  E >   FETCH_OBJ_R                                      ~0      '_country'
          1      > RETURN                                                   ~0
  217     2*     > RETURN                                                   null

End of function getcountry

Function setcountry:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  setCountry
number of ops:  5
compiled vars:  !0 = $country
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  222     0  E >   RECV                                             !0      
  224     1        CAST                                          6  ~2      !0
          2        ASSIGN_OBJ                                               '_country'
          3        OP_DATA                                                  ~2
  225     4      > RETURN                                                   null

End of function setcountry

End of class Address.

Class AddressHelper:
Function parse:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 19, Position 2 = 49
Branch analysis from position: 19
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 49
filename:       /in/Tu1Ns
function name:  parse
number of ops:  51
compiled vars:  !0 = $address, !1 = $parts, !2 = $format, !3 = $args, !4 = $street, !5 = $number, !6 = $postcode, !7 = $city, !8 = $addition
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  232     0  E >   RECV                                             !0      
          1        RECV                                             !1      
  234     2        FUNC_GET_ARGS                                    ~9      
          3        ASSIGN                                                   !1, ~9
  235     4        INIT_FCALL                                               'array_shift'
          5        SEND_REF                                                 !1
          6        DO_ICALL                                         $11     
          7        ASSIGN                                                   !0, $11
  237     8        ASSIGN                                                   !2, '%7E%5E%28.%2A%3F%5Cn%29%3F%3F%28%3F%3Cstreet%3E%5B%5E0-9%5D.%2A%7C.%2A%3F%5B%5E0-9%5D%29%5B%5Cb%5Cs%5D%2A%3F%28%3F%3Cnumber%3E%5B0-9%5D%7B1%2C5%7D%3F%29%5B%5Cb%5Cs%5C-%5D%2A%3F%28%3F%3Caddition%3E%5B%5E%5Cs%5D%2A%3F%29%5B%5Cb%5Cs%2C%5D%2A%3F%28%3F%3Cpostcode%3E%5B0-9%5D%7B4%7D%5Cs%3F%5BA-Z%5D%7B2%7D%29%5B%5Cb%5Cs%2C%5D%2A%3F%28%3F%3Ccity%3E%5B%5Cw%5D%5B%5Cw%5Cs%5D%2A%3F%29%28%5Cn.%2A%29%3F%3F%24%7EmsiU'
  245     9        INIT_FCALL                                               'preg_match'
         10        SEND_VAR                                                 !2
         11        INIT_FCALL                                               'implode'
         12        SEND_VAL                                                 '%0A'
         13        SEND_VAR                                                 !1
         14        DO_ICALL                                         $14     
         15        SEND_VAR                                                 $14
         16        SEND_REF                                                 !3
         17        DO_ICALL                                         $15     
         18      > JMPZ                                                     $15, ->49
  247    19    >   ASSIGN                                           ~16     !8, null
         20        ASSIGN                                           ~17     !7, ~16
         21        ASSIGN                                           ~18     !6, ~17
         22        ASSIGN                                           ~19     !5, ~18
         23        ASSIGN                                                   !4, ~19
  249    24        INIT_FCALL                                               'extract'
         25        SEND_REF                                                 !3
         26        SEND_VAL                                                 0
         27        DO_ICALL                                                 
  251    28        INIT_METHOD_CALL                                         !0, 'setStreet'
         29        SEND_VAR_EX                                              !4
         30        DO_FCALL                                      0          
  252    31        INIT_METHOD_CALL                                         !0, 'setHouseNumber'
         32        SEND_VAR_EX                                              !5
         33        DO_FCALL                                      0          
  253    34        INIT_METHOD_CALL                                         !0, 'setHouseNumberAddition'
         35        SEND_VAR_EX                                              !8
         36        DO_FCALL                                      0          
  254    37        INIT_METHOD_CALL                                         !0, 'setPostcode'
         38        SEND_VAR_EX                                              !6
         39        DO_FCALL                                      0          
  255    40        INIT_METHOD_CALL                                         !0, 'setCity'
         41        INIT_FCALL                                               'strtoupper'
         42        INIT_FCALL                                               'trim'
         43        SEND_VAR                                                 !7
         44        DO_ICALL                                         $26     
         45        SEND_VAR                                                 $26
         46        DO_ICALL                                         $27     
         47        SEND_VAR_NO_REF_EX                                       $27
         48        DO_FCALL                                      0          
  258    49    > > RETURN                                                   !0
  259    50*     > RETURN                                                   null

End of function parse

End of class AddressHelper.

Class Marshaller:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  __construct
number of ops:  4
compiled vars:  !0 = $includeNilValues
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  266     0  E >   RECV_INIT                                        !0      <true>
  268     1        ASSIGN_OBJ                                               '_includeNilValues'
          2        OP_DATA                                                  !0
  269     3      > RETURN                                                   null

End of function __construct

Function marshall:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tu1Ns
function name:  marshall
number of ops:  6
compiled vars:  !0 = $object
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  271     0  E >   RECV                                             !0      
  273     1        INIT_METHOD_CALL                                         '_marshallObject'
          2        SEND_VAR_EX                                              !0
          3        DO_FCALL                                      0  $1      
          4      > RETURN                                                   $1
  274     5*     > RETURN                                                   null

End of function marshall

Function _marshallobject:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 10, Position 2 = 27
Branch analysis from position: 10
2 jumps found. (Code = 78) Position 1 = 11, Position 2 = 27
Branch analysis from position: 11
1 jumps found. (Code = 42) Position 1 = 10
Branch analysis from position: 10
Branch analysis from position: 27
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 27
filename:       /in/Tu1Ns
function name:  _marshallObject
number of ops:  30
compiled vars:  !0 = $object, !1 = $output, !2 = $refClass, !3 = $refProp, !4 = $propValue
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  276     0  E >   RECV                                             !0      
  278     1        ASSIGN                                                   !1, <array>
  279     2        NEW                                              $6      'ReflectionClass'
          3        SEND_VAR_EX                                              !0
          4        DO_FCALL                                      0          
          5        ASSIGN                                                   !2, $6
  281     6        INIT_METHOD_CALL                                         !2, 'getProperties'
          7        SEND_VAL_EX                                              3
          8        DO_FCALL                                      0  $9      
          9      > FE_RESET_R                                       $10     $9, ->27
         10    > > FE_FETCH_R                                               $10, !3, ->27
  283    11    >   INIT_METHOD_CALL                                         '_getPropertyAccessor'
         12        INIT_METHOD_CALL                                         !3, 'getName'
         13        DO_FCALL                                      0  $11     
         14        SEND_VAR_NO_REF_EX                                       $11
         15        DO_FCALL                                      0  $12     
         16        INIT_METHOD_CALL                                         !0, $12
         17        DO_FCALL                                      0  $13     
         18        ASSIGN                                                   !4, $13
  284    19        INIT_METHOD_CALL                                         '_marshallProperty'
         20        INIT_METHOD_CALL                                         !3, 'getName'
         21        DO_FCALL                                      0  $15     
         22        SEND_VAR_NO_REF_EX                                       $15
         23        SEND_VAR_EX                                              !4
         24        SEND_VAR_EX                                              !1
         25        DO_FCALL                                      0          
  281    26      > JMP                                                      ->10
         27    >   FE_FREE                                                  $10
  286    28      > RETURN                                                   !1
  287    29*     > RETURN                                                   null

End of function _marshallobject

Function _marshallproperty:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 47) Position 1 = 5, Position 2 = 7
Branch analysis from position: 5
2 jumps found. (Code = 46) Position 1 = 8, Position 2 = 11
Branch analysis from position: 8
2 jumps found. (Code = 43) Position 1 = 12, Position 2 = 13
Branch analysis from position: 12
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 13
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 27
Branch analysis from position: 15
1 jumps found. (Code = 42) Position 1 = 72
Branch analysis from position: 72
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 27
2 jumps found. (Code = 43) Position 1 = 29, Position 2 = 64
Branch analysis from position: 29
2 jumps found. (Code = 77) Position 1 = 31, Position 2 = 51
Branch analysis from position: 31
2 jumps found. (Code = 78) Position 1 = 32, Position 2 = 51
Branch analysis from position: 32
1 jumps found. (Code = 42) Position 1 = 31
Branch analysis from position: 31
Branch analysis from position: 51
2 jumps found. (Code = 43) Position 1 = 58, Position 2 = 63
Branch analysis from position: 58
1 jumps found. (Code = 42) Position 1 = 72
Branch analysis from position: 72
Branch analysis from position: 63
Branch analysis from position: 51
Branch analysis from position: 64
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 11
Branch analysis from position: 7
filename:       /in/Tu1Ns
function name:  _marshallProperty
number of ops:  73
compiled vars:  !0 = $propName, !1 = $propValue, !2 = $output, !3 = $arrayOutput, !4 = $nestedPropVal, !5 = $array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
  289     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV                                             !2      
  291     3        TYPE_CHECK                                    2  ~6      !1
          4      > JMPNZ_EX                                         ~6      ~6, ->7
          5    >   IS_IDENTICAL                                     ~7      !1, ''
          6        BOOL                                             ~6      ~7
          7    > > JMPZ_EX                                          ~6      ~6, ->11
          8    >   FETCH_OBJ_R                                      ~8      '_includeNilValues'
          9        TYPE_CHECK                                    4  ~9      ~8
         10        BOOL                                             ~6      ~9
         11    > > JMPZ                                                     ~6, ->13
  292    12    > > RETURN                                                   null
  294    13    >   TYPE_CHECK                                  256          !1
         14      > JMPZ                                                     ~10, ->27
  296    15    >   INIT_METHOD_CALL                                         '_assignArrayValue'
         16        SEND_VAR_EX                                              !2
         17        INIT_METHOD_CALL                                         '_getPropertyArrayKey'
         18        SEND_VAR_EX                                              !0
         19        DO_FCALL                                      0  $11     
         20        SEND_VAR_NO_REF_EX                                       $11
         21        INIT_METHOD_CALL                                         '_marshallObject'
         22        SEND_VAR_EX                                              !1
         23        DO_FCALL                                      0  $12     
         24        SEND_VAR_NO_REF_EX                                       $12
         25        DO_FCALL                                      0          
         26      > JMP                                                      ->72
  298    27    >   TYPE_CHECK                                  128          !1
         28      > JMPZ                                                     ~14, ->64
  300    29    >   ASSIGN                                                   !3, <array>
  301    30      > FE_RESET_R                                       $16     !1, ->51
         31    > > FE_FETCH_R                                               $16, !4, ->51
  303    32    >   ASSIGN                                                   !5, <array>
  304    33        INIT_METHOD_CALL                                         '_marshallProperty'
         34        INIT_METHOD_CALL                                         '_getPropertyArrayKey'
         35        SEND_VAR_EX                                              !0
         36        DO_FCALL                                      0  $18     
         37        SEND_VAR_NO_REF_EX                                       $18
         38        SEND_VAR_EX                                              !4
         39        SEND_VAR_EX                                              !5
         40        DO_FCALL                                      0          
  305    41        INIT_FCALL                                               'array_merge_recursive'
         42        SEND_VAR                                                 !3
         43        INIT_FCALL                                               'array_shift'
         44        SEND_REF                                                 !5
         45        DO_ICALL                                         $20     
         46        INIT_ARRAY                                       ~21     $20
         47        SEND_VAL                                                 ~21
         48        DO_ICALL                                         $22     
         49        ASSIGN                                                   !3, $22
  301    50      > JMP                                                      ->31
         51    >   FE_FREE                                                  $16
  307    52        INIT_FCALL                                               'implode'
         53        SEND_VAL                                                 ''
         54        SEND_VAR                                                 !3
         55        DO_ICALL                                         $24     
         56        IS_NOT_IDENTICAL                                         $24, ''
         57      > JMPZ                                                     ~25, ->63
  308    58    >   INIT_METHOD_CALL                                         '_getPropertyArrayKey'
         59        SEND_VAR_EX                                              !0
         60        DO_FCALL                                      0  $26     
         61        ASSIGN_DIM                                               !2, $26
         62        OP_DATA                                                  !3
         63    > > JMP                                                

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.98 ms | 1420 KiB | 29 Q