Added several small improvements

This commit is contained in:
Robert Vokac 2024-08-31 20:56:09 +02:00
parent 438fbfaeeb
commit fde7655e0b
No known key found for this signature in database
GPG Key ID: C459E1E4B4A986BB
4 changed files with 18 additions and 4 deletions

View File

@ -41,7 +41,7 @@ public class ConfigDef {
.filter(l -> !l.trim().startsWith(HASH_CHARACTER))
.filter(l -> l.contains(EQUALS_CHARACTER))
.forEach(line -> {
String[] array = line.split("=");
String[] array = line.split(EQUALS_CHARACTER);
String key = array[0];
String value = array[1];
map.put(key, value);

View File

@ -36,8 +36,8 @@ public interface Storage {
cd("/");
mkdir("home");
cd("home");
mkdir("openeggbert");
cd("openeggbert");
mkdir(uname());
cd(uname());
return "";
}
@ -74,6 +74,8 @@ public interface Storage {
public String touch(String name);
public boolean rm(String name);
public boolean rmdir(String dirname);
public String cp(String source, String target);
@ -96,5 +98,8 @@ public interface Storage {
public String debug();
public void flush();
default String uname() {return OPENEGGBERT;}
static final String OPENEGGBERT = "openeggbert";
}

View File

@ -19,7 +19,6 @@
///////////////////////////////////////////////////////////////////////////////////////////////
package com.openeggbert.gdx.storage.filesystem;
import com.badlogic.gdx.Application;
import com.openeggbert.core.fbox.entity.Platform;
import com.openeggbert.gdx.storage.Storage;
import java.util.List;
@ -127,4 +126,9 @@ public abstract class DesktopAndroidStorage implements Storage {
public void flush() {
//nothing to do
}
@Override
public boolean rmdir(String dirname) {
throw new UnsupportedOperationException("Not supported yet."); // Generated from nbfs://nbhost/SystemFileSystem/Templates/Classes/Code/GeneratedMethodBody
}
}

View File

@ -339,4 +339,9 @@ public class MapStorage implements Storage {
map.flush();
}
@Override
public boolean rmdir(String dirname) {
throw new UnsupportedOperationException("Not supported yet."); // Generated from nbfs://nbhost/SystemFileSystem/Templates/Classes/Code/GeneratedMethodBody
}
}