src/Shared/Attribute/StaticVarTrait.php
protected static function getStaticVar($staticVarName)/*# : array */
    {
        $class = get_called_class();
        $parent = get_parent_class($class);

        // get current class' static variable
        $res = $class::${$staticVarName};

        // merge with ancestor class' same static variable
        if ($parent && property_exists($parent, $staticVarName)) {
            $res = $parent::getStaticVar($staticVarName);
            if ($class::${$staticVarName} != $parent::${$staticVarName}) {
                $res = array_replace_recursive($res, $class::${$staticVarName});
            }
        }

        return $res;
    }
protected static function getStaticVar($staticVarName)/*# : array */
    {
        $class = get_called_class();
        $parent = get_parent_class($class);

        // get current class' static variable
        $res = $class::${$staticVarName};

        // merge with ancestor class' same static variable
        if ($parent && property_exists($parent, $staticVarName)) {
            $res = $parent::getStaticVar($staticVarName);
            if ($class::${$staticVarName} != $parent::${$staticVarName}) {
                $res = array_replace_recursive($res, $class::${$staticVarName});
            }
        }

        return $res;
    }
Get MERGED/REPLACED static variable for CURRENT class

@param  string $staticVarName static variable name
@return array
@access protected
@static