(<dates & dts)Returns true if the given java.util.Date arguments are in strictly ascending order.
Returns true if the given `java.util.Date` arguments are in strictly ascending order.
(>dates & dts)Returns true if the given java.util.Date arguments are in strictly descending order.
Returns true if the given `java.util.Date` arguments are in strictly descending order.
(_api-stub)(_api-stub expected-result)Returns a function that captures its argument list unless it is invoked
with :stub/state as the initial argument. If it is invoked with
:stub/state as the initial argument, it returns the last argument list
it captured. Otherwise, it returns expected-result or nil if none
was specified.
Intended for use in tests.
Returns a function that captures its argument list unless it is invoked with `:stub/state` as the initial argument. If it is invoked with `:stub/state` as the initial argument, it returns the last argument list it captured. Otherwise, it returns `expected-result` or `nil` if none was specified. Intended for use in tests.
(kw->java-constant m maybe-kw)Converts a keyword like :some/constant-name to SomeConstantName. Returns nil if the keyword is not found in the map.
Converts a keyword like :some/constant-name to SomeConstantName. Returns nil if the keyword is not found in the map.
(kw->java-constant-strict m err maybe-kw)Converts a keyword like :some/constant-name to SomeConstantName.
Converts a keyword like :some/constant-name to SomeConstantName.
(maybe f x)A maybe monoid implementation for Clojure where the nil value behaves as the
monoid zero.
Takes a function f and a value x, applies f to x if x is not nil,
otherwise returns nil.
A `maybe` monoid implementation for Clojure where the nil value behaves as the monoid zero. Takes a function `f` and a value `x`, applies `f` to `x` if `x` is not nil, otherwise returns nil.
(next-day dt)Takes a Date dt and returns a new date with
24 hours added.
Takes a Date `dt` and returns a new date with 24 hours added.
(oci-region-from-id ocid)Returns the region segment of an OCID, e.g. "phx" for
ocid1.instance.oc1.phx.<tail>. Returns nil for global resources whose
region segment is empty (compartments, users, tenancies), and for
non-strings or malformed input.
The returned segment may be either a 3-letter region code ("phx") or a
full region-id ("us-phoenix-1"); callers that need a Region object should
use Region/fromRegionCodeOrId to normalize.
Returns the region segment of an OCID, e.g. "phx" for
`ocid1.instance.oc1.phx.<tail>`. Returns nil for global resources whose
region segment is empty (compartments, users, tenancies), and for
non-strings or malformed input.
The returned segment may be either a 3-letter region code ("phx") or a
full region-id ("us-phoenix-1"); callers that need a Region object should
use `Region/fromRegionCodeOrId` to normalize.(primitive? parameter-type)Returns true if the given parameter-type is a Java primitive type
or a commonly used boxed type or other simple type.
Returns true if the given `parameter-type` is a Java primitive type or a commonly used boxed type or other simple type.
(random-string length)(random-string length prepend)Generate a cryptographically-secure random string of length, with optional
prepend prefix.
Generate a cryptographically-secure random string of `length`, with optional `prepend` prefix.
(region-from-availability-domain ad-string)Extracts the canonical region-id from an availability-domain string like "FDlC:PHX-AD-1". Returns nil if the AD is malformed or names a region the SDK doesn't know about.
AD format is <account-prefix>:<REGION-CODE>-AD-<n>; this fn pulls the
3-letter code and resolves it to a region-id via Region/fromRegionCode,
so the result is always the canonical id like "us-phoenix-1".
Extracts the canonical region-id from an availability-domain string like "FDlC:PHX-AD-1". Returns nil if the AD is malformed or names a region the SDK doesn't know about. AD format is `<account-prefix>:<REGION-CODE>-AD-<n>`; this fn pulls the 3-letter code and resolves it to a region-id via `Region/fromRegionCode`, so the result is always the canonical id like "us-phoenix-1".
(start-of-day dt)Takes a Date dt, returns a new Date representing
the start of that day (00:00:00.000) in UTC.
Takes a Date `dt`, returns a new Date representing the start of that day (00:00:00.000) in UTC.
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |