Exemplo n.º 1
0
        public TrunkSizeChecker(LuggageList luggageList, IContainer trunk)
        {
            if (luggageList == null || trunk == null)
            {
                throw new ArgumentNullException("Luggage list or trunk not existing");
            }

            this.luggageList = luggageList;
            this.trunk       = (Trunk)trunk;
        }
Exemplo n.º 2
0
        public LuggageCalc(LuggageList luggageList, IContainer trunk)
        {
            if (luggageList == null || trunk == null)
            {
                throw new ArgumentNullException("Luggage list or trunk not existing");
            }

            this.luggageList = luggageList;
            this.trunk       = (Trunk)trunk;

            TrunkSizeChecker checkTrunksSize = new TrunkSizeChecker(luggageList, trunk);

            isTrunkBigEnough = checkTrunksSize.evaluateTrunkSize();

            DebugSupporter.printPropertyValue(nameof(isTrunkBigEnough), isTrunkBigEnough);
        }