Beispiel #1
0
        public static TableFamily FindOrCreate(double length, double width, double height, double top_thickness, double leg_thickness)
        {
            var         tuple  = Tuple.Create(length, width, height, top_thickness, leg_thickness);
            TableFamily family = null;

            if (!familyInstances.TryGetValue(tuple, out family))
            {
                family = new TableFamily {
                    length = length, width = width, height = height, top_thickness = top_thickness, leg_thickness = leg_thickness
                };
                familyInstances.Add(tuple, family);
            }
            return(family);
        }
Beispiel #2
0
        public static TableChairFamily FindOrCreate(TableFamily tableFamily, ChairFamily chairFamily,
                                                    int chairsOnTop, int chairsOnBottom, int chairsOnRight, int chairsOnLeft, double spacing)
        {
            var tuple = Tuple.Create(tableFamily, chairFamily, chairsOnTop, chairsOnBottom, chairsOnRight, chairsOnLeft, spacing);
            TableChairFamily family = null;

            if (!familyInstances.TryGetValue(tuple, out family))
            {
                family = new TableChairFamily {
                    tableFamily   = tableFamily, chairFamily = chairFamily,
                    chairsOnTop   = chairsOnTop, chairsOnBottom = chairsOnBottom,
                    chairsOnRight = chairsOnRight, chairsOnLeft = chairsOnLeft,
                    spacing       = spacing
                };
                familyInstances.Add(tuple, family);
            }
            return(family);
        }
Beispiel #3
0
 public void wTableFamily(TableFamily f) => wBIMFamily(f);