Deprecated API


Contents
Deprecated Interfaces
javax.servlet.jsp.el.FunctionMapper
          As of JSP 2.1, replaced by FunctionMapper 
javax.resource.spi.security.GenericCredential
          The preferred way to represent generic credential information is via the org.ietf.jgss.GSSCredential interface in J2SE Version 1.4, which provides similar functionality. 
javax.servlet.http.HttpSessionContext
          As of Java(tm) Servlet API 2.1 for security reasons, with no replacement. This interface will be removed in a future version of this API. 
javax.servlet.SingleThreadModel
          As of Java Servlet API 2.4, with no direct replacement. 
javax.xml.bind.Validator
          since JAXB 2.0 
javax.servlet.jsp.el.VariableResolver
          As of JSP 2.1, replaced by ELResolver 
 

Deprecated Classes
javax.faces.webapp.AttributeTag
          The Faces implementation must now provide the implementation for this class. 
javax.faces.webapp.ConverterTag
          This has been partially replaced by ConverterELTag. The remainder of the functionality, namely, the binding facility and the implementation of the ConverterTag.createConverter() method, is now an implementation detail. 
javax.servlet.jsp.el.Expression
          As of JSP 2.1, replaced by ValueExpression 
javax.servlet.jsp.el.ExpressionEvaluator
          As of JSP 2.1, replaced by ExpressionFactory 
javax.servlet.http.HttpUtils
          As of Java(tm) Servlet API 2.3. These methods were only useful with the default encoding and have been moved to the request interfaces. 
javax.faces.el.MethodBinding
          This has been replaced by MethodExpression. 
javax.faces.el.PropertyResolver
          This has been replaced by ELResolver. 
javax.faces.application.StateManager.SerializedView
          This class was not marked Serializable in the 1.0 version of the spec. It was also not a static inner class, so it can't be made to be Serializable. Therefore, it is being deprecated in version 1.2 of the spec. The replacement is to use an implementation dependent Object. 
javax.faces.webapp.UIComponentBodyTag
          All component tags now implement BodyTag. This class has been replaced by UIComponentELTag. 
javax.faces.webapp.UIComponentTag
          Use of this class has been replaced with UIComponentELTag, which extends UIComponentClassicTagBase to add properties that use the EL API introduced as part of JSP 2.1. 
javax.faces.webapp.ValidatorTag
          This has been partially replaced by ValidatorELTag. The remainder of the functionality, namely, the binding facility and the implementation of the ValidatorTag.createValidator() method, is now an implementation detail. 
javax.faces.el.ValueBinding
          This has been replaced by ValueExpression. 
javax.faces.el.VariableResolver
          This has been replaced by ELResolver when operating with a null base argument. 
 

Deprecated Exceptions
javax.servlet.jsp.el.ELException
          As of JSP 2.1, replaced by ELException 
javax.servlet.jsp.el.ELParseException
          As of JSP 2.1, replaced by ELException 
javax.faces.el.EvaluationException
          This has been replaced by ELException. 
javax.faces.el.MethodNotFoundException
          This has been replaced by MethodNotFoundException. 
javax.faces.el.PropertyNotFoundException
          This has been replaced by PropertyNotFoundException. 
javax.faces.el.ReferenceSyntaxException
          This has been replaced by ELException. 
 

Deprecated Annotation Types
javax.jws.soap.InitParam
          As of JSR-181 2.0 with no replacement. 
javax.jws.soap.SOAPMessageHandler
          As of JSR-181 2.0 with no replacement. 
javax.jws.soap.SOAPMessageHandlers
          As of JSR-181 2.0 with no replacement. 
 

Deprecated Fields
javax.faces.component.UIComponent.bindings
           
javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_TAG
          As of Java JSP API 1.2, use BodyTag.EVAL_BODY_BUFFERED or IterationTag.EVAL_BODY_AGAIN. 
javax.faces.validator.Validator.NOT_IN_RANGE_MESSAGE_ID
          Use DoubleRangeValidator#NOT_IN_RANGE_MESSAGE_ID or LongRangeValidator#NOT_IN_RANGE_MESSAGE_ID instead. 
javax.persistence.Persistence.PERSISTENCE_PROVIDER
            
javax.persistence.Persistence.providers
            
javax.faces.component.NamingContainer.SEPARATOR_CHAR
          use UINamingContainer#getSeparatorChar(javax.faces.context.FacesContext) 
 

Deprecated Methods
javax.faces.application.Application.createComponent(ValueBinding, FacesContext, String)
          This has been replaced by Application.createComponent(javax.el.ValueExpression,javax.faces.context.FacesContext,java.lang.String). 
javax.faces.application.Application.createMethodBinding(String, Class[])
          This has been replaced by calling Application.getExpressionFactory() then ExpressionFactory#createMethodExpression. 
javax.xml.bind.JAXBContext.createValidator()
          since JAXB2.0 
javax.faces.application.Application.createValueBinding(String)
          This has been replaced by calling Application.getExpressionFactory() then ExpressionFactory#createValueExpression. 
javax.enterprise.deploy.spi.DeploymentManager.distribute(Target[], InputStream, InputStream)
          as of Java EE 5, replaced with DeploymentManager.distribute(Target[], ModuleType, InputStream, InputStream) 
javax.faces.webapp.UIComponentClassicTagBase.encodeBegin()
          No encoding is done during JSP page execution. Encoding is deferred until the page has completed executing to allow the entire tree to be built before any encoding occurs. 
javax.faces.webapp.UIComponentClassicTagBase.encodeChildren()
          No encoding is done during JSP page execution. Encoding is deferred until the page has completed executing to allow the entire tree to be built before any encoding occurs. 
javax.faces.webapp.UIComponentClassicTagBase.encodeEnd()
          No encoding is done during JSP page execution. Encoding is deferred until the page has completed executing to allow the entire tree to be built before any encoding occurs. 
javax.servlet.http.HttpServletResponseWrapper.encodeRedirectUrl(String)
          As of version 2.1, use HttpServletResponseWrapper.encodeRedirectURL(String url) instead 
javax.servlet.http.HttpServletResponse.encodeRedirectUrl(String)
          As of version 2.1, use encodeRedirectURL(String url) instead 
javax.servlet.http.HttpServletResponseWrapper.encodeUrl(String)
          As of version 2.1, use HttpServletResponseWrapper.encodeURL(String url) instead 
javax.servlet.http.HttpServletResponse.encodeUrl(String)
          As of version 2.1, use encodeURL(String url) instead 
javax.faces.component.ActionSource.getAction()
          This has been replaced by ActionSource2#getActionExpression. 
javax.faces.component.UICommand.getAction()
          This has been replaced by UICommand.getActionExpression(). 
javax.faces.component.ActionSource.getActionListener()
          Use ActionSource.getActionListeners() instead. 
javax.faces.component.UICommand.getActionListener()
          Use UICommand.getActionListeners() instead. 
javax.ejb.EJBContext.getCallerIdentity()
          Use Principal getCallerPrincipal() instead. 
javax.faces.render.ResponseStateManager.getComponentStateToRestore(FacesContext)
          This method has been replaced by ResponseStateManager.getState(javax.faces.context.FacesContext, java.lang.String). The default implementation returns null. 
javax.faces.application.StateManager.getComponentStateToSave(FacesContext)
          the distinction between tree structure and component state is now an implementation detail. The default implementation returns null. 
javax.ejb.EJBContext.getEnvironment()
          Use the JNDI naming context java:comp/env to access enterprise bean's environment. 
javax.xml.bind.Validator.getEventHandler()
          since JAXB2.0 
javax.servlet.jsp.JspContext.getExpressionEvaluator()
          As of JSP 2.1, replaced by JspApplicationContext#getExpressionFactory 
javax.servlet.http.HttpSessionContext.getIds()
          As of Java Servlet API 2.1 with no replacement. This method must return an empty Enumeration and will be removed in a future version of this API. 
javax.resource.ResourceException.getLinkedException()
          J2SE release 1.4 supports a chained exception facility that allows any throwable to know about another throwable, if any, that caused it to get thrown. Refer to getCause and initCause methods of the java.lang.Throwable class.. 
javax.resource.cci.ResourceWarning.getLinkedWarning()
          J2SE release 1.4 supports a chained exception facility that allows any throwable to know about another throwable, if any, that caused it to get thrown. Refer to getCause and initCause methods of the java.lang.Throwable class. 
javax.enterprise.deploy.model.DeployableObject.getModuleDTDVersion()
          As of version 1.1 replaced by DDBeanRoot.getDDBeanRootVersion() 
javax.enterprise.deploy.model.DDBeanRoot.getModuleDTDVersion()
          As of version 1.1 replaced by DDBeanRoot.getDDBeanRootVersion() 
javax.xml.bind.Validator.getProperty(String)
          since JAXB2.0 
javax.faces.application.Application.getPropertyResolver()
          This has been replaced by Application.getELResolver(). 
javax.servlet.ServletRequestWrapper.getRealPath(String)
          As of Version 2.1 of the Java Servlet API, use ServletContext#getRealPath instead 
javax.servlet.ServletRequest.getRealPath(String)
          As of Version 2.1 of the Java Servlet API, use ServletContext#getRealPath instead. 
javax.servlet.jsp.JspException.getRootCause()
          As of JSP 2.1, replaced by Throwable.getCause() 
javax.servlet.UnavailableException.getServlet()
          As of Java Servlet API 2.2, with no replacement. Returns the servlet that is reporting its unavailability. 
javax.servlet.ServletContext.getServlet(String)
          As of Java Servlet API 2.1, with no direct replacement.

This method was originally defined to retrieve a servlet from a ServletContext. In this version, this method always returns null and remains only to preserve binary compatibility. This method will be permanently removed in a future version of the Java Servlet API.

In lieu of this method, servlets can share information using the ServletContext class and can perform shared business logic by invoking methods on common non-servlet classes. 

javax.servlet.ServletContext.getServletNames()
          As of Java Servlet API 2.1, with no replacement.

This method was originally defined to return an Enumeration of all the servlet names known to this context. In this version, this method always returns an empty Enumeration and remains only to preserve binary compatibility. This method will be permanently removed in a future version of the Java Servlet API. 

javax.servlet.ServletContext.getServlets()
          As of Java Servlet API 2.0, with no replacement.

This method was originally defined to return an Enumeration of all the servlets known to this servlet context. In this version, this method always returns an empty enumeration and remains only to preserve binary compatibility. This method will be permanently removed in a future version of the Java Servlet API. 

javax.servlet.http.HttpSessionContext.getSession(String)
          As of Java Servlet API 2.1 with no replacement. This method must return null and will be removed in a future version of this API. 
javax.servlet.http.HttpSession.getSessionContext()
          As of Version 2.1, this method is deprecated and has no replacement. It will be removed in a future version of the Java Servlet API. 
javax.faces.render.ResponseStateManager.getTreeStructureToRestore(FacesContext, String)
          This method has been replaced by ResponseStateManager.getState(javax.faces.context.FacesContext, java.lang.String). The default implementation returns null. 
javax.faces.application.StateManager.getTreeStructureToSave(FacesContext)
          the distinction between tree structure and component state is now an implementation detail. The default implementation returns null. 
javax.faces.component.EditableValueHolder.getValidator()
          EditableValueHolder.getValidators() should be used instead. 
javax.faces.component.UIInput.getValidator()
          UIInput.getValidators() should be used instead. 
javax.servlet.http.HttpSession.getValue(String)
          As of Version 2.2, this method is replaced by HttpSession.getAttribute(java.lang.String). 
javax.faces.component.UIComponentBase.getValueBinding(String)
          This has been replaced by UIComponent.getValueExpression(java.lang.String). 
javax.faces.component.UISelectBoolean.getValueBinding(String)
          This has been replaced by UISelectBoolean.getValueExpression(java.lang.String). 
javax.faces.component.UISelectMany.getValueBinding(String)
          this has been replaced by UISelectMany.getValueExpression(java.lang.String). 
javax.faces.component.UIGraphic.getValueBinding(String)
          This has been replaced by UIGraphic.getValueExpression(java.lang.String). 
javax.faces.component.UIComponent.getValueBinding(String)
          This has been replaced by UIComponent.getValueExpression(java.lang.String). 
javax.faces.component.EditableValueHolder.getValueChangeListener()
          Use EditableValueHolder.getValueChangeListeners() instead. 
javax.servlet.http.HttpSession.getValueNames()
          As of Version 2.2, this method is replaced by HttpSession.getAttributeNames() 
javax.faces.application.Application.getVariableResolver()
          This has been replaced by Application.getELResolver(). 
javax.servlet.jsp.JspContext.getVariableResolver()
          As of JSP 2.1, replaced by ELContext#getELResolver, which can be obtained by jspContext.getELContext().getELResolver(). 
javax.ejb.EJBContext.isCallerInRole(Identity)
          Use boolean isCallerInRole(String roleName) instead. 
javax.servlet.http.HttpServletRequest.isRequestedSessionIdFromUrl()
          As of Version 2.1 of the Java Servlet API, use HttpServletRequest.isRequestedSessionIdFromURL() instead. 
javax.xml.bind.Unmarshaller.isValidating()
          since JAXB2.0, please see Unmarshaller.getSchema() 
javax.servlet.ServletContext.log(Exception, String)
          As of Java Servlet API 2.1, use ServletContext.log(String message, Throwable throwable) instead.

This method was originally defined to write an exception's stack trace and an explanatory error message to the servlet log file. 

javax.servlet.http.HttpSession.putValue(String, Object)
          As of Version 2.2, this method is replaced by HttpSession.setAttribute(java.lang.String, java.lang.Object) 
javax.servlet.http.HttpSession.removeValue(String)
          As of Version 2.2, this method is replaced by HttpSession.removeAttribute(java.lang.String) 
javax.faces.application.StateManager.restoreComponentState(FacesContext, UIViewRoot, String)
          the distinction between tree structure and component state is now an implementation detail. The default implementation does nothing. 
javax.faces.application.StateManager.restoreTreeStructure(FacesContext, String, String)
          the distinction between tree structure and component state is now an implementation detail. The default implementation returns null. 
javax.faces.application.StateManager.saveSerializedView(FacesContext)
          this has been replaced by StateManager.saveView(javax.faces.context.FacesContext). The default implementation calls saveView and inspects the return. If the return is an Object [], it casts the result to an Object [] wrapping the first and second elements in an instance of StateManager.SerializedView, which it then returns. Otherwise, it return null 
javax.faces.component.ActionSource.setAction(MethodBinding)
          This has been replaced by ActionSource2#setActionExpression(javax.el.MethodExpression). 
javax.faces.component.UICommand.setAction(MethodBinding)
          This has been replaced by UICommand.setActionExpression(javax.el.MethodExpression). 
javax.faces.component.ActionSource.setActionListener(MethodBinding)
          This has been replaced by ActionSource.addActionListener(javax.faces.event.ActionListener). 
javax.faces.component.UICommand.setActionListener(MethodBinding)
          This has been replaced by UICommand.addActionListener(javax.faces.event.ActionListener). 
javax.xml.bind.Validator.setEventHandler(ValidationEventHandler)
          since JAXB2.0 
javax.resource.ResourceException.setLinkedException(Exception)
          J2SE release 1.4 supports a chained exception facility that allows any throwable to know about another throwable, if any, that caused it to get thrown. Refer to getCause and initCause methods of the java.lang.Throwable class. 
javax.resource.cci.ResourceWarning.setLinkedWarning(ResourceWarning)
          J2SE release 1.4 supports a chained exception facility that allows any throwable to know about another throwable, if any, that caused it to get thrown. Refer to getCause and initCause methods of the java.lang.Throwable class. 
javax.xml.bind.Validator.setProperty(String, Object)
          since JAXB2.0 
javax.faces.application.Application.setPropertyResolver(PropertyResolver)
          The recommended way to affect the execution of the EL is to provide an <el-resolver> element at the right place in the application configuration resources which will be considered in the normal course of expression evaluation. This method now will cause the argument resolver to be wrapped inside an implementation of ELResolver and exposed to the EL resolution system as if the user had called Application.addELResolver(javax.el.ELResolver). 
javax.servlet.http.HttpServletResponseWrapper.setStatus(int, String)
          As of version 2.1, due to ambiguous meaning of the message parameter. To set a status code use HttpServletResponseWrapper.setStatus(int), to send an error with a description use HttpServletResponseWrapper.sendError(int, String) 
javax.servlet.http.HttpServletResponse.setStatus(int, String)
          As of version 2.1, due to ambiguous meaning of the message parameter. To set a status code use setStatus(int), to send an error with a description use sendError(int, String). Sets the status code and message for this response. 
javax.xml.bind.Unmarshaller.setValidating(boolean)
          since JAXB2.0, please see Unmarshaller.setSchema(javax.xml.validation.Schema) 
javax.faces.component.EditableValueHolder.setValidator(MethodBinding)
          Use EditableValueHolder.addValidator(javax.faces.validator.Validator) instead, obtaining the argument Validator by creating an instance of MethodExpressionValidator. 
javax.faces.component.UIInput.setValidator(MethodBinding)
          Use UIInput.addValidator(javax.faces.validator.Validator) instead, obtaining the argument Validator by creating an instance of MethodExpressionValidator. 
javax.faces.component.UIComponentBase.setValueBinding(String, ValueBinding)
          This has been replaced by UIComponent.setValueExpression(java.lang.String, javax.el.ValueExpression). 
javax.faces.component.UISelectBoolean.setValueBinding(String, ValueBinding)
          This has been replaced by UISelectBoolean.setValueExpression(java.lang.String, javax.el.ValueExpression). 
javax.faces.component.UISelectMany.setValueBinding(String, ValueBinding)
          This has been replaced by UISelectMany.setValueExpression(java.lang.String, javax.el.ValueExpression). 
javax.faces.component.UIGraphic.setValueBinding(String, ValueBinding)
          This has been replaced by UIGraphic.setValueExpression(java.lang.String, javax.el.ValueExpression). 
javax.faces.component.UIData.setValueBinding(String, ValueBinding)
          This has been replaced by UIData.setValueExpression(java.lang.String, javax.el.ValueExpression). 
javax.faces.component.UIComponent.setValueBinding(String, ValueBinding)
          This has been replaced by UIComponent.setValueExpression(java.lang.String, javax.el.ValueExpression). 
javax.faces.component.EditableValueHolder.setValueChangeListener(MethodBinding)
          Use EditableValueHolder.addValueChangeListener(javax.faces.event.ValueChangeListener) instead, obtaining the argument ValueChangeListener by creating an instance of MethodExpressionValueChangeListener. 
javax.faces.component.UIInput.setValueChangeListener(MethodBinding)
          Use UIInput.addValueChangeListener(javax.faces.event.ValueChangeListener) instead, obtaining the argument ValueChangeListener by creating an instance of MethodExpressionValueChangeListener. 
javax.faces.application.Application.setVariableResolver(VariableResolver)
          The recommended way to affect the execution of the EL is to provide an <el-resolver> element at the right place in the application configuration resources which will be considered in the normal course of expression evaluation. This method now will cause the argument resolver to be wrapped inside an implementation of ELResolver and exposed to the EL resolution system as if the user had called Application.addELResolver(javax.el.ELResolver). 
javax.xml.bind.Validator.validate(Object)
          since JAXB2.0 
javax.xml.bind.Validator.validateRoot(Object)
          since JAXB2.0 
javax.faces.application.StateManager.writeState(FacesContext, StateManager.SerializedView)
          This method has been replaced by StateManager.writeState(javax.faces.context.FacesContext,java.lang.Object). The default implementation calls the non-deprecated variant of the method passing an Object [] as the second argument, where the first element of the array is the return from getStructure() and the second is the return from getState() on the argument state. 
javax.faces.render.ResponseStateManager.writeState(FacesContext, StateManager.SerializedView)
          This method has been replaced by ResponseStateManager.writeState(javax.faces.context.FacesContext,java.lang.Object). The default implementation creates a two element Object array with the first element being the return from calling StateManager.SerializedView.getStructure(), and the second being the return from StateManager.SerializedView.getState(). It then passes this Object array to ResponseStateManager.writeState(javax.faces.context.FacesContext, java.lang.Object). 
 

Deprecated Constructors
javax.servlet.UnavailableException(int, Servlet, String)
          As of Java Servlet API 2.2, use UnavailableException.UnavailableException(String, int) instead. 
javax.servlet.UnavailableException(Servlet, String)
          As of Java Servlet API 2.2, use UnavailableException.UnavailableException(String) instead. 
 

Deprecated Annotation Type Elements
javax.jws.HandlerChain.name
          As of JSR-181 2.0 with no replacement. 
 



Submit a bug or feature

Copyright © 2009-2011, Oracle Corporation and/or its affiliates. All Rights Reserved. Use is subject to license terms.

Generated on 10-February-2011 12:41