astro
Class StarSextractor

java.lang.Object
  extended by astro.StarDescription
      extended by astro.StarSextractor
All Implemented Interfaces:
Serializable, Cloneable

public class StarSextractor
extends StarDescription

Star description derived out of sextractor output. Has no color information or proper motion, but provides x and y location on the CCD (via getCcdX() and getCcdY() and a magnitude error. via getMagErr(). Usually, also the flags are retrievable getFlags(), the FWHM of the stellar image on the CCD in pixel ($getFwhm), and the ellipticity of the image getEllipticity().

A helper application that reads sextractor output files and parses them into a list of StarSextractor is SextractorRead, additional comparators for sorting are inner classes to this class.

See Also:
Serialized Form

Nested Class Summary
static class StarSextractor.Flag
           
static class StarSextractor.PixelPosition
          Returns a comparator that sorts sextractor stars depending on pixel distance from a certain central pixel, stated at construct.
 
Nested classes/interfaces inherited from class astro.StarDescription
StarDescription.StarComparator<T extends StarDescription>
 
Field Summary
private  Double ccdx
          The x-pixel coordinate on the CCD.
private  Double ccdy
          The y-pixel coordinate on the CCD.
private  Float ellipticity
          The ellipticity of the star.
private  Integer flags
          For memory reasons, the flags are stored as a bitmask.
private  Float fwhm
          The fwhm of the star.
private  Float magerr
          The magnitude error.
 
Fields inherited from class astro.StarDescription
COLOR, DEC, DEFCOLOR, DEFEPOCH, DEFEQUINOX, DEFID, DEFPROPDEC, DEFPROPRA, EPOCH, EQUINOX, ID, MAG, NAME, PROPDEC, PROPRA, RA, SOL, UNKNOWN
 
Constructor Summary
StarSextractor()
          Constructs a new empty sextractor star.
StarSextractor(String name)
          Constructs a new sextractor star using a sepcified name.
 
Method Summary
 Object addFlag(StarSextractor.Flag f)
          Adds an extraction flag.
 double getCcdX()
          Gets the position on the CCD, x coordinate in pixel.
 double getCcdY()
          Gets the position on the CCD, x coordinate in pixel.
 float getEllipticity()
          Returns the ellipticity.
 List<StarSextractor.Flag> getFlags()
          Gets all the flags.
 float getFwhm()
          Gets the pixel fwhm.
 int getIntegerFlags()
          Gets the integer flags.
 float getMagErr()
          Gets the mag error.
 Point2D getPixelPosition()
          Returns the position on the CCD as a point2d object.
 boolean isFlagSet(int mask)
          Returns true, if any of these flags is set.
 boolean isFlagSet(List<StarSextractor.Flag> mask)
          Returns true, if any of these flags is set.
static boolean removeAll(List<StarSextractor> list, int mask)
          Removes all sextractor stars from this list that have one of the specified flags set.
static boolean removeAll(List<StarSextractor> list, List<StarSextractor.Flag> mask)
          Removes all sextractor stars from this list that have one of the specified flags set.
static boolean retainAll(List<StarSextractor> list, int mask)
          Retains only those stars, which flag is set according to the query bitmask.
static boolean retainAll(List<StarSextractor> list, List<StarSextractor.Flag> mask)
          Retains only those stars, which flag is set according to the query bitmask.
 Object setCcdX(double x)
          Sets the CCD position, x.
 Object setCcdY(double y)
          Sets the CCD position, y.
 Object setEllipticity(float ell)
          Sets the mag error.
 Object setFlags(List<StarSextractor.Flag> f)
          Sets a list of flags for this star.
 Object setFwhm(float fwhm)
          Sets the pixel fwhm.
 Object setIntegerFlags(int flags)
          Sets the extraction falgs as an integer bitmask.
 Object setMagErr(float magerr)
          Sets the mag error.
 
Methods inherited from class astro.StarDescription
equals, exportIdMap, exportNameMap, fillMissing, fillMissing, get, getColor, getDec, getEpoch, getEquinox, getID, getMag, getName, getPropDec, getProperty, getPropRa, getRa, getSeparation, getSeparation, getSeparation, getSeparation, isFullyValid, isMarginallyValid, isSexagesimal, isValid, isVeryValid, matches, parseSexagesimal, set, setColor, setDec, setEpoch, setEquinox, setID, setMag, setName, setPropDec, setProperty, setPropRa, setRa, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

ccdx

private Double ccdx
The x-pixel coordinate on the CCD.


ccdy

private Double ccdy
The y-pixel coordinate on the CCD.


magerr

private Float magerr
The magnitude error.


fwhm

private Float fwhm
The fwhm of the star.


ellipticity

private Float ellipticity
The ellipticity of the star.


flags

private Integer flags
For memory reasons, the flags are stored as a bitmask.

Constructor Detail

StarSextractor

public StarSextractor()
Constructs a new empty sextractor star. Note that all fields are undefined.


StarSextractor

public StarSextractor(String name)
Constructs a new sextractor star using a sepcified name.

Method Detail

setCcdX

public Object setCcdX(double x)
Sets the CCD position, x.


setCcdY

public Object setCcdY(double y)
Sets the CCD position, y.


setMagErr

public Object setMagErr(float magerr)
Sets the mag error.


setFwhm

public Object setFwhm(float fwhm)
Sets the pixel fwhm.


setEllipticity

public Object setEllipticity(float ell)
Sets the mag error.


setIntegerFlags

public Object setIntegerFlags(int flags)
Sets the extraction falgs as an integer bitmask.


addFlag

public Object addFlag(StarSextractor.Flag f)
Adds an extraction flag.


setFlags

public Object setFlags(List<StarSextractor.Flag> f)
Sets a list of flags for this star.


getIntegerFlags

public int getIntegerFlags()
Gets the integer flags.


getFlags

public List<StarSextractor.Flag> getFlags()
Gets all the flags.


isFlagSet

public boolean isFlagSet(List<StarSextractor.Flag> mask)
Returns true, if any of these flags is set.


isFlagSet

public boolean isFlagSet(int mask)
Returns true, if any of these flags is set.


getPixelPosition

public Point2D getPixelPosition()
Returns the position on the CCD as a point2d object. Returns null if any coordinate is null.


getCcdX

public double getCcdX()
Gets the position on the CCD, x coordinate in pixel.


getCcdY

public double getCcdY()
Gets the position on the CCD, x coordinate in pixel.


getMagErr

public float getMagErr()
Gets the mag error.


getFwhm

public float getFwhm()
Gets the pixel fwhm.


getEllipticity

public float getEllipticity()
Returns the ellipticity.


removeAll

public static boolean removeAll(List<StarSextractor> list,
                                List<StarSextractor.Flag> mask)
Removes all sextractor stars from this list that have one of the specified flags set.


removeAll

public static boolean removeAll(List<StarSextractor> list,
                                int mask)
Removes all sextractor stars from this list that have one of the specified flags set.


retainAll

public static boolean retainAll(List<StarSextractor> list,
                                List<StarSextractor.Flag> mask)
Retains only those stars, which flag is set according to the query bitmask. If flag = OK, only stars with OK survive.


retainAll

public static boolean retainAll(List<StarSextractor> list,
                                int mask)
Retains only those stars, which flag is set according to the query bitmask. If flag = OK, only stars with OK survive.