Java URL Value Check isValidChannelUrl(String url)

Here you can find the source of isValidChannelUrl(String url)

Description

is Valid Channel Url

License

Open Source License

Declaration

public static boolean isValidChannelUrl(String url) 

Method Source Code


//package com.java2s;
//License from project: Open Source License 

import java.net.URI;
import java.net.URISyntaxException;

public class Main {
    public static boolean isValidChannelUrl(String url) {
        try {// w  w w  . java2  s  . c  o  m
            URI uri = new URI(url);
            return uri.getPath().contains("/channel/");
        } catch (URISyntaxException e) {
            return false;
        }
    }
}

Related

  1. isUrlResponding(String url)
  2. isUrlValid(final URL url)
  3. isUrlValid(URL url)
  4. isValid(String candidateUrl)
  5. isValid(String url)
  6. isValidServerURL(String serverURL)
  7. isValidSuccessfulSignInURL(String url)
  8. isValidURL(CharSequence urlStr)
  9. isValidURL(final String candidateString)