Commits

Toby Inkster committed 8a07432 Draft

Make rdf_query function private

  • Participants
  • Parent commits 9ef9e57

Comments (0)

Files changed (1)

 	);
 }
 
-sub rdf_query
+sub __rdf_query
 {
 	my ($sparql, $model) = @_;
 	my $result = RDF::Query->new($sparql)->execute($model);
 			});
 		}
 		
-		my $iterator = rdf_query($self->_make_sparql($uri, $list), $model);
+		my $iterator = __rdf_query($self->_make_sparql($uri, $list), $model);
 		while (my $row = $iterator->next)
 		{
 			push @results, $row->{'descriptor'}->uri
 		($response, $rdfx) = $self->_cond_parse_rdf($response, $model, $uri)
 			unless defined $rdfa;
 		
-		my $iterator = rdf_query($self->_make_sparql($uri, $list), $model);
+		my $iterator = __rdf_query($self->_make_sparql($uri, $list), $model);
 		while (my $row = $iterator->next)
 		{
 			push @results, $row->{'descriptor'}->uri
 	# STEP 2a: AtomOWL doesn't use <id> as a subject URI.
 	if (defined $rdfa && $rdfa->{'atom_parser'} && blessed($self->{'cache'}->{$uri}))
 	{
-		my $iterator = rdf_query($self->_make_sparql_atomowl($uri, $list), $self->{'cache'}->{$uri});
+		my $iterator = __rdf_query($self->_make_sparql_atomowl($uri, $list), $self->{'cache'}->{$uri});
 		while (my $row = $iterator->next)
 		{
 			push @results, $row->{'descriptor'}->uri
 		my $hm_graph = $self->{'cache'}->{$hostmeta_location};
 		
 		# First try original query.
-		my $iterator = rdf_query($self->_make_sparql($uri, $list), $hm_graph);
+		my $iterator = __rdf_query($self->_make_sparql($uri, $list), $hm_graph);
 		while (my $row = $iterator->next)
 		{
 			push @results, $row->{'descriptor'}->uri
 		}
 		
 		# Then try using host-meta URI templates.
-		$iterator = rdf_query($self->_make_sparql_template($uri, $list), $hm_graph);
+		$iterator = __rdf_query($self->_make_sparql_template($uri, $list), $hm_graph);
 		while (my $row = $iterator->next)
 		{
 			if (defined $row->{'descriptor'}