Liking cljdoc? Tell your friends :D

hara.core.base.result


->dataclj

(->data res)

accesses the data held by the result

(->data 1) => 1

(->data (result {:status :warn :data [1 2 3 4]})) => [1 2 3 4]

accesses the data held by the result

(->data 1) => 1

(->data (result {:status :warn :data [1 2 3 4]}))
=> [1 2 3 4]
raw docstring

->resultclj

(->result key data)

converts data into a result

(->result :hello [1 2 3]) ;;#result.return{:data [1 2 3], :key :hello} => hara.core.base.result.Result

converts data into a result

(->result :hello [1 2 3])
;;#result.return{:data [1 2 3], :key :hello}
=> hara.core.base.result.Result
raw docstring

Resultclj


resultclj

(result m)

creates a result used for printing

(result {:status :warn :data [1 2 3 4]}) ;; #result{:status :warn, :data [1 2 3 4]} => hara.core.base.result.Result

creates a result used for printing

(result {:status :warn :data [1 2 3 4]})
;; #result{:status :warn, :data [1 2 3 4]}
=> hara.core.base.result.Result
raw docstring

result?clj

(result? obj)

checks if an object is a result

(-> (result {:status :warn :data [1 2 3 4]}) result?) => true

checks if an object is a result

(-> (result {:status :warn :data [1 2 3 4]})
    result?)
=> true
raw docstring

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

× close