gov.sns.application
Class PrintManager

java.lang.Object
  |
  +--gov.sns.application.PrintManager

public class PrintManager
extends java.lang.Object

Manage document printing.


Field Summary
protected static PrintManager defaultManager
           
protected  java.awt.print.PageFormat pageFormat
           
 
Constructor Summary
PrintManager()
          Creates a new instance of PrintManager
 
Method Summary
static PrintManager defaultManager()
          Get the default print manager.
 java.awt.print.PageFormat getPageFormat()
          Get the page format set by the user or the default one if none has been set.
 void pageSetup()
          Show the PageSetup dialog so the user can set the PageFormat.
 void print(XalDocument document)
          Print a document.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

defaultManager

protected static PrintManager defaultManager

pageFormat

protected java.awt.print.PageFormat pageFormat
Constructor Detail

PrintManager

public PrintManager()
Creates a new instance of PrintManager

Method Detail

defaultManager

public static PrintManager defaultManager()
Get the default print manager. The print manager is shared by the application.

Returns:
The default print manager instance.

getPageFormat

public java.awt.print.PageFormat getPageFormat()
Get the page format set by the user or the default one if none has been set.

Returns:
The page format to use for printing.

pageSetup

public void pageSetup()
Show the PageSetup dialog so the user can set the PageFormat.


print

public void print(XalDocument document)
Print a document.

Parameters:
document - The document to print.