if (NS_FAILED(rv = NS_NewRDFHistoryDataSource((nsIRDFDataSource**) &inst)))
if (NS_FAILED(rv = NS_NewHistoryDataSource((nsIHistoryDataSource**) &inst)))
RDFFactoryImpl::CreateInstance(nsISupports *aOuter,                               const nsIID &aIID,                               void **aResult){    if (! aResult)        return NS_ERROR_NULL_POINTER;    if (aOuter)        return NS_ERROR_NO_AGGREGATION;    *aResult = nsnull;    nsresult rv;    nsISupports *inst = nsnull;    if (mClassID.Equals(kRDFServiceCID)) {        if (NS_FAILED(rv = NS_NewRDFService((nsIRDFService**) &inst)))            return rv;    }    else if (mClassID.Equals(kXULSortServiceCID)) {        if (NS_FAILED(rv = NS_NewXULSortService((nsIXULSortService**) &inst)))            return rv;    }    else if (mClassID.Equals(kRDFInMemoryDataSourceCID)) {        if (NS_FAILED(rv = NS_NewRDFInMemoryDataSource((nsIRDFDataSource**) &inst)))            return rv;    }    else if (mClassID.Equals(kRDFXMLDataSourceCID)) {        if (NS_FAILED(rv = NS_NewRDFXMLDataSource((nsIRDFXMLDataSource**) &inst)))          return rv;    }    else if (mClassID.Equals(kRDFBookmarkDataSourceCID)) {        if (NS_FAILED(rv = NS_NewRDFBookmarkDataSource((nsIRDFDataSource**) &inst)))            return rv;    }    else if (mClassID.Equals(kRDFFileSystemDataSourceCID)) {        if (NS_FAILED(rv = NS_NewRDFFileSystemDataSource((nsIRDFDataSource**) &inst)))            return rv;    }    else if (mClassID.Equals(kRDFFindDataSourceCID)) {        if (NS_FAILED(rv = NS_NewRDFFindDataSource((nsIRDFDataSource**) &inst)))            return rv;    }    else if (mClassID.Equals(kRDFCompositeDataSourceCID)) {        if (NS_FAILED(rv = NS_NewRDFCompositeDataSource((nsIRDFCompositeDataSource**) &inst)))            return rv;    }    else if (mClassID.Equals(kRDFHistoryDataSourceCID)) {        if (NS_FAILED(rv = NS_NewRDFHistoryDataSource((nsIRDFDataSource**) &inst)))            return rv;    }    else if (mClassID.Equals(kXULDocumentCID)) {        if (NS_FAILED(rv = NS_NewXULDocument((nsIRDFDocument**) &inst)))            return rv;    }    else if (mClassID.Equals(kXULDocumentInfoCID)) {        if (NS_FAILED(rv = NS_NewXULDocumentInfo((nsIXULDocumentInfo**) &inst)))            return rv;    }    else if (mClassID.Equals(kRDFHTMLBuilderCID)) {        if (NS_FAILED(rv = NS_NewRDFHTMLBuilder((nsIRDFContentModelBuilder**) &inst)))            return rv;    }    else if (mClassID.Equals(kRDFMenuBuilderCID)) {        if (NS_FAILED(rv = NS_NewRDFMenuBuilder((nsIRDFContentModelBuilder**) &inst)))            return rv;    }    else if (mClassID.Equals(kRDFToolbarBuilderCID)) {        if (NS_FAILED(rv = NS_NewRDFToolbarBuilder((nsIRDFContentModelBuilder**) &inst)))            return rv;    }    else if (mClassID.Equals(kRDFTreeBuilderCID)) {        if (NS_FAILED(rv = NS_NewRDFTreeBuilder((nsIRDFContentModelBuilder**) &inst)))            return rv;    }    else if (mClassID.Equals(kRDFXULBuilderCID)) {        if (NS_FAILED(rv = NS_NewRDFXULBuilder((nsIRDFContentModelBuilder**) &inst)))            return rv;    }    else if (mClassID.Equals(kRDFContentSinkCID)) {        if (NS_FAILED(rv = NS_NewRDFContentSink((nsIRDFContentSink**) &inst)))            return rv;    }	else if (mClassID.Equals(kXULDataSourceCID)) {		if (NS_FAILED(rv = NS_NewXULDataSource((nsIRDFXMLDataSource**) &inst)))			return rv;	}	else if (mClassID.Equals(kXULContentSinkCID)) {        if (NS_FAILED(rv = NS_NewXULContentSink((nsIXULContentSink**) &inst)))            return rv;    }	else if (mClassID.Equals(kRDFDefaultResourceCID)) {        if (NS_FAILED(rv = NS_NewDefaultResource((nsIRDFResource**) &inst)))            return rv;    }    else {        return NS_ERROR_NO_INTERFACE;    }    if (! inst)        return NS_ERROR_OUT_OF_MEMORY;    if (NS_FAILED(rv = inst->QueryInterface(aIID, aResult))) {        // We didn't get the right interface.        NS_ERROR("didn't support the interface you wanted");    }    NS_IF_RELEASE(inst);    return rv;}