HttpServletRequest中getRemoteUser和getUserPrincipal方法

HttpServletRequest是一个接口类,继承自ServletRequest,并且又新增了许多抽象方法,getRemoteUser()方法和getUserPrincipal()方法就在其中。许多web项目中会定义基于HttpServletRequest的实现类,比如shiro中的ShiroHttpServletRequest,该类中对getRemoteUser和getUserPrincipal方法进行了实现。

posted on 2019-06-24 17:24  阿泰555  阅读(6387)  评论(0编辑  收藏  举报

导航