Artenus 2D Framework
Artenus Reference
Represents a group of products, accessible using their SKUs.

See Also:

public class ProductList

Constructor Summary

Modifier and TypeConstructor and Description
public ProductList()

Method Summary

Modifier and TypeMethod and Description
public Productget(String sku)
Gets a product from this list.
public Collection<Product>getAllProducts()
Gets all products in this list.
public voidput(Product product)
Adds a new product to this list.

Methods inherited from java.lang.Object

clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail

ProductList
public  ProductList()

Method Detail

get
public Product get(
    String sku
)
Gets a product from this list.
Parameters:
skuSKU of the desired product
Returns:
The desired product, or null if it doesn't exist in the group
getAllProducts
public Collection<Product> getAllProducts()
Gets all products in this list.
Returns:
A collection of products
put
public void put(
    Product product
)
Adds a new product to this list.
Parameters:
productThe new product