Class TimeTag

    • Constructor Detail

      • TimeTag

        public TimeTag()
    • Method Detail

      • writeTimeJavaScript

        public static void writeTimeJavaScript​(long date,
                                               Sequence sequence,
                                               Union_Palpable_Phrasing<?> content,
                                               Appendable scriptOut)
                                        throws IOException
        Writes a JavaScript script tag that a time in the user's locale.

        Because this needs to modify the DOM it can lead to poor performance or large data sets. To provide more performance options, the JavaScript is written to scriptOut. This could then be buffered into one long script to execute at once or using body.onload.

        The provided sequence should start at one for any given HTML page because parts of the script will only be written when the sequence is equal to one.

        Throws:
        IOException
        See Also:
        SQLUtility.formatTime(long)
      • writeTimeJavaScript

        public static void writeTimeJavaScript​(Long date,
                                               Sequence sequence,
                                               Union_Palpable_Phrasing<?> content,
                                               Appendable scriptOut)
                                        throws IOException
        Writes a JavaScript script tag that a time in the user's locale. Prints nothing when the date is null.

        Because this needs to modify the DOM it can lead to poor performance or large data sets. To provide more performance options, the JavaScript is written to scriptOut. This could then be buffered into one long script to execute at once or using body.onload.

        The provided sequence should start at one for any given HTML page because parts of the script will only be written when the sequence is equal to one.

        Throws:
        IOException
        See Also:
        SQLUtility.formatTime(java.lang.Long)
      • writeTimeJavaScript

        public static void writeTimeJavaScript​(Date date,
                                               Sequence sequence,
                                               Union_Palpable_Phrasing<?> content,
                                               Appendable scriptOut)
                                        throws IOException
        Writes a JavaScript script tag that a time in the user's locale. Prints nothing when the date is null.

        Because this needs to modify the DOM it can lead to poor performance or large data sets. To provide more performance options, the JavaScript is written to scriptOut. This could then be buffered into one long script to execute at once or using body.onload.

        The provided sequence should start at one for any given HTML page because parts of the script will only be written when the sequence is equal to one.

        Throws:
        IOException
        See Also:
        SQLUtility.formatTime(java.util.Date)