key property
A name that identifies the source of the document.
PdfDocument is cached based on the PdfDocumentRefKey. If you create multiple PdfDocumentRefs with the same key, they share the same PdfDocumentListenable and thus the same PdfDocument instance.
By default, the key is created from the source name (for example, file path or URI) of the document. But it may be insufficient to identify the document uniquely in some cases. For example, if the document is not only identified by the URI but also by some HTTP headers (for example, authentication/authorization headers), you should create a custom key that includes the headers as well.
Implementation
final PdfDocumentRefKey key;