The method calls (events) are queued, guaranteeing order; the next method request in the queue is not sent until the previous one returns.
将方法调用(事件)放入队列,以保证顺序。在队列中,在前一个方法请求返回之前,不会发送下一个方法请求。
An order from one of WidgetCo's customers is implemented as a list of Widget objects, with one extra method to compute the order's total cost.
来自Widget Co客户之一的订单会作为一个Widget对象列表来实现,并使用一个额外的方法来计算订单的总成本,即。
The results method calls get_cart, which will retrieve the current Order object or create a new one, if one doesn't exist or cannot be found.
results 方法会调用 get_cart,它会检索当前的 Order 对象,如果不存在或没有找到,就创建一个新对象。
应用推荐