Event fired when a controller triggers a redirect. Only the
status codes 301 (moved permanently), 302 (found), 303 (see other) and
307 (temporary redirect) are REQUIRED to be reported. Note that the
JAX-RS methods
jakarta.} and
jakarta.}
use the status codes to 303 and 307, respectively. Must be
fired after jakarta..
For example:
public class EventObserver {
public void onControllerRedirect(@Observes ControllerRedirectEvent e) {
...
}
}
jakarta.enterprise.event.Observes
| Modifier and Type | Method and Description |
|---|---|
| public URI | |
| public ResourceInfo | |
| public UriInfo |
| getLocation | back to summary |
|---|---|
| public URI getLocation() The target of the redirection.
| |
| getResourceInfo | back to summary |
|---|---|
| public ResourceInfo getResourceInfo() Access to the current request controller information.
| |
| getUriInfo | back to summary |
|---|---|
| public UriInfo getUriInfo() Access to the current request URI information.
| |