[Java] 56. HTTP 서버에 Reflection & Annotation 활용
·
Java/Reflection, Annotation
HTTP 서버 활용#Java/adv2/HTTP/HTTP 서버7 - 애노테이션 서블릿1 - 시작 : 애노테이션을 이용하여 ReflectionServlet의 문제점을 개선해보자.애노테이션@Retention( RetentionPolicy.RUNTIME)@Target(ElementType.METHOD)@Documentedpublic @interface Mapping { String value();}AnnotationServletpublic class AnnotationServletV1 implements HttpServlet { private final List controllers; public AnnotationServletV1(List controllers) { this.con..