
com.peterphi.std.guice.web.rest.auth.userprovider.HttpServletUserProvider Maven / Gradle / Ivy
package com.peterphi.std.guice.web.rest.auth.userprovider;
import com.google.inject.Provider;
import com.peterphi.std.guice.common.auth.iface.CurrentUser;
import com.peterphi.std.guice.web.HttpCallContext;
class HttpServletUserProvider implements Provider
{
@Override
public CurrentUser get()
{
if (HttpCallContext.peek() == null)
return null; // Not an HTTP call
return new HttpCallUser();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy