Skip to content

Commit 7e003f5

Browse files
committed
snaploader-examples: applied API changes
1 parent 125a95b commit 7e003f5

File tree

3 files changed

+5
-6
lines changed

3 files changed

+5
-6
lines changed

snaploader-examples/src/main/java/electrostatic4j/snaploader/examples/TestBasicFeatures.java

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
public final class TestBasicFeatures {
5151

5252
protected static final LibraryInfo libraryInfo = new LibraryInfo(getJarFilePath(),
53-
"lib/placeholder",
53+
new DirectoryPath(DefaultDynamicLibraries.LINUX_X86.getPlatformDirectory()),
5454
getLibraryBaseName(),
5555
getLibrariesAbsolutePath());
5656

@@ -95,9 +95,8 @@ protected static DirectoryPath getLibrariesAbsolutePath() {
9595
return new DirectoryPath(PropertiesProvider.USER_DIR.getSystemProperty(), "libs");
9696
}
9797

98-
protected static String getJarFilePath() {
99-
return getLibrariesAbsolutePath().getPath() +
100-
PropertiesProvider.FILE_SEPARATOR.getSystemProperty() + getJarFile();
98+
protected static DirectoryPath getJarFilePath() {
99+
return new DirectoryPath(getLibrariesAbsolutePath().getPath(), getJarFile());
101100
}
102101

103102
protected static String getNativeDynamicLibraryPath() {

snaploader-examples/src/main/java/electrostatic4j/snaploader/examples/TestBasicFeatures2.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ public static void main(String[] args) throws Exception {
5959
final Path extractionPath = Files.createDirectories(Paths.get(PropertiesProvider.USER_DIR.getSystemProperty(), "libs",
6060
NativeVariant.OS_NAME.getProperty(), NativeVariant.OS_ARCH.getProperty()));
6161

62-
final LibraryInfo libraryInfo = new LibraryInfo(compressionPath.toString(), "lib/placeholder",
62+
final LibraryInfo libraryInfo = new LibraryInfo(new DirectoryPath(compressionPath.toString()), new DirectoryPath("lib/placeholder"),
6363
"jmealloc", new DirectoryPath(extractionPath.toString()));
6464

6565
final NativeDynamicLibrary[] libraries = new NativeDynamicLibrary[] {

snaploader-examples/src/main/java/electrostatic4j/snaploader/examples/TestFilesystemException.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ public static void main(String[] args) throws Exception {
2121
final Path extractionPath = Files.createDirectories(Paths.get(PropertiesProvider.USER_DIR.getSystemProperty(), "libs",
2222
NativeVariant.OS_NAME.getProperty(), NativeVariant.OS_ARCH.getProperty()));
2323

24-
final LibraryInfo libraryInfo = new LibraryInfo(compressionPath.toString(), "lib/placeholder",
24+
final LibraryInfo libraryInfo = new LibraryInfo(new DirectoryPath(compressionPath.toString()), new DirectoryPath("lib/placeholder"),
2525
"jme3alloc", new DirectoryPath(extractionPath.toString()));
2626

2727
final NativeDynamicLibrary[] libraries = new NativeDynamicLibrary[] {

0 commit comments

Comments
 (0)