powerquotes.common
Class StockCache
java.lang.Object
|
+--powerquotes.common.StockCache
- public class StockCache
- extends java.lang.Object
Singleton class that represents the system's current knowledge about stocks
This is updated as updates come in, and accessible when to service client subscriptions
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
getInstance
public StockCache getInstance()
- Returns:
- the instance of the StockCache
setStock
public void setStock(StockInfo stock)
getAllStocks
public java.util.Collection getAllStocks()
getStock
public StockInfo getStock(java.lang.Integer stockId)
- Returns:
- the StockInfo for this stockId or null if it wasn't found