Function: org-babel-java-val-to-base-type

org-babel-java-val-to-base-type is a byte-compiled function defined in ob-java.el.gz.

Signature

(org-babel-java-val-to-base-type VAL)

Documentation

Determine the base type of VAL.

VAL may be integerp if all base values are integers floatp if all base values are either floating points or integers stringp otherwise.

Source Code

;; Defined in /usr/src/emacs/lisp/org/ob-java.el.gz
(defun org-babel-java-val-to-base-type (val)
  "Determine the base type of VAL.
VAL may be
`integerp' if all base values are integers
`floatp' if all base values are either floating points or integers
`stringp' otherwise."
  (cond
   ((integerp val) 'integerp)
   ((floatp val) 'floatp)
   ((or (listp val) (vectorp val))
    (let ((type nil))
      (mapc (lambda (v)
              (pcase (org-babel-java-val-to-base-type v)
                (`stringp (setq type 'stringp))
                (`floatp
                 (when (or (not type) (eq type 'integerp))
                   (setq type 'floatp)))
                (`integerp
                 (unless type (setq type 'integerp)))))
            val)
      type))
   (t 'stringp)))