public void setInsideRibbon(IRibbonLike insideRibbon) { nextRibbonInward = insideRibbon; }
private void testAribbonOffset(int pglGroupingIndex, bool outsideRibbonOrNot, int ribbonIndex, double station, double expectedValue) { Profile offsetProfile = null; double? testDbl = 0.0; double actualValue; testPGLgrouping = testCorridor.allPGLgroupings[pglGroupingIndex]; if (outsideRibbonOrNot == true) testRibbon = testPGLgrouping.outsideRibbons.ToList()[ribbonIndex]; else testRibbon = testPGLgrouping.insideRibbons.ToList()[ribbonIndex]; offsetProfile = testRibbon.getOffsetProfile(); testDbl = offsetProfile.getElevation((CogoStation) station); if (testDbl == null) throw new NullReferenceException(); else actualValue = (double) testDbl; Assert.AreEqual(expectedValue, actualValue, 0.00001); //Assert.AreNotEqual(expectedValue, actualValue, 0.00001); }
// public HorizontalAlignment horizAlignment { get; set; } public void addOutsideRibbon(IRibbonLike newOutsideRibbon) { IRibbonLike nextInnerRibbon = this.thePGLoffsetRibbon; if (outsideRibbons == null) outsideRibbons = new LinkedList<IRibbonLike>(); else { nextInnerRibbon = outsideRibbons.Last(); } newOutsideRibbon.setMyIndex(outsideRibbons.Count); newOutsideRibbon.setMyProgressionDirection(new rm21Side(this.myIndex, 1)); outsideRibbons.AddLast(newOutsideRibbon); newOutsideRibbon.setInsideRibbon(nextInnerRibbon); newOutsideRibbon.setPGLgroupingParent(this); }