All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.twingly.search.client.Client Maven / Gradle / Ivy

There is a newer version: 1.1.1
Show newest version
package com.twingly.search.client;

import com.twingly.search.Query;
import com.twingly.search.domain.Result;
import com.twingly.search.exception.TwinglySearchException;

/**
 * Performs all network operations related to using Twingly Search API
 *
 * @see com.twingly.search.Query
 */
public interface Client {
    /**
     * Get current User Agent that will be used in request
     *
     * @return user agent string
     */
    String getUserAgent();

    /**
     * Set user agent to use in requests
     *
     * @param userAgent user agent to be set
     */
    void setUserAgent(String userAgent);

    /**
     * Make request with given query
     *
     * @param query query to perform request with
     * @return Result object
     * @throws TwinglySearchException if any exception happens
     */
    Result makeRequest(Query query);
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy