Functions and utilities for source implementations.
Functions and utilities for source implementations.
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.
(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.
(flush-caches)
Removes all cached values, forcing functions that depend on
with-classpath-cache
to recalculate.
Removes all cached values, forcing functions that depend on `with-classpath-cache` to recalculate.
(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.
(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.
(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.
(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.
(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.
(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.
(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.
(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.
(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.
(root-packages-on-classpath)
Return a set of all classname "TLDs" on the classpath.
Return a set of all classname "TLDs" on the classpath.
(split-by-leading-literals symbol-str)
Separate quote/var/deref qualifiers from a var name.
Separate quote/var/deref qualifiers from a var name.
(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).
(with-classpath-cache 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.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close