我想访问 HttpMessageNotReadableException
中的 _path
属性,但我不知道通过哪个或哪些方法来执行此操作。我怎样才能访问它?
我的JDK版本是JDK8,我的Spring Boot版本是2.1.4。
最佳答案
这就是我要做的:
e.getHttpInputMessage().getHeaders().getLocation().getPath()
我将在必要时让您检查 null
。
关于java - 如何访问 HttpMessageNotReadableException 中的 _path 属性,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/56696989/