protected function getNestedOptVal( array $options, $arg )
    {
        //@codeCoverageIgnoreStart
        $args = func_get_args();
        
        if ( count( $args ) == 2 && is_array( $args[1] ) ) {
            $args = $args[1];
        } else if ( count( $args ) < 3 ) {
            throw new \BadMethodCallException( '\Altamira\JsWriterAbstract::getNestedOptVal requires at least three arguments' );
        } else {
            array_shift( $args );
        }
        
        do {
            $arg = array_shift( $args );
            
            if (! isset( $options[$arg] ) ) {
                return null;
            }
            $options = &$options[$arg];
            
        } while ( count( $args ) > 1 );
        
        $finalArg = array_shift( $args );
        return isset( $options[$finalArg] ) ? $options[$finalArg] : null;
        //@codeCoverageIgnoreEnd
    }
protected function getNestedOptVal( array $options, $arg )
    {
        //@codeCoverageIgnoreStart
        $args = func_get_args();
        
        if ( count( $args ) == 2 && is_array( $args[1] ) ) {
            $args = $args[1];
        } else if ( count( $args ) < 3 ) {
            throw new \BadMethodCallException( '\Altamira\JsWriterAbstract::getNestedOptVal requires at least three arguments' );
        } else {
            array_shift( $args );
        }
        
        do {
            $arg = array_shift( $args );
            
            if (! isset( $options[$arg] ) ) {
                return null;
            }
            $options = &$options[$arg];
            
        } while ( count( $args ) > 1 );
        
        $finalArg = array_shift( $args );
        return isset( $options[$finalArg] ) ? $options[$finalArg] : null;
        //@codeCoverageIgnoreEnd
    }
protected function getNestedOptVal ( array $ options , $ arg ) { //@codeCoverageIgnoreStart $ args = func_get_args ( ) ; if ( count ( $ args ) == 2 && is_array ( $ args [ 1 ] ) ) { $ args = $ args [ 1 ] ; } else if ( count ( $ args ) < 3 ) { throw new \ BadMethodCallException ( '\Altamira\JsWriterAbstract::getNestedOptVal requires at least three arguments' ) ; } else { array_shift ( $ args ) ; } do { $ arg = array_shift ( $ args ) ; if ( ! isset ( $ options [ $ arg ] ) ) { return null ; } $ options = & $ options [ $ arg ] ; } while ( count ( $ args ) > 1 ) ; $ finalArg = array_shift ( $ args ) ; return isset ( $ options [ $ finalArg ] ) ? $ options [ $ finalArg ] : null ; //@codeCoverageIgnoreEnd }
Allows you to get the value for discretely infinite nesting without notices
by returning null without a warning if it doesn't exist
@param array $options
@param mixed $arg the first of any number of arguments to nest through an array, the final of which being the value to return
@return mixed
Allows you to get the value for discretely infinite nesting without notices by returning null without a warning if it doesn t exist