Skip to content

An extention of the great Retrofit with integration of Estivate

License

Notifications You must be signed in to change notification settings

btheu/futurefit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Futurefit

An extention of the great Retrofit with integration of Estivate

Getting Started

    public static void main(String args[]) {
	    Futurefit adapter = new Futurefit.Builder()
	    	.baseUrl("https://www.google.com/")
	        .build();
		
	    GoogleApi create = adapter.create(GoogleApi.class);
		
	    String stats = create.search("retrofit").getResultStatistics();
		
	    System.out.println(stats);
	}
	
	public interface GoogleApi {
	    @Estivate
	    @GET("/search?hl=en&safe=off")
	    @Headers({ "User-Agent:Mozilla/5.0 Firefox/68.0" })
	    public Page search(@Query("q") String query);
	}
	
	public class Page {
	    // get the div holding statistics
	    @Text(select="#resultStats")
	    public String resultStatistics;
	}

Download

<dependency>
    <groupId>com.github.btheu.futurefit2</groupId>
    <artifactId>futurefit</artifactId>
    <version>0.4.3</version>
</dependency>

About

An extention of the great Retrofit with integration of Estivate

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Languages