While crawling directories for data, LuciadFusion also searches for metadata files next to the data files. By default, LuciadFusion searches for ISO 19139 XML metadata files with the same name as the data file, but with an XML extension. If it finds metadata files, LuciadFusion monitors them: if the metadata files have been updated, it crawls the directory again, and refreshes the metadata. If it doesn’t find such metadata files, LuciadFusion generates the metadata based on the TLcdModelMetadata of the data model.

If you want to use your own metadata file format, you must start by implementing the ILcdMetadataDecoder interface and annotate it as a @LcdService so that LuciadFusion can find you custom decoder. Make sure to override the findAndDecodeMetadata method so that LuciadFusion knows which metadata files to monitor for changes.

The metadata returned from the decoder doesn’t have to be complete. LuciadFusion fills in the missing information based on the TLcdModelMetadata of the data model for which the metadata was decoded.

For more information about implementing an ILcdMetadataDecoder, see the Support a custom metadata format tutorial in the LuciadLightspeed documentation. It illustrates the creation of a custom ILcdMetadataDecoder.