atg.svc.fragment
Class TransactionalFragment

java.lang.Object
  extended by atg.nucleus.logging.VariableArgumentApplicationLoggingImpl
      extended by atg.nucleus.GenericService
          extended by atg.svc.fragment.TransactionalFragment
All Implemented Interfaces:
atg.naming.NameContextBindingListener, atg.naming.NameContextElement, atg.naming.NameResolver, atg.nucleus.AdminableService, atg.nucleus.logging.ApplicationLogging, atg.nucleus.logging.ApplicationLoggingSender, atg.nucleus.logging.TraceApplicationLogging, atg.nucleus.logging.VariableArgumentApplicationLogging, atg.nucleus.naming.ComponentNameResolver, atg.nucleus.Service, atg.nucleus.ServiceListener, java.util.EventListener

public class TransactionalFragment
extends atg.nucleus.GenericService

TransactionalFragment Defines a transactional fragment component. The component configures the display name, description, url and an optional array of parameters that are passed to the url. The array of parameters is a String array of parameter names to associate with the transactional fragment. The parameters are defined in the repository as TransactionalFragmentParameter objects (TransactionalFragmentParameter).

See Also:
TransactionalFragmentService

Field Summary
static java.lang.String CLASS_VERSION
          Class version string
 
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
TransactionalFragment()
           
 
Method Summary
 void doStartService()
          Outputs some debug info about the TransactionalFragment.
 java.lang.String getDescription()
          Gets the description.
 java.lang.String getDisplayName()
          Gets the display name.
 int getHeight()
          Gets the initial height the frame that renders the transactional fragment should be set to.
 java.lang.String[] getParameterNames()
          Gets the list of parameter names that are associated with the fragment.
 java.util.List getParameters()
          Gets a List of TransactionalFragmentParameter associated with this transactional fragment as configured in the parameterNames property.
 java.lang.String getResourceBundle()
          Gets the name of the resource bundle to use for the displayName, description and parameter labels.
 java.lang.String getServletContext()
          Optional context root for when the fragment lives in a different webapp context.
 java.lang.String getUrl()
          Gets the URL of the JSP, HTML, etc.
 boolean isInteractive()
          Returns true if the transactional fragment should always be rendered inside of an IFRAME.
 boolean isSelectable()
          Returns true if this transactional fragment is available to be selected during authoring.
 void setDescription(java.lang.String pDescription)
          Sets the optional description text.
 void setDisplayName(java.lang.String pDisplayName)
          Sets the Transactional Fragment display name.
 void setHeight(int pHeight)
          Sets the initial height the frame that renders the transactional fragment should be set to.
 void setInteractive(boolean pInteractive)
          Set true if the transactional fragment should always be rendered inside of an IFRAME.
 void setParameterNames(java.lang.String[] pParameterNames)
          Sets the list of parameter names that are associated with the fragment.
 void setResourceBundle(java.lang.String pResourceBundle)
          Sets the name of the resource bundle to use for the displayName, description and parameter labels.
 void setSelectable(boolean pSelectable)
          Set true if this transactional fragment is available to be selected during authoring.
 void setServletContext(java.lang.String pServletContext)
          Optional context root for when the fragment lives in a different webapp context.
 void setUrl(java.lang.String pUrl)
          Sets the URL of the JSP, HTML, etc.
 java.lang.String toString()
          Gets a string representation of the configuration of this component.
 
Methods inherited from class atg.nucleus.GenericService
addLogListener, createAdminServlet, doStopService, getAbsoluteName, getAdminServlet, getAdminServletOutputStreamEncoding, getLoggingForVlogging, getLogListenerCount, getLogListeners, getName, getNameContext, getNucleus, getRoot, getServiceConfiguration, getServiceInfo, isAdminServletUseServletOutputStream, isLoggingDebug, isLoggingError, isLoggingInfo, isLoggingTrace, isLoggingWarning, isRunning, logDebug, logDebug, logDebug, logError, logError, logError, logInfo, logInfo, logInfo, logTrace, logTrace, logTrace, logWarning, logWarning, logWarning, nameContextElementBound, nameContextElementUnbound, removeLogListener, reResolveThis, resolveName, resolveName, resolveName, resolveName, sendLogEvent, setAdminServletOutputStreamEncoding, setAdminServletUseServletOutputStream, setLoggingDebug, setLoggingError, setLoggingInfo, setLoggingTrace, setLoggingWarning, setNucleus, setServiceInfo, startService, stopService
 
Methods inherited from class atg.nucleus.logging.VariableArgumentApplicationLoggingImpl
vlogDebug, vlogDebug, vlogDebug, vlogDebug, vlogDebugTrace, 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, wait, wait, wait
 

Field Detail

CLASS_VERSION

public static java.lang.String CLASS_VERSION
Class version string

Constructor Detail

TransactionalFragment

public TransactionalFragment()
Method Detail

getDisplayName

public java.lang.String getDisplayName()
Gets the display name. The value of the display name will be used to as a resource to lookup in the configured resource bundle. If no resource is found in the bundle the string is just returned.

Returns:
The display name from the configured resource bundle or as configured if not found or blank
Throws:
java.util.MissingResourceException - If the configured resource bundle is not found in the class path.

setDisplayName

public void setDisplayName(java.lang.String pDisplayName)
Sets the Transactional Fragment display name. This will show in all picklists.

Parameters:
pDisplayName - The Transactional Fragment display name.

getDescription

public java.lang.String getDescription()
Gets the description. The value of the display name will be used to as a resource to lookup in the configured resource bundle. If no resource is found in the bundle the string is just returned.

Returns:
The display name from the configured resource bundle or as configured if not found or blank.
Throws:
java.util.MissingResourceException - If the configured resource bundle is not found in the class path.

setDescription

public void setDescription(java.lang.String pDescription)
Sets the optional description text.

Parameters:
pDescription - The description text.

getServletContext

public java.lang.String getServletContext()
Optional context root for when the fragment lives in a different webapp context.

Returns:
The context root for the fragment URL.

setServletContext

public void setServletContext(java.lang.String pServletContext)
Optional context root for when the fragment lives in a different webapp context.

Parameters:
pServletContext - The context root for the fragment URL.

getUrl

public java.lang.String getUrl()
Gets the URL of the JSP, HTML, etc. that will be rendered when this transactional fragment is viewed. If the URL is outside the context root of the webapp it should be a fully qualified URL.

Returns:
The URL to display when the fragment is viewed.

setUrl

public void setUrl(java.lang.String pUrl)
Sets the URL of the JSP, HTML, etc. that will be rendered when this transactional fragment is viewed. If the URL is outside the context root of the webapp it should be a fully qualified URL.

Parameters:
pUrl - The URL to display when the fragment is viewed.

getResourceBundle

public java.lang.String getResourceBundle()
Gets the name of the resource bundle to use for the displayName, description and parameter labels.

Returns:
The name of the resource bundle to use for the displayName, description and parameter labels.

setResourceBundle

public void setResourceBundle(java.lang.String pResourceBundle)
Sets the name of the resource bundle to use for the displayName, description and parameter labels.

Parameters:
pResourceBundle - The name of the resource bundle to use for the displayName, description and parameter labels.

isSelectable

public boolean isSelectable()
Returns true if this transactional fragment is available to be selected during authoring.

Returns:
True if this transactional fragment is available to be selected during authoring.

setSelectable

public void setSelectable(boolean pSelectable)
Set true if this transactional fragment is available to be selected during authoring.

Parameters:
pSelectable - True if this transactional fragment is available to be selected during authoring.

isInteractive

public boolean isInteractive()
Returns true if the transactional fragment should always be rendered inside of an IFRAME. Most fragments should be rendered inside of an IFRAME due to being interactive and showing as part of a solution. Fragments that are interactive and that do not show inside an IFRAME could accidentally replace the application with the form successUrl.

Returns:
True if the transactional fragment should always be rendered inside of an IFRAME

setInteractive

public void setInteractive(boolean pInteractive)
Set true if the transactional fragment should always be rendered inside of an IFRAME. Most fragments should be rendered inside of an IFRAME due to being interactive and showing as part of a solution. Fragments that are interactive and that do not show inside an IFRAME could accidentally replace the application with the form successUrl.

Parameters:
pInteractive - True if the transactional fragment should always be rendered inside of an IFRAME

getHeight

public int getHeight()
Gets the initial height the frame that renders the transactional fragment should be set to. If the height is not configured the default is 200.

Returns:
The initial height the frame that renders the transactional fragment should be set to.

setHeight

public void setHeight(int pHeight)
Sets the initial height the frame that renders the transactional fragment should be set to. This setting only applies if interactive is set to true. If the height is not configured the default is 200.

Parameters:
pHeight - The initial height the frame that renders the transactional fragment should be set to.

getParameterNames

public java.lang.String[] getParameterNames()
Gets the list of parameter names that are associated with the fragment. Each parameter name corresponds to a parameter object defined in the repository.

Returns:
The list of parameter names in the repository to associate with the fragment. If there are none then an empty array is returned.

setParameterNames

public void setParameterNames(java.lang.String[] pParameterNames)
Sets the list of parameter names that are associated with the fragment. Each parameter name corresponds to a parameter object defined in the repository.

Parameters:
pParameterNames - The list of parameter names in the repository to associate with the fragment.

getParameters

public java.util.List getParameters()
Gets a List of TransactionalFragmentParameter associated with this transactional fragment as configured in the parameterNames property. Each name in the parameterNames property is mapped to a TransactionalFragmentParameter in the repository and set in the List that is returned.

Returns:
A List of TransactionalFragmentParameter objects or an empty list if there are no parameters configured.

doStartService

public void doStartService()
                    throws atg.nucleus.ServiceException
Outputs some debug info about the TransactionalFragment.

Overrides:
doStartService in class atg.nucleus.GenericService
Throws:
atg.nucleus.ServiceException

toString

public java.lang.String toString()
Gets a string representation of the configuration of this component.

Overrides:
toString in class java.lang.Object
Returns:
The String with info about this component