Codota Logo
UserSessionHandler.create
Code IndexAdd Codota to your IDE (free)

How to use
create
method
in
io.vertx.ext.web.handler.UserSessionHandler

Best Java code snippets using io.vertx.ext.web.handler.UserSessionHandler.create (Showing top 14 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
Dictionary d =
  • Codota Iconnew Hashtable()
  • Codota IconBundle bundle;bundle.getHeaders()
  • Codota Iconnew Properties()
  • Smart code suggestions by Codota
}
origin: vert-x3/vertx-examples

router.route().handler(UserSessionHandler.create(authProvider));
origin: vert-x3/vertx-examples

router.route().handler(UserSessionHandler.create(authProvider));
origin: vert-x3/vertx-examples

router.route().handler(UserSessionHandler.create(authProvider));
origin: vert-x3/vertx-examples

router.route().handler(UserSessionHandler.create(authProvider));
origin: vert-x3/vertx-rx

/**
 * Create a new handler
 * @param authProvider The auth provider to use
 * @return the handler
 */
public static io.vertx.rxjava.ext.web.handler.UserSessionHandler create(io.vertx.rxjava.ext.auth.AuthProvider authProvider) { 
 io.vertx.rxjava.ext.web.handler.UserSessionHandler ret = io.vertx.rxjava.ext.web.handler.UserSessionHandler.newInstance(io.vertx.ext.web.handler.UserSessionHandler.create(authProvider.getDelegate()));
 return ret;
}
origin: io.vertx/vertx-rx-java

/**
 * Create a new handler
 * @param authProvider The auth provider to use
 * @return the handler
 */
public static io.vertx.rxjava.ext.web.handler.UserSessionHandler create(io.vertx.rxjava.ext.auth.AuthProvider authProvider) { 
 io.vertx.rxjava.ext.web.handler.UserSessionHandler ret = io.vertx.rxjava.ext.web.handler.UserSessionHandler.newInstance(io.vertx.ext.web.handler.UserSessionHandler.create(authProvider.getDelegate()));
 return ret;
}
origin: vert-x3/vertx-web

router.route().handler(UserSessionHandler.create(authProvider));
router.route("/protected/*").handler(BasicAuthHandler.create(authProvider));
origin: vert-x3/vertx-web

private void doLoginCommon(Handler<RoutingContext> handler, Set<String> authorities) throws Exception {
 router.route().handler(BodyHandler.create());
 router.route().handler(CookieHandler.create());
 SessionStore store = LocalSessionStore.create(vertx);
 router.route().handler(SessionHandler.create(store));
 router.route().handler(UserSessionHandler.create(authProvider));
 AuthHandler authHandler = RedirectAuthHandler.create(authProvider);
 if (authorities != null) {
  authHandler.addAuthorities(authorities);
 }
 router.route("/protected/*").handler(authHandler);
 router.route("/protected/somepage").handler(handler);
 String loginHTML = createloginHTML();
 router.route("/loginpage").handler(rc -> rc.response().putHeader("content-type", "text/html").end(loginHTML));
 if (formLoginHandler == null) {
  formLoginHandler = FormLoginHandler.create(authProvider);
 }
 router.route("/login").handler(formLoginHandler);
 testRequest(HttpMethod.GET, "/protected/somepage", null, resp -> {
  String location = resp.headers().get("location");
  assertNotNull(location);
  assertEquals("/loginpage", location);
  String setCookie = resp.headers().get("set-cookie");
  assertNotNull(setCookie);
  sessionCookie.set(setCookie);
 }, 302, "Found", null);
 testRequest(HttpMethod.GET, "/loginpage", req -> req.putHeader("cookie", sessionCookie.get()), resp -> {
 }, 200, "OK", loginHTML);
}
origin: vert-x3/vertx-web

SessionStore store = LocalSessionStore.create(vertx);
router.route().handler(SessionHandler.create(store));
router.route().handler(UserSessionHandler.create(authProvider));
AuthHandler authHandler = RedirectAuthHandler.create(authProvider);
origin: de.braintags/NetRelayController

private void initUserSessionHandler() {
 getNetRelay().getRouter().route().handler(UserSessionHandler.create(getAuthProvider()));
}
origin: sczyh30/vertx-blueprint-microservice

router.route().handler(UserSessionHandler.create(oauth2));
origin: io.vertx/vertx-web

router.route().handler(UserSessionHandler.create(authProvider));
router.route("/protected/*").handler(BasicAuthHandler.create(authProvider));
origin: io.vertx/vertx-web

private void doLoginCommon(Handler<RoutingContext> handler, Set<String> authorities) throws Exception {
 router.route().handler(BodyHandler.create());
 router.route().handler(CookieHandler.create());
 SessionStore store = LocalSessionStore.create(vertx);
 router.route().handler(SessionHandler.create(store));
 router.route().handler(UserSessionHandler.create(authProvider));
 AuthHandler authHandler = RedirectAuthHandler.create(authProvider);
 if (authorities != null) {
  authHandler.addAuthorities(authorities);
 }
 router.route("/protected/*").handler(authHandler);
 router.route("/protected/somepage").handler(handler);
 String loginHTML = createloginHTML();
 router.route("/loginpage").handler(rc -> rc.response().putHeader("content-type", "text/html").end(loginHTML));
 if (formLoginHandler == null) {
  formLoginHandler = FormLoginHandler.create(authProvider);
 }
 router.route("/login").handler(formLoginHandler);
 testRequest(HttpMethod.GET, "/protected/somepage", null, resp -> {
  String location = resp.headers().get("location");
  assertNotNull(location);
  assertEquals("/loginpage", location);
  String setCookie = resp.headers().get("set-cookie");
  assertNotNull(setCookie);
  sessionCookie.set(setCookie);
 }, 302, "Found", null);
 testRequest(HttpMethod.GET, "/loginpage", req -> req.putHeader("cookie", sessionCookie.get()), resp -> {
 }, 200, "OK", loginHTML);
}
origin: io.vertx/vertx-web

SessionStore store = LocalSessionStore.create(vertx);
router.route().handler(SessionHandler.create(store));
router.route().handler(UserSessionHandler.create(authProvider));
AuthHandler authHandler = RedirectAuthHandler.create(authProvider);
io.vertx.ext.web.handlerUserSessionHandlercreate

Javadoc

Create a new handler

Popular methods of UserSessionHandler

  • handle

Popular in Java

  • Start an intent from android
  • getSystemService (Context)
  • getContentResolver (Context)
  • compareTo (BigDecimal)
    Compares this BigDecimal with the specified BigDecimal. Two BigDecimal objects that are equal in val
  • Window (java.awt)
    A Window object is a top-level window with no borders and no menubar. The default layout for a windo
  • InputStreamReader (java.io)
    An InputStreamReader is a bridge from byte streams to character streams: It reads bytes and decodes
  • URLConnection (java.net)
    The abstract class URLConnection is the superclass of all classes that represent a communications li
  • Time (java.sql)
    Java representation of an SQL TIME value. Provides utilities to format and parse the time's represen
  • Hashtable (java.util)
    Hashtable is a synchronized implementation of Map. All optional operations are supported.Neither key
  • LinkedList (java.util)
    Doubly-linked list implementation of the List and Dequeinterfaces. Implements all optional list oper
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now