with-tramp-file-property

with-tramp-file-property is a Lisp macro in `tramp.el'.

(with-tramp-file-property VEC FILE PROPERTY &rest BODY)

Check in Tramp cache for PROPERTY, otherwise execute BODY and set cache.
FILE must be a local file name on a connection identified via VEC.