Package dd2480.group4.net
Class Http
java.lang.Object
dd2480.group4.net.Http
- All Implemented Interfaces:
HttpInterface
public class Http extends java.lang.Object implements HttpInterface
Http requests used to update commit status on GitHub
-
Constructor Details
-
Http
public Http()
-
-
Method Details
-
post
public java.net.HttpURLConnection post(java.net.URL url, java.lang.String json) throws java.io.IOException- Specified by:
post
in interfaceHttpInterface
- Parameters:
url
- The endpoint to send the POST request tojson
- The body in the request in json format- Returns:
- Returns a HttpURLConnection with the given URL ready to send the JSON.
- Throws:
java.io.IOException
- when it fails to send the message.
-