Liking cljdoc? Tell your friends :D

convex.cell

Constructors for CVX cells and related type predicate functions.

Also constructors for a few common idioms such as creating a def form.

Constructors for CVX cells and related type predicate functions.

Also constructors for a few common idioms such as creating a [[def]] form.
raw docstring

addressclj

(address long)

Creates a CVX address from a long.

Creates a CVX address from a long.
sourceraw docstring

address?clj

(address? x)

Is x an address?

Is `x` an address?
sourceraw docstring

blobclj

(blob byte-array)

Creates a CVX blob from a byte array.

Creates a CVX blob from a byte array.
sourceraw docstring

blob?clj

(blob? x)

Is x a blob?

Is `x` a blob?
sourceraw docstring

booleanclj

(boolean x)

Creates a CVX boolean given a falsy or truthy value.

Creates a CVX boolean given a falsy or truthy value.
sourceraw docstring

boolean?clj

(boolean? x)

Is x a CVX boolean?

Is `x` a CVX boolean?
sourceraw docstring

byteclj

(byte b)

Creates a CVX byte from a value between 0 and 255 inclusive.

Creates a CVX byte from a value between 0 and 255 inclusive.
sourceraw docstring

byte?clj

(byte? x)

Is x a CVX byte?

Is `x` a CVX byte?
sourceraw docstring

call?clj

(call? x form)

Is x a call for form such as (form ...)?

Is `x` a call for `form` such as `(form ...)`?
sourceraw docstring

charclj

(char ch)

Creates a CVX character from a regular character.

Creates a CVX character from a regular character.
sourceraw docstring

char?clj

(char? x)

Is x a CVX char?

Is `x` a CVX char?
sourceraw docstring

code-std*cljmacro

(code-std* kw)

Given a Clojure keyword, returns the corresponding standard error code (any of the Convex keyword the CVM itself uses):

  • :ARGUMENT
  • :ARITY
  • :ASSERT
  • :BOUNDS
  • :CAST
  • :COMPILE
  • :DEPTH
  • :EXCEPTION
  • :EXPAND
  • :FATAL
  • :FUNDS
  • :HALT
  • :JUICE
  • :MEMORY
  • :NOBODY
  • :RECUR
  • :REDUCED
  • :RETURN
  • :ROLLBACK
  • :SEQUENCE
  • :SIGNATURE
  • :STATE
  • :TAILCALL
  • :TODO
  • :TRUST
  • :UNDECLARED
  • :UNEXPECTED

Throws if keyword does not match any of those.

Note that in user functions, codes can be anything, any type, using those codes is not at all mandatory.

Given a Clojure keyword, returns the corresponding standard error code (any of the Convex keyword the CVM itself
uses):

- `:ARGUMENT`
- `:ARITY`
- `:ASSERT`
- `:BOUNDS`
- `:CAST`
- `:COMPILE`
- `:DEPTH`
- `:EXCEPTION`
- `:EXPAND`
- `:FATAL`
- `:FUNDS`
- `:HALT`
- `:JUICE`
- `:MEMORY`
- `:NOBODY`
- `:RECUR`
- `:REDUCED`
- `:RETURN`
- `:ROLLBACK`
- `:SEQUENCE`
- `:SIGNATURE`
- `:STATE`
- `:TAILCALL`
- `:TODO`
- `:TRUST`
- `:UNDECLARED`
- `:UNEXPECTED`

Throws if keyword does not match any of those.

Note that in user functions, codes can be anything, any type, using those codes is not at all mandatory.
sourceraw docstring

defclj

(def sym x)

Creates a def form which interns x under sym.

Creates a `def` form which interns `x` under `sym`.
sourceraw docstring

deployclj

(deploy code)
(deploy sym code)

Creates a deploy form which deploys code.

If sym is provided, the deploy form is embedded in a def.

Creates a `deploy` form which deploys `code`.

If `sym` is provided, the deploy form is embedded in a [[def]].
sourceraw docstring

doclj

(do cell+)

Creates a do form embedded the given cells.

Creates a `do` form embedded the given cells.
sourceraw docstring

doubleclj

(double x)

Creates a CVX double.

Creates a CVX double.
sourceraw docstring

double?clj

(double? x)

Is x a CVX double?

Is `x` a CVX double?
sourceraw docstring

errorclj

(error message)
(error code message)
(error code message trace)

An error value as Convex data.

code is often a CVX keyword (:ASSERT by default), message could be any CVX value (albeit often a human-readable string), and trace is an optional stacktrace (CVX vector of CVX strings).

An error value as Convex data.

`code` is often a CVX keyword (`:ASSERT` by default), `message` could be any CVX value (albeit often a human-readable
string), and `trace` is an optional stacktrace (CVX vector of CVX strings).
sourceraw docstring

importclj

(import x as)

Creates an import form which imports x as as.

Creates an `import` form which imports `x` as `as`.
sourceraw docstring

keyclj

(key blob)

Creates an account key from a 32-byte blob.

Returns nil if the given blob is of wrong size.

Creates an account key from a 32-byte [[blob]].

Returns nil if the given [[blob]] is of wrong size.
sourceraw docstring

key-fakeclj

Zeroed key that can be used during dev and testing so that an account is considered as a user, not an actor.

Zeroed [[key]] that can be used during dev and testing so that an account is considered as a user, not an actor.
sourceraw docstring

keywordclj

(keyword string)

Creates a CVX keyword from a string.

Creates a CVX keyword from a string.
sourceraw docstring

keyword?clj

(keyword? x)

Is x a CVX keyword?

Is `x` a CVX keyword?
sourceraw docstring

listclj

(list)
(list x)

Creates a CVX list from a collection of CVX items.

Creates a CVX list from a collection of CVX items.
sourceraw docstring

list?clj

(list? x)

Is x a CVX list?

Is `x` a CVX list?
sourceraw docstring

longclj

(long x)

Creates a CVX long.

Creates a CVX long.
sourceraw docstring

long?clj

(long? x)

Is x a CVX long?

Is `x` a CVX long?
sourceraw docstring

mapclj

(map)
(map x)

Creates a CVX map from a collection of [key value].

Creates a CVX map from a collection of `[key value]`.
sourceraw docstring

map?clj

(map? x)

Is x a CVX map?

Is `x` a CVX map?
sourceraw docstring

quoteclj

(quote x)

Creates form which quotes x.

Creates form which quotes `x`.
sourceraw docstring

setclj

(set)
(set x)

Creates a CVX set from a collection of CVX items.

Creates a CVX set from a collection of CVX items.
sourceraw docstring

set?clj

(set? x)

Is x a CVX set?

Is `x` a CVX set?
sourceraw docstring

stringclj

(string string)

Creates a CVX string from a regular string.

Creates a CVX string from a regular string.
sourceraw docstring

string?clj

(string? x)

Is x a CVX string?

Is `x` a CVX string?
sourceraw docstring

symbolclj

(symbol string)

Creates a CVX symbol from a string.

Creates a CVX symbol from a string.
sourceraw docstring

symbol?clj

(symbol? x)

Is x a CVX symbol?

Is `x` a CVX symbol?
sourceraw docstring

undefclj

(undef sym)

Opposite of def.

Opposite of [[def]].
sourceraw docstring

vectorclj

(vector)
(vector x)

Creates a CVX vector from a collection of CVX items.

Creates a CVX vector from a collection of CVX items.
sourceraw docstring

vector?clj

(vector? x)

Is x a CVX vector?

Is `x` a CVX vector?
sourceraw docstring

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

× close