예제 #1
0
        public double DiamondWeightEstimator(DiamondShape diamondShape, DiamondMeasurement dm)
        {
            DiamondCalculations.CalculateWeight dc = new DiamondCalculations.CalculateWeight();

            var weight = dc.CalculateDiamondWeight(diamondShape.ShapeName, dm);

            return((double)weight);
        }
예제 #2
0
        public List <decimal> DiamondVisualWeightEstimator()
        {
            var           d = TestDiamondPart();
            List <string> EstimatedDepth = new List <string>()
            {
                "Shallow", "Ideal", "Deep"
            };

            var ListOfWeights = new List <decimal>();

            DiamondCalculations.CalculateWeight dc = new DiamondCalculations.CalculateWeight();

            foreach (string depth in EstimatedDepth)
            {
                ListOfWeights.Add(dc.CalculateDiamondWeight(d.DiamondShape.ShapeName, d.DiamondMeasurement.DiamondDiameterMeasurements.ToList(), depth));
            }

            return(ListOfWeights);
        }