Search in sources :

Example 1 with DefaultMetaInf

use of org.apache.jackrabbit.vault.fs.config.DefaultMetaInf in project sling by apache.

the class VltUtils method getExportOptions.

public static ExportOptions getExportOptions(WorkspaceFilter filter, String[] packageRoots, String packageGroup, String packageName, String packageVersion, boolean useBinaryReferences) {
    DefaultMetaInf inf = new DefaultMetaInf();
    ExportOptions opts = new ExportOptions();
    inf.setFilter(filter);
    Properties props = new Properties();
    props.setProperty(VaultPackage.NAME_GROUP, packageGroup);
    props.setProperty(VaultPackage.NAME_NAME, packageName);
    props.setProperty(VaultPackage.NAME_VERSION, packageVersion);
    props.setProperty(PackageProperties.NAME_USE_BINARY_REFERENCES, String.valueOf(useBinaryReferences));
    inf.setProperties(props);
    opts.setMetaInf(inf);
    String root = getPackageRoot(filter.getFilterSets(), packageRoots);
    opts.setRootPath(root);
    opts.setMountPath(root);
    return opts;
}
Also used : DefaultMetaInf(org.apache.jackrabbit.vault.fs.config.DefaultMetaInf) ExportOptions(org.apache.jackrabbit.vault.packaging.ExportOptions) Properties(java.util.Properties) PackageProperties(org.apache.jackrabbit.vault.packaging.PackageProperties)

Aggregations

Properties (java.util.Properties)1 DefaultMetaInf (org.apache.jackrabbit.vault.fs.config.DefaultMetaInf)1 ExportOptions (org.apache.jackrabbit.vault.packaging.ExportOptions)1 PackageProperties (org.apache.jackrabbit.vault.packaging.PackageProperties)1