You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
28 lines
537 B
28 lines
537 B
package mightypork.util.files.ion.templates;
|
|
|
|
|
|
import java.io.IOException;
|
|
import java.io.InputStream;
|
|
import java.io.OutputStream;
|
|
import java.util.HashMap;
|
|
|
|
import mightypork.util.files.ion.Ion;
|
|
import mightypork.util.files.ion.Ionizable;
|
|
|
|
|
|
public abstract class IonizableHashMap<K, V> extends HashMap<K, V> implements Ionizable {
|
|
|
|
@Override
|
|
public void load(InputStream in) throws IOException
|
|
{
|
|
Ion.readMap(in, this);
|
|
}
|
|
|
|
|
|
@Override
|
|
public void save(OutputStream out) throws IOException
|
|
{
|
|
Ion.writeMap(out, this);
|
|
}
|
|
|
|
}
|
|
|