public static function validateOptions(array $config)
    {
        if (!isset($config['expected'])) {
            throw new \InvalidArgumentException('expected is required');
        }

        if (!is_callable($config['expected'])) {
            throw new \InvalidArgumentException('expected must be callable');
        }

        if (!isset($config['hash'])) {
            throw new \InvalidArgumentException('hash is required');
        }

        if (!($config['hash']) instanceof HashInterface) {
            throw new \InvalidArgumentException('hash must be an instance of '
                . __NAMESPACE__ . '\\HashInterface');
        }
    }
public static function validateOptions(array $config)
    {
        if (!isset($config['expected'])) {
            throw new \InvalidArgumentException('expected is required');
        }

        if (!is_callable($config['expected'])) {
            throw new \InvalidArgumentException('expected must be callable');
        }

        if (!isset($config['hash'])) {
            throw new \InvalidArgumentException('hash is required');
        }

        if (!($config['hash']) instanceof HashInterface) {
            throw new \InvalidArgumentException('hash must be an instance of '
                . __NAMESPACE__ . '\\HashInterface');
        }
    }
public static function validateOptions ( array $ config ) { if ( ! isset ( $ config [ 'expected' ] ) ) { throw new \ InvalidArgumentException ( 'expected is required' ) ; } if ( ! is_callable ( $ config [ 'expected' ] ) ) { throw new \ InvalidArgumentException ( 'expected must be callable' ) ; } if ( ! isset ( $ config [ 'hash' ] ) ) { throw new \ InvalidArgumentException ( 'hash is required' ) ; } if ( ! ( $ config [ 'hash' ] ) instanceof HashInterface ) { throw new \ InvalidArgumentException ( 'hash must be an instance of ' . __NAMESPACE__ . '\\HashInterface' ) ; } }
Validates the options provided to an integrity plugin.

@param array $config Associative array of configuration options.
@throws \InvalidArgumentException
Validates the options provided to an integrity plugin .