Function: secrets-get-attributes

secrets-get-attributes is an autoloaded and byte-compiled function defined in secrets.el.gz.

Signature

(secrets-get-attributes COLLECTION ITEM)

Documentation

Return the lookup attributes of item labeled ITEM in COLLECTION.

If there are several items labeled ITEM, it is undefined which one is returned. If there is no such item, or the item has no attributes, return nil.

ITEM can also be an object path, which is used if contained in COLLECTION.

Source Code

;; Defined in /usr/src/emacs/lisp/net/secrets.el.gz
(defun secrets-get-attributes (collection item)
  "Return the lookup attributes of item labeled ITEM in COLLECTION.
If there are several items labeled ITEM, it is undefined which
one is returned.  If there is no such item, or the item has no
attributes, return nil.

ITEM can also be an object path, which is used if contained in COLLECTION."
  (let ((item-path (secrets-item-path collection item)))
    (unless (secrets-empty-path item-path)
      (mapcar
       (lambda (attribute)
	 (cons (intern (concat ":" (car attribute))) (cadr attribute)))
       (dbus-get-property
	:session secrets-service item-path
	secrets-interface-item "Attributes")))))