Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;

public class Main {
    /**
     * checks for network authentication errors as well as the service call exceptions
     * @param response String
     * @return boolean isValidResult
     */
    public static boolean isValidJsonResult(String response) {
        return response != null && !response.contains("<HTML") && !response.equals("")
                && !response.contains("<!DOCTYPE") && !response.contains("/>");
    }
}