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.
35 lines
714 B
35 lines
714 B
import { Component } from "../component";
|
|
|
|
/** @enum {string} */
|
|
export const enumLogicGateType = {
|
|
and: "and",
|
|
not: "not",
|
|
xor: "xor",
|
|
or: "or",
|
|
transistor: "transistor",
|
|
|
|
analyzer: "analyzer",
|
|
rotater: "rotater",
|
|
unstacker: "unstacker",
|
|
cutter: "cutter",
|
|
compare: "compare",
|
|
stacker: "stacker",
|
|
painter: "painter",
|
|
};
|
|
|
|
export class LogicGateComponent extends Component {
|
|
static getId() {
|
|
return "LogicGate";
|
|
}
|
|
|
|
/**
|
|
*
|
|
* @param {object} param0
|
|
* @param {enumLogicGateType=} param0.type
|
|
*/
|
|
constructor({ type = enumLogicGateType.and }) {
|
|
super();
|
|
this.type = type;
|
|
}
|
|
}
|