public class GetRequest extends Request
gsonBuilder
Constructor and Description |
---|
GetRequest(String ref)
Create a new get request for the specified object.
|
Modifier and Type | Method and Description |
---|---|
protected String |
getEndpoint() |
Fetch |
getFetch()
Get the current list of fields to be returned on the retrieved object.
|
void |
setFetch(Fetch fetch)
Set the current list of fields to be returned on the retrieved object.
|
String |
toUrl()
Convert this request into a url compatible with the WSAPI.
|
addParam, getGsonBuilder, getParams, setGsonBuilder, setParams
public GetRequest(String ref)
ref
- the ref of the WSAPI object to be retrieved. May be absolute or relative, e.g. "/defect/12345"
May also be "/user" or "/subscription" to get the current instancespublic Fetch getFetch()
Get the current list of fields to be returned on the retrieved object.
By default all fields will be returned in the response (fetch=true).public void setFetch(Fetch fetch)
fetch
- the list of fields to be returned.public String toUrl()
Convert this request into a url compatible with the WSAPI.
The current fetch and any other parameters will be included.protected String getEndpoint()
Copyright © 2016. All Rights Reserved.