1
0
mirror of https://github.com/quinton-ashley/java2js synced 2024-12-29 10:11:54 +01:00
java2js/jdk/java/io/InputStream.js

22 lines
378 B
JavaScript
Raw Permalink Normal View History

2021-09-24 00:36:29 -05:00
jdk.imports['java.io.InputStream'].load = async () => {
2021-09-23 01:41:44 -05:00
class InputStream {
constructor() {
this.reset();
let _this = this;
2022-02-20 13:52:18 -05:00
if (jdk.log) {
jdk.log.onkeyup = () => {
_this.stream = jdk.log.value;
2021-09-23 19:56:21 -05:00
};
}
2021-09-23 01:41:44 -05:00
}
reset() {
this.stream = '';
this.mark = 0;
}
read(length) {
this.mark += length;
}
}
2021-09-23 23:26:42 -05:00
jdk.java.io.InputStream = InputStream;
2021-09-23 01:41:44 -05:00
};