doc.com.rallydev.rest.request.CollectionUpdateRequest.html Maven / Gradle / Ivy
CollectionUpdateRequest (Rally Rest API for Java 2.2)
com.rallydev.rest.request
Class CollectionUpdateRequest
- java.lang.Object
-
- com.rallydev.rest.request.Request
-
- com.rallydev.rest.request.CollectionUpdateRequest
-
public class CollectionUpdateRequest
extends Request
Represents a WSAPI request to update a collection.
-
-
Constructor Summary
Constructors
Constructor and Description
CollectionUpdateRequest(JsonObject collection,
JsonArray items,
boolean add)
Create a new update request for the specified collection and values.
CollectionUpdateRequest(String collectionRef,
JsonArray items,
boolean adding)
Create a new update request for the specified collection and values.
-
Method Summary
Methods
Modifier and Type
Method and Description
String
getBody()
Get the JSON encoded string representation of the object to be updated.
Fetch
getFetch()
Get the current list of fields to be returned on the updated object.
void
setFetch(Fetch fetch)
Set the current list of fields to be returned on the updated object.
String
toUrl()
Convert this request into a url compatible with the WSAPI.
-
Methods inherited from class com.rallydev.rest.request.Request
addParam, getGsonBuilder, getParams, setGsonBuilder, setParams
-
-
Constructor Detail
-
CollectionUpdateRequest
public CollectionUpdateRequest(JsonObject collection,
JsonArray items,
boolean add)
Create a new update request for the specified collection and values.
Note that this class is only usable with WSAPI versions 2.0 and above.
- Parameters:
collection
- the collection to be updateditems
- the items to be added or removedadd
- true if adding, false if removing
-
CollectionUpdateRequest
public CollectionUpdateRequest(String collectionRef,
JsonArray items,
boolean adding)
Create a new update request for the specified collection and values.
- Parameters:
collectionRef
- the ref of the collection to be updated. May be absolute or relative, e.g. "/defect/12345/tags"items
- the items to be added or removedadding
- true if adding, false if removing
-
Method Detail
-
getBody
public String getBody()
Get the JSON encoded string representation of the object to be updated.
- Returns:
- the JSON encoded object
-
getFetch
public Fetch getFetch()
Get the current list of fields to be returned on the updated object.
By default all fields will be returned in the response (fetch=true).
- Returns:
- the current list of fields.
-
setFetch
public void setFetch(Fetch fetch)
Set the current list of fields to be returned on the updated object.
- Parameters:
fetch
- the list of fields to be returned.
© 2015 - 2025 Weber Informatics LLC | Privacy Policy