Skip to content
D edited this page Dec 18, 2018 · 2 revisions

Retrofit form 1: Singleton (using global configuration)

        Aster.getDefault().get(url).request()->

Retrofit form 2: New instance (supports new custom configuration, supports the above three chain forms)

        Aster.get(url).request()->

Difference between New instance and Singleton usage

  • New - Starts with Aster instead of Aster.getDefault()
  • Config - Custom configuration, support for all configuration parameters such as .connectTimeout(), .baseUrl(), .headers(), only for this request.