public function handle(Args $args, IO $io)
    {
        $criteria = array();

        if ($args->isOptionSet('path')) {
            $criteria['path'] = $args->getOption('path');
            $criteria['language'] = $args->getOption('language');
        }

        if ($args->isOptionSet('name')) {
            if (isset($criteria['path'])) {
                throw new RuntimeException('The options --name and --path cannot be combined.');
            }

            $criteria['path'] = '/**/'.$args->getOption('name');
            $criteria['language'] = $args->getOption('language');
        }

        if ($args->isOptionSet('class')) {
            $criteria['class'] = $args->getOption('class');
        }

        if ($args->isOptionSet('type')) {
            $criteria['bindingType'] = $args->getOption('type');
        }

        if (empty($criteria)) {
            throw new RuntimeException('No search criteria specified.');
        }

        return $this->listMatches($io, $criteria);
    }