Hdf proxy resqml22 branch

Hi,

I switched to resqml22 branch.
On the master I use the same hdf_proxy from a representation to write another representation.
For that I use the Uuid of the proxy given by an AbstractRepresentation to access the object using getDataObjectByUuid<>().

On the resqml22 branch this is no longer possible (the Uuid is not longer accessible via a getter).
I attempted to do something as below:

auto* rep = dynamic_cast<resqml2_2::PolylineSetRepresentation*>(obj);
auto factory = std::make_unique<COMMON_NS::HdfProxyFactory>();
auto dor = rep->getHdfProxyDor();
auto hdf_proxy = factory->make(dor);
hdf_proxy->getRelativePath(); // is Empty !

Then, the use of the hdf_proxy object in a pushBack raises an exception: what(): The HDF5 file does not exist or is not a valid HDF5 file.

Do you have any clue ?

Hi Lionel,

I don’t understand why the UUID is not longer accessible via a getter. It still exists getUuid() method in https://github.com/F2I-Consulting/fesapi/blob/resqml22/src/common/AbstractObject.h line 326.
This is clearly a bug if you cannot access the UUID of an HDF proxy. Could you send a code which shows how you try to get the UUID of your known HDF proxy please?

I did this:
hdf_proxy = repo.getDataObjectByUuid<common::AbstractHdfProxy>(rep->getHdfProxyUuid());

where rep is for example a PolylineSetRepresentation

Ok my mistake, I can do
hdf_proxy = repo.getDataObjectByUuid<eml2::AbstractHdfProxy>(rep->getHdfProxyDor().getUuid());

it is just a bit less userfriendly :slight_smile: