Liking cljdoc? Tell your friends :D

compliment.utils

Functions and utilities for source implementations.

Functions and utilities for source implementations.
raw docstring

*extra-metadata*clj

Signals to downstream sources which additional information about completion candidates they should attach . Should be a set of keywords.

Signals to downstream sources which additional information about completion
candidates they should attach . Should be a set of keywords.
sourceraw docstring

cache-last-resultcljmacro

(cache-last-result name key value)

If cache for name is absent, or key doesn't match the key in the cache, calculate v and return it. Else return value from cache.

If cache for `name` is absent, or `key` doesn't match the key in the cache,
calculate `v` and return it. Else return value from cache.
sourceraw docstring

classes-on-classpathclj

(classes-on-classpath)

Returns a map of all classes that can be located on the classpath. Key represent the root package of the class, and value is a list of all classes for that package.

Returns a map of all classes that can be located on the classpath. Key
represent the root package of the class, and value is a list of all classes
for that package.
sourceraw docstring

flush-cachesclj

(flush-caches)

Removes all cached values, forcing functions that depend on cache-last-result to recalculate.

Removes all cached values, forcing functions that depend on
`cache-last-result` to recalculate.
sourceraw docstring

fuzzy-matches-no-skip?clj

(fuzzy-matches-no-skip? prefix symbol separator?)

Tests if symbol matches the prefix where separator? checks whether character is a separator. Unlike fuzzy-matches? requires separator characters to be present in prefix.

Tests if symbol matches the prefix where separator? checks whether character
is a separator. Unlike `fuzzy-matches?` requires separator characters to be
present in prefix.
sourceraw docstring

fuzzy-matches?clj

(fuzzy-matches? prefix symbol separator)

Tests if symbol matches the prefix when symbol is split into parts on separator.

Tests if symbol matches the prefix when symbol is split into parts on
separator.
sourceraw docstring

invocation-form->classclj

(invocation-form->class ns form)

Given a form that might be an invocation form (i.e. a list), return the class that is returned, according to the invoked function's var metadata.

Given a form that might be an invocation form (i.e. a list),
return the class that is returned, according to the invoked function's var metadata.
sourceraw docstring

list-jdk9-base-classfilescljmacro

(list-jdk9-base-classfiles)

Because on JDK9+ the classfiles are stored not in rt.jar on classpath, but in modules, we have to do extra work to extract them.

Because on JDK9+ the classfiles are stored not in rt.jar on classpath, but in
modules, we have to do extra work to extract them.
sourceraw docstring

literal->classclj

(literal->class form)

Extracts the class from a literal. This is meant to support interop on strings and Clojure collections.

Extracts the class from a literal.
This is meant to support interop on strings and Clojure collections.
sourceraw docstring

namespaces&files-on-classpathclj

(namespaces&files-on-classpath)

Returns a collection of maps (e.g. {:ns-str "some.ns", :file "some/ns.cljs"}) of all clj/cljc/cljs namespaces obtained by classpath scanning.

Returns a collection of maps (e.g. `{:ns-str "some.ns", :file "some/ns.cljs"}`) of all clj/cljc/cljs namespaces obtained by classpath scanning.
sourceraw docstring

namespaces-on-classpathcljdeprecated

(namespaces-on-classpath)
source

primitive-cacheclj

source

project-resourcesclj

(project-resources)

Returns a list of all non-code files in the current project.

Returns a list of all non-code files in the current project.
sourceraw docstring

resolve-classclj

(resolve-class ns sym)

Tries to resolve a classname from the given symbol, or returns nil if classname can't be resolved.

Tries to resolve a classname from the given symbol, or returns nil
if classname can't be resolved.
sourceraw docstring

resolve-namespaceclj

(resolve-namespace sym ns)

Tries to resolve a namespace from the given symbol, either from a fully qualified name or an alias in the given namespace.

Tries to resolve a namespace from the given symbol, either from a
fully qualified name or an alias in the given namespace.
sourceraw docstring

resource-separatorclj

The path separator used within resources and .jar files.

Note that should always have the same value, regardless of OS.

The path separator used within resources and .jar files.

Note that should always have the same value, regardless of OS.
sourceraw docstring

split-by-leading-literalsclj

(split-by-leading-literals symbol-str)

Meant for symbol-strings that might have leading @, #', or '.

Examples: "@some-atom" => '("@" "some-atom") "@#'a" => '("@#'" "a") "#'some.ns/some-var" => '("#'" "some.ns/some-var")

" @wont-work" => '(nil " @wont-work") "nothing-todo" => '(nil "nothing-todo")

Meant for symbol-strings that might have leading @, #', or '.

Examples:
"@some-atom" => '("@" "some-atom")
"@#'a" => '("@#'" "a")
"#'some.ns/some-var" => '("#'" "some.ns/some-var")

" @wont-work" => '(nil " @wont-work")
"nothing-todo" => '(nil "nothing-todo")
sourceraw docstring

var->classclj

(var->class ns form)

Given a form that may be a var, returns the class that is associated to its :tag or its value (in that precedence order).

Given a form that may be a var, returns the class that is associated
to its :tag or its value (in that precedence order).
sourceraw docstring

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

× close