Class CurrentUserService

java.lang.Object
edu.ucsb.cs156.gauchoride.services.CurrentUserService
Direct Known Subclasses:
CurrentUserServiceImpl

public abstract class CurrentUserService extends Object
  • Constructor Details

    • CurrentUserService

      public CurrentUserService()
  • Method Details

    • getUser

      public abstract User getUser()
    • getCurrentUser

      public abstract CurrentUser getCurrentUser()
    • getRoles

      public abstract Collection<? extends org.springframework.security.core.GrantedAuthority> getRoles()
    • isLoggedIn

      public final boolean isLoggedIn()
    • resetCurrentUser

      public abstract void resetCurrentUser()
      This should only be called in test code, never in production code! It resets the current user to a known state for tests, in case a previous test has changed it in some way.