Sample code for 30+ languages & platforms
Java

Example: Rest.AddHeader method

Demonstrates the AddHeader 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[])
  {
    CkRest rest = new CkRest();

    rest.AddHeader("User-Agent","MyApplication/1.0");

    //  ...
    //  ...
    //  ...
  }
}