Examples of CurrentUser


Examples of br.jus.tjrn.arq.commons.auth.CurrentUser

        testSpringSecurityCurrentUser();
    }
    private static void testSpringSecurityCurrentUser() {
        SecurityContextHolder.getContext().setAuthentication(
                new UsernamePasswordAuthenticationToken("ladysman217", "samwitwicky"));
        CurrentUser c = ac.getBean(CurrentUser.class);
        System.out.println(String.format("O usuário do contexto atual é: %s", c.getLogin()));
    }
View Full Code Here

Examples of com.github.zhangkaitao.shiro.chapter16.web.bind.annotation.CurrentUser

        return false;
    }

    @Override
    public Object resolveArgument(MethodParameter parameter, ModelAndViewContainer mavContainer, NativeWebRequest webRequest, WebDataBinderFactory binderFactory) throws Exception {
        CurrentUser currentUserAnnotation = parameter.getParameterAnnotation(CurrentUser.class);
        return webRequest.getAttribute(currentUserAnnotation.value(), NativeWebRequest.SCOPE_REQUEST);
    }
View Full Code Here

Examples of com.github.zhangkaitao.shiro.chapter18.web.bind.annotation.CurrentUser

        return false;
    }

    @Override
    public Object resolveArgument(MethodParameter parameter, ModelAndViewContainer mavContainer, NativeWebRequest webRequest, WebDataBinderFactory binderFactory) throws Exception {
        CurrentUser currentUserAnnotation = parameter.getParameterAnnotation(CurrentUser.class);
        return webRequest.getAttribute(currentUserAnnotation.value(), NativeWebRequest.SCOPE_REQUEST);
    }
View Full Code Here

Examples of com.github.zhangkaitao.shiro.chapter19.web.bind.annotation.CurrentUser

        return false;
    }

    @Override
    public Object resolveArgument(MethodParameter parameter, ModelAndViewContainer mavContainer, NativeWebRequest webRequest, WebDataBinderFactory binderFactory) throws Exception {
        CurrentUser currentUserAnnotation = parameter.getParameterAnnotation(CurrentUser.class);
        return webRequest.getAttribute(currentUserAnnotation.value(), NativeWebRequest.SCOPE_REQUEST);
    }
View Full Code Here

Examples of com.github.zhangkaitao.shiro.chapter21.web.bind.annotation.CurrentUser

        return false;
    }

    @Override
    public Object resolveArgument(MethodParameter parameter, ModelAndViewContainer mavContainer, NativeWebRequest webRequest, WebDataBinderFactory binderFactory) throws Exception {
        CurrentUser currentUserAnnotation = parameter.getParameterAnnotation(CurrentUser.class);
        return webRequest.getAttribute(currentUserAnnotation.value(), NativeWebRequest.SCOPE_REQUEST);
    }
View Full Code Here

Examples of com.github.zhangkaitao.shiro.chapter22.web.bind.annotation.CurrentUser

        return false;
    }

    @Override
    public Object resolveArgument(MethodParameter parameter, ModelAndViewContainer mavContainer, NativeWebRequest webRequest, WebDataBinderFactory binderFactory) throws Exception {
        CurrentUser currentUserAnnotation = parameter.getParameterAnnotation(CurrentUser.class);
        return webRequest.getAttribute(currentUserAnnotation.value(), NativeWebRequest.SCOPE_REQUEST);
    }
View Full Code Here

Examples of com.github.zhangkaitao.shiro.chapter23.web.bind.annotation.CurrentUser

        return false;
    }

    @Override
    public Object resolveArgument(MethodParameter parameter, ModelAndViewContainer mavContainer, NativeWebRequest webRequest, WebDataBinderFactory binderFactory) throws Exception {
        CurrentUser currentUserAnnotation = parameter.getParameterAnnotation(CurrentUser.class);
        return webRequest.getAttribute(currentUserAnnotation.value(), NativeWebRequest.SCOPE_REQUEST);
    }
View Full Code Here

Examples of com.github.zhangkaitao.shiro.chapter24.web.bind.annotation.CurrentUser

        return false;
    }

    @Override
    public Object resolveArgument(MethodParameter parameter, ModelAndViewContainer mavContainer, NativeWebRequest webRequest, WebDataBinderFactory binderFactory) throws Exception {
        CurrentUser currentUserAnnotation = parameter.getParameterAnnotation(CurrentUser.class);
        return webRequest.getAttribute(currentUserAnnotation.value(), NativeWebRequest.SCOPE_REQUEST);
    }
View Full Code Here

Examples of com.google.gerrit.server.CurrentUser

    }

    private String generateName(HttpServletRequest req) {
      String userName = "";

      CurrentUser who = userProvider.get();
      if (who instanceof IdentifiedUser) {
        String name = ((IdentifiedUser) who).getUserName();
        if (name != null && !name.isEmpty()) {
          userName = " (" + name + ")";
        }
View Full Code Here

Examples of com.google.gerrit.server.CurrentUser

    async.close();
  }

  @Override
  public void log(final Request req, final Response rsp) {
    CurrentUser user = (CurrentUser) req.getAttribute(GetUserFilter.REQ_ATTR_KEY);
    doLog(req, rsp, user);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.