ResearchObject / ro-crate-py

Python library for RO-Crate
https://pypi.org/project/rocrate/
Apache License 2.0
46 stars 23 forks source link

dump the metadata of the RO-Crate #153

Closed hakor closed 1 year ago

hakor commented 1 year ago

hi all

I just started with RO Crate using jupyter notebooks. First steps with RO Crate and interaction with Invenio work fine.

Two questions:

Thanks for support!

simleo commented 1 year ago
  • is there a dokumentation about the methods somewhere online? I did not find any documentation like a "good old JAVA Doc" style.

All the documentation is in the top-level README file. There are also some docstrings in the code, but not for everything.

  • Is there a simple method to dump the current metadata of the RO Crate? ROC.dump() and I got the LD-JSON on screen! Would be create for understanding.
import json
print(json.dumps(crate.metadata.generate(), indent=4))

where crate is an ROCrate object.