public Base generatePaperBase(String type) { Base paperBase = new Base(0, 0, type); if (type == "bottom") { for (int i = 0; i < this.ribNum; i++) { int after = i + 1; if (i == this.ribNum) { after = 0; } DCHalfEdge outerBottomCircle = new DCHalfEdge( new CompPoint(xMainTop[rib.bottomNotchPos][i], zMainTop[rib.bottomNotchPos][i]), new CompPoint( xMainTop[rib.bottomNotchPos][after], zMainTop[rib.bottomNotchPos][after])); paperBase.addHalfEdge(outerBottomCircle); } double tabWidth = -50; paperBase.largeTabs(tabWidth); paperBase.generateHole(bottomHoleWidth / 2); } if (type == "top") { for (int i = 0; i < this.ribNum; i++) { int after = i + 1; if (i == this.ribNum) { after = 0; } DCHalfEdge outerTopCircle = new DCHalfEdge( new CompPoint(xMainTop[rib.topNotchPos][i], zMainTop[rib.topNotchPos][i]), new CompPoint(xMainTop[rib.topNotchPos][after], zMainTop[rib.topNotchPos][after])); paperBase.addHalfEdge(outerTopCircle); } double tabWidth = -50; paperBase.largeTabs(tabWidth); paperBase.generateHole(topHoleWidth / 2); } return paperBase; }