java获取当前服务器地址 例 http://localhost:xxxx

String path=request.getScheme()+"://"+request.getServerName()+":"+request.getLocalPort();

 http://localhost:xxxx

 

 

 

posted @ 2020-02-28 13:55  ___mouM  阅读(1092)  评论(0)    收藏  举报