public void SegmentTime_SetSpan_EndMoreMax() { SegmentTime segmentTime = new SegmentTime(); segmentTime.SetSegment(DateTime.MaxValue, DateTime.MaxValue); Panel_InterfaceSegment <DateTime, TimeSpan> .SetSpan(segmentTime, TimeSpan.MaxValue, DateTime.MaxValue); }
public void SegmentTime_SetSpan_Negate() { SegmentTime segmentTime = new SegmentTime(); segmentTime.SetSegment(_label_1, _label_2); Panel_InterfaceSegment <DateTime, TimeSpan> .SetSpan(segmentTime, _spanTickNegate, _label_2); }
public void SegmentDouble_StartState_Reverse() { SegmentDouble segmentDirect = new SegmentDouble( Panel_SegmentDouble.Label_2, Panel_SegmentDouble.Label_1); Panel_InterfaceSegment <Double, Double> .AssertState(segmentDirect, Panel_SegmentDouble.Label_2, Panel_SegmentDouble.Label_2); }
public void SegmentTime_SetSpan_Max() { _label_1 = DateTime.MaxValue - _spanTick; SegmentTime segmentTime = new SegmentTime(); segmentTime.SetSegment(_label_1, _label_1); Panel_InterfaceSegment <DateTime, TimeSpan> .SetSpan(segmentTime, _spanTick, DateTime.MaxValue); }
public void SegmentDoubleRound_SetSegment_Round_RounderNull() { SegmentRoundDouble segmentRound = new SegmentRoundDouble(_segmentOriginal, null); segmentRound.SetSegment(_label_1, _label_2); Panel_InterfaceSegment <Double, Double> .SetSegment(segmentRound, _label_1, _label_2); Assert.IsTrue(segmentRound.StartRoundValue == _label_1); Assert.IsTrue(segmentRound.EndRoundValue == _label_2); }
public static void GetSpanAfterSetSegment(ISegment <Int32, Int32> segment) { Panel_InterfaceSegment <Int32, Int32> .GetSpanAfterSetSegment(segment, 1, 1, 1); Panel_InterfaceSegment <Int32, Int32> .GetSpanAfterSetSegment(segment, 2, 4, 3); Panel_InterfaceSegment <Int32, Int32> .GetSpanAfterSetSegment(segment, -1, -1, 1); Panel_InterfaceSegment <Int32, Int32> .GetSpanAfterSetSegment(segment, -4, -2, 3); }
public static void GetSpanAfterSetSegment(ISegment <Double, Double> segmentDouble) { Panel_InterfaceSegment <Double, Double> .GetSpanAfterSetSegment(segmentDouble, 0.0, 0.0, 0.0); Panel_InterfaceSegment <Double, Double> .GetSpanAfterSetSegment(segmentDouble, 1.0, 4.0, 3.0); Panel_InterfaceSegment <Double, Double> .GetSpanAfterSetSegment(segmentDouble, -1.0, -1.0, 0.0); Panel_InterfaceSegment <Double, Double> .GetSpanAfterSetSegment(segmentDouble, -4.0, -1.0, 3.0); }
public void SegmentDoubleRound_SetSegment_Round() { _segmentRound.SetSegment(_label_1, _label_2); Panel_InterfaceSegment <Double, Double> .SetSegment(_segmentRound, _label_1, _label_2); Double etalonStartRound = _rounder.Round(_label_1); Double etalonEndRound = _rounder.Round(_label_2); Assert.IsTrue(_segmentRound.StartRoundValue == etalonStartRound); Assert.IsTrue(_segmentRound.EndRoundValue == etalonEndRound); }
public void SegmentTime_GetSpanAfterSetSegment() { SegmentTime segment = new SegmentTime(); Panel_InterfaceSegment <DateTime, TimeSpan> .GetSpanAfterSetSegment(segment, _label_1, _label_1, TimeSpan.Zero); DateTime startDay = new DateTime(2016, 1, 1); DateTime startNextDay = new DateTime(2016, 1, 2); TimeSpan spanDay = new TimeSpan(1, 0, 0, 0); Panel_InterfaceSegment <DateTime, TimeSpan> .GetSpanAfterSetSegment(segment, startDay, startNextDay, spanDay); }
public void SegmentInt_Shift() { SegmentInt segmentMax = new SegmentInt(Int32.MinValue, Int32.MaxValue); Panel_InterfaceSegment <Int32, Int32> .ShiftMax(segmentMax, 1); Panel_InterfaceSegment <Int32, Int32> .ShiftMax(segmentMax, -1); SegmentInt segmentLeftMin = new SegmentInt(Int32.MinValue, Int32.MaxValue - 1); SegmentInt segmentRightMax = new SegmentInt(Int32.MinValue + 1, Int32.MaxValue); Panel_InterfaceSegment <Int32, Int32> .Shift(segmentLeftMin, 1, segmentRightMax); Panel_InterfaceSegment <Int32, Int32> .Shift(segmentRightMax, -2, segmentLeftMin); }
public void SegmentDouble_Shift() { SegmentDouble segmentMax = new SegmentDouble(double.MinValue, double.MaxValue); Panel_InterfaceSegment <double, double> .ShiftMax(segmentMax, 1.0); Panel_InterfaceSegment <double, double> .ShiftMax(segmentMax, -1.0); SegmentDouble segmentLeftMin = new SegmentDouble(double.MinValue, double.MaxValue - 1.0); SegmentDouble segmentRightMax = new SegmentDouble(double.MinValue + 1.0, double.MaxValue); Panel_InterfaceSegment <double, double> .Shift(segmentLeftMin, 1.0, segmentRightMax); Panel_InterfaceSegment <double, double> .Shift(segmentRightMax, -2.0, segmentLeftMin); }
public void SegmentTime_Shift() { TimeSpan one = new TimeSpan(1); TimeSpan two = new TimeSpan(2); SegmentTime segmentMax = new SegmentTime(DateTime.MinValue, DateTime.MaxValue); Panel_InterfaceSegment <DateTime, TimeSpan> .ShiftMax(segmentMax, one); Panel_InterfaceSegment <DateTime, TimeSpan> .ShiftMax(segmentMax, one.Negate()); SegmentTime segmentLeftMin = new SegmentTime(DateTime.MinValue, DateTime.MaxValue - one); SegmentTime segmentRightMax = new SegmentTime(DateTime.MinValue + one, DateTime.MaxValue); Panel_InterfaceSegment <DateTime, TimeSpan> .Shift(segmentLeftMin, one, segmentRightMax); Panel_InterfaceSegment <DateTime, TimeSpan> .Shift(segmentRightMax, two.Negate(), segmentLeftMin); }
public void SegmentTime_IsPoint() { SegmentTime segmentInt = new SegmentTime(); Panel_InterfaceSegment <DateTime, TimeSpan> .IsPoint(segmentInt, _label_1, _label_2); }
public static void SetSegment_ReverseLabel(ISegment <Int32, Int32> segment) { Panel_InterfaceSegment <Int32, Int32> .SetSegment_ReverseLabel(segment, Label_2, Label_1); }
public static void SetSegment(ISegment <Int32, Int32> segment) { Panel_InterfaceSegment <Int32, Int32> .SetSegment(segment, Label_1, Label_2); }
public void SegmentInt_SetSpan_Max() { SegmentInt segmentInt = new SegmentInt(_label_1, _label_1); Panel_InterfaceSegment <Int32, Int32> .SetSpan(segmentInt, Int32.MaxValue, Int32.MaxValue); }
public static void StartState(ISegment <Int32, Int32> segment) { Panel_InterfaceSegment <Int32, Int32> .StartState_Empty(segment); }
public void SegmentInt_IsPoint() { SegmentInt segmentInt = new SegmentInt(); Panel_InterfaceSegment <Int32, Int32> .IsPoint(segmentInt, _label_1, _label_2); }
public void SegmentInt_SetSpan_One() { SegmentInt segmentInt = new SegmentInt(_label_1, _label_2); Panel_InterfaceSegment <Int32, Int32> .SetSpan(segmentInt, _label_1, _label_1); }
public static void StartState_Empty(ISegment <Double, Double> segmentDouble) { Panel_InterfaceSegment <Double, Double> .StartState_Empty(segmentDouble); }
public void SegmentInt_StartState_Reverse() { SegmentInt segmentInt = new SegmentInt(Panel_SegmentInt.Label_2, Panel_SegmentInt.Label_1); Panel_InterfaceSegment <Int32, Int32> .AssertState(segmentInt, Panel_SegmentInt.Label_2, Panel_SegmentInt.Label_2); }
public static void SetReverseLabel(ISegment <Double, Double> segmentDouble) { Panel_InterfaceSegment <Double, Double> .SetSegment_ReverseLabel(segmentDouble, _label_2, _label_1); }
public void SegmentInt_SetSpan_EndMoreMax() { SegmentInt segmentInt = new SegmentInt(Int32.MaxValue, Int32.MaxValue); Panel_InterfaceSegment <Int32, Int32> .SetSpan(segmentInt, _label_2, Int32.MaxValue); }
public void SegmentTime_SetReverseLabel() { SegmentTime segmentInt = new SegmentTime(); Panel_InterfaceSegment <DateTime, TimeSpan> .SetSegment_ReverseLabel(segmentInt, _label_2, _label_1); }
public static void IsPoint(ISegment <Double, Double> segmentDouble) { Panel_InterfaceSegment <Double, Double> .IsPoint(segmentDouble, _label_1, _label_2); }
public void SegmentTime_StartState() { SegmentTime segmentTime = new SegmentTime(); Panel_InterfaceSegment <DateTime, TimeSpan> .StartState_Empty(segmentTime); }
public static void SetSpan_EndMoreMax(ISegment <Double, Double> segmentDouble) { segmentDouble.SetSegment(Double.MaxValue, Double.MaxValue); Panel_InterfaceSegment <Double, Double> .SetSpan(segmentDouble, _label_1, Double.MaxValue); }
public static void SetSpan(ISegment <Double, Double> segmentDouble) { Panel_InterfaceSegment <Double, Double> .SetSpan(segmentDouble, _label_1, _label_1); }