src/main/java/edu/cmu/lti/oaqa/util/BingSearcherUtil.java
/*
	 * Builds a URL of search query to retrieve results from the Server
	 */
Builds a URL of search query to retrieve results from the Server
Builds a URL of search query to retrieve results from the Server
public static String BuildRequest(String queryString, int numResults)
			throws URISyntaxException {
		URI QueryURI = new URI("https", null /* user info */,
				"api.datamarket.azure.com", -1 /* port */,
				"/Bing/SearchWeb/v1/Web", "Query='" + queryString + "'&$top="
						+ numResults + "&$format=atom", null /* fragment */);
		return QueryURI.toString();
	}
public static String BuildRequest ( String queryString , int numResults ) throws URISyntaxException { URI QueryURI = new URI ( "https" , null /* user info */ , "api.datamarket.azure.com" , - 1 /* port */ , "/Bing/SearchWeb/v1/Web" , "Query='" + queryString + "'&$top=" + numResults + "&$format=atom" , null /* fragment */ ) ; return QueryURI . toString ( ) ; }
Builds a URL of search query to retrieve results from the Server
Builds a URL of search query to retrieve results from the Server
// Note that the query should be in single quotes!