I'm currently preparing to take my Magento Certified Developer test next Tuesday. A couple of the practice tests I have encountered have the following question:
Which object never encapsulates any shopping cart items?
A. Mage_Checkout_Model_Cart
B. Mage_Sales_Model_Quote
C. Mage_Sales_Model_Quote_Address<type=shipping>
D. Mage_Sales_Model_Quote_Address<type=billing>
Answer: B
Why would that be the correct answer? Mage_Sales_Model_Quote
has shopping cart items that are associated with it ($_items
property, getAllItems() and getItemsCollection()
methods). Perhaps I don't properly understand what is meant by encapsulation - what would be the meaning of encapsulation in this context?