You're viewing version 1.2.0 of name. The latest stable version of Clojure Core is 1.3.0.
1.2.0 Arrow_down_16x16
  • (name x)
Returns the name String of a string, symbol or keyword.

1 Example top

  • user=> (name :x)
    "x"
    user=> (name "x")
    "x"
    user=> (name 'x)
    "x"
Log in to add / edit an example.

See Also top

Log in to add a see also.

Plus_12x12 Minus_12x12 Source clojure/core.clj:1240 top

(defn name
  "Returns the name String of a string, symbol or keyword."
  {:tag String
   :added "1.0"}
  [^clojure.lang.Named x]
  (if (string? x) x (. x (getName))))
Vars in clojure.core/name: defn string?
Used in 134 other vars (expand)
fn defstruct import symbol defrecord proxy-super memfn definline defn- intern ns defn defmacro deftype defmulti proxy keyword defonce defprotocol print-special-doc doc old-table-model deftest- deftest run-all-tests inc-report-counter set-test start-element emit-element defmacro- defvar- defvar defunbound- defunbound defonce- defalias defstruct- build-source-cell get-cells get-old-value get-cell get-values cell get-value build-standard-cell add-index ensure-relation add-relation is-query-var? is-var? as-str wall-hack-method wall-hack-field set-system-properties build-attribute-info as-str attributes deftemplate domonad defmonad defmonadfn pprint-simple-default pprint-code-symbol prof print-summary set-system-properties get-field call-method set-repl-name print-repl-info drop-table get-connection create-table defst deftest- deftest run-all-tests inc-report-counter set-test find-holes tracer trace deftrace trace-fn-call create-font define-ant-task set-properties! instantiate-task env defproject make-dependency help tasks new make-exclusion make-mailing-list make-license defconfig defn! deftemplate defsnippets defsnippet defslimefn slime-fn maybe-ns xref unmunge describe-definition-for-emacs locals-for-emacs add-restart-if thread-set-name connection-info apropos-list-for-emacs potential-classes potential-var-public potential-var potential-ns swank-require defhook swank-ns? compile-swank register-dispatch has-identity? memfn-varargs when-feature add-identity open-channel defcontract contract defconstrainedfn auto-setters icon-setters kw-to-setter set-constraint!

Comments top

No comments for name. Log in to add a comment.