How do I add custom namespace properties in XMP metadata when generating/converting to PDF/A?

Q:

For PDF/A conversion we rely on ‘pdftron.PDF.PDFA.PDFACompliance’ from PDFTron PDFNet SDK.

The conversion works great, however I would like to be able to add some custom properties / metadata (i.e. extended XMP metadata in a custom namespace ).

a) Load initla XMP metadata from PDF (see https://groups.google.com/d/msg/pdfnet-sdk/9IOo9GhDUbg/QyrE192IK4MJ).

b) Convert to PDF/A

c) Overwrite the original metadata with your own version (this is also covered in the above article).

Note:

The problem is that PDF/A 1 - does not support compressed PDF streams, so failing to use the flag could introduce compatibility issue relared to ‘compressed object streams’