2 * Quelaton – a high-level FCP client with an easy-to-use fluent interface.
4 * Quelaton can be used by FCP applications to easily perform the most commons tasks, such as retrieving or inserting
5 * data, or generating keys. The main entry class is {@link net.pterodactylus.fcp.quelaton.FcpClient} which can create
6 * FCP commands which can then be fed arguments or data and which can be executed, yielding a result in form of a
7 * {@link java.util.concurrent.Future}.
9 * FcpClient fcpClient = ...
10 * Optional<Data> data = fcpClient.clientGet().uri("KSK@gpl.txt").{@link java.util.concurrent.Future#get()
12 * if (data.isPresent()) {
13 * ... process data ...
17 * As is the case with {@link java.util.concurrent.Future}’s, the call to {@link java.util.concurrent.Future#get()}
18 * will block until the request has finished. This allows starting the request (by calling
19 * {@link net.pterodactylus.fcp.quelaton.ClientGetCommand#uri(String)}) and waiting for it to finish in a different
20 * thread. Using Guava’s {@link com.google.common.util.concurrent.ListenableFuture} allows client applications to
21 * register listeners that will automatically be run once the request finishes.
23 * @author <a href="mailto:bombe@freenetproject.org">David ‘Bombe’ Roden</a>
25 package net.pterodactylus.fcp.quelaton;