定義返回類型解析
private final static ParameterizedTypeReference<ResultVO<UserInfoDTO>> userReference = new ParameterizedTypeReference<ResultVO<UserInfoDTO>>(){};
請求使用方式
ResultVO<AuthenticationDTO> result = restTemplate.exchange(url, HttpMethod.POST,new HttpEntity<MultiValueMap<String, String>>(null, headers), authorizationReference).getBody();