Interface Duration


  • @Deprecated
    public interface Duration
    Deprecated.
    use the JDFDuration class only
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String REGEX_DURATION
      Deprecated.
       
      static long serialVersionUID
      Deprecated.
       
    • Method Summary

      All Methods Instance Methods Abstract Methods Deprecated Methods 
      Modifier and Type Method Description
      int getDuration()
      Deprecated.
      the duration in seconds
      java.lang.String getDurationISO()
      Deprecated.
      Format and return the duration set by 'setDuration(int i)' or 'setDurationString(String a_aDuration)' as an ISO conform String.
      boolean isLonger​(Duration x)
      Deprecated.
      isLess - tests if the duration of this JDFDuration is longer then the duration of the specified JDFDuration.
      boolean isShorter​(Duration x)
      Deprecated.
      isShorter - tests if the duration of this JDFDuration is less then the duration of the specified JDFDuration.
      void setDuration​(int i)
      Deprecated.
      setDuration sets a duration for this in seconds.
      boolean setDurationISO​(java.lang.String a_aDuration)
      Deprecated.
      Set a duration.
    • Method Detail

      • getDurationISO

        java.lang.String getDurationISO()
        Deprecated.
        Format and return the duration set by 'setDuration(int i)' or 'setDurationString(String a_aDuration)' as an ISO conform String. For Exmaple: 'P1Y2M3DT10H30M'
        Returns:
        String the duration formated as an ISO 8601 conform String if duration is '0' return value is 'PT00M'
      • setDurationISO

        boolean setDurationISO​(java.lang.String a_aDuration)
        Deprecated.
        Set a duration. Durations are not bound to time or date and can be set independently
        Parameters:
        a_aDuration - formatted duration string 'P1Y2M3DT10H30M'
        Returns:
        true the duration was set false the duration was not set, because a NumberFormatException was thrown (-> parseInt())
      • setDuration

        void setDuration​(int i)
        Deprecated.
        setDuration sets a duration for this in seconds. This duration is used in multiple classes of the jdf. Heating time for example.
        Parameters:
        i - the duration in seconds. Values below '0' are set to '0'
      • getDuration

        int getDuration()
        Deprecated.
        the duration in seconds
        Returns:
        int the duration in seconds; '0' default
      • isLonger

        boolean isLonger​(Duration x)
        Deprecated.
        isLess - tests if the duration of this JDFDuration is longer then the duration of the specified JDFDuration.
        Parameters:
        x - - the JDFDuration object you whant to compare with 'this' JDFDuration object
        Returns:
        boolean - true if the duration of this JDFDuration is longer then the duration of the JDFDuration 'x'.
      • isShorter

        boolean isShorter​(Duration x)
        Deprecated.
        isShorter - tests if the duration of this JDFDuration is less then the duration of the specified JDFDuration.
        Parameters:
        x - - the JDFDuration object that duration you whant to compare with duration of 'this' JDFDuration object
        Returns:
        boolean - true if the duration of this JDFDuration is shorter then the duration of the JDFDuration 'x'.