#include <fileformat.h>
FileFormatInterface allows to implement and register file formats with its detection algorithm. The FileFormats registry allows to register any format (e.g. FileFormats::Browsable, FileFormats::ImageJpg...).
Public Member Functions | |
MAXON_METHOD Result< Bool > | Detect (const Url &url, const InputStreamRef &probeStream, FILEFORMATDETECTIONFLAGS flags) const |
Private Member Functions | |
MAXON_INTERFACE (FileFormatInterface, MAXON_REFERENCE_CONST, "net.maxon.interface.fileformat") | |
Result< void > | SetData (ForwardingDataPtr &&key, Data &&data)=delete |
|
private |
|
privatedelete |
MAXON_METHOD Result<Bool> Detect | ( | const Url & | url, |
const InputStreamRef & | probeStream, | ||
FILEFORMATDETECTIONFLAGS | flags | ||
) | const |
For implementations to check if a given url/stream supports this file format. You should never call this function directly. It's triggered by FileFormatDetectionInterface::Detect()/DetectAll().
[in] | url | Url to check. |
[in] | probeStream | Optional parameter that allows to read content in case that the url is a file. This stream is not a plain file stream but wraps a memory cache stream which allows to seek and read already loaded data without overhead. |
[in] | flags | see FILEFORMATDETECTIONFLAGS. |