com.liferay.faces.util.context
Class FacesRequestContext

java.lang.Object
  extended by com.liferay.faces.util.context.FacesRequestContext

Deprecated. Please use FacesContextHelperUtil instead.

@Deprecated
public abstract class FacesRequestContext
extends Object

This class defines the usage of static singleton that can be used to add scripts to a response.

Author:
Kyle Stiemann

Constructor Summary
FacesRequestContext()
          Deprecated.  
 
Method Summary
abstract  void addScript(javax.faces.context.FacesContext facesContext, String script)
          Deprecated. Call FacesContextHelperUtil.addScript(javax.faces.context.FacesContext, java.lang.String) instead.
abstract  void addScript(Script script)
          Deprecated. Call FacesContextHelperUtil.addScript(javax.faces.context.FacesContext, com.liferay.faces.util.client.Script) instead.
abstract  void addScript(String script)
          Deprecated. Call FacesContextHelperUtil.addScript(javax.faces.context.FacesContext, java.lang.String) instead.
static FacesRequestContext getCurrentInstance()
          Deprecated. No replacement available.
abstract  List<Script> getScripts()
          Deprecated. Call FacesContextHelperUtil#getScripts(javax.faces.context.FacesContext instead.
abstract  void release()
          Deprecated. No replacement available.
static void setCurrentInstance(FacesRequestContext facesRequestContext)
          Deprecated. Please use FacesContextHelperFactory to decorate the response script functionality instead.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FacesRequestContext

public FacesRequestContext()
Deprecated. 
Method Detail

getCurrentInstance

@Deprecated
public static FacesRequestContext getCurrentInstance()
Deprecated. No replacement available.

Returns a static singleton instance of FacesRequestContext.


setCurrentInstance

@Deprecated
public static void setCurrentInstance(FacesRequestContext facesRequestContext)
Deprecated. Please use FacesContextHelperFactory to decorate the response script functionality instead.

This method has no effect.

Parameters:
facesRequestContext - If a non-null value is specified, then it will become the singleton value. If null is specified, then singleton value is removed from the ThreadLocal. is removed.

addScript

@Deprecated
public abstract void addScript(Script script)
Deprecated. Call FacesContextHelperUtil.addScript(javax.faces.context.FacesContext, com.liferay.faces.util.client.Script) instead.

Adds the specified Script to the list of scripts that are to be executed on the client.


addScript

@Deprecated
public abstract void addScript(String script)
Deprecated. Call FacesContextHelperUtil.addScript(javax.faces.context.FacesContext, java.lang.String) instead.

Adds the specified script to the list of scripts that are to be executed on the client.

Parameters:
script - The script that is to be added.

addScript

@Deprecated
public abstract void addScript(javax.faces.context.FacesContext facesContext,
                                          String script)
Deprecated. Call FacesContextHelperUtil.addScript(javax.faces.context.FacesContext, java.lang.String) instead.

Adds the specified script to the list of scripts that are to be executed on the client.

Parameters:
facesContext - The current faces context.
script - The script that is to be added.
Since:
3.1, 2.1, 1.1

getScripts

@Deprecated
public abstract List<Script> getScripts()
Deprecated. Call FacesContextHelperUtil#getScripts(javax.faces.context.FacesContext instead.

Returns an immutable list of scripts that were added via the addScript(Script) or addScript(FacesContext,String) method.


release

@Deprecated
public abstract void release()
Deprecated. No replacement available.

Releases any resources that are associated with this FacesRequestContext instance.



Copyright © 2019 Liferay, Inc.. All rights reserved.