Class Star

Direct Known Subclasses:
TheSun

public class Star extends SpaceObject
The Class Star.
  • Constructor Details

    • Star

      public Star(double distance_ly, double apparent_magnitude, double absolute_magnitude, double liminosity, Color color, double radius, StellarSpectrum spectrum)
      Instantiates a new star.
      Parameters:
      distance_ly - the distance ly
      apparent_magnitude - the apparent magnitude
      absolute_magnitude - the absolute magnitude
      liminosity - the liminosity
      color - the color
      radius - the radius
      spectrum - the spectrum
  • Method Details

    • computeDistanceGivenTheta

      public static double computeDistanceGivenTheta(double theta)
      Compute distance given theta.
      Parameters:
      theta - the theta
      Returns:
      the double
    • getDistance_ly

      public double getDistance_ly()
      Gets the distance ly.
      Returns:
      the distance_ly
    • setDistance_ly

      public void setDistance_ly(double distance_ly)
      Sets the distance ly.
      Parameters:
      distance_ly - the distance_ly to set
    • getApparent_magnitude

      public double getApparent_magnitude()
      Gets the apparent magnitude.
      Returns:
      the apparent_magnitude
    • setApparent_magnitude

      public void setApparent_magnitude(double apparent_magnitude)
      Sets the apparent magnitude.
      Parameters:
      apparent_magnitude - the apparent_magnitude to set
    • getAbsolute_magnitude

      public double getAbsolute_magnitude()
      Gets the absolute magnitude.
      Returns:
      the absolute_magnitude
    • setAbsolute_magnitude

      public void setAbsolute_magnitude(double absolute_magnitude)
      Sets the absolute magnitude.
      Parameters:
      absolute_magnitude - the absolute_magnitude to set
    • getLiminosity

      public double getLiminosity()
      Gets the liminosity.
      Returns:
      the liminosity
    • setLiminosity

      public void setLiminosity(double liminosity)
      Sets the liminosity.
      Parameters:
      liminosity - the liminosity to set
    • getColor

      public Color getColor()
      Gets the color.
      Returns:
      the color
    • setColor

      public void setColor(Color color)
      Sets the color.
      Parameters:
      color - the color to set
    • getRadius

      public double getRadius()
      Gets the radius.
      Returns:
      the radius
    • setRadius

      public void setRadius(double radius)
      Sets the radius.
      Parameters:
      radius - the radius to set
    • getSpectrum

      public StellarSpectrum getSpectrum()
      Gets the spectrum.
      Returns:
      the spectrum
    • setSpectrum

      public void setSpectrum(StellarSpectrum spectrum)
      Sets the spectrum.
      Parameters:
      spectrum - the spectrum to set