Sample code for 30+ languages & platforms
Java

Example: Http.GetDomain method

Demonstrates the GetDomain method.

Chilkat Java Downloads

Java
import com.chilkatsoft.*;

public class ChilkatExample {

  static {
    try {
        System.loadLibrary("chilkat");
    } catch (UnsatisfiedLinkError e) {
      System.err.println("Native code library failed to load.\n" + e);
      System.exit(1);
    }
  }

  public static void main(String argv[])
  {
    CkHttp http = new CkHttp();

    String domain = http.getDomain("https://chilkatsoft.com/refdoc/csharp.asp");
    System.out.println(domain);

    //  Output: chilkatsoft.com
  }
}