Package org.codelibs.fess.helper
Class ViewHelper
java.lang.Object
org.codelibs.fess.helper.ViewHelper
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic class -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected ViewHelper.ActionHookprotected static final Stringprotected Stringprotected static final Stringprotected static final Stringprotected booleanprotected Stringprotected Stringprotected com.google.common.cache.Cache<String,FacetResponse> protected longprotected final List<FacetQueryView>protected String[]protected Stringprotected Stringprotected static final Stringprotected static final Patternprotected Stringprotected Stringprotected static final Stringprotected static final Stringprotected static final Patternprotected static final intprotected intprotected intprotected intprotected Stringprotected boolean -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddFacetQueryView(FacetQueryView facetQueryView) voidaddInitFacetParam(String key, String value) voidaddInitGeoParam(String key, String value) voidaddInlineMimeType(String mimeType) protected StringappendHTMLSearchWord(Map<String, Object> document, String url) protected StringappendPDFSearchWord(Map<String, Object> document, String url) protected StringappendQueryParameter(Map<String, Object> document, String url) org.lastaflute.web.response.StreamResponseasContentResponse(Map<String, Object> doc) createCacheContent(Map<String, Object> doc, String[] queries) createHighlightText(org.opensearch.search.fetch.subphase.highlight.HighlightField highlightField) createTextFragmentsByHighlight(org.opensearch.search.fetch.subphase.highlight.HighlightField[] fields) protected StringescapeHighlight(String text) getCachedFacetResponse(String query) getClientIp(javax.servlet.http.HttpServletRequest request) getContentDescription(Map<String, Object> document) getContentTitle(Map<String, Object> document) getPagePath(String page) getSitePath(Map<String, Object> docMap) getUrlLink(Map<String, Object> document) voidinit()booleanprotected StringremoveHighlightTag(String str) protected StringreplaceHighlightQueries(String cache, String[] queries) voidsetActionHook(ViewHelper.ActionHook actionHook) voidsetCacheTemplateName(String cacheTemplateName) voidsetEncodeUrlLink(boolean encodeUrlLink) voidsetFacetCacheDuration(long facetCacheDuration) voidsetOriginalHighlightTagPost(String originalHighlightTagPost) voidsetOriginalHighlightTagPre(String originalHighlightTagPre) voidsetUrlLinkEncoding(String urlLinkEncoding) voidsetUseSession(boolean useSession) protected StringupdateFileProtocol(String url) protected voidupdateHighlightInfo(HighlightInfo highlightInfo, int width) protected org.lastaflute.web.response.StreamResponsewriteContent(String configId, String url, org.codelibs.fess.crawler.client.CrawlerClient client) protected voidwriteContentType(org.lastaflute.web.response.StreamResponse response, org.codelibs.fess.crawler.entity.ResponseData responseData) protected voidwriteFileName(org.lastaflute.web.response.StreamResponse response, org.codelibs.fess.crawler.entity.ResponseData responseData) protected voidwriteNoCache(org.lastaflute.web.response.StreamResponse response, org.codelibs.fess.crawler.entity.ResponseData responseData)
-
Field Details
-
SCREEN_WIDTH
- See Also:
-
TABLET_WIDTH
protected static final int TABLET_WIDTH- See Also:
-
CONTENT_DISPOSITION
- See Also:
-
HL_CACHE
- See Also:
-
QUERIES
- See Also:
-
CACHE_MSG
- See Also:
-
LOCAL_PATH_PATTERN
-
SHARED_FOLDER_PATTERN
-
ELLIPSIS
- See Also:
-
encodeUrlLink
protected boolean encodeUrlLink -
urlLinkEncoding
-
highlightedFields
-
originalHighlightTagPre
-
originalHighlightTagPost
-
highlightTagPre
-
highlightTagPost
-
useSession
protected boolean useSession -
pageCacheMap
-
initFacetParamMap
-
initGeoParamMap
-
facetQueryViewList
-
cacheTemplateName
-
escapedHighlightPre
-
escapedHighlightPost
-
highlightTerminalCharSet
-
actionHook
-
inlineMimeTypeSet
-
facetCache
-
facetCacheDuration
protected long facetCacheDuration -
textFragmentPrefixLength
protected int textFragmentPrefixLength -
textFragmentSuffixLength
protected int textFragmentSuffixLength -
textFragmentSize
protected int textFragmentSize
-
-
Constructor Details
-
ViewHelper
public ViewHelper()
-
-
Method Details
-
init
@PostConstruct public void init() -
getContentTitle
-
getQuerySet
-
getContentDescription
-
escapeHighlight
-
removeHighlightTag
-
createHighlightInfo
-
updateHighlightInfo
-
getUrlLink
-
updateFileProtocol
-
appendQueryParameter
-
appendHTMLSearchWord
-
appendPDFSearchWord
-
getPagePath
-
createCacheContent
-
replaceHighlightQueries
-
getSitePath
-
asContentResponse
-
writeContent
-
writeNoCache
protected void writeNoCache(org.lastaflute.web.response.StreamResponse response, org.codelibs.fess.crawler.entity.ResponseData responseData) -
writeFileName
protected void writeFileName(org.lastaflute.web.response.StreamResponse response, org.codelibs.fess.crawler.entity.ResponseData responseData) -
writeContentType
protected void writeContentType(org.lastaflute.web.response.StreamResponse response, org.codelibs.fess.crawler.entity.ResponseData responseData) -
getClientIp
-
getCachedFacetResponse
-
createHighlightText
public String createHighlightText(org.opensearch.search.fetch.subphase.highlight.HighlightField highlightField) -
createTextFragmentsByHighlight
public ViewHelper.TextFragment[] createTextFragmentsByHighlight(org.opensearch.search.fetch.subphase.highlight.HighlightField[] fields) -
createTextFragmentsByQuery
-
isUseSession
public boolean isUseSession() -
setUseSession
public void setUseSession(boolean useSession) -
addInitFacetParam
-
getInitFacetParamMap
-
addInitGeoParam
-
getInitGeoParamMap
-
addFacetQueryView
-
getFacetQueryViewList
-
addInlineMimeType
-
getActionHook
-
setActionHook
-
setEncodeUrlLink
public void setEncodeUrlLink(boolean encodeUrlLink) -
setUrlLinkEncoding
-
setOriginalHighlightTagPre
-
setOriginalHighlightTagPost
-
setCacheTemplateName
-
setFacetCacheDuration
public void setFacetCacheDuration(long facetCacheDuration)
-