atg.svc.ui.formhandlers
Class ViewDocumentFormHandler

java.lang.Object
  extended by atg.nucleus.logging.VariableArgumentApplicationLoggingImpl
      extended by atg.nucleus.GenericService
          extended by atg.droplet.EmptyFormHandler
              extended by atg.droplet.GenericFormHandler
                  extended by atg.droplet.TransactionalFormHandler
                      extended by atg.web.formhandlers.ApplicationFormHandler
                          extended by atg.svc.ui.formhandlers.ServiceFormHandler
                              extended by atg.svc.ui.formhandlers.FrameworkBaseFormHandler
                                  extended by atg.svc.ui.formhandlers.ViewDocumentFormHandler
All Implemented Interfaces:
atg.droplet.DropletFormHandler, 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, FormHandlerConstants, java.util.EventListener

public class ViewDocumentFormHandler
extends FrameworkBaseFormHandler

Allows viewing document that was found earlier. First usage is to pass serialized com.primus.searchstudio.Response response object in the same property, call handleViewDocument(atg.servlet.DynamoHttpServletRequest, atg.servlet.DynamoHttpServletResponse) and use getResult(). This performs saving "document viewed" event. Second usage is to set getContextId(), maybe getURL() and #getQuestion(), call handleRetrieveAnswer(atg.servlet.DynamoHttpServletRequest, atg.servlet.DynamoHttpServletResponse) and use #getAnswer() as a document with highlight info.


Field Summary
static java.lang.String CLASS_VERSION
          Class version string
static java.lang.String CURRENT_SOLUTION_ID_WINDOW_STATE_KEY
           
static java.lang.String DOCUMENT_RESULT_WINDOW_STATE_KEY
          Keys for window state
protected  java.lang.String mContextId
           
protected  java.lang.String mDocTitle
           
protected  java.lang.String mDocType
           
protected  boolean mIsRecordAnswerViewed
          whether the viewed answer is to be record or not
protected  boolean mIsViewInContext
           
protected  java.lang.String mKnowledgeContextName
           
 int mMaxContextIdLength
           
protected  java.lang.String mURL
           
static java.lang.String SOLUTION_ID_WINDOW_STATE_KEY
           
static java.lang.String SOLUTION_RESULT_WINDOW_STATE_KEY
           
 
Fields inherited from class atg.svc.ui.formhandlers.ServiceFormHandler
PERFMON_OP_FORM_HANDLER
 
Fields inherited from class atg.web.formhandlers.ApplicationFormHandler
EQUALS, PARAM_DELIMITER, QUERY_DELIMITER, STATUS_ERROR_REDIRECT, STATUS_ERROR_STAY, STATUS_SUCCESS
 
Fields inherited from class atg.droplet.GenericFormHandler
PARAM_DEFER_FORWARD_OR_REDIRECT, PARAM_USE_FORWARDS
 
Fields inherited from class atg.nucleus.GenericService
SERVICE_INFO_KEY
 
Fields inherited from interface atg.svc.ui.formhandlers.FormHandlerConstants
OPTIONS_ANSWER_DISPLAY, OPTIONS_ANSWER_DISPLAY_CURRENT_WINDOW, OPTIONS_ANSWER_DISPLAY_MULTIPLE_WINDOWS, OPTIONS_ANSWER_DISPLAY_SINGLE_WINDOW, OPTIONS_FILTER_BY_DOC_SET, OPTIONS_FILTER_BY_FORMAT, OPTIONS_FILTER_BY_SOURCE, OPTIONS_FILTER_BY_TITLE, OPTIONS_FILTER_OR_GROUPING_FILTER, OPTIONS_FILTER_OR_GROUPING_GROUP, OPTIONS_FILTER_OR_GROUPING_NONE, OPTIONS_QUERY_LANGUAGE, OPTIONS_RESULT_LANGUAGE, OPTIONS_SHOW_ANSWERS_AS, OPTIONS_SHOW_ANSWERS_BY_DOC, OPTIONS_SHOW_ANSWERS_INDIVIDUAL, OPTIONS_SHOW_FAQS_AS_QUESTIONS, OPTIONS_SHOW_FAQS_AS_QUESTIONS_AND_ANSWERS, PARAM_SITE_ID
 
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
ViewDocumentFormHandler()
           
 
Method Summary
 java.lang.String getContextId()
           
 java.lang.String getDocTitle()
           
 java.lang.String getDocType()
           
 atg.search.routing.command.search.Document getDocumentForPreview()
          Converts answer info (context ID, group ID, maybe URL, Title and docType) into result document with highlighting.
 boolean getIsRecordAnswerViewed()
           
 boolean getIsViewInContext()
           
 java.lang.String getKnowledgeContextName()
           
protected  atg.svc.search.KnowledgeQueryContext getKnowledgeQueryContextForWindow()
           
 int getMaxContextIdLength()
           
 java.lang.String getQueryId()
           
 atg.search.routing.command.search.Document getResult()
           
 java.lang.String getResultAsString()
           
 java.lang.String getSearchContextAsString()
           
 atg.svc.search.SearchService getSearchService()
           
 SessionService getSessionService()
           
protected  atg.svc.repository.beans.Solution getSolution()
          Gets the solution using the formhandler properties.
 java.lang.String getSolutionId()
           
 SolutionService getSolutionService()
           
 java.lang.String getSolutionVersion()
           
 int getTotalResultCount()
           
protected  java.lang.String getTruncatedContextId(java.lang.String contextId)
           
 java.lang.String getURL()
           
 java.lang.String getVersionId()
           
 boolean handleCreateSolutionFromDocument(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          This handle method is called when the 'Create Solution from this Document' is selected on the Research Tab.
 boolean handleCreateSolutionFromDocumentRecent(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          This handle method is called when the 'Create Solution from this Document' is selected on the Research Tab.
 boolean handleResearchViewSolutionByDisplayId(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
           
 boolean handleRetrieveAnswer(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          Converts answer info (context ID, group ID, maybe URL and question) into result document with highlighting as "answer" string property.
 boolean handleViewDocument(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          Unpacks serializedResult to use and serializedSearchContext; records "doc viewed" event unless getIsRecordAnswerViewed() property is set to "false".
 boolean handleViewedRecordDocument(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
           
 boolean handleViewedRecordSolution(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
           
 boolean handleViewSolution(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          Unpacks serializedResult to use and serializedSearchContext; records "doc viewed - Solution" event unless getIsRecordAnswerViewed() property is set to "false".
 boolean handleViewSolutionByDisplayId(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
           
 void processRetrieveAnswer(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          Converts answer info (context ID, group ID, maybe URL and question) into result document with highlighting as "answer" string property.
 void processViewDocument(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          Unpacks serializedResult to use and serializedSearchContext; records "doc viewed" event unless getIsRecordAnswerViewed() property is set to "false".
 void processViewedRecordDocument(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
           
 void processViewedRecordSolution(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
           
 void processViewSolution(atg.servlet.DynamoHttpServletRequest pRequest, atg.servlet.DynamoHttpServletResponse pResponse)
          Unpacks serializedResult to use and serializedSearchContext; records "doc viewed - Solution" event unless getIsRecordAnswerViewed() property is set to "false".
 void setContextId(java.lang.String pContextId)
          Answer context -- document ID and it's fragments that are answers to passed question.
 void setDocTitle(java.lang.String pDocTitle)
           
 void setDocType(java.lang.String pDocType)
           
 void setIsRecordAnswerViewed(boolean pIsRecordAnswerViewed)
          Set to false if this is a previously viewed answer we're viewing again.
 void setIsViewInContext(boolean pIsViewInContext)
          Set to true to retrieve a document or solution with the answer highlighted, set to false if you want to retrieve a solution without highlighting
 void setKnowledgeContextName(java.lang.String pKnowledgeContextName)
           
 void setMaxContextIdLength(int length)
           
 void setQueryId(java.lang.String pQueryId)
           
 void setResult(atg.search.routing.command.search.Document pResult)
           
 void setResultAsString(java.lang.String pSerializedResult)
           
 void setSearchContextAsString(java.lang.String pSerializedSearchContext)
           
 void setSearchService(atg.svc.search.SearchService pSearchService)
           
 void setSessionService(SessionService pSessionService)
           
 void setSolutionId(java.lang.String pSolutionId)
           
 void setSolutionService(SolutionService pSolutionService)
           
 void setSolutionVersion(java.lang.String pSolutionVersion)
           
 void setTotalResultCount(int pTotalResultCount)
           
 void setURL(java.lang.String pURL)
           
 void setVersionId(java.lang.String pVersionId)
           
 
Methods inherited from class atg.svc.ui.formhandlers.FrameworkBaseFormHandler
formHandlerInit, getErrorURL, getParameterMap, getParameters, handleChangeTab, handleCloseWindow, handleGetWindowTab, handleHidePanel, handleProcessPanel, handleScrollPanelTabsLeft, handleScrollPanelTabsRight, handleSelectTabbedPanel, handleShowPanel, handleToggleCell, handleTogglePanel, handleTogglePanelContent, handleTogglePanelsToTabs, handleTransform, setErrorURL, setParameterMap, setParameters
 
Methods inherited from class atg.svc.ui.formhandlers.ServiceFormHandler
handleUncheckedFormException, isLoggingUncheckedException, isRollbackTransactionOnFormError, isTransactionMarkedAsRollback, processException, processException, setLoggingUncheckedException, setRollbackTransactionOnFormError
 
Methods inherited from class atg.web.formhandlers.ApplicationFormHandler
addParameterToURLString, beforeGet, beforeSet, checkFormError, checkFormRedirect, checkFormSuccess, formHandlerBeforeGet, formHandlerBeforeSet, getRedirectDelayMS, getString, getString, getString, getSuccessURL, getUserMessagesResourceBundle, handleCancel, processException, processException, processExceptionAndLog, processExceptionAndLog, redirect, setRedirectDelayMS, setSuccessURL, setUserMessagesResourceBundle
 
Methods inherited from class atg.droplet.TransactionalFormHandler
afterSet, commitTransaction, getTransactionDemarcation, getTransactionStatus, isEnsureTransaction, isRollbackTransaction, isRollbackTransactionOnUnhandledException, setEnsureTransaction, setRollbackTransaction, setRollbackTransactionOnUnhandledException, setTransactionDemarcation
 
Methods inherited from class atg.droplet.GenericFormHandler
addFormException, addUncheckedFormException, createFormSubmissionMessage, getCancelURL, getCheckForValidSession, getFormError, getFormExceptions, getFormName, getMessagePort, getMessageSource, getMessageType, getPropertyExceptions, getSendMessages, getUncheckedFormExceptions, handleFormException, hasUncheckedFormExceptions, isDeferForwardsAndRedirects, isRestorableForm, isUseForwards, isValidSession, redirectOrForward, resetFormExceptions, setCancelURL, setCheckForValidSession, setDeferForwardsAndRedirects, setFormName, setMessagePort, setMessageSource, setMessageType, setRestorableForm, setSendMessages, setUseForwards
 
Methods inherited from class atg.droplet.EmptyFormHandler
afterGet
 
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
Class version string


DOCUMENT_RESULT_WINDOW_STATE_KEY

public static final java.lang.String DOCUMENT_RESULT_WINDOW_STATE_KEY
Keys for window state

See Also:
Constant Field Values

SOLUTION_ID_WINDOW_STATE_KEY

public static final java.lang.String SOLUTION_ID_WINDOW_STATE_KEY
See Also:
Constant Field Values

SOLUTION_RESULT_WINDOW_STATE_KEY

public static final java.lang.String SOLUTION_RESULT_WINDOW_STATE_KEY
See Also:
Constant Field Values

CURRENT_SOLUTION_ID_WINDOW_STATE_KEY

public static final java.lang.String CURRENT_SOLUTION_ID_WINDOW_STATE_KEY
See Also:
Constant Field Values

mMaxContextIdLength

public int mMaxContextIdLength

mIsViewInContext

protected boolean mIsViewInContext

mIsRecordAnswerViewed

protected boolean mIsRecordAnswerViewed
whether the viewed answer is to be record or not


mContextId

protected java.lang.String mContextId

mURL

protected java.lang.String mURL

mDocType

protected java.lang.String mDocType

mDocTitle

protected java.lang.String mDocTitle

mKnowledgeContextName

protected java.lang.String mKnowledgeContextName
Constructor Detail

ViewDocumentFormHandler

public ViewDocumentFormHandler()
Method Detail

getSessionService

public SessionService getSessionService()

setSessionService

public void setSessionService(SessionService pSessionService)

getSolutionService

public SolutionService getSolutionService()

setSolutionService

public void setSolutionService(SolutionService pSolutionService)

getSearchService

public atg.svc.search.SearchService getSearchService()

setSearchService

public void setSearchService(atg.svc.search.SearchService pSearchService)

getMaxContextIdLength

public int getMaxContextIdLength()

setMaxContextIdLength

public void setMaxContextIdLength(int length)

setTotalResultCount

public void setTotalResultCount(int pTotalResultCount)
Parameters:
pTotalResultCount - How much results were found at the latest search.

getTotalResultCount

public int getTotalResultCount()
Returns:
How much results were found at the latest search.

setResult

public void setResult(atg.search.routing.command.search.Document pResult)
Parameters:
pResult - Answer (document + highlighing) to view.

getResult

public atg.search.routing.command.search.Document getResult()
Returns:
Answer (document + highlighing) to view.

setQueryId

public void setQueryId(java.lang.String pQueryId)
Parameters:
pQueryId - ID of the latest search event.

getQueryId

public java.lang.String getQueryId()
Returns:
ID of the latest search event.

setSolutionId

public void setSolutionId(java.lang.String pSolutionId)
Parameters:
pSolutionId - ID of the solution to show.

getSolutionId

public java.lang.String getSolutionId()
Returns:
If latest search returned solution and user wants to see it, use this as an ID of the solution to show.

setSolutionVersion

public void setSolutionVersion(java.lang.String pSolutionVersion)
Parameters:
pSolutionId - version of the solution to show.

getSolutionVersion

public java.lang.String getSolutionVersion()
Returns:
If latest search returned solution and user wants to see it, use this version of the solution to show.

setVersionId

public void setVersionId(java.lang.String pVersionId)
Parameters:
pVersionId - required to store info for displaying the Version document in GUI

getVersionId

public java.lang.String getVersionId()
Returns:
ID of the solution version to show.

setSearchContextAsString

public void setSearchContextAsString(java.lang.String pSerializedSearchContext)
Parameters:
pSerializedSearchContext - serialized search context object as base64-encoded string

getSearchContextAsString

public java.lang.String getSearchContextAsString()
Returns:
serialized search context object as base64-encoded string

setResultAsString

public void setResultAsString(java.lang.String pSerializedResult)
Parameters:
pSerializedResult - serialized view-in-context result object as base64-encoded string

getResultAsString

public java.lang.String getResultAsString()
Returns:
serialized view-in-context result object as base64-encoded string

getIsViewInContext

public boolean getIsViewInContext()
Returns:
whether the request is a request to view in context or not

setIsViewInContext

public void setIsViewInContext(boolean pIsViewInContext)
Set to true to retrieve a document or solution with the answer highlighted, set to false if you want to retrieve a solution without highlighting


getIsRecordAnswerViewed

public boolean getIsRecordAnswerViewed()
Returns:
whether the viewed answer is to be record or not

setIsRecordAnswerViewed

public void setIsRecordAnswerViewed(boolean pIsRecordAnswerViewed)
Set to false if this is a previously viewed answer we're viewing again.


getContextId

public java.lang.String getContextId()
Returns:
Answer context -- document ID and it's fragments that are answers to passed question.

setContextId

public void setContextId(java.lang.String pContextId)
Answer context -- document ID and it's fragments that are answers to passed question.


getURL

public java.lang.String getURL()

setURL

public void setURL(java.lang.String pURL)

getDocType

public java.lang.String getDocType()

setDocType

public void setDocType(java.lang.String pDocType)

getDocTitle

public java.lang.String getDocTitle()

setDocTitle

public void setDocTitle(java.lang.String pDocTitle)

getKnowledgeContextName

public java.lang.String getKnowledgeContextName()

setKnowledgeContextName

public void setKnowledgeContextName(java.lang.String pKnowledgeContextName)

handleViewDocument

public boolean handleViewDocument(atg.servlet.DynamoHttpServletRequest pRequest,
                                  atg.servlet.DynamoHttpServletResponse pResponse)
                           throws java.lang.Exception
Unpacks serializedResult to use and serializedSearchContext; records "doc viewed" event unless getIsRecordAnswerViewed() property is set to "false".

Returns:
as usually, "true" to proceed rendering current page and "false" if redirect is needed.
Throws:
java.lang.Exception

processViewDocument

public void processViewDocument(atg.servlet.DynamoHttpServletRequest pRequest,
                                atg.servlet.DynamoHttpServletResponse pResponse)
                         throws java.lang.Exception
Unpacks serializedResult to use and serializedSearchContext; records "doc viewed" event unless getIsRecordAnswerViewed() property is set to "false".

Throws:
java.lang.Exception

handleViewSolution

public boolean handleViewSolution(atg.servlet.DynamoHttpServletRequest pRequest,
                                  atg.servlet.DynamoHttpServletResponse pResponse)
                           throws java.lang.Exception
Unpacks serializedResult to use and serializedSearchContext; records "doc viewed - Solution" event unless getIsRecordAnswerViewed() property is set to "false". This is similar to handleViewDocument , but in addition it tries to record the Solution even if it is searched without context based on solution ID

Returns:
as usually, "true" to proceed rendering current page and "false" if redirect is needed.
Throws:
java.lang.Exception

processViewSolution

public void processViewSolution(atg.servlet.DynamoHttpServletRequest pRequest,
                                atg.servlet.DynamoHttpServletResponse pResponse)
                         throws java.lang.Exception
Unpacks serializedResult to use and serializedSearchContext; records "doc viewed - Solution" event unless getIsRecordAnswerViewed() property is set to "false". This is similar to processViewDocument , but in addition it tries to record the Solution even if it is searched without context based on solution ID

Throws:
java.lang.Exception

handleCreateSolutionFromDocument

public boolean handleCreateSolutionFromDocument(atg.servlet.DynamoHttpServletRequest pRequest,
                                                atg.servlet.DynamoHttpServletResponse pResponse)
                                         throws java.lang.Exception
This handle method is called when the 'Create Solution from this Document' is selected on the Research Tab. In the case where the current document is selected through the favorites panel (in other words, not a traditional search), the handleCreateSolutionFromDocumentRecent method is called instead.

Returns:
"true" to proceed rendering current page and "false" if a redirect is required.
Throws:
java.lang.Exception

handleCreateSolutionFromDocumentRecent

public boolean handleCreateSolutionFromDocumentRecent(atg.servlet.DynamoHttpServletRequest pRequest,
                                                      atg.servlet.DynamoHttpServletResponse pResponse)
                                               throws java.lang.Exception
This handle method is called when the 'Create Solution from this Document' is selected on the Research Tab. In the case where the current document is selected from a traditional search (in other words, by selecting a document from a search result), the handleCreateSolutionFromDocument method is called instead.

Returns:
"true" to proceed rendering current page and "false" if a redirect is required.
Throws:
java.lang.Exception

handleViewSolutionByDisplayId

public boolean handleViewSolutionByDisplayId(atg.servlet.DynamoHttpServletRequest pRequest,
                                             atg.servlet.DynamoHttpServletResponse pResponse)
                                      throws java.lang.Exception
Throws:
java.lang.Exception

handleResearchViewSolutionByDisplayId

public boolean handleResearchViewSolutionByDisplayId(atg.servlet.DynamoHttpServletRequest pRequest,
                                                     atg.servlet.DynamoHttpServletResponse pResponse)
                                              throws java.lang.Exception
Throws:
java.lang.Exception

handleRetrieveAnswer

public boolean handleRetrieveAnswer(atg.servlet.DynamoHttpServletRequest pRequest,
                                    atg.servlet.DynamoHttpServletResponse pResponse)
                             throws java.lang.Exception
Converts answer info (context ID, group ID, maybe URL and question) into result document with highlighting as "answer" string property. Does not save events.

Returns:
as usually, "true" to proceed rendering current page and "false" if redirect is needed.
Throws:
java.lang.Exception

processRetrieveAnswer

public void processRetrieveAnswer(atg.servlet.DynamoHttpServletRequest pRequest,
                                  atg.servlet.DynamoHttpServletResponse pResponse)
                           throws java.lang.Exception
Converts answer info (context ID, group ID, maybe URL and question) into result document with highlighting as "answer" string property. Does not save events.

Throws:
java.lang.Exception

handleViewedRecordSolution

public boolean handleViewedRecordSolution(atg.servlet.DynamoHttpServletRequest pRequest,
                                          atg.servlet.DynamoHttpServletResponse pResponse)
                                   throws java.lang.Exception
Throws:
java.lang.Exception

processViewedRecordSolution

public void processViewedRecordSolution(atg.servlet.DynamoHttpServletRequest pRequest,
                                        atg.servlet.DynamoHttpServletResponse pResponse)
                                 throws java.lang.Exception
Throws:
java.lang.Exception

handleViewedRecordDocument

public boolean handleViewedRecordDocument(atg.servlet.DynamoHttpServletRequest pRequest,
                                          atg.servlet.DynamoHttpServletResponse pResponse)
                                   throws java.lang.Exception
Throws:
java.lang.Exception

processViewedRecordDocument

public void processViewedRecordDocument(atg.servlet.DynamoHttpServletRequest pRequest,
                                        atg.servlet.DynamoHttpServletResponse pResponse)
                                 throws java.lang.Exception
Throws:
java.lang.Exception

getDocumentForPreview

public atg.search.routing.command.search.Document getDocumentForPreview()
Converts answer info (context ID, group ID, maybe URL, Title and docType) into result document with highlighting.


getTruncatedContextId

protected java.lang.String getTruncatedContextId(java.lang.String contextId)
Parameters:
contextId - Highlighting info as returned from AE server, format is: doc#.offset1:len1,offset2:len2...
Returns:
ContextId truncated to fit into DB column.

getSolution

protected atg.svc.repository.beans.Solution getSolution()
                                                 throws ObjectNotFoundException
Gets the solution using the formhandler properties. The common implementation is to get the solution by id.

Returns:
The Solution object.
Throws:
ObjectNotFoundException - If the Solution object was not found.

getKnowledgeQueryContextForWindow

protected atg.svc.search.KnowledgeQueryContext getKnowledgeQueryContextForWindow()