Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
/*
* JBoss, Home of Professional Open Source
* Copyright 2008, Red Hat, Inc., and individual contributors
* by the @authors tag. See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.jboss.weld.module.jsf;
import java.util.List;
import java.util.Map;
import jakarta.faces.application.ViewHandler;
import jakarta.faces.application.ViewHandlerWrapper;
import jakarta.faces.context.FacesContext;
import org.jboss.weld.Container;
import org.jboss.weld.bootstrap.api.helpers.RegistrySingletonProvider;
import org.jboss.weld.context.ConversationContext;
import org.jboss.weld.context.http.HttpConversationContext;
/**
*
* A forwarding JSF ViewHandler implementation that produces URLs containing the
* conversation id query string parameter. All methods except those which
* produce a URL that need to be enhanced are forwarded to the ViewHandler
* delegate.
*
*
*
* A request parameter was chosen to propagate the conversation because it's
* the most technology agnostic approach for passing data between requests and
* allows for the ensuing request to use whatever means necessary (a servlet
* filter, phase listener, etc) to capture the conversation id and restore the
* long-running conversation.
*
*
* @author Dan Allen
* @author Pete Muir
* @author Ales Justin
* @author Marko Luksa
*/
public class ConversationAwareViewHandler extends ViewHandlerWrapper {
private static enum Source {
ACTION,
BOOKMARKABLE,
REDIRECT,
RESOURCE
}
private final ViewHandler delegate;
private volatile ConversationContext conversationContext;
private static final ThreadLocal