You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As it was discussed in #977 , the idea would be to add in master a RAII class named Exiv2::Library (or better name) which would take care of allocating/freeing library resources in a RAII fashion. At least we should have there the calls to the XmpParser::initialize() and XmpParser::terminate in case the XMP support is enabled.
The text was updated successfully, but these errors were encountered:
We should investigate this for v1.00. As we have a new API for v1.00, we can "clean up" some of those legacy issues.
I know Andreas was strongly against having a library initialisation function. His argument is that all that an application needs is to include <exiv2/exiv2.hpp> and it can call Exiv2 library functions. And he's right. That will work. However, it's better architecture to have process singleton.
If a developer is using Exiv2 in a large/complex application, he may be unable to modify 'main' to host the singleton. That's regrettable. It's not catastrophic.
The use of the singleton is desirable. It should not be compulsory.
As it was discussed in #977 , the idea would be to add in
master
a RAII class namedExiv2::Library
(or better name) which would take care of allocating/freeing library resources in a RAII fashion. At least we should have there the calls to theXmpParser::initialize()
andXmpParser::terminate
in case the XMP support is enabled.The text was updated successfully, but these errors were encountered: