public class ServerResponse<T>
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected java.lang.String |
error |
protected Status |
status |
protected T |
t |
Modifier | Constructor and Description |
---|---|
protected |
ServerResponse(T t,
Status status,
java.lang.String error) |
public static <T> ServerResponse<T> from(java.lang.Class<T> type, retrofit.client.Response response)
type
- class type contained within responseresponse
- Retrofit response to be converted to type.public Status getStatus()
public java.lang.String getError()
public T get()