Enum Class Zodiac

java.lang.Object
java.lang.Enum<Zodiac>
net.time4j.calendar.astro.Zodiac
All Implemented Interfaces:
Serializable, Comparable<Zodiac>, java.lang.constant.Constable

public enum Zodiac extends Enum<Zodiac>

Enumeration of the thirteen astronomical zodiac definitions.

See also Wikipedia. The boundaries of the associated constellations have been defined by IAU (International Astronomical Union).

Attention: Users are required to make a strict difference between constellations and the twelve astrological (horoscopic) zodiacs. Latter type is also supported by specialized methods.

Since:
4.37
Author:
Meno Hochschild
  • Enum Constant Details

    • ARIES

      public static final Zodiac ARIES
    • TAURUS

      public static final Zodiac TAURUS
    • GEMINI

      public static final Zodiac GEMINI
    • CANCER

      public static final Zodiac CANCER
    • LEO

      public static final Zodiac LEO
    • VIRGO

      public static final Zodiac VIRGO
    • LIBRA

      public static final Zodiac LIBRA
    • SCORPIUS

      public static final Zodiac SCORPIUS
    • OPHIUCHUS

      public static final Zodiac OPHIUCHUS
    • SAGITTARIUS

      public static final Zodiac SAGITTARIUS
    • CAPRICORNUS

      public static final Zodiac CAPRICORNUS
    • AQUARIUS

      public static final Zodiac AQUARIUS
    • PISCES

      public static final Zodiac PISCES
  • Method Details

    • values

      public static Zodiac[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static Zodiac valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • constellationPassedBySun

      public static Zodiac constellationPassedBySun(Moment moment)

      Determines the zodiac constellation passed by the sun at given moment.

      Parameters:
      moment - the moment when any zodiac is passed
      Returns:
      Zodiac constellation
    • constellationPassedByMoon

      public static Zodiac constellationPassedByMoon(Moment moment)

      Determines the zodiac constellation passed by the moon at given moment.

      Parameters:
      moment - the moment when any zodiac is passed
      Returns:
      Zodiac constellation
    • signPassedBySun

      public static Zodiac signPassedBySun(Moment moment)

      Determines the zodiac sign passed by the sun at given moment.

      Parameters:
      moment - the moment when any zodiac is passed
      Returns:
      Zodiac sign
    • signPassedByMoon

      public static Zodiac signPassedByMoon(Moment moment)

      Determines the zodiac sign passed by the moon at given moment.

      Parameters:
      moment - the moment when any zodiac is passed
      Returns:
      Zodiac sign
    • getSymbol

      public char getSymbol()

      Obtains the associated symbol character.

      Returns:
      char
    • getDisplayName

      public String getDisplayName(Locale locale)

      Obtains a localized name.

      Parameters:
      locale - language
      Returns:
      localized name or the Latin name if given language is not supported
    • previous

      public Zodiac previous()

      Obtains the zodiac which happens previous before this zodiac.

      Returns:
      previous zodiac
    • next

      public Zodiac next()

      Obtains the zodiac which happens next after this zodiac.

      Returns:
      next zodiac