View Javadoc
1   package ejava.examples.asyncmarket;
2   
3   import java.util.List;
4   
5   import ejava.examples.asyncmarket.bo.AuctionItem;
6   import ejava.examples.asyncmarket.bo.Order;
7   import ejava.examples.asyncmarket.ejb.InvalidRequestException;
8   import ejava.examples.asyncmarket.ejb.ResourceNotFoundException;
9   
10  public interface Buyer {
11      List<AuctionItem> getAvailableItems(int index, int count);
12      AuctionItem getItem(long itemId)
13          throws ResourceNotFoundException;    
14      long bidProduct(long productId, String userId, double amount)
15          throws ResourceNotFoundException, InvalidRequestException;    
16      long placeOrder(long productId, String userId, double maxAmount)
17          throws ResourceNotFoundException, InvalidRequestException;    
18      Order getOrder(long orderId)
19          throws ResourceNotFoundException;    
20  }