예제 #1
0
        public int NumberOfStocksInIndex(string inIndexName)
        {
            string     unifiedIndexName = unifyName(inIndexName);
            StockIndex stockIndex       = getStockIndexFromStockExchange(unifiedIndexName);

            return(stockIndex.NumberOfStocksInIndex());
        }
예제 #2
0
        public decimal GetIndexValue(string inIndexName, DateTime inTimeStamp)
        {
            DateTime   roundedTS        = roundTimestamp(inTimeStamp);
            string     unifiedIndexName = unifyName(inIndexName);
            StockIndex stockIndex       = getStockIndexFromStockExchange(unifiedIndexName);

            return(stockIndex.GetIndexValue(roundedTS));
        }
예제 #3
0
        public bool IsStockPartOfIndex(string inIndexName, string inStockName)
        {
            string unifiedName      = unifyName(inStockName);
            string unifiedIndexName = unifyName(inIndexName);

            StockIndex stockIndex = getStockIndexFromStockExchange(unifiedIndexName);

            return(stockIndex.IsStockPartOfIndex(unifiedName));
        }