Heat REST API contains operations for both stack abandoning (deletes a stack but leaves its resources intact, and returns data that describes the stack and its resources) and adoption (creates a stack from existing resources)
See:
https://developer.openstack.org/api-ref/orchestration/v1/#abandon-stack
and
https://developer.openstack.org/api-ref/orchestration/v1/#adopt-stack
It would be nice to have support for these operations in OpenStack4J as well.