API.Put

static class Put

Methods

event

static void event(RequestQueue queue, Event event, SharedPreferences settings, Response.Listener<NetworkResponse<String>> listener)

PUT to the server a request, via /event/new, to update an Event. Success or failure status will be passed via a NetworkResponse to the listener.

Parameters:
  • queue – Queue to which the asynchronous task will be added
  • event – Updated version of the Event to change
  • listener – Listener whose onResponse method will be called when task completes

post

static void post(RequestQueue queue, org.codethechange.culturemesh.models.Post post, SharedPreferences settings, Response.Listener<NetworkResponse<String>> listener)

PUT to the server, via /user/users, a request to make changes a org.codethechange.culturemesh.models.Post. Success or failure status will be passed via a NetworkResponse to the listener.

Parameters:
  • queue – Queue to which the asynchronous task will be added
  • post – Updated version of the post to change
  • listener – Listener whose onResponse method will be called when task completes

reply

static void reply(RequestQueue queue, PostReply comment, SharedPreferences settings, Response.Listener<NetworkResponse<String>> listener)

PUT to the server a request, via /post/{postId}/reply, to update a PostReply. Success or failure status will be passed via a NetworkResponse to the listener.

Parameters:
  • queue – Queue to which the asynchronous task will be added
  • comment – Updated version of the PostReply to make changes to
  • listener – Listener whose onResponse method will be called when task completes

user

static void user(RequestQueue queue, User user, String email, SharedPreferences settings, Response.Listener<NetworkResponse<String>> listener)

PUT to the server, via /user/users, a request to make changes a User. Success or failure status will be passed via a NetworkResponse to the listener.

Parameters:
  • queue – Queue to which the asynchronous task will be added
  • user – Updated version of the user to change
  • email – User’s email address
  • listener – Listener whose onResponse method will be called when task completes