Function: org-id-time-to-b36

org-id-time-to-b36 is a byte-compiled function defined in org-id.el.gz.

Signature

(org-id-time-to-b36 &optional TIME)

Documentation

Encode TIME as a 12-digit string.

This string holds the time to micro-second accuracy, and can be decoded using org-id-decode.

Source Code

;; Defined in /usr/src/emacs/lisp/org/org-id.el.gz
(defun org-id-time-to-b36 (&optional time)
  "Encode TIME as a 12-digit string.
This string holds the time to micro-second accuracy, and can be decoded
using `org-id-decode'."
  ;; FIXME: If TIME represents N seconds after the epoch, then
  ;; this encoding assumes 0 <= N < 110075314176 = (* (expt 36 4) 65536),
  ;; i.e., that TIME is from 1970-01-01 00:00:00 to 5458-02-23 20:09:36 UTC.
  (setq time (org-time-convert-to-list nil))
  (concat (org-id-int-to-b36 (nth 0 time) 4)
	  (org-id-int-to-b36 (nth 1 time) 4)
	  (org-id-int-to-b36 (nth 2 time) 4)))