2009-08-11, 02:28
A couple of observations on the latest rev of the code:
1) ScraperManager isn't as tolerant of malformed scrapers (several of which appear to be included with XBMC) as the previous version. Adding a catch on XmlException in ScraperManager() fixes that problem and skips the bogus scrapers.
2) The various Get*Details methods on ScraperManager actually modify the ScrapeResultsEntity passed in in such a way that calling the function twice with the same ScrapeResultsEntity leads to the second call failing, because instead of a single Url it now has a bunch. I'm not sure if this is correct behavior or not, but it was certainly unexpected. To get around this I added a Clone() method to ScrapeResultsEntity and have the Get*Details calls clone the input parameter before use, which works for me but may not be the intended usage. Are those calls supposed to return information in the resultsEntity parameter?
1) ScraperManager isn't as tolerant of malformed scrapers (several of which appear to be included with XBMC) as the previous version. Adding a catch on XmlException in ScraperManager() fixes that problem and skips the bogus scrapers.
2) The various Get*Details methods on ScraperManager actually modify the ScrapeResultsEntity passed in in such a way that calling the function twice with the same ScrapeResultsEntity leads to the second call failing, because instead of a single Url it now has a bunch. I'm not sure if this is correct behavior or not, but it was certainly unexpected. To get around this I added a Clone() method to ScrapeResultsEntity and have the Get*Details calls clone the input parameter before use, which works for me but may not be the intended usage. Are those calls supposed to return information in the resultsEntity parameter?