public class NetUtils extends Object
| Constructor and Description |
|---|
NetUtils() |
| Modifier and Type | Method and Description |
|---|---|
static String |
getHost(String endpoint) |
static String |
getHostByURL(String url) |
static boolean |
isSameHost(String toTestHost,
String toLookForHost) |
static boolean |
isUp(String url) |
static void |
makeAuthorizedCall(String urlString,
String user,
String password) |
static void |
makeAuthorizedCall(String host,
String path,
String user,
String password) |
static String |
resolveRedirects(String url) |
public static boolean isSameHost(String toTestHost, String toLookForHost) throws UnknownHostException
UnknownHostExceptionpublic static final String getHost(String endpoint) throws MalformedURLException
MalformedURLExceptionpublic static boolean isUp(String url) throws IOException
IOExceptionpublic static String resolveRedirects(String url) throws IOException
IOExceptionpublic static void makeAuthorizedCall(String host, String path, String user, String password) throws IOException
IOExceptionpublic static void makeAuthorizedCall(String urlString, String user, String password) throws IOException
IOExceptionCopyright © 2020. All Rights Reserved.