Generated by
JDiff

com.google.inject.servlet Documentation Differences

This file contains all the changes in documentation in the package com.google.inject.servlet as colored differences. Deletions are shown like this, and additions are shown like this.
If no deletions or additions are shown in an entry, the HTML tags will be what has changed. The new HTML tags are shown in the differences. If no documentation existed, and then some was added in a later version, this change is noted in the appropriate class pages of differences, but the change is not shown on this page. Only changes in existing text are shown here. Similarly, documentation which was inherited from another class or interface is not shown here.
Note that an HTML error in the new documentation may cause the display of other documentation changes to be presented incorrectly. For instance, failure to close a <code> tag will cause all subsequent paragraphs to be displayed differently.

Class ServletScopes, Callable<T> continueRequest(Callable<T>, Map<Key<?>, Object>)

Wraps the given callable in a contextual callable that "continues" the HTTP request in another thread. This acts as a way of transporting request context data from the request processing thread to to worker threads.

There are some limitations:

The returned callable will throw a ScopingException when called if the HTTP request scope is still active on the current thread. @param callable code to be executed in another thread, which depends on the request scope. @param seedMap the initial set of scoped instances for Guice to seed the request scope with. To seed a key with null, use {@code null} as the value. @return a callable that will invoke the given callable, making the request context available to it. @throws OutOfScopeException if this method is called from a non-request thread, or if the request has completed. @since 3.0

Class ServletScopes, Callable<T> scopeRequest(Callable<T>, Map<Key<?>, Object>)

Scopes the given callable inside a request scope. This is not the same as the HTTP request scope, but is used if no HTTP request scope is in progress. In this way, keys can be scoped as @RequestScoped and exist in non-HTTP requests (for example: RPC requests) as well as in HTTP request threads.

The returned callable will throw a ScopingException when called if there is a request scope already active on the current thread. @param callable code to be executed which depends on the request scope. Typically in another thread, but not necessarily so. @param seedMap the initial set of scoped instances for Guice to seed the request scope with. To seed a key with null, use {@code null} as the value. @return a callable that when called will run inside the a request scope that exposes the instances in the {@code seedMap} as scoped keys. @since 3.0