Uses of Class
java.util.Calendar

Packages that use Calendar
Package Description
java.sql
Provides the API for accessing and processing data stored in a data source (usually a relational database) using the Java programming language.
java.text
Provides classes and interfaces for handling text, dates, numbers, and messages in a manner independent of natural languages.
java.util
Contains the collections framework, some internationalization support classes, a service loader, properties, random number generation, string parsing and scanning classes, base64 encoding and decoding, a bit array, and several miscellaneous utility classes.
javax.sql
Provides the API for server side data source access and processing from the Java programming language.
javax.sql.rowset
Standard interfaces and base classes for JDBC RowSet implementations.
javax.xml.datatype
Defines XML/Java Type Mappings.
  • Uses of Calendar in java.sql

    Methods in java.sql with parameters of type Calendar
    Modifier and Type Method Description
    Date CallableStatement.getDate​(int parameterIndex, Calendar cal)
    Retrieves the value of the designated JDBC DATE parameter as a java.sql.Date object, using the given Calendar object to construct the date.
    Date CallableStatement.getDate​(String parameterName, Calendar cal)
    Retrieves the value of a JDBC DATE parameter as a java.sql.Date object, using the given Calendar object to construct the date.
    Date ResultSet.getDate​(int columnIndex, Calendar cal)
    Retrieves the value of the designated column in the current row of this ResultSet object as a java.sql.Date object in the Java programming language.
    Date ResultSet.getDate​(String columnLabel, Calendar cal)
    Retrieves the value of the designated column in the current row of this ResultSet object as a java.sql.Date object in the Java programming language.
    Time CallableStatement.getTime​(int parameterIndex, Calendar cal)
    Retrieves the value of the designated JDBC TIME parameter as a java.sql.Time object, using the given Calendar object to construct the time.
    Time CallableStatement.getTime​(String parameterName, Calendar cal)
    Retrieves the value of a JDBC TIME parameter as a java.sql.Time object, using the given Calendar object to construct the time.
    Time ResultSet.getTime​(int columnIndex, Calendar cal)
    Retrieves the value of the designated column in the current row of this ResultSet object as a java.sql.Time object in the Java programming language.
    Time ResultSet.getTime​(String columnLabel, Calendar cal)
    Retrieves the value of the designated column in the current row of this ResultSet object as a java.sql.Time object in the Java programming language.
    Timestamp CallableStatement.getTimestamp​(int parameterIndex, Calendar cal)
    Retrieves the value of the designated JDBC TIMESTAMP parameter as a java.sql.Timestamp object, using the given Calendar object to construct the Timestamp object.
    Timestamp CallableStatement.getTimestamp​(String parameterName, Calendar cal)
    Retrieves the value of a JDBC TIMESTAMP parameter as a java.sql.Timestamp object, using the given Calendar object to construct the Timestamp object.
    Timestamp ResultSet.getTimestamp​(int columnIndex, Calendar cal)
    Retrieves the value of the designated column in the current row of this ResultSet object as a java.sql.Timestamp object in the Java programming language.
    Timestamp ResultSet.getTimestamp​(String columnLabel, Calendar cal)
    Retrieves the value of the designated column in the current row of this ResultSet object as a java.sql.Timestamp object in the Java programming language.
    void CallableStatement.setDate​(String parameterName, Date x, Calendar cal)
    Sets the designated parameter to the given java.sql.Date value, using the given Calendar object.
    void PreparedStatement.setDate​(int parameterIndex, Date x, Calendar cal)
    Sets the designated parameter to the given java.sql.Date value, using the given Calendar object.
    void CallableStatement.setTime​(String parameterName, Time x, Calendar cal)
    Sets the designated parameter to the given java.sql.Time value, using the given Calendar object.
    void PreparedStatement.setTime​(int parameterIndex, Time x, Calendar cal)
    Sets the designated parameter to the given java.sql.Time value, using the given Calendar object.
    void CallableStatement.setTimestamp​(String parameterName, Timestamp x, Calendar cal)
    Sets the designated parameter to the given java.sql.Timestamp value, using the given Calendar object.
    void PreparedStatement.setTimestamp​(int parameterIndex, Timestamp x, Calendar cal)
    Sets the designated parameter to the given java.sql.Timestamp value, using the given Calendar object.
  • Uses of Calendar in java.text

    Fields in java.text declared as Calendar
    Modifier and Type Field Description
    protected Calendar DateFormat.calendar
    The Calendar instance used for calculating the date-time fields and the instant of time.
    Methods in java.text that return Calendar
    Modifier and Type Method Description
    Calendar DateFormat.getCalendar()
    Gets the calendar associated with this date/time formatter.
    Methods in java.text with parameters of type Calendar
    Modifier and Type Method Description
    void DateFormat.setCalendar​(Calendar newCalendar)
    Set the calendar to be used by this date format.
  • Uses of Calendar in java.util

    Subclasses of Calendar in java.util
    Modifier and Type Class Description
    class  GregorianCalendar
    GregorianCalendar is a concrete subclass of Calendar and provides the standard calendar system used by most of the world.
    Methods in java.util that return Calendar
    Modifier and Type Method Description
    Calendar Calendar.Builder.build()
    Returns a Calendar built from the parameters set by the setter methods.
    static Calendar Calendar.getInstance()
    Gets a calendar using the default time zone and locale.
    static Calendar Calendar.getInstance​(Locale aLocale)
    Gets a calendar using the default time zone and specified locale.
    static Calendar Calendar.getInstance​(TimeZone zone)
    Gets a calendar using the specified time zone and default locale.
    static Calendar Calendar.getInstance​(TimeZone zone, Locale aLocale)
    Gets a calendar with the specified time zone and locale.
    Methods in java.util with parameters of type Calendar
    Modifier and Type Method Description
    int Calendar.compareTo​(Calendar anotherCalendar)
    Compares the time values (millisecond offsets from the Epoch) represented by two Calendar objects.
  • Uses of Calendar in javax.sql

    Methods in javax.sql with parameters of type Calendar
    Modifier and Type Method Description
    void RowSet.setDate​(int parameterIndex, Date x, Calendar cal)
    Sets the designated parameter in this RowSet object's command with the given java.sql.Date value.
    void RowSet.setDate​(String parameterName, Date x, Calendar cal)
    Sets the designated parameter to the given java.sql.Date value, using the given Calendar object.
    void RowSet.setTime​(int parameterIndex, Time x, Calendar cal)
    Sets the designated parameter in this RowSet object's command with the given java.sql.Time value.
    void RowSet.setTime​(String parameterName, Time x, Calendar cal)
    Sets the designated parameter to the given java.sql.Time value, using the given Calendar object.
    void RowSet.setTimestamp​(int parameterIndex, Timestamp x, Calendar cal)
    Sets the designated parameter in this RowSet object's command with the given java.sql.Timestamp value.
    void RowSet.setTimestamp​(String parameterName, Timestamp x, Calendar cal)
    Sets the designated parameter to the given java.sql.Timestamp value, using the given Calendar object.
  • Uses of Calendar in javax.sql.rowset

    Methods in javax.sql.rowset with parameters of type Calendar
    Modifier and Type Method Description
    void BaseRowSet.setDate​(int parameterIndex, Date x, Calendar cal)
    Sets the designated parameter to the given java.sql.Date object.
    void BaseRowSet.setDate​(String parameterName, Date x, Calendar cal)
    Sets the designated parameter to the given java.sql.Date value, using the given Calendar object.
    void BaseRowSet.setTime​(int parameterIndex, Time x, Calendar cal)
    Sets the designated parameter to the given java.sql.Time object.
    void BaseRowSet.setTime​(String parameterName, Time x, Calendar cal)
    Sets the designated parameter to the given java.sql.Time value, using the given Calendar object.
    void BaseRowSet.setTimestamp​(int parameterIndex, Timestamp x, Calendar cal)
    Sets the designated parameter to the given java.sql.Timestamp object.
    void BaseRowSet.setTimestamp​(String parameterName, Timestamp x, Calendar cal)
    Sets the designated parameter to the given java.sql.Timestamp value, using the given Calendar object.
  • Uses of Calendar in javax.xml.datatype

    Methods in javax.xml.datatype with parameters of type Calendar
    Modifier and Type Method Description
    abstract void Duration.addTo​(Calendar calendar)
    Adds this duration to a Calendar object.
    long Duration.getTimeInMillis​(Calendar startInstant)
    Returns the length of the duration in milli-seconds.
    abstract Duration Duration.normalizeWith​(Calendar startTimeInstant)
    Converts the years and months fields into the days field by using a specific time instant as the reference point.