protected static function addElementToFilteredArray($key, $value)
    {
        if (is_null(self::$filteringCallback)) {
            return ($value);
        }

        if (is_string(self::$filteringCallback) && function_exists(self::$filteringCallback)) {
            $callback = self::$filteringCallback;

            return $callback($key, $value);
        }

        return call_user_func(self::$filteringCallback, $key, $value);
    }