test_class.file: ui/src/test/java/org/glowroot/ui/HttpServerHandlerTest.java
test_class.identifier: HttpServerHandlerTest
test_case.body: @Test
      public void shouldStripContextPath() {
          assertThat(HttpServerHandler.stripContextPath("/one", "/")).isEqualTo("/one");
          assertThat(HttpServerHandler.stripContextPath("/", "/")).isEqualTo("/");
          assertThat(HttpServerHandler.stripContextPath("/one", "/one")).isEqualTo("/");
          assertThat(HttpServerHandler.stripContextPath("/one/", "/one")).isEqualTo("/");
          assertThat(HttpServerHandler.stripContextPath("/one/two", "/one")).isEqualTo("/two");
          assertThat(HttpServerHandler.stripContextPath("/one/two/", "/one")).isEqualTo("/two/");
      }
test_case.class_method_signature: HttpServerHandlerTest.shouldStripContextPath()
test_case.full_signature: @Test public void shouldStripContextPath()
test_case.identifier: shouldStripContextPath
test_case.invocations: isEqualTo assertThat stripContextPath isEqualTo assertThat stripContextPath isEqualTo assertThat stripContextPath isEqualTo assertThat stripContextPath isEqualTo assertThat stripContextPath isEqualTo assertThat stripContextPath
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void shouldStripContextPath()
focal_class.declarator: logger = LoggerFactory.getLogger(HttpServerHandler.class)
focal_class.modifier: private static final
focal_class.original_string: private static final Logger logger = LoggerFactory.getLogger(HttpServerHandler.class);
focal_class.type: Logger
focal_class.var_name: logger
focal_class.declarator: currentChannel =
              new ThreadLocal</*@Nullable*/ Channel>()
focal_class.modifier: private static final
focal_class.original_string: private static final ThreadLocal</*@Nullable*/ Channel> currentChannel =
              new ThreadLocal</*@Nullable*/ Channel>();
focal_class.type: ThreadLocal</*@Nullable*/ Channel>
focal_class.var_name: currentChannel
focal_class.declarator: allChannels
focal_class.modifier: private final
focal_class.original_string: private final ChannelGroup allChannels;
focal_class.type: ChannelGroup
focal_class.var_name: allChannels
focal_class.declarator: contextPathSupplier
focal_class.modifier: private final
focal_class.original_string: private final Supplier<String> contextPathSupplier;
focal_class.type: Supplier<String>
focal_class.var_name: contextPathSupplier
focal_class.declarator: commonHandler
focal_class.modifier: private final
focal_class.original_string: private final CommonHandler commonHandler;
focal_class.type: CommonHandler
focal_class.var_name: commonHandler
focal_class.file: ui/src/main/java/org/glowroot/ui/HttpServerHandler.java
focal_class.identifier: HttpServerHandler
focal_class.class_method_signature: HttpServerHandler.HttpServerHandler(Supplier<String> contextPathSupplier, CommonHandler commonHandler)
focal_class.full_signature:   HttpServerHandler(Supplier<String> contextPathSupplier, CommonHandler commonHandler)
focal_class.identifier: HttpServerHandler
focal_class.parameters: (Supplier<String> contextPathSupplier, CommonHandler commonHandler)
focal_class.signature:  HttpServerHandler(Supplier<String> contextPathSupplier, CommonHandler commonHandler)
focal_class.class_method_signature: HttpServerHandler.channelActive(ChannelHandlerContext ctx)
focal_class.full_signature: @Override public void channelActive(ChannelHandlerContext ctx)
focal_class.identifier: channelActive
focal_class.modifiers: @Override public
focal_class.parameters: (ChannelHandlerContext ctx)
focal_class.return: void
focal_class.signature: void channelActive(ChannelHandlerContext ctx)
focal_class.class_method_signature: HttpServerHandler.closeAllButCurrent()
focal_class.full_signature:  void closeAllButCurrent()
focal_class.identifier: closeAllButCurrent
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void closeAllButCurrent()
focal_class.class_method_signature: HttpServerHandler.channelReadComplete(ChannelHandlerContext ctx)
focal_class.full_signature: @Override public void channelReadComplete(ChannelHandlerContext ctx)
focal_class.identifier: channelReadComplete
focal_class.modifiers: @Override public
focal_class.parameters: (ChannelHandlerContext ctx)
focal_class.return: void
focal_class.signature: void channelReadComplete(ChannelHandlerContext ctx)
focal_class.class_method_signature: HttpServerHandler.channelRead(ChannelHandlerContext ctx, Object msg)
focal_class.full_signature: @Override public void channelRead(ChannelHandlerContext ctx, Object msg)
focal_class.identifier: channelRead
focal_class.modifiers: @Override public
focal_class.parameters: (ChannelHandlerContext ctx, Object msg)
focal_class.return: void
focal_class.signature: void channelRead(ChannelHandlerContext ctx, Object msg)
focal_class.class_method_signature: HttpServerHandler.sendResponse(ChannelHandlerContext ctx, FullHttpRequest request,
              CommonResponse response, boolean keepAlive)
focal_class.full_signature: private static void sendResponse(ChannelHandlerContext ctx, FullHttpRequest request,
              CommonResponse response, boolean keepAlive)
focal_class.identifier: sendResponse
focal_class.modifiers: private static
focal_class.parameters: (ChannelHandlerContext ctx, FullHttpRequest request,
              CommonResponse response, boolean keepAlive)
focal_class.return: void
focal_class.signature: void sendResponse(ChannelHandlerContext ctx, FullHttpRequest request,
              CommonResponse response, boolean keepAlive)
focal_class.class_method_signature: HttpServerHandler.sendFullResponse(ChannelHandlerContext ctx, FullHttpRequest request,
              FullHttpResponse response, boolean keepAlive)
focal_class.full_signature: @SuppressWarnings("argument.type.incompatible") private static void sendFullResponse(ChannelHandlerContext ctx, FullHttpRequest request,
              FullHttpResponse response, boolean keepAlive)
focal_class.identifier: sendFullResponse
focal_class.modifiers: @SuppressWarnings("argument.type.incompatible") private static
focal_class.parameters: (ChannelHandlerContext ctx, FullHttpRequest request,
              FullHttpResponse response, boolean keepAlive)
focal_class.return: void
focal_class.signature: void sendFullResponse(ChannelHandlerContext ctx, FullHttpRequest request,
              FullHttpResponse response, boolean keepAlive)
focal_class.class_method_signature: HttpServerHandler.exceptionCaught(ChannelHandlerContext ctx, Throwable cause)
focal_class.full_signature: @Override public void exceptionCaught(ChannelHandlerContext ctx, Throwable cause)
focal_class.identifier: exceptionCaught
focal_class.modifiers: @Override public
focal_class.parameters: (ChannelHandlerContext ctx, Throwable cause)
focal_class.return: void
focal_class.signature: void exceptionCaught(ChannelHandlerContext ctx, Throwable cause)
focal_class.class_method_signature: HttpServerHandler.stripContextPath(String path, String contextPath)
focal_class.full_signature: @VisibleForTesting static String stripContextPath(String path, String contextPath)
focal_class.identifier: stripContextPath
focal_class.modifiers: @VisibleForTesting static
focal_class.parameters: (String path, String contextPath)
focal_class.return: String
focal_class.signature: String stripContextPath(String path, String contextPath)
focal_class.superclass: extends ChannelInboundHandlerAdapter
focal_method.body: @VisibleForTesting
      static String stripContextPath(String path, String contextPath) {
          if (contextPath.equals("/")) {
              return path;
          }
          if (path.equals(contextPath)) {
              return "/";
          }
          return path.substring(contextPath.length());
      }
focal_method.class_method_signature: HttpServerHandler.stripContextPath(String path, String contextPath)
focal_method.full_signature: @VisibleForTesting static String stripContextPath(String path, String contextPath)
focal_method.identifier: stripContextPath
focal_method.invocations: equals equals substring length
focal_method.modifiers: @VisibleForTesting static
focal_method.parameters: (String path, String contextPath)
focal_method.return: String
focal_method.signature: String stripContextPath(String path, String contextPath)