RequestBeanWriter { public <T> void registerQueryParam(Class<T> beanClass, BeanClassNameValidator beanClassNameValidator) { if (!queryParamContext.containsKey(beanClass)) { new QueryParamClassValidator(beanClass, beanClassNameValidator).validate(); queryParamContext.put(beanClass, new QueryParamContext<>(beanClass)); } }  void registerQueryParam(Class<T> beanClass, BeanClassNameValidator beanClassNameValidator); void registerBean(Class<?> beanClass, BeanClassValidator validator); Map<String, String> toParams(Class<T> beanClass, T bean); byte[] toJSON(Class<T> beanClass, T bean);  }
@Test void registerQueryParam() { writer.registerQueryParam(TestQueryParamBean.class, validator.beanClassNameValidator); writer.registerQueryParam(TestQueryParamBean.class, validator.beanClassNameValidator); }