|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.atlassian.confluence.content.render.xhtml.view.excerpt.DefaultExcerpter
public class DefaultExcerpter
| Field Summary | |
|---|---|
static Set<String> |
DEFAULT_EXCLUDE_SET
|
static int |
DEFAULT_MAX_BLOCKS_FOR_EXCERPT
|
| Constructor Summary | |
|---|---|
DefaultExcerpter(XMLOutputFactory xmlFragmentOutputFactory,
XmlEventReaderFactory xmlEventReaderFactory,
HtmlToXmlConverter htmlToXmlConverter,
SettingsManager settingsManager,
Renderer viewRenderer,
Unmarshaller<EmbeddedImage> embeddedImageUnmarshaller,
FragmentTransformer fragmentTransformer,
AttachmentResourceIdentifierResolver attachmentResolver,
DataSourceFactory datasourceFactory,
ThumbnailManager thumbnailManager,
XhtmlContent xhtmlContent)
|
|
| Method Summary | |
|---|---|
String |
createExcerpt(Content content)
Creates an excerpt block from the provided content object without any tags excluded, using an implementation specific number of blocks. |
String |
createExcerpt(ContentEntityObject contentEntity,
String outputType)
Creates an excerpt of the contentEntityObject without any tags excluded including an implementation specific number of blocking |
String |
createExcerpt(ContentEntityObject contentEntity,
String outputType,
ExcerptConfig config)
Creates an excerpt of the contentEntityObject excluding any html tags that are in the exclude set. |
String |
createExcerpt(ContentEntityObject contentEntity,
String outputType,
Set<String> excludeSet,
int maxBlocksForExcerpt)
|
String |
createExcerpt(String contentHtml,
ExcerptConfig config)
|
List<DataSource> |
extractImageSrc(ContentEntityObject ceo,
int maxImages)
|
List<DataSource> |
extractImageSrc(ContentEntityObject ceo,
int maxImages,
boolean alwaysUseThumbnails)
|
List<String> |
extractImageSrc(String contentHtml,
int maxImages)
|
List<URI> |
extractImageThumbnailUris(ContentEntityObject contentEntity,
int maxUris)
Returns the URIs of thumbnails for each of the images attached to the specified content entity. |
protected List<XMLEvent> |
filterEmptyAndExcludedEvents(XMLEventReader reader,
Set<String> excludeSet)
|
String |
renderContent(ContentEntityObject contentEntity,
String outputType)
Deprecated. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final Set<String> DEFAULT_EXCLUDE_SET
public static final int DEFAULT_MAX_BLOCKS_FOR_EXCERPT
| Constructor Detail |
|---|
public DefaultExcerpter(XMLOutputFactory xmlFragmentOutputFactory,
XmlEventReaderFactory xmlEventReaderFactory,
HtmlToXmlConverter htmlToXmlConverter,
SettingsManager settingsManager,
Renderer viewRenderer,
Unmarshaller<EmbeddedImage> embeddedImageUnmarshaller,
FragmentTransformer fragmentTransformer,
AttachmentResourceIdentifierResolver attachmentResolver,
DataSourceFactory datasourceFactory,
ThumbnailManager thumbnailManager,
XhtmlContent xhtmlContent)
| Method Detail |
|---|
public String createExcerpt(Content content)
throws Exception
Excerpter
createExcerpt in interface Excerptercontent - - the content entity object to create an excerpt of
Exception - - if an excerpt cannot be created for this content object
public String createExcerpt(ContentEntityObject contentEntity,
String outputType)
throws Exception
Excerpter
createExcerpt in interface ExcerptercontentEntity - - contentEntityObject to create an excerpt ofoutputType - - the output type in which to render the content, @see RenderContextOutputType
Exception - - if an excerpt could not be created for this ContentEntityObject
public String createExcerpt(ContentEntityObject contentEntity,
String outputType,
Set<String> excludeSet,
int maxBlocksForExcerpt)
throws Exception
Exception
public String createExcerpt(ContentEntityObject contentEntity,
String outputType,
ExcerptConfig config)
throws XMLStreamException
Excerpter
createExcerpt in interface ExcerptercontentEntity - - contentEntityObject to create an excerpt ofoutputType - - the output type in which to render the content, @see RenderContextOutputTypeconfig - - a parameter object that allows the content of the excerpt to be customized. @see ExcerptConfig
XMLStreamException
@Deprecated
public String renderContent(ContentEntityObject contentEntity,
String outputType)
public String createExcerpt(String contentHtml,
ExcerptConfig config)
throws XMLStreamException
XMLStreamException
public List<DataSource> extractImageSrc(ContentEntityObject ceo,
int maxImages)
throws XMLStreamException,
XhtmlException
extractImageSrc in interface ExcerpterXMLStreamException
XhtmlException
public List<DataSource> extractImageSrc(ContentEntityObject ceo,
int maxImages,
boolean alwaysUseThumbnails)
throws XMLStreamException,
XhtmlException
extractImageSrc in interface ExcerpterXMLStreamException
XhtmlException
public List<String> extractImageSrc(String contentHtml,
int maxImages)
throws XMLStreamException
extractImageSrc in interface ExcerpterXMLStreamException
protected List<XMLEvent> filterEmptyAndExcludedEvents(XMLEventReader reader,
Set<String> excludeSet)
public List<URI> extractImageThumbnailUris(ContentEntityObject contentEntity,
int maxUris)
throws XhtmlException
Excerpter
extractImageThumbnailUris in interface ExcerptercontentEntity - the content entitymaxUris - the maximum URI's to return
XhtmlException - if there is an error parsing the contents for image references.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||