protected static function _getPluginData(array $data, $key = null)
    {
        if (isset($data[$key])) {
            $data = $data[$key];
        }

        return new Data($data);
    }
protected static function _getPluginData(array $data, $key = null)
    {
        if (isset($data[$key])) {
            $data = $data[$key];
        }

        return new Data($data);
    }
protected static function _getPluginData ( array $ data , $ key = null ) { if ( isset ( $ data [ $ key ] ) ) { $ data = $ data [ $ key ] ; } return new Data ( $ data ) ; }
Get current plugin data.

@param array $data
@param null|string $key
@return Data
Get current plugin data .