Function: diary-icalendar-parse-entry-type

diary-icalendar-parse-entry-type is a byte-compiled function defined in diary-icalendar.el.gz.

Signature

(diary-icalendar-parse-entry-type)

Documentation

Return the type symbol for the component type used to export an entry.

Default is icalendar-vevent. If the entry is nonmarking and diary-icalendar-export-nonmarking-as-vjournal is non-nil, icalendar-vjournal is returned. If diary-icalendar-todo-regexp is non-nil and the entry matches it, icalendar-vtodo is returned.

If the entry is nonmarking and diary-icalendar-export-nonmarking-entries is nil, nil is returned, indicating that the entry should not be exported.

Source Code

;; Defined in /usr/src/emacs/lisp/calendar/diary-icalendar.el.gz
(defun di:parse-entry-type ()
  "Return the type symbol for the component type used to export an entry.

Default is `icalendar-vevent'.  If the entry is nonmarking and
`diary-icalendar-export-nonmarking-as-vjournal' is non-nil,
`icalendar-vjournal' is returned.  If `diary-icalendar-todo-regexp' is
non-nil and the entry matches it, `icalendar-vtodo' is returned.

If the entry is nonmarking and `diary-icalendar-export-nonmarking-entries'
is nil, nil is returned, indicating that the entry should not be
exported."
  (let (type)
    (goto-char (point-min))
    (unless (and (looking-at-p diary-nonmarking-symbol)
                 (not di:export-nonmarking-entries))
      (setq type 'ical:vevent)
      (when (and (looking-at-p diary-nonmarking-symbol)
                 di:export-nonmarking-as-vjournal)
        (setq type 'ical:vjournal))
      (when (and di:todo-regexp (re-search-forward di:todo-regexp nil t))
        (setq type 'ical:vtodo)))
    type))