com.levigo.jadice.document
Interface PageSegmentSource

All Superinterfaces:
MetadataProvider, PropertiesProvider

public interface PageSegmentSource
extends PropertiesProvider, MetadataProvider

A PageSegmentSource describes the origin of a page segment. Since Documents are not engaged in a 1:1 relation with a single source stream from which the document was loaded, a document may have many source streams from which its contents are derived. In contrast to that, AbstractPageSegments are usually derived from a single stream only. However, there are PageSegments which are not derived from a source stream at all. These PageSegments return null from a call to their AbstractPageSegment.getSource() method.


Method Summary
 Format getFormat()
          Return the format description for this page segment.
 Metadata getMetadata()
          Return the stream's meta-data.
 Map<String,Object> getProperties()
          Return the stream's user properties.
 SourceID getSourceID()
          Return this PageSegmentSource's identifying object.
 SeekableInputStream getStream()
          Return the stream from which the page segment was read.
 

Method Detail

getStream

SeekableInputStream getStream()
Return the stream from which the page segment was read. Return null if the page segment was not read from a stream.

Returns:
the stream

getFormat

Format getFormat()
Return the format description for this page segment.

Returns:
String a format description

getMetadata

Metadata getMetadata()
Return the stream's meta-data.

Specified by:
getMetadata in interface MetadataProvider
Returns:
the stream's meta-data.

getProperties

Map<String,Object> getProperties()
Return the stream's user properties.

Specified by:
getProperties in interface PropertiesProvider
Returns:
a map of user properties
See Also:
PropertiesProvider

getSourceID

SourceID getSourceID()
Return this PageSegmentSource's identifying object.

Returns:
an instance of SourceID which uniquely identifies this PageSegmentSource among all PageSegmentSources.


Copyright © 1995-2020 levigo holding gmbh. All Rights Reserved.