public class DocumentationComponent extends DefaultComponent implements DocumentationService
Modifier and Type | Field and Description |
---|---|
static String |
DIRECTORY_NAME |
protected static org.apache.commons.logging.Log |
log |
static String |
Read_Grp |
static String |
Root_NAME |
static String |
Root_PATH |
protected ArtifactSearcher |
searcher |
static String |
Write_Grp |
lastModified
Constructor and Description |
---|
DocumentationComponent() |
activate, deactivate, getLastModified, registerContribution, registerExtension, setLastModified, setModifiedNow, start, stop, unregisterContribution, unregisterExtension
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
applicationStarted, getApplicationStartedOrder
public static final String DIRECTORY_NAME
public static final String Root_PATH
public static final String Root_NAME
public static final String Read_Grp
public static final String Write_Grp
protected static final org.apache.commons.logging.Log log
protected final ArtifactSearcher searcher
public DocumentationComponent()
protected DocumentModel getDocumentationRoot(CoreSession session)
public <T> T getAdapter(Class<T> adapter)
Adaptable
null
if no such object can be found.getAdapter
in interface Adaptable
getAdapter
in class DefaultComponent
adapter
- the adapter class to look upnull
if this object does not have an adapter for
the given classpublic Map<String,List<DocumentationItem>> listDocumentationItems(CoreSession session, String category, String targetType)
listDocumentationItems
in interface DocumentationService
public List<DocumentationItem> findDocumentItems(CoreSession session, NuxeoArtifact nxItem)
findDocumentItems
in interface DocumentationService
protected DocumentationItem findBestMatch(NuxeoArtifact nxItem, List<DocumentationItem> docItems)
public List<DocumentationItem> findDocumentationItemVariants(CoreSession session, DocumentationItem item)
findDocumentationItemVariants
in interface DocumentationService
public List<DocumentModel> findDocumentModelVariants(CoreSession session, DocumentationItem item)
public DocumentationItem createDocumentationItem(CoreSession session, NuxeoArtifact item, String title, String content, String type, List<String> applicableVersions, boolean approved, String renderingType)
createDocumentationItem
in interface DocumentationService
public void deleteDocumentationItem(CoreSession session, String uuid)
deleteDocumentationItem
in interface DocumentationService
protected DocumentModel updateDocumentModel(DocumentModel doc, DocumentationItem item)
public DocumentationItem updateDocumentationItem(CoreSession session, DocumentationItem docItem)
updateDocumentationItem
in interface DocumentationService
protected List<DocumentModel> listCategories()
public List<String> getCategoryKeys()
getCategoryKeys
in interface DocumentationService
public Map<String,String> getCategories()
getCategories
in interface DocumentationService
public void exportDocumentation(CoreSession session, OutputStream out)
exportDocumentation
in interface DocumentationService
public void importDocumentation(CoreSession session, InputStream is)
importDocumentation
in interface DocumentationService
public String getDocumentationStats(CoreSession session)
getDocumentationStats
in interface DocumentationService
public Map<String,DocumentationItem> getAvailableDescriptions(CoreSession session, String targetType)
getAvailableDescriptions
in interface DocumentationService
Copyright © 2018 Nuxeo. All rights reserved.