~~ ==================================================================== ~~ Licensed to the Apache Software Foundation (ASF) under one ~~ or more contributor license agreements. See the NOTICE file ~~ distributed with this work for additional information ~~ regarding copyright ownership. The ASF licenses this file ~~ to you under the Apache License, Version 2.0 (the ~~ "License"); you may not use this file except in compliance ~~ with the License. You may obtain a copy of the License at ~~ ~~ http://www.apache.org/licenses/LICENSE-2.0 ~~ ~~ Unless required by applicable law or agreed to in writing, ~~ software distributed under the License is distributed on an ~~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY ~~ KIND, either express or implied. See the License for the ~~ specific language governing permissions and limitations ~~ under the License. ~~ ==================================================================== ~~ ~~ This software consists of voluntary contributions made by many ~~ individuals on behalf of the Apache Software Foundation. For more ~~ information on the Apache Software Foundation, please see ~~ . ---------- HttpComponents HttpCore Examples ---------- ---------- ---------- HttpCore Examples * {{{./httpcore/examples/org/apache/http/examples/ElementalHttpGet.java} Basic HTTP GET}} This example demonstrates how to execute a series of synchronous (blocking) HTTP GET requests. * {{{./httpcore/examples/org/apache/http/examples/ElementalHttpPost.java} Basic HTTP POST}} This example demonstrates how to execute a series of synchronous (blocking) HTTP POST requests that enclose entity content of various types: a string, a byte array, an arbitrary input stream. * {{{./httpcore/examples/org/apache/http/examples/ElementalHttpServer.java} Basic HTTP server}} This is an example of an HTTP/1.1 file server based on a synchronous (blocking) I/O model. * {{{./httpcore-nio/examples/org/apache/http/examples/nio/NHttpClient.java} Asynchronous HTTP GET}} This example demonstrates how HttpCore NIO can be used to execute multiple HTTP requests asynchronously using only one I/O thread. * {{{./httpcore-nio/examples/org/apache/http/examples/nio/NHttpServer.java} Asynchronous HTTP server}} This example demonstrates the use of HttpCore NIO to build an asynchronous (non-blocking) HTTP server capable of direct channel (zero copy) data transfer. * {{{./httpcore-nio/examples/org/apache/http/examples/nio/NHttpReverseProxy.java} Asynchronous HTTP reverse proxy}} This example demonstrates how HttpCore NIO can be used to build an asynchronous, fully streaming reverse HTTP proxy.