Class ALcyPrintContext<V extends ILcdView>

java.lang.Object
com.luciad.lucy.addons.print.ALcyPrintContext<V>
All Implemented Interfaces:
ILcdChangeSource
Direct Known Subclasses:
TLcyLspPrintContext, TLcyPrintContext

public abstract class ALcyPrintContext<V extends ILcdView> extends Object implements ILcdChangeSource
Represents all that is needed to print, preview, modify, ... a component which can be printed to one or more pages.

Instances of this object are created internally in the print add-ons.

Since:
2013.0
  • Constructor Details

    • ALcyPrintContext

      protected ALcyPrintContext(V aView, TLcyProperties aProperties)
      Creates a new print context for the given view and properties.
      Instances of this object should only be created internally by the print add-ons.
      Parameters:
      aView - the view
      aProperties - the properties.
  • Method Details

    • getView

      public V getView()
      Returns the view that represents the content of the printable.
      Returns:
      the view.
    • dispose

      public abstract void dispose()
      Dispose this print context.
    • getProperties

      public TLcyProperties getProperties()
      Get the properties object for this printable component. The keys of these properties are the various constants that end in KEY of TLcyPrintAddOn.
      Returns:
      the properties object for this printable component.
    • addChangeListener

      public void addChangeListener(ILcdChangeListener aListener)
      Description copied from interface: ILcdChangeSource

      Registers the given listener so it will receive change events from this source.

      In case you need to register a listener which keeps a reference to an object with a shorter life-time than this change source, you can use a ALcdWeakChangeListener instance as change listener.

      Specified by:
      addChangeListener in interface ILcdChangeSource
      Parameters:
      aListener - The listener to be notified when a change has happened.
      See Also:
    • removeChangeListener

      public void removeChangeListener(ILcdChangeListener aListener)
      Description copied from interface: ILcdChangeSource
      Removes the specified listener so it is no longer notified.
      Specified by:
      removeChangeListener in interface ILcdChangeSource
      Parameters:
      aListener - The listener to remove.
    • firePrintableComponentChangeEvent

      protected final void firePrintableComponentChangeEvent(TLcdChangeEvent aEvent)
      Fires a change event to notify that the printable component has changed.
      Parameters:
      aEvent - a change event
    • getPrintable

      public abstract Printable getPrintable()
      Returns the Printable that prints the view.
      Returns:
      the Printable that prints the view.
    • invalidate

      public abstract void invalidate()
      Invalidates the state of this ALcyPrintContext. It can for example be used to refresh the print preview.