Class SimpleDate

  • java.lang.Object

  • public class SimpleDate
    extends java.lang.Object
    A class for storing simple date values without a time component.
    • Constructor Summary

      Constructor and Description
      SimpleDate(int year, int month, int day)
      Constructs a new simple date.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      boolean equals(java.lang.Object obj) 
      int getDay()
      Gets the calendar day; this should be between 1 and 31.
      int getMonth()
      Gets the calendar month number.
      int getYear()
      Gets the calendar year.
      int hashCode() 
      java.lang.String toString() 
      • Methods inherited from class java.lang.Object

        getClass, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • SimpleDate

        public SimpleDate(int year,
                          int month,
                          int day)
        Constructs a new simple date.
        year - the full year number
        month - a month number between 1-12
        day - a day number between 1-31
        java.lang.IllegalArgumentException - throws if the date is invalid, or the year is outside the RFC3339 supported range
    • Method Detail

      • getYear

        public int getYear()
        Gets the calendar year.
        the full year number
      • getMonth

        public int getMonth()
        Gets the calendar month number. This would return 1 for January, and 12 for December.
        the month number
      • getDay

        public int getDay()
        Gets the calendar day; this should be between 1 and 31.
        the day number
      • equals

        public boolean equals(java.lang.Object obj)
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        toString in class java.lang.Object

Monitor your resources on the go

Get the Google Cloud Console app to help you manage your projects.

Send feedback about...

Cloud Endpoints Frameworks for App Engine