private function getAnnotatedBinding(\ReflectionClass $class)
    {
        $annotations = annotationsOf($class);
        if ($class->isInterface() && $annotations->contain('ImplementedBy')) {
            return $this->bind($class->getName())
                    ->to($this->findImplementation($annotations, $class->getName()));
        } elseif ($annotations->contain('ProvidedBy')) {
            return $this->bind($class->getName())
                    ->toProviderClass(
                        $annotations->firstNamed('ProvidedBy')
                                ->getProviderClass()
                    );
        }

        return $this->getImplicitBinding($class);
    }