private function _subcompile(
        $className)
    {
        // Sub-compile the target class. If this DOESN'T throw, we know that the
        // target class successfully exists in the compilation cache afterwards.
        // NOTE: If it throws, we know that IT has already rolled back all its
        // changes itself via its own compile()-catch, so WE don't have to worry
        // about reading its state on error. We ONLY care when it succeeds.
        $subCompiler = new self( // Throws.
            false, // Is NOT the root call!
            $this->_propertyMapCache, // Use the same cache to share locks.
            $className
        );
        $subCompiler->compile(); // Throws.

        // Add its state of successfully compiled classes to our own list of
        // compiled classes, so that the info is preserved throughout the stack.
        // NOTE: This is EXTREMELY important, so that we can clear those classes
        // from the cache in case ANY other step of the compilation chain fails
        // unexpectedly. Because in that case, we'll NEED to be able to roll
        // back ALL of our entire compile-chain's property map cache changes!
        // NOTE: The merge function de-duplicates keys!
        $this->compiledClasses = array_merge(
            $this->compiledClasses,
            $subCompiler->compiledClasses
        );

        // Add the sub-compiled class hierarchy's own encountered property-
        // classes to our list of encountered classes. It gives us everything
        // from their extends-hierarchy and everything from their own imports.
        // And in case they had multi-level chained imports (classes that import
        // classes that import classes), it'll actually be containing a FULLY
        // recursively resolved and merged sub-import list. We will get them ALL
        // from their WHOLE sub-hierarchy! Exactly as intended.
        // NOTE: The merge function de-duplicates keys!
        $this->uncompiledPropertyClasses = array_merge(
            $this->uncompiledPropertyClasses,
            $subCompiler->uncompiledPropertyClasses
        );
    }
private function _subcompile(
        $className)
    {
        // Sub-compile the target class. If this DOESN'T throw, we know that the
        // target class successfully exists in the compilation cache afterwards.
        // NOTE: If it throws, we know that IT has already rolled back all its
        // changes itself via its own compile()-catch, so WE don't have to worry
        // about reading its state on error. We ONLY care when it succeeds.
        $subCompiler = new self( // Throws.
            false, // Is NOT the root call!
            $this->_propertyMapCache, // Use the same cache to share locks.
            $className
        );
        $subCompiler->compile(); // Throws.

        // Add its state of successfully compiled classes to our own list of
        // compiled classes, so that the info is preserved throughout the stack.
        // NOTE: This is EXTREMELY important, so that we can clear those classes
        // from the cache in case ANY other step of the compilation chain fails
        // unexpectedly. Because in that case, we'll NEED to be able to roll
        // back ALL of our entire compile-chain's property map cache changes!
        // NOTE: The merge function de-duplicates keys!
        $this->compiledClasses = array_merge(
            $this->compiledClasses,
            $subCompiler->compiledClasses
        );

        // Add the sub-compiled class hierarchy's own encountered property-
        // classes to our list of encountered classes. It gives us everything
        // from their extends-hierarchy and everything from their own imports.
        // And in case they had multi-level chained imports (classes that import
        // classes that import classes), it'll actually be containing a FULLY
        // recursively resolved and merged sub-import list. We will get them ALL
        // from their WHOLE sub-hierarchy! Exactly as intended.
        // NOTE: The merge function de-duplicates keys!
        $this->uncompiledPropertyClasses = array_merge(
            $this->uncompiledPropertyClasses,
            $subCompiler->uncompiledPropertyClasses
        );
    }
private function _subcompile ( $ className ) { // Sub-compile the target class. If this DOESN'T throw, we know that the // target class successfully exists in the compilation cache afterwards. // NOTE: If it throws, we know that IT has already rolled back all its // changes itself via its own compile()-catch, so WE don't have to worry // about reading its state on error. We ONLY care when it succeeds. $ subCompiler = new self ( // Throws. false , // Is NOT the root call! $ this -> _propertyMapCache , // Use the same cache to share locks. $ className ) ; $ subCompiler -> compile ( ) ; // Throws. // Add its state of successfully compiled classes to our own list of // compiled classes, so that the info is preserved throughout the stack. // NOTE: This is EXTREMELY important, so that we can clear those classes // from the cache in case ANY other step of the compilation chain fails // unexpectedly. Because in that case, we'll NEED to be able to roll // back ALL of our entire compile-chain's property map cache changes! // NOTE: The merge function de-duplicates keys! $ this -> compiledClasses = array_merge ( $ this -> compiledClasses , $ subCompiler -> compiledClasses ) ; // Add the sub-compiled class hierarchy's own encountered property- // classes to our list of encountered classes. It gives us everything // from their extends-hierarchy and everything from their own imports. // And in case they had multi-level chained imports (classes that import // classes that import classes), it'll actually be containing a FULLY // recursively resolved and merged sub-import list. We will get them ALL // from their WHOLE sub-hierarchy! Exactly as intended. // NOTE: The merge function de-duplicates keys! $ this -> uncompiledPropertyClasses = array_merge ( $ this -> uncompiledPropertyClasses , $ subCompiler -> uncompiledPropertyClasses ) ; }
Used internally when this compiler needs to run a sub-compilation.

Performs the sub-compile. And if it was successful (meaning it had no
auto-rollbacks due to ITS `compile()` call failing), then we'll merge its
compiler state with our own so that we preserve important state details.

@param string $className The full path of the class to sub-compile, but
without any leading `\` global prefix. To save
time, we assume the caller has already verified
that it is a valid `LazyJsonMapper` class.

@throws BadPropertyDefinitionException
@throws BadPropertyMapException
@throws CircularPropertyMapException
Used internally when this compiler needs to run a sub - compilation .