public class SectionImpl extends ResourceBaseImpl implements Section
PROPERTY_EXCLUDE_FROM_NAV, PROPERTY_REDIRECT_CONFIG, PROPERTY_SECTION_CONFIGPROPERTY_AUTHOR, PROPERTY_DESCRIPTION, PROPERTY_MODIFIED_TIME, PROPERTY_TITLE| Constructor and Description |
|---|
SectionImpl() |
| Modifier and Type | Method and Description |
|---|---|
protected String |
checkRedirects(String path) |
Query |
createQuery()
A factory method for returning an empty search query object.
|
Asset |
getAsset(String resourceName)
Gets the asset with the given name in this section.
|
AssetCollection |
getAssetCollection(String name)
Retrieve the named asset collection from this section.
|
AssetCollection |
getAssetCollection(String name,
int resultsToSkip,
int maxResults) |
boolean |
getExcludeFromNav()
Should this section be excluded from navigation components?
|
Asset |
getIndexPage()
Gets a section's index page
|
String |
getPath()
Gets the path of the section
|
Section |
getSection(String sectionName)
Find a subsection with the specified name
|
List<Section> |
getSections()
Gets the child sections.
|
List<Tag> |
getTags()
Gets the tags used within this section (and below) order by their usage
(most popular first)
|
String |
getTemplate(String type)
Gets the template for a given type of asset for this section
|
Map<String,String> |
getTemplateMappings()
Get the template mappings for this section
|
PathResolutionDetails |
resolvePath(String path) |
SearchResults |
search(Query query)
Carry out a search for resources below this section
|
SearchResults |
search(String phrase,
int maxResults,
int resultsToSkip)
Carry out a search for resources below this section that contain all the
words in the supplied phrase
|
SearchResults |
searchByTag(String tag,
int maxResults,
int resultsToSkip)
Carry out a search for resources below this section that are tagged with
the specified tag
|
void |
setDictionaryService(DictionaryService dictionaryService)
Set the dictionary service
|
void |
setProperties(Map<String,Serializable> props)
Set resources properties
|
void |
setTags(List<Tag> tags)
Set the tags used by this section (and below)
|
getAssetFactory, getCollectionFactory, getContainingSection, getDescription, getId, getName, getPrimarySectionId, getProperties, getProperty, getSectionFactory, getTitle, getType, setAssetFactory, setCollectionFactory, setPrimarySectionId, setSectionFactoryclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetContainingSection, getDescription, getId, getName, getProperties, getProperty, getTitle, getTypepublic List<Section> getSections()
SectiongetSections in interface SectionSection.getSections()public Section getSection(String sectionName)
SectiongetSection in interface SectionsectionName - The name of the section that the caller is asking forSection.getSection(java.lang.String)public void setTags(List<Tag> tags)
tags - the tags used by the sectionpublic List<Tag> getTags()
SectiongetTags in interface SectionSection.getTags()public void setDictionaryService(DictionaryService dictionaryService)
dictionaryService - public Map<String,String> getTemplateMappings()
SectiongetTemplateMappings in interface SectionSection.getTemplateMappings()public boolean getExcludeFromNav()
SectiongetExcludeFromNav in interface Sectionpublic void setProperties(Map<String,Serializable> props)
ResourceBaseImplsetProperties in class ResourceBaseImplprops - property mapResourceBaseImpl.setProperties(java.util.Map)public Asset getAsset(String resourceName)
SectiongetAsset in interface SectionSection.getAsset(java.lang.String)public Asset getIndexPage()
SectiongetIndexPage in interface SectionSection.getIndexPage()public String getPath()
SectiongetPath in interface SectionSection.getPath()public SearchResults search(Query query)
Sectionpublic SearchResults search(String phrase, int maxResults, int resultsToSkip)
Sectionsearch in interface Sectionphrase - The words to search for. This is considered to be a
space-separated set of words that must all appear in an asset
for it to match.maxResults - The maximum number of results to returnresultsToSkip - The number of results to skip over before returning. In
combination with maxResults, this is useful for pagination of
results. For example, calling this operation with maxResults
set to 10 and resultsToSkip set to 0 will return the first
"page" of 10 results. Calling it with maxResults set to 10 and
resultsToSkip set to 10 will return the second "page" of 10
results, and so on.public SearchResults searchByTag(String tag, int maxResults, int resultsToSkip)
SectionsearchByTag in interface SectionmaxResults - The maximum number of results to returnresultsToSkip - The number of results to skip over before returning. In
combination with maxResults, this is useful for pagination of
results. For example, calling this operation with maxResults
set to 10 and resultsToSkip set to 0 will return the first
"page" of 10 results. Calling it with maxResults set to 10 and
resultsToSkip set to 10 will return the second "page" of 10
results, and so on.public Query createQuery()
SectioncreateQuery in interface SectionSection.createQuery()public String getTemplate(String type)
SectiongetTemplate in interface Sectiontype - typeSection.getTemplate(java.lang.String)public AssetCollection getAssetCollection(String name)
SectiongetAssetCollection in interface Sectionpublic AssetCollection getAssetCollection(String name, int resultsToSkip, int maxResults)
getAssetCollection in interface Sectionpublic PathResolutionDetails resolvePath(String path)
resolvePath in interface SectionCopyright © 2005–2014 Alfresco Software. All rights reserved.