Class DynamicCompositePageSegment
- java.lang.Object
-
- com.levigo.jadice.document.AbstractPageSegment
-
- com.levigo.jadice.document.AbstractMutablePageSegment
-
- com.levigo.jadice.document.composite.AbstractCompositePageSegment
-
- com.levigo.jadice.document.composite.DynamicCompositePageSegment
-
- All Implemented Interfaces:
ConditionFactoryProvider,com.levigo.jadice.document.internal.PageAwarePageSegment,com.levigo.jadice.document.internal.presentation.group.PresentationInitializer,com.levigo.jadice.document.internal.presentation.group.VisualizationInitializer,MetadataProvider,MutablePageSegment,PageSegment,PermissionsProvider<PageSegment>,PropertiesProvider,Identifiable
public final class DynamicCompositePageSegment extends AbstractCompositePageSegment
Within aDynamicCompositePageSegment(dcps) one or morePageSegments can be arranged by transformations and clippings. In difference to aCompositePageSegmentthe bounds of a dcps are dynamically calculated, using the addedPageSegments andAffineTransforms:- The upper left corner is always x=0 and y=0. Therefore the dcps can only "grow" in positive x- and y-direction, negative bounds are not included to the resulting bounds. This has to be considered when adding transformed pageSegments.
- When clipping a pageSegment, only the remaining shape is included to the bounds.
AbstractPageSegment.getPermissions(),AbstractPageSegment.getProperties()orAbstractPageSegment.getSource()to its child-segments. If needed, this has to be done manually using the according getters and setters of thePageSegments.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.levigo.jadice.document.composite.AbstractCompositePageSegment
AbstractCompositePageSegment.TransformedElement
-
Nested classes/interfaces inherited from class com.levigo.jadice.document.AbstractPageSegment
AbstractPageSegment.CacheableVisualElement
-
-
Field Summary
Fields Modifier and Type Field Description protected static LoggerLOGGER-
Fields inherited from class com.levigo.jadice.document.AbstractPageSegment
CACHE_KEY_CONTENTS, format, id
-
-
Constructor Summary
Constructors Constructor Description DynamicCompositePageSegment()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidfireModified()Fire a notification about a general change to the page segment.Rectangle2DgetBounds()Returns the raw size and position of thePageSegmentin base units.Dimension2DgetSize()Returns the raw size/dimensions of thePageSegmentin base units.-
Methods inherited from class com.levigo.jadice.document.composite.AbstractCompositePageSegment
addPageSegment, addPageSegment, createCacheableVisualElement, getMetadata, getResolution, getSegments, isAuxiliary, isOpaque, setCurrentPage, setOpaque, setSource
-
Methods inherited from class com.levigo.jadice.document.AbstractMutablePageSegment
addPageSegmentListener, createPageSegmentEvent, fireModified, fireModified, removePageSegmentListener
-
Methods inherited from class com.levigo.jadice.document.AbstractPageSegment
getCachedVisualElement, getId, getInitialized, getPermissions, getProperties, getSource, isInitialized, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com.levigo.jadice.document.condition.ConditionFactoryProvider
getConditionFactories
-
Methods inherited from interface org.jadice.util.base.Identifiable
getId
-
Methods inherited from interface com.levigo.jadice.document.PageSegment
getSource
-
Methods inherited from interface com.levigo.jadice.document.PermissionsProvider
getPermissions
-
Methods inherited from interface com.levigo.jadice.document.internal.presentation.group.PresentationInitializer
getInitialized, isInitialized
-
Methods inherited from interface com.levigo.jadice.document.util.PropertiesProvider
getProperties
-
-
-
-
Field Detail
-
LOGGER
protected static final Logger LOGGER
-
-
Method Detail
-
getBounds
public Rectangle2D getBounds()
Description copied from interface:PageSegmentReturns the raw size and position of thePageSegmentin base units. Position is measured in relation to thePage's coordinate system's origin point (0,0).- Specified by:
getBoundsin interfacePageSegment- Specified by:
getBoundsin interfacecom.levigo.jadice.document.internal.presentation.group.VisualizationInitializer- Overrides:
getBoundsin classAbstractPageSegment- Returns:
- the raw size and position
-
getSize
public Dimension2D getSize()
Description copied from interface:PageSegmentReturns the raw size/dimensions of thePageSegmentin base units.- Returns:
- the
PageSegment's raw size
-
fireModified
protected void fireModified()
Description copied from class:AbstractMutablePageSegmentFire a notification about a general change to the page segment. Please consider firing a more specialized one, indicating the actual damage region.- Overrides:
fireModifiedin classAbstractCompositePageSegment
-
-