@specs-feup/alpakka
Version:
A Smali/APK source-to-source compiler written in Typescript
43 lines • 1.29 kB
JavaScript
import InstructionNode from "./InstructionNode.js";
var GotoNode;
(function (GotoNode) {
class Class extends InstructionNode.Class {
get jp() {
return this.scratchData.$jp;
}
}
GotoNode.Class = Class;
class Builder extends InstructionNode.Builder {
constructor($jp) {
super(InstructionNode.Type.GOTO, $jp);
}
buildData(data) {
return {
...super.buildData(data),
};
}
buildScratchData(scratchData) {
return {
...super.buildScratchData(scratchData),
};
}
}
GotoNode.Builder = Builder;
GotoNode.TypeGuard = {
isDataCompatible(data) {
if (!InstructionNode.TypeGuard.isDataCompatible(data))
return false;
const d = data;
if (d.instructionFlowNodeType !== InstructionNode.Type.GOTO)
return false;
return true;
},
isScratchDataCompatible(scratchData) {
if (!InstructionNode.TypeGuard.isScratchDataCompatible(scratchData))
return false;
return true;
},
};
})(GotoNode || (GotoNode = {}));
export default GotoNode;
//# sourceMappingURL=GotoNode.js.map