Class ValuationZoneTimeDefinition

  • All Implemented Interfaces:
    Serializable, org.joda.beans.Bean, org.joda.beans.ImmutableBean

    public final class ValuationZoneTimeDefinition
    extends Object
    implements org.joda.beans.ImmutableBean, Serializable
    Definition of valuation zone and time.

    This contains ZoneId and a set of LocalTime to create ZonedDateTime from LocalDate.

    See Also:
    Serialized Form
    • Method Detail

      • of

        public static ValuationZoneTimeDefinition of​(LocalTime defaultLocalTime,
                                                     ZoneId zoneId,
                                                     LocalTime... localTimes)
        Obtains an instance.
        defaultLocalTime - default local time
        zoneId - the zone ID
        localTimes - the local time
        the instance
      • toZonedDateTime

        public MarketDataBox<ZonedDateTime> toZonedDateTime​(MarketDataBox<LocalDate> dates)
        Creates zoned date time.

        If the scenario size of dates is greater than the size of localTimes, defaultLocalTime is used. If dates is single value, defaultLocalTime is used.

        dates - the local date
        the zoned date time
      • getDefaultLocalTime

        public LocalTime getDefaultLocalTime()
        Gets the default local time.

        The default local time will be used if the input date is not scenario value or if the scenario size of the input date exceeds the size of localTimes.

        the value of the property, not null
      • getZoneId

        public ZoneId getZoneId()
        Gets the zone ID.
        the value of the property, not null
      • getLocalTimes

        public ImmutableList<LocalTime> getLocalTimes()
        Gets the local time.

        The local time in zoneId. The size is not necessarily the same as the scenario size. defaultLocalTime will be used if extra LocalTime is required.

        the value of the property, not null
      • hashCode

        public int hashCode()
        hashCode in class Object