diff options
Diffstat (limited to 'dslog')
-rw-r--r-- | dslog/PdplogReader.java | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/dslog/PdplogReader.java b/dslog/PdplogReader.java new file mode 100644 index 0000000..0f1fe8e --- /dev/null +++ b/dslog/PdplogReader.java @@ -0,0 +1,28 @@ +package dslog; + +import java.io.IOException; +import java.io.InputStream; +import java.lang.UnsupportedOperationException; + +class DseventsReader { + private final InputStream reader; + + public final int version; + + public DseventsReader(InputStream reader) throws IOException { + this.reader = reader; + this.version = Read.i32(reader); + switch (this.version) { + case 0: // ????-???? + throw new UnsupportedOperationException("PDPLOG version 0 not implemented yet"); + case 1: // ????-2015 + throw new UnsupportedOperationException("PDPLOG version 1 not implemented yet"); + default: + throw new UnsupportedOperationException("Unrecognized PDPLOG version: "+this.version); + } + } + + public void close() throws IOException { + reader.close(); + } +} |