Package: BundleLocationUtil

BundleLocationUtil

nameinstructionbranchcomplexitylinemethod
BundleLocationUtil()
M: 3 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%
createInstallLocation(File, File)
M: 10 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%
getRelativisedURI(File, File)
M: 6 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%

Coverage

1: package org.eclipse.virgo.nano.deployer.util;
2:
3: import java.io.File;
4: import java.net.URI;
5:
6: public class BundleLocationUtil {
7:
8: public static final String REFERENCE_FILE_PREFIX = "reference:file:";
9:
10: public static String createInstallLocation(final File kernelHomeFile, final File archiveFile) {
11: return REFERENCE_FILE_PREFIX + getRelativisedURI(kernelHomeFile, archiveFile);
12: }
13:
14: public static URI getRelativisedURI(final File kernelHomeFile, final File archiveFile) {
15: return kernelHomeFile.toURI().relativize(archiveFile.toURI());
16: }
17: }