开发者

org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver : Resolved

开发者 https://www.devze.com 2022-12-07 19:45 出处:网络
@Value("${mobileapi}") private String mobileapi; @Override public String getcircleoperator(String mobilenum)throws JsonMappingException, JsonProcessingException {

@Value("${mobileapi}")
private String mobileapi;

@Override
    public String getcircleoperator(String mobilenum)throws JsonMappingException, JsonProcessingException {
        HttpHeaders headers1 = new HttpHeaders();
    HttpEntity<HttpHeaders> request = new HttpEntity<>(headers1);
        RestTemplate restTemplate = new RestTemplate();
        String newapivar=mobileapi+mobilenum.;
        ResponseEntity<String> responsee = restTemplate.exchange(newapivar,HttpMethod.GET,request,String.class);
        System.out.println("check these values new url"+responsee.getBody());
        
          ObjectMapper mapper = new ObjectMapper();
          MobileNumberResponse browsePlanResponses=mapper.readValue(responsee.getBody(), MobileNumberResponse.class);
        return  null;
    }

I was try this code i get the error. in object mapper line throwing the Error. I don't know the why its just happened. can you please help me开发者_Python百科 to solve this issues.

0

精彩评论

暂无评论...
验证码 换一张
取 消