@specs-feup/alpakka
Version:
Alpakka is a [LARA Framework](https://github.com/specs-feup/lara-framework) source-to-source compiler for Android's [smali](https://github.com/google/smali) syntax. It enables the analysis and transformation of Android apps through APK files.
26 lines (23 loc) • 579 B
text/typescript
import DotFormatter from "./DotFormatter.js";
import BaseEdge from "../graph/BaseEdge.js";
import BaseNode from "../graph/BaseNode.js";
export default class DefaultDotFormatter extends DotFormatter {
override formatNode(node: BaseNode.Class): DotFormatter.Node {
return {
id: node.id,
attrs: {
label: node.id,
shape: "box",
},
};
}
override formatEdge(edge: BaseEdge.Class): DotFormatter.Edge {
return {
source: edge.source.id,
target: edge.target.id,
attrs: {
label: edge.id,
},
};
}
}