atg.droplet
Class ProtocolChange

java.lang.Object
  extended by atg.nucleus.logging.VariableArgumentApplicationLoggingImpl
      extended by atg.nucleus.GenericService
          extended by atg.nucleus.TimedOperationService
              extended by atg.nucleus.servlet.ServletService
                  extended by atg.nucleus.servlet.HttpServletService
                      extended by atg.servlet.DynamoServlet
                          extended by atg.droplet.ProtocolChange
All Implemented Interfaces:
NameContextBindingListener, NameContextElement, NameResolver, AdminableService, ApplicationLogging, atg.nucleus.logging.ApplicationLoggingSender, atg.nucleus.logging.TraceApplicationLogging, atg.nucleus.logging.VariableArgumentApplicationLogging, ComponentNameResolver, Service, ServiceListener, ParameterServlet, java.util.EventListener, javax.servlet.Servlet

public class ProtocolChange
extends DynamoServlet

The ChangeProtocol droplet takes in a url and outputs a full url to that location for both secure and insecure protocols. Enable this by setting the enable property to true.

inUrl
Required output param. The relative or full url that you want to convert to another protocol.
output
The oparam rendered when the request is serviced.
secureUrl
The url in secure protocol.
nonSecureUrl
The url in secure protocol.


Field Summary
static java.lang.String CLASS_VERSION
           
static int DEFAULT_NON_SECURE_PORT
           
static int DEFAULT_SECURE_PORT
           
static ParameterName IN_URL
           
static ParameterName NON_SECURE_URL
           
static ParameterName OUTPUT
           
static ParameterName SECURE_URL
           
 
Fields inherited from class atg.servlet.DynamoServlet
mAllowCleanupRequest, mParameters
 
Fields inherited from class atg.nucleus.servlet.ServletService
SERVLET_INFO_KEY
 
Fields inherited from class atg.nucleus.GenericService
SERVICE_INFO_KEY
 
Fields inherited from interface atg.nucleus.logging.TraceApplicationLogging
DEFAULT_LOG_TRACE_STATUS
 
Fields inherited from interface atg.nucleus.logging.ApplicationLogging
DEFAULT_LOG_DEBUG_STATUS, DEFAULT_LOG_ERROR_STATUS, DEFAULT_LOG_INFO_STATUS, DEFAULT_LOG_WARNING_STATUS
 
Constructor Summary
ProtocolChange()
           
 
Method Summary
 int getDefaultNonSecurePort()
          Deprecated.  
 int getDefaultSecurePort()
          Deprecated.  
 java.lang.String getNonSecureHost()
           
 int getNonSecurePort()
           
 java.lang.String getNonSecureProtocol()
           
 java.lang.String getSecureHost()
           
 int getSecurePort()
           
 java.lang.String getSecureProtocol()
           
 boolean isEnable()
           
 void service(DynamoHttpServletRequest pReq, DynamoHttpServletResponse pRes)
          Service the request
 void setDefaultNonSecurePort(int pDefaultNonSecurePort)
           
 void setDefaultSecurePort(int pDefaultSecurePort)
          Deprecated.  
 void setEnable(boolean pEnable)
          If this is true then the secureUrl and nonSecureUrl output parameters will be fully qualified urls to the appropriate secure or non secure server.
 void setNonSecureHost(java.lang.String pNonSecureHost)
           
 void setNonSecurePort(int pNonSecurePort)
           
 void setNonSecureProtocol(java.lang.String pNonSecureProtocol)
          Sets the property nonSecureProtocol.
Note, changing this property will NOT change the protocol used for non secure requests.
http:// will always be used as the non secure protocol.
 void setSecureHost(java.lang.String pSecureHost)
           
 void setSecurePort(int pSecurePort)
           
 void setSecureProtocol(java.lang.String pSecureProtocol)
          Sets the property secureProtocol.
Note, changing this property will NOT change the protocol used for secure requests.
https:// will always be used as the secure protocol.
 
Methods inherited from class atg.servlet.DynamoServlet
doDelete, doGet, doPost, doPut, getParameter, getParameters, getServletContext, service, service, setParameter
 
Methods inherited from class atg.nucleus.servlet.ServletService
destroy, getServletConfig, getServletInfo, init, setServletInfo
 
Methods inherited from class atg.nucleus.TimedOperationService
getAverageRequestHandlingTime, getHandledRequestCount, getRequestStartTime, getTotalRequestHandlingTime, isKeepingStatistics, notifyHandledRequest, resetStatistics, setKeepingStatistics
 
Methods inherited from class atg.nucleus.GenericService
addLogListener, createAdminServlet, doStartService, doStopService, getAbsoluteName, getAdminServlet, getLoggingForVlogging, getLogListenerCount, getLogListeners, getName, getNameContext, getNucleus, getRoot, getServiceConfiguration, getServiceInfo, isLoggingDebug, isLoggingError, isLoggingInfo, isLoggingTrace, isLoggingWarning, isRunning, logDebug, logDebug, logDebug, logError, logError, logError, logInfo, logInfo, logInfo, logTrace, logTrace, logTrace, logWarning, logWarning, logWarning, nameContextElementBound, nameContextElementUnbound, removeLogListener, resolveName, resolveName, resolveName, resolveName, sendLogEvent, setLoggingDebug, setLoggingError, setLoggingInfo, setLoggingTrace, setLoggingWarning, setNucleus, setServiceInfo, startService, stopService
 
Methods inherited from class atg.nucleus.logging.VariableArgumentApplicationLoggingImpl
vlogDebug, vlogDebug, vlogDebug, vlogDebug, vlogError, vlogError, vlogError, vlogError, vlogInfo, vlogInfo, vlogInfo, vlogInfo, vlogTrace, vlogTrace, vlogTrace, vlogTrace, vlogWarning, vlogWarning, vlogWarning, vlogWarning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CLASS_VERSION

public static java.lang.String CLASS_VERSION

DEFAULT_SECURE_PORT

public static final int DEFAULT_SECURE_PORT
See Also:
Constant Field Values

DEFAULT_NON_SECURE_PORT

public static final int DEFAULT_NON_SECURE_PORT
See Also:
Constant Field Values

IN_URL

public static final ParameterName IN_URL

OUTPUT

public static final ParameterName OUTPUT

SECURE_URL

public static final ParameterName SECURE_URL

NON_SECURE_URL

public static final ParameterName NON_SECURE_URL
Constructor Detail

ProtocolChange

public ProtocolChange()
Method Detail

service

public void service(DynamoHttpServletRequest pReq,
                    DynamoHttpServletResponse pRes)
             throws javax.servlet.ServletException,
                    java.io.IOException
Service the request

Overrides:
service in class DynamoServlet
Parameters:
pReq - the request to be processed
pRes - the response object for this request
Throws:
javax.servlet.ServletException - an application specific error occurred processing this request
java.io.IOException - an error occurred reading data from the request or writing data to the response.

setEnable

public void setEnable(boolean pEnable)
If this is true then the secureUrl and nonSecureUrl output parameters will be fully qualified urls to the appropriate secure or non secure server. If false, then the secureUrl and nonSecureUrl will just be the same value as the inUrl with no processing at all.


isEnable

public boolean isEnable()

setSecureHost

public void setSecureHost(java.lang.String pSecureHost)

getSecureHost

public java.lang.String getSecureHost()

setNonSecureHost

public void setNonSecureHost(java.lang.String pNonSecureHost)

getNonSecureHost

public java.lang.String getNonSecureHost()

setSecurePort

public void setSecurePort(int pSecurePort)

getSecurePort

public int getSecurePort()

setNonSecurePort

public void setNonSecurePort(int pNonSecurePort)

getNonSecurePort

public int getNonSecurePort()

setSecureProtocol

public void setSecureProtocol(java.lang.String pSecureProtocol)
Sets the property secureProtocol.
Note, changing this property will NOT change the protocol used for secure requests.
https:// will always be used as the secure protocol.


getSecureProtocol

public java.lang.String getSecureProtocol()

setNonSecureProtocol

public void setNonSecureProtocol(java.lang.String pNonSecureProtocol)
Sets the property nonSecureProtocol.
Note, changing this property will NOT change the protocol used for non secure requests.
http:// will always be used as the non secure protocol.


getNonSecureProtocol

public java.lang.String getNonSecureProtocol()

setDefaultSecurePort

public void setDefaultSecurePort(int pDefaultSecurePort)
Deprecated. 


getDefaultSecurePort

public int getDefaultSecurePort()
Deprecated. 


setDefaultNonSecurePort

public void setDefaultNonSecurePort(int pDefaultNonSecurePort)

getDefaultNonSecurePort

public int getDefaultNonSecurePort()
Deprecated.