net.aerith.misao.pixy
Class Agent

java.lang.Object
  |
  +--net.aerith.misao.pixy.Agent

public abstract class Agent
extends java.lang.Object
implements ImageConverter

The Agent is an interface of agent to operate image examination in a specific situation with peculiar rules and styles.


Constructor Summary
Agent()
           
 
Method Summary
 boolean addsDssImageInHtmlImageGallery()
          Returns true when to add a DSS image in the HTML image gallery.
 MonoImage convertImage(MonoImage image)
          Applies some image filters to the specified image.
abstract  ExaminationOperator createExaminationOperator(XmlInstruction instruction)
          Creates the examination operator.
 double getHtmlGalleryImageResolution()
          Gets the resolution in arcsec/pixel of images in the HTML image gallery.
 Size getHtmlGalleryImageSize()
          Gets the image size for HTML image gallery.
abstract  XmlInstruction[] getInstructions()
          Returns the list of image files and instruction parameters.
abstract  java.lang.String getName()
          Returns the name of this agent.
abstract  double getNewStarSearchAmplitude()
          Gets the amplitude for new star search.
 int getNewStarSearchHtmlImageGalleryMode()
          Returns the mode of HTML image gallery for new star search.
abstract  double getNewStarSearchLimitingMagnitude()
          Gets the limiting magnitude for new star search.
 boolean initialize(java.awt.Container pane)
          Initializes.
 XmlInstruction preOperation(XmlInstruction instruction)
          Does something for an image before operation.
 boolean rotatesHtmlGalleryImageNorthUpAtRightAngles()
          Returns true when to rotate images north up at right angles in the HTML image gallery.
 boolean unifiesHtmlGalleryImageResolution()
          Returns true when to unify the resolution of images in the HTML image gallery.
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Constructor Detail

Agent

public Agent()
Method Detail

getName

public abstract java.lang.String getName()
Returns the name of this agent.
Returns:
the name of this agent.

initialize

public boolean initialize(java.awt.Container pane)
Initializes. This method can be overrided in the sub class if needed. For example, it shows a dialog to select image files and input parameters.
Parameters:
pane - the container.
Returns:
true when ready.

getInstructions

public abstract XmlInstruction[] getInstructions()
Returns the list of image files and instruction parameters.
Returns:
the list of instruction parameters.

preOperation

public XmlInstruction preOperation(XmlInstruction instruction)
                            throws java.lang.Exception
Does something for an image before operation. This method can be overrided in the sub class if needed. For example, it downloads the image file and saves in the hard disk.
Parameters:
instruction - a set of instruction parameters.
Returns:
a new set of instruction parameters.
Throws:
java.lang.Exception - if an exception occurs.

convertImage

public MonoImage convertImage(MonoImage image)
                       throws java.lang.Exception
Applies some image filters to the specified image. This method can be overrided in the sub class if needed. For example, it corrects the width/height ratio of a SBIG ST-4/ST-6 image.
Specified by:
convertImage in interface ImageConverter
Parameters:
image - an image.
Returns:
a new image.
Throws:
java.lang.Exception - if an exception occurs.

createExaminationOperator

public abstract ExaminationOperator createExaminationOperator(XmlInstruction instruction)
Creates the examination operator.
Parameters:
instruction - the XML instruction element.
Returns:
the examination operator.

getNewStarSearchLimitingMagnitude

public abstract double getNewStarSearchLimitingMagnitude()
Gets the limiting magnitude for new star search.
Returns:
the limiting magnitude for new star search.

getNewStarSearchAmplitude

public abstract double getNewStarSearchAmplitude()
Gets the amplitude for new star search.
Returns:
the amplitude for new star search.

getHtmlGalleryImageSize

public Size getHtmlGalleryImageSize()
Gets the image size for HTML image gallery.
Returns:
the image size for HTML image gallery.

unifiesHtmlGalleryImageResolution

public boolean unifiesHtmlGalleryImageResolution()
Returns true when to unify the resolution of images in the HTML image gallery.
Returns:
true when to unify the resolution of images in the HTML image gallery.

getHtmlGalleryImageResolution

public double getHtmlGalleryImageResolution()
Gets the resolution in arcsec/pixel of images in the HTML image gallery.
Returns:
the resolution in arcsec/pixel of images in the HTML image gallery.

rotatesHtmlGalleryImageNorthUpAtRightAngles

public boolean rotatesHtmlGalleryImageNorthUpAtRightAngles()
Returns true when to rotate images north up at right angles in the HTML image gallery.
Returns:
true when to rotate images north up at right angles in the HTML image gallery.

getNewStarSearchHtmlImageGalleryMode

public int getNewStarSearchHtmlImageGalleryMode()
Returns the mode of HTML image gallery for new star search.
Returns:
the mode of HTML image gallery for new star search.

addsDssImageInHtmlImageGallery

public boolean addsDssImageInHtmlImageGallery()
Returns true when to add a DSS image in the HTML image gallery.
Returns:
true when to add a DSS image in the HTML image gallery.