mirror of
https://github.com/2OOP/pism.git
synced 2026-02-04 10:54:51 +00:00
New assetManager
This commit is contained in:
24
framework/src/main/java/org/toop/framework/assets/Asset.java
Normal file
24
framework/src/main/java/org/toop/framework/assets/Asset.java
Normal file
@@ -0,0 +1,24 @@
|
||||
package org.toop.framework.assets;
|
||||
|
||||
import org.toop.framework.SnowflakeGenerator;
|
||||
|
||||
import java.nio.file.Path;
|
||||
|
||||
public class Asset {
|
||||
private Long id;
|
||||
private String name;
|
||||
private Path assetPath;
|
||||
private String asset;
|
||||
|
||||
public Asset(String name, Path assetPath) {
|
||||
this.id = new SnowflakeGenerator().nextId();
|
||||
this.name = name;
|
||||
this.assetPath = assetPath;
|
||||
}
|
||||
|
||||
private void loadAsset() {
|
||||
java.nio.file.Path
|
||||
this.asset = this.assetPath;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
package org.toop.framework.assets;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
public class AssetManager {
|
||||
|
||||
private HashMap<Long, Asset> assets = new HashMap<>();
|
||||
|
||||
public AssetManager() {
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user