is Url Format Invalid - Android Network

Android examples for Network:URL

Description

is Url Format Invalid

Demo Code


//package com.java2s;

import android.webkit.URLUtil;

public class Main {
    public static boolean isUrlFormatInvalid(String url) {
        return url == null || url.isEmpty() || !URLUtil.isValidUrl(url)
                || "http://".equals(url) || "https://".equals(url);
    }//from w  w w  .  j  a v a 2 s. c  o m
}

Related Tutorials