All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.bdeploy.bhive.objects.DefaultReferenceHandler Maven / Gradle / Ivy

Go to download

Public API including dependencies, ready to be used for integrations and plugins.

There is a newer version: 7.3.6
Show newest version
package io.bdeploy.bhive.objects;

import java.nio.file.Path;

import io.bdeploy.bhive.model.Manifest;
import io.bdeploy.bhive.model.Tree.Key;

/**
 * Default reference handler which recursively exports {@link Manifest} references inline in the referencing location.
 */
public class DefaultReferenceHandler implements ReferenceHandler {

    private final ObjectManager om;

    public DefaultReferenceHandler(ObjectManager om) {
        this.om = om;
    }

    @Override
    public void onReference(Path location, Key key, Manifest referenced) {
        om.exportTree(referenced.getRoot(), location.resolve(key.getName()), this);
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy