comparison rdf/RDFImporter.cpp @ 542:1ddab154fb9a

* minor fix
author Chris Cannam
date Tue, 03 Feb 2009 11:12:19 +0000
parents 3ccf48fb81d6
children 1d7ebc05157e
comparison
equal deleted inserted replaced
541:57f3eec55957 542:1ddab154fb9a
936 QString(" SELECT ?x FROM <%1> WHERE { ?x <y> <z> } ") 936 QString(" SELECT ?x FROM <%1> WHERE { ?x <y> <z> } ")
937 .arg(url)); 937 .arg(url));
938 938
939 SimpleSPARQLQuery::ResultList r = q.execute(); 939 SimpleSPARQLQuery::ResultList r = q.execute();
940 if (!q.isOK()) { 940 if (!q.isOK()) {
941 SimpleSPARQLQuery::closeSingleSource(url);
941 return NotRDF; 942 return NotRDF;
942 } 943 }
943 944
944 SimpleSPARQLQuery::Value value = 945 SimpleSPARQLQuery::Value value =
945 SimpleSPARQLQuery::singleResultQuery 946 SimpleSPARQLQuery::singleResultQuery
984 if (value.type == SimpleSPARQLQuery::URIValue) { 985 if (value.type == SimpleSPARQLQuery::URIValue) {
985 haveAnnotations = true; 986 haveAnnotations = true;
986 } 987 }
987 } 988 }
988 989
990 SimpleSPARQLQuery::closeSingleSource(url);
991
989 if (haveAudio) { 992 if (haveAudio) {
990 if (haveAnnotations) { 993 if (haveAnnotations) {
991 return AudioRefAndAnnotations; 994 return AudioRefAndAnnotations;
992 } else { 995 } else {
993 return AudioRef; 996 return AudioRef;
998 } else { 1001 } else {
999 return OtherRDFDocument; 1002 return OtherRDFDocument;
1000 } 1003 }
1001 } 1004 }
1002 1005
1003 SimpleSPARQLQuery::closeSingleSource(url); 1006 return OtherRDFDocument;
1004 } 1007 }
1005 1008
1006 void 1009 void
1007 RDFImporterImpl::loadPrefixes(ProgressReporter *reporter) 1010 RDFImporterImpl::loadPrefixes(ProgressReporter *reporter)
1008 { 1011 {