Liking cljdoc? Tell your friends :D

java-time.core


after?clj

(after? x)
(after? x y)
(after? x y & more)

Returns non-nil if time entities are ordered from the latest to the earliest (same semantics as >):

(after? (local-date 2011) (local-date 2010) (local-date 2009)) => truthy...

(after? (instant 99999999) (interval (instant 10000) (instant 1000000))) => truthy...

Returns non-nil if time entities are ordered from the latest to the earliest
(same semantics as `>`):

  (after? (local-date 2011) (local-date 2010) (local-date 2009))
  => truthy...

  (after? (instant 99999999)
          (interval (instant 10000) (instant 1000000)))
  => truthy...
sourceraw docstring

Amountcljprotocol

absclj

(abs a)

Returns the absolute value of a temporal amount:

(abs (negate x)) == (abs x)

Returns the absolute value of a temporal amount:

(abs (negate x)) == (abs x)

negateclj

(negate a)

Negates a temporal amount:

(negate (negate x)) == x

Negates a temporal amount:

(negate (negate x)) == x

negative?clj

(negative? a)

True if the amount is negative

True if the amount is negative

zero?clj

(zero? a)

True if the amount is zero

True if the amount is zero
source

Ascljprotocol

as*clj

(as* o k)

Value of property/unit identified by key/object k of the temporal entity o

Value of property/unit identified by key/object `k` of the temporal
entity `o`
source

asclj

(as o k)
(as o k1 k2)
(as o k1 k2 & ks)

Values of property/unit identified by keys/objects ks of the temporal entity o, e.g.

(as (duration 1 :hour) :minutes) => 60

(as (local-date 2015 9) :year :month-of-year) => [2015 9]

Values of property/unit identified by keys/objects `ks` of the temporal
entity `o`, e.g.

  (as (duration 1 :hour) :minutes)
  => 60

  (as (local-date 2015 9) :year :month-of-year)
  => [2015 9]
sourceraw docstring

before?clj

(before? x)
(before? x y)
(before? x y & more)

Returns non-nil if time entities are ordered from the earliest to the latest (same semantics as <):

(before? (local-date 2009) (local-date 2010) (local-date 2011)) => truthy...

(before? (interval (instant 10000) (instant 1000000)) (instant 99999999)) => truthy...

Returns non-nil if time entities are ordered from the earliest to the latest
(same semantics as `<`):

  (before? (local-date 2009) (local-date 2010) (local-date 2011))
  => truthy...

  (before? (interval (instant 10000) (instant 1000000))
           (instant 99999999))
  => truthy...
sourceraw docstring

HasChronologycljprotocol

chronologyclj

(chronology o)

The Chronology of the entity

The `Chronology` of the entity
source

HasFieldscljprotocol

field*clj

(field* o k)

Internal use

Internal use

fieldsclj

(fields o)

Fields present in this temporal entity

Fields present in this temporal entity
source

HasPropertiescljprotocol

propertiesclj

(properties o)

Map of properties present in this temporal entity

Map of properties present in this temporal entity

propertyclj

(property o k)

Property of this temporal entity under key k

Property of this temporal entity under key `k`
source

HasUnitscljprotocol

unit*clj

(unit* o k)

Internal use

Internal use

unitsclj

(units o)

Units present in this temporal entity.

Units present in this temporal entity.
source

HasZonecljprotocol

with-zoneclj

(with-zone o z)

Returns this temporal entity with the specified ZoneId

Returns this temporal entity with the specified `ZoneId`
source

KnowsIfLeapcljprotocol

leap?clj

(leap? o)

True if the year of this entity is a leap year.

True if the year of this entity is a leap year.
source

KnowsTimeBetweencljprotocol

time-betweenclj

(time-between o e u)

Time between temporal entities o and e in unit u.

(j/time-between (j/local-date 2015) (j/local-date 2016) :days) => 365

(j/time-between :days (j/local-date 2015) (j/local-date 2016)) => 365

Time between temporal entities `o` and `e` in unit `u`.

(j/time-between (j/local-date 2015) (j/local-date 2016) :days)
=> 365

(j/time-between :days (j/local-date 2015) (j/local-date 2016))
=> 365
source

maxclj

(max o & os)

Latest/longest of the given time entities. Entities should be of the same type

Latest/longest of the given time entities. Entities should be of the same
type
sourceraw docstring

minclj

(min o & os)

Earliest/shortest of the given time entities. Entities should be of the same type

Earliest/shortest of the given time entities. Entities should be of the same
type
sourceraw docstring

minusclj

(minus o & os)

Subtracts all of the os from the time entity o

(j/minus (j/local-date 2015) (j/years 1)) => <java.time.LocalDate "2014-01-01">

Subtracts all of the `os` from the time entity `o`

(j/minus (j/local-date 2015) (j/years 1))
=> <java.time.LocalDate "2014-01-01">
sourceraw docstring

Minusablecljprotocol

Internal

Internal

seq-minusclj

(seq-minus o os)
sourceraw docstring

Multipliablecljprotocol

multiply-byclj

(multiply-by o v)

Entity o mutlitplied by the value v

Entity `o` mutlitplied by the value `v`
source

Orderedcljprotocol

single-after?clj

(single-after? a b)

Internal use

Internal use

single-before?clj

(single-before? a b)

Internal use

Internal use
source

plusclj

(plus o & os)

Adds all of the os to the time entity o

(j/plus (j/local-date 2015) (j/years 1)) => <java.time.LocalDate "2016-01-01">

Adds all of the `os` to the time entity `o`

(j/plus (j/local-date 2015) (j/years 1))
=> <java.time.LocalDate "2016-01-01">
sourceraw docstring

Plusablecljprotocol

Internal

Internal

seq-plusclj

(seq-plus o os)
sourceraw docstring

readable-range-property-fnsclj

source

ReadablePropertycljprotocol

valueclj

(value p)

Value of the property

Value of the property
source

ReadableRangePropertycljprotocol

largest-min-valueclj

(largest-min-value p)

Largest minimum value of this property

Largest minimum value of this property

max-valueclj

(max-value p)

Maximum value of this property, e.g. 29th of February for months

Maximum value of this property, e.g. 29th of February for months

min-valueclj

(min-value p)

Minimum value of this property

Minimum value of this property

rangeclj

(range p)

Range of values for this property

Range of values for this property

smallest-max-valueclj

(smallest-max-value p)

Smallest maximum value of this property, e.g. 28th of February for months

Smallest maximum value of this property, e.g. 28th of February for months
source

Supportingcljprotocol

supports?clj

(supports? o p)

True if the o entity supports the p property

True if the `o` entity supports the `p` property
source

Truncatablecljprotocol

truncate-toclj

(truncate-to o u)

Truncates this entity to the specified time unit. Only works for units that divide into the length of standard day without remainder (up to :days).

Truncates this entity to the specified time unit. Only works for units that
divide into the length of standard day without remainder (up to `:days`).
source

WritablePropertycljprotocol

with-valueclj

(with-value p v)

Underlying temporal entity with the value of this property set to v

Underlying temporal entity with the value of this property set to `v`
source

WritableRangePropertycljprotocol

with-largest-min-valueclj

(with-largest-min-value p)

Underlying temporal entity with the value set to the largest minimum available for this property

Underlying temporal entity with the value set to the largest minimum
available for this property

with-max-valueclj

(with-max-value p)

Underlying temporal entity with the value set to the maximum available for this property

Underlying temporal entity with the value set to the maximum
available for this property

with-min-valueclj

(with-min-value p)

Underlying temporal entity with the value set to the minimum available for this property

Underlying temporal entity with the value set to the minimum available for
this property

with-smallest-max-valueclj

(with-smallest-max-value p)

Underlying temporal entity with the value set to the smallest maximum available for this property

Underlying temporal entity with the value set to the smallest maximum
available for this property
source

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close