O'Reilly logo

Rapid Application Development with Mozilla™ by Nigel McFarlane

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

16.7. Debug Corner: Working with Data Sources

Some of the most common problems that hit when working with data sources include the following:

  • Capitalization. Unlike the rest of XPCOM, data source interface methods are stated in InitCaps, not in initCaps. Thus it is GetResource() not getResource().

  • Asynchronous loading. If the nsIRDFDataSource interface's GetDataSource() methods is used to create a data source instead of GetDataSourceBlocking(), the data source loads “in the background.” In that case, any statements manipulating that data source immediately after its object is created are at risk. The risk is that the data source has not finished loading yet, and so not all anticipated facts may yet be present.

  • Syntax problems in test data.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required