You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
find example class here [ApiRequester](https://github.com/devloopsnet/Base/blob/master/app/src/main/java/com/devloops/activities/http/ApiRequester.java)
81
+
##### 2- Create ApiMethods Interface
82
+
* include retrofit dependencies in your build.gradle file
* define routes like you normally do with retrofit with your desired model.
83
91
84
-
##### 3- Create ApiMethods Class
85
-
find example class here [ApiMethods](https://github.com/devloopsnet/Base/blob/master/app/src/main/java/com/devloops/activities/http/ApiMethods.java)
92
+
find example here [ApiMethods](https://github.com/devloopsnet/Base/blob/master/app/src/main/java/com/devloops/activities/http/ApiMethods.java)
86
93
87
-
##### 4- Create instance of ApiRequester
94
+
##### 4- Create ApiRequester Class
95
+
* create varialbles for Context and ApiMethods.
96
+
* create constructor to initialize context and ApiMethods.
97
+
* Create a getInstance mehtod to get ApiRequester instance.
98
+
* call your api's using ApiMethods instance.
99
+
* create your own ApiCallback interface.
100
+
101
+
find example class here [ApiRequester](https://github.com/devloopsnet/Base/blob/master/app/src/main/java/com/devloops/activities/http/ApiRequester.java)
102
+
103
+
##### 4- Create instance of ApiRequester in your activity or fragment.
88
104
```
89
105
requester = ApiRequester.getInstance(context);
90
106
```
91
-
Then call your api..
107
+
Then call your api with the api's you defined in your ApiRequester class.
0 commit comments