0.2.3 docs





    Nov 9, 2017

    Christopher Brown
    University of Texas at Austin
    Austin, TX


    Index of all namespaces

    « Project + dependencies

    Cross-platform time tools

    Cross-platform Date(Time) conversion & coercion; the API reflects the
    varied types of dates in Java, but every method also works in ClojureScript,
    but simply returns a js/Date instead of the different JVM types.
    JavaScript's single Date type seems to me to be most similar to Java's
    OffsetDateTime, so whenever a default date instance surfaces on the JVM
    side, it will be a java.time.OffsetDateTime.
    The README below is fetched from the published project artifact. Some relative links may be broken.


    Travis CI Build Status Coverage Status Clojars Project

    Cross-platform DateTime type coercion, parsing, and manipulation.

    Supports Clojure and ClojureScript via reader conditionals, so it requires Clojure 1.7.0, [org.clojure/clojure "1.7.0"], or newer.

    When compiled for the Clojure/Java platform, it uses the java.time.* API (a.k.a. JSR-310), so Java 8 is required.


    • Timestamp (= Instant): a finite point in linear time, measurable in milliseconds since the epoch
    • Duration: an amount of linear time, measurable in milliseconds
    • Interval: two timestamps – or a single timestamp plus a duration (and a single bit to say whether the timestamp is the beginning or the end)
    • Period: a semantic (non-linear) duration, like “2 weeks”. This is a bit confusing, since the ISO-8601 prefix/indicator for duration syntax is “P”, but it is used for duration, not period – since you can only have hour, minute, and second values in that duration.


    JVM-only; uses Joda time for Java <8. - clj-time * Documentation * Source

    JVM-only; depends on Joda time even with Java 8.


    Copyright © 2017 Christopher Brown. Eclipse Public License - v 1.0.