SCC_SC_CHECKOUT
This service operation checks out the items that the user has added to the cart. A user interface can use this operation for a single or multiple cart items. The service operation sends back a response message indicating success or failure.
Example: After adding all the desired classes to the enrollment shopping cart, the student confirms his or her choices by checking out the items. The enrollment shopping cart uses the SCC_SC_CHECKOUT operation to check out (enroll) the classes added to the enrollment shopping cart. On successful enrollment, the response message returns the following message to the student: The class has been added to your schedule. If any error occurs during enrollment, the response message contains the appropriate error message.
Note:
The checkout code should be specific to the shopping cart feature that you are implementing. Therefore, whoever implements a shopping cart needs to create feature-specific checkout logic as part of the adopting feature's application class. In the preceding example, the enrollment checkout logic is not part of the Shopping Cart framework. We have incorporated this enrollment checkout logic in the CourseShoppingCart application class, purchase method (part of SSR_COURSE application package). This class and method are specific to the enrollment shopping cart. The purchase method executes when the enrollment shopping cart user interface invokes the SCC_SC_CHECKOUT service operation.