The goal of this project was not stock quotes. Instead, I was learning, and practicing in these topics:
A general provider pattern
A provider factory pattern
Using linq and reflection
Benefits of using interfaces
Microsoft.VisualBasic.FileIO.TextFieldParser
HttpWebRequest , HttpWebRequest
If you would like to add a new stock quote provider, add a class in the Providers folder and have it implement the IStockQuoteProvider interface. That is all you have to do; but you could also add unit tests for your new provider. Note that the existing providers are implemented as “Friend.” This enforces callers who reference the assembly to create instances of providers by using the StockQuoteProviderFactory.
Thanks to Ryan Cromwell for pairing with me and providing the starting template. I’m sure this code can be improved. If you see opportunities to make it better please let me know.
No comments:
Post a Comment