test_class.file: http/src/test/java/ro/polak/http/errorhandler/impl/HttpErrorHandlerResolverImplTest.java
test_class.identifier: HttpErrorHandlerResolverImplTest
test_case.body: @Test
      public void shouldCaptureIntermediateExceptions() {
          ServerConfig serverConfig = null; // WIll throw NPE
          HttpErrorHandlerResolver httpErrorHandlerResolver = new HttpErrorHandlerResolverImpl(serverConfig);
          HttpErrorHandler handler = httpErrorHandlerResolver.getHandler(new NotFoundException());
          assertThat(handler, is(instanceOf(HttpError500Handler.class)));
      }
test_case.class_method_signature: HttpErrorHandlerResolverImplTest.shouldCaptureIntermediateExceptions()
test_case.full_signature: @Test public void shouldCaptureIntermediateExceptions()
test_case.identifier: shouldCaptureIntermediateExceptions
test_case.invocations: getHandler assertThat is instanceOf
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void shouldCaptureIntermediateExceptions()
focal_class.declarator: serverConfig
focal_class.modifier: private
focal_class.original_string: private ServerConfig serverConfig;
focal_class.type: ServerConfig
focal_class.var_name: serverConfig
focal_class.file: http/src/main/java/ro/polak/http/errorhandler/impl/HttpErrorHandlerResolverImpl.java
focal_class.identifier: HttpErrorHandlerResolverImpl
focal_class.interfaces: implements HttpErrorHandlerResolver
focal_class.class_method_signature: HttpErrorHandlerResolverImpl.HttpErrorHandlerResolverImpl(final ServerConfig serverConfig)
focal_class.full_signature: public  HttpErrorHandlerResolverImpl(final ServerConfig serverConfig)
focal_class.identifier: HttpErrorHandlerResolverImpl
focal_class.modifiers: public
focal_class.parameters: (final ServerConfig serverConfig)
focal_class.signature:  HttpErrorHandlerResolverImpl(final ServerConfig serverConfig)
focal_class.class_method_signature: HttpErrorHandlerResolverImpl.getHandler(final RuntimeException e)
focal_class.full_signature: @Override public HttpErrorHandler getHandler(final RuntimeException e)
focal_class.identifier: getHandler
focal_class.modifiers: @Override public
focal_class.parameters: (final RuntimeException e)
focal_class.return: HttpErrorHandler
focal_class.signature: HttpErrorHandler getHandler(final RuntimeException e)
focal_class.class_method_signature: HttpErrorHandlerResolverImpl.getAllowedMethods()
focal_class.full_signature: private String getAllowedMethods()
focal_class.identifier: getAllowedMethods
focal_class.modifiers: private
focal_class.parameters: ()
focal_class.return: String
focal_class.signature: String getAllowedMethods()
focal_class.class_method_signature: HttpErrorHandlerResolverImpl.getProtocolExceptionHandler(final ProtocolException e)
focal_class.full_signature: private HttpErrorHandler getProtocolExceptionHandler(final ProtocolException e)
focal_class.identifier: getProtocolExceptionHandler
focal_class.modifiers: private
focal_class.parameters: (final ProtocolException e)
focal_class.return: HttpErrorHandler
focal_class.signature: HttpErrorHandler getProtocolExceptionHandler(final ProtocolException e)
focal_method.body: @Override
      public HttpErrorHandler getHandler(final RuntimeException e) {
          Throwable fallbackException;
  
          try {
              if (e instanceof ProtocolException) {
                  return getProtocolExceptionHandler((ProtocolException) e);
              } else if (e instanceof AccessDeniedException) {
                  return new HttpError403Handler(serverConfig.getErrorDocument403Path());
              } else if (e instanceof NotFoundException) {
                  Statistics.incrementError404();
                  return new HttpError404Handler(serverConfig.getErrorDocument404Path());
              } else if (e instanceof MethodNotAllowedException) {
                  return new HttpError405Handler(getAllowedMethods());
              } else {
                  fallbackException = e;
              }
          } catch (Throwable handlingException) {
              fallbackException = handlingException;
          }
  
          Statistics.incrementError500();
          return new HttpError500Handler().setReason(fallbackException);
      }
focal_method.class_method_signature: HttpErrorHandlerResolverImpl.getHandler(final RuntimeException e)
focal_method.full_signature: @Override public HttpErrorHandler getHandler(final RuntimeException e)
focal_method.identifier: getHandler
focal_method.invocations: getProtocolExceptionHandler getErrorDocument403Path incrementError404 getErrorDocument404Path getAllowedMethods incrementError500 setReason
focal_method.modifiers: @Override public
focal_method.parameters: (final RuntimeException e)
focal_method.return: HttpErrorHandler
focal_method.signature: HttpErrorHandler getHandler(final RuntimeException e)