package gve.calc.logic; import gve.calc.packaging.*; import gve.calc.formula.*; public class PackageInfo extends PackageDescriptor { public PackageInfo() {} public PartDescriptor [] getParts() { PartDescriptor [] result = { new TableauPartInfo(), new ProofInfo() }; return result; } } class TableauPartInfo extends PartDescriptor { public TableauPartInfo() { super("Tableau"); } public Part genNew() { return new TableauPart(new Identifier(""),new Identifier("")); } } class ProofInfo extends PartDescriptor { public ProofInfo() { super("Proof"); } public void generateNew(Part dummy,FormulaView view) { Formula f = view.getFormula(); Identifier ident; Proof prf = new Proof(ident = new Identifier()); f.replace(dummy,prf); view.setCursorPart(ident); } }