@Nullable
    public static String encode(final String text) {
        try {
            return URLEncoder.encode(text, StandardCharsets.UTF_8.name());
        } catch (final UnsupportedEncodingException e) {
            Log.e("Network.encode", e);
        }
        return null;
    }
Wait until a request has completed and check its response status. An exception will be thrown if the
request does not complete successfully.success status.

@param response the response to check
main/src/main/java/cgeo/geocaching/network/Network.java