@Override public Object getValueAt(final int row, final int col) { SecurityNode cn = performanceSummary.getSecurities().get(row); InvestmentPerformanceSummary.SecurityPerformanceData pd = performanceSummary.getPerformanceData(cn); switch (col) { case 0: if (longNameCheckBox.isSelected()) { return pd.getNode().getDescription(); } return pd.getNode().getSymbol(); case 1: return pd.getSharesHeld(); case 2: return pd.getCostBasisPerShare(); case 3: return pd.getHeldCostBasis(); case 4: return pd.getPrice(baseCurrency); case 5: return pd.getMarketValue(baseCurrency); case 6: return pd.getUnrealizedGains(); case 7: return pd.getRealizedGains(); case 8: return pd.getTotalGains(); case 9: return pd.getTotalGainsPercentage(); case 10: return pd.getPercentPortfolio(); case 11: return "group"; default: return "ERR"; } }
@Override public int getRowCount() { return performanceSummary.getSecurities().size(); }