Record Class CalendarMethodsRecord

java.lang.Object
java.lang.Record
com.oracle.truffle.js.runtime.builtins.temporal.CalendarMethodsRecord
Record Components:
receiver - The calendar object, or a string indicating a built-in time zone. A String or Object.
dateAdd - The calendar's dateAdd method. For a built-in calendar this is always %Temporal.Calendar.prototype.dateAdd%. A function object or null.
dateFromFields - The calendar's dateFromFields method. For a built-in calendar this is always %Temporal.Calendar.prototype.dateFromFields%. A function object or null.
dateUntil - The calendar's dateUntil method. For a built-in calendar this is always %Temporal.Calendar.prototype.dateUntil%. A function object or null.
day - The calendar's day method. For a built-in calendar this is always %Temporal.Calendar.prototype.day%. A function object or null.
fields - The calendar's fields method. For a built-in calendar this is always %Temporal.Calendar.prototype.fields%. A function object or null.
mergeFields - The calendar's mergeFields method. For a built-in calendar this is always %Temporal.Calendar.prototype.mergeFields%. A function object or null.
monthDayFromFields - The calendar's monthDayFromFields method. For a built-in calendar this is always %Temporal.Calendar.prototype.monthDayFromFields%. A function object or null.
yearMonthFromFields - The calendar's yearMonthFromFields method. For a built-in calendar this is always %Temporal.Calendar.prototype.yearMonthFromFields%. A function object or null.

public record CalendarMethodsRecord(Object receiver, Object dateAdd, Object dateFromFields, Object dateUntil, Object day, Object fields, Object mergeFields, Object monthDayFromFields, Object yearMonthFromFields) extends Record
Calendar Methods Record. Field values may be null in case they have not been read, and therefore must not be used. Conversely, fields that have been read must not be null. The receiver must never be null.
  • Constructor Details

    • CalendarMethodsRecord

      public CalendarMethodsRecord(Object receiver, Object dateAdd, Object dateFromFields, Object dateUntil, Object day, Object fields, Object mergeFields, Object monthDayFromFields, Object yearMonthFromFields)
      Creates an instance of a CalendarMethodsRecord record class.
      Parameters:
      receiver - the value for the receiver record component
      dateAdd - the value for the dateAdd record component
      dateFromFields - the value for the dateFromFields record component
      dateUntil - the value for the dateUntil record component
      day - the value for the day record component
      fields - the value for the fields record component
      mergeFields - the value for the mergeFields record component
      monthDayFromFields - the value for the monthDayFromFields record component
      yearMonthFromFields - the value for the yearMonthFromFields record component
  • Method Details

    • forDateAdd

      public static CalendarMethodsRecord forDateAdd(Object receiver, Object dateAdd)
    • forMonthDayFromFieldsMethod

      public static CalendarMethodsRecord forMonthDayFromFieldsMethod(Object receiver, Object monthDayFromFields)
    • forYearMonthFromFields

      public static CalendarMethodsRecord forYearMonthFromFields(Object receiver, Object yearMonthFromFields)
    • forDateAddDateUntil

      public static CalendarMethodsRecord forDateAddDateUntil(Object receiver, Object dateAdd, Object dateUntil)
    • forDateFromFieldsAndFields

      public static CalendarMethodsRecord forDateFromFieldsAndFields(Object receiver, Object dateFromFields, Object fields)
    • forDateFromFieldsAndFieldsAndMergeFields

      public static CalendarMethodsRecord forDateFromFieldsAndFieldsAndMergeFields(Object receiver, Object dateFromFields, Object fields, Object mergeFields)
    • forFieldsAndMonthDayFromFields

      public static CalendarMethodsRecord forFieldsAndMonthDayFromFields(Object receiver, Object fields, Object monthDayFromFields)
    • forFieldsAndMergeFieldsAndMonthDayFromFields

      public static CalendarMethodsRecord forFieldsAndMergeFieldsAndMonthDayFromFields(Object receiver, Object fields, Object mergeFields, Object monthDayFromFields)
    • forFieldsAndMergeFieldsAndYearMonthFromFields

      public static CalendarMethodsRecord forFieldsAndMergeFieldsAndYearMonthFromFields(Object receiver, Object fields, Object mergeFields, Object yearMonthFromFields)
    • forFieldsAndYearMonthFromFields

      public static CalendarMethodsRecord forFieldsAndYearMonthFromFields(Object receiver, Object fields, Object yearMonthFromFields)
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • receiver

      public Object receiver()
      Returns the value of the receiver record component.
      Returns:
      the value of the receiver record component
    • dateAdd

      public Object dateAdd()
      Returns the value of the dateAdd record component.
      Returns:
      the value of the dateAdd record component
    • dateFromFields

      public Object dateFromFields()
      Returns the value of the dateFromFields record component.
      Returns:
      the value of the dateFromFields record component
    • dateUntil

      public Object dateUntil()
      Returns the value of the dateUntil record component.
      Returns:
      the value of the dateUntil record component
    • day

      public Object day()
      Returns the value of the day record component.
      Returns:
      the value of the day record component
    • fields

      public Object fields()
      Returns the value of the fields record component.
      Returns:
      the value of the fields record component
    • mergeFields

      public Object mergeFields()
      Returns the value of the mergeFields record component.
      Returns:
      the value of the mergeFields record component
    • monthDayFromFields

      public Object monthDayFromFields()
      Returns the value of the monthDayFromFields record component.
      Returns:
      the value of the monthDayFromFields record component
    • yearMonthFromFields

      public Object yearMonthFromFields()
      Returns the value of the yearMonthFromFields record component.
      Returns:
      the value of the yearMonthFromFields record component