From b171126719c983b590c51f22eb60a3e0afdf1fb9 Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Fri, 10 Sep 2010 06:42:24 +0200 Subject: [PATCH] Reformat source code, new line length for comments (79), some trailing whitespace removed. --- src/main/java/net/pterodactylus/fcp/AllData.java | 6 +++--- src/main/java/net/pterodactylus/fcp/ClientGet.java | 8 ++++---- src/main/java/net/pterodactylus/fcp/ClientPut.java | 22 +++++++++++----------- .../net/pterodactylus/fcp/ClientPutComplexDir.java | 8 ++++---- .../net/pterodactylus/fcp/ClientPutDiskDir.java | 22 +++++++++++----------- src/main/java/net/pterodactylus/fcp/DSAGroup.java | 4 ++-- src/main/java/net/pterodactylus/fcp/DataFound.java | 4 ++-- .../net/pterodactylus/fcp/EndListPeerNotes.java | 3 ++- .../fcp/EndListPersistentRequests.java | 4 ++-- .../net/pterodactylus/fcp/FCPPluginMessage.java | 10 +++++----- .../java/net/pterodactylus/fcp/FcpConnection.java | 12 ++++++------ .../pterodactylus/fcp/FcpConnectionHandler.java | 2 +- .../java/net/pterodactylus/fcp/FcpListener.java | 17 +++++++++-------- .../net/pterodactylus/fcp/FcpListenerManager.java | 10 ++++++---- .../java/net/pterodactylus/fcp/FcpMessage.java | 14 +++++++------- src/main/java/net/pterodactylus/fcp/FcpUtils.java | 4 ++-- src/main/java/net/pterodactylus/fcp/GetConfig.java | 12 ++++++------ src/main/java/net/pterodactylus/fcp/GetFailed.java | 17 +++++++++-------- src/main/java/net/pterodactylus/fcp/GetNode.java | 11 ++++++----- .../net/pterodactylus/fcp/GetRequestStatus.java | 5 +++-- src/main/java/net/pterodactylus/fcp/ListPeer.java | 6 +++--- src/main/java/net/pterodactylus/fcp/ListPeers.java | 7 ++++--- .../java/net/pterodactylus/fcp/ModifyPeer.java | 8 ++++---- .../java/net/pterodactylus/fcp/ModifyPeerNote.java | 4 ++-- src/main/java/net/pterodactylus/fcp/NodeData.java | 8 ++++---- src/main/java/net/pterodactylus/fcp/NodeHello.java | 12 ++++++------ src/main/java/net/pterodactylus/fcp/NodeRef.java | 4 ++-- src/main/java/net/pterodactylus/fcp/Peer.java | 15 ++++++++------- src/main/java/net/pterodactylus/fcp/PeerNote.java | 4 ++-- .../java/net/pterodactylus/fcp/PersistentGet.java | 13 +++++++------ .../net/pterodactylus/fcp/PersistentPutDir.java | 3 ++- .../fcp/PersistentRequestModified.java | 4 ++-- .../fcp/PersistentRequestRemoved.java | 4 ++-- .../java/net/pterodactylus/fcp/ProtocolError.java | 4 ++-- src/main/java/net/pterodactylus/fcp/PutFailed.java | 8 ++++---- .../pterodactylus/fcp/ReceivedBookmarkFeed.java | 8 ++++---- .../net/pterodactylus/fcp/SendBookmarkFeed.java | 4 ++-- .../net/pterodactylus/fcp/SubscribedUSKUpdate.java | 10 +++++----- .../java/net/pterodactylus/fcp/TestDDAReply.java | 5 +++-- .../java/net/pterodactylus/fcp/TestDDARequest.java | 3 ++- .../net/pterodactylus/fcp/TestDDAResponse.java | 17 +++++++++-------- .../java/net/pterodactylus/fcp/URIGenerated.java | 10 +++++----- src/main/java/net/pterodactylus/fcp/Verbosity.java | 8 ++++---- src/main/java/net/pterodactylus/fcp/Version.java | 4 ++-- .../net/pterodactylus/fcp/highlevel/FcpClient.java | 8 ++++---- .../net/pterodactylus/fcp/highlevel/Request.java | 11 ++++++----- .../java/net/pterodactylus/fcp/package-info.java | 18 +++++++++--------- 47 files changed, 210 insertions(+), 195 deletions(-) diff --git a/src/main/java/net/pterodactylus/fcp/AllData.java b/src/main/java/net/pterodactylus/fcp/AllData.java index dfc7dc2..b4daa27 100644 --- a/src/main/java/net/pterodactylus/fcp/AllData.java +++ b/src/main/java/net/pterodactylus/fcp/AllData.java @@ -22,9 +22,9 @@ import java.io.InputStream; /** * The “AllData” message carries the payload of a successful {@link ClientGet} - * request. You will only received this message if the {@link ClientGet} request - * was started with a return type of {@link ReturnType#direct}. If you get this - * message and decide that the data is for you, call + * request. You will only received this message if the {@link ClientGet} + * request was started with a return type of {@link ReturnType#direct}. If you + * get this message and decide that the data is for you, call * {@link #getPayloadInputStream()} to get the data. If an AllData message * passes through all registered {@link FcpListener}s without the payload being * consumed, the payload is discarded! diff --git a/src/main/java/net/pterodactylus/fcp/ClientGet.java b/src/main/java/net/pterodactylus/fcp/ClientGet.java index ce2abf1..1126824 100644 --- a/src/main/java/net/pterodactylus/fcp/ClientGet.java +++ b/src/main/java/net/pterodactylus/fcp/ClientGet.java @@ -89,8 +89,8 @@ public class ClientGet extends FcpMessage { } /** - * Sets the maximum size of the file to retrieve. If the file is larger than - * this size the request will fail! + * Sets the maximum size of the file to retrieve. If the file is larger + * than this size the request will fail! * * @param maxSize * The maximum size of the file to retrieve @@ -207,8 +207,8 @@ public class ClientGet extends FcpMessage { } /** - * Sets the name for the temporary file. You should only call this method if - * your return type is {@link ReturnType#disk}! + * Sets the name for the temporary file. You should only call this method + * if your return type is {@link ReturnType#disk}! * * @param tempFilename * The name of the temporary file diff --git a/src/main/java/net/pterodactylus/fcp/ClientPut.java b/src/main/java/net/pterodactylus/fcp/ClientPut.java index 5176e6a..5dcbf71 100644 --- a/src/main/java/net/pterodactylus/fcp/ClientPut.java +++ b/src/main/java/net/pterodactylus/fcp/ClientPut.java @@ -55,8 +55,8 @@ public class ClientPut extends FcpMessage { * test your direct-disk access (see {@link TestDDARequest}, * {@link TestDDAReply}, {@link TestDDAResponse}, {@link TestDDAComplete}) * before using this option! If uploadFrom is - * {@link UploadFrom#redirect}, use {@link #setTargetURI(String)} to set the - * target URI of the redirect. + * {@link UploadFrom#redirect}, use {@link #setTargetURI(String)} to set + * the target URI of the redirect. * * @param uri * The URI to insert to @@ -117,8 +117,8 @@ public class ClientPut extends FcpMessage { } /** - * Determines whether the node should really insert the data or generate the - * final CHK only. + * Determines whether the node should really insert the data or generate + * the final CHK only. * * @param getCHKOnly * true to generate the final CHK only, @@ -132,8 +132,8 @@ public class ClientPut extends FcpMessage { * Sets whether an insert request should be forked when it is cached. * * @param forkOnCacheable - * {@code true} to fork the insert when it is cached, {@code - * false} otherwise + * {@code true} to fork the insert when it is cached, + * {@code false} otherwise */ public void setForkOnCacheable(boolean forkOnCacheable) { setField("ForkOnCacheable", String.valueOf(forkOnCacheable)); @@ -175,17 +175,17 @@ public class ClientPut extends FcpMessage { * already been compressed. * * @param dontCompress - * true to skip compression of the data in the node, - * false to allow compression + * true to skip compression of the data in the + * node, false to allow compression */ public void setDontCompress(boolean dontCompress) { setField("DontCompress", String.valueOf(dontCompress)); } /** - * Sets an optional client token. This client token is mentioned in progress - * and other request-related messages and can be used to identify this - * request. + * Sets an optional client token. This client token is mentioned in + * progress and other request-related messages and can be used to identify + * this request. * * @param clientToken * The client token diff --git a/src/main/java/net/pterodactylus/fcp/ClientPutComplexDir.java b/src/main/java/net/pterodactylus/fcp/ClientPutComplexDir.java index 5b724c7..154c837 100644 --- a/src/main/java/net/pterodactylus/fcp/ClientPutComplexDir.java +++ b/src/main/java/net/pterodactylus/fcp/ClientPutComplexDir.java @@ -105,8 +105,8 @@ public class ClientPutComplexDir extends FcpMessage { * Sets whether an insert request should be forked when it is cached. * * @param forkOnCacheable - * {@code true} to fork the insert when it is cached, {@code - * false} otherwise + * {@code true} to fork the insert when it is cached, + * {@code false} otherwise */ public void setForkOnCacheable(boolean forkOnCacheable) { setField("ForkOnCacheable", String.valueOf(forkOnCacheable)); @@ -229,8 +229,8 @@ public class ClientPutComplexDir extends FcpMessage { * {@inheritDoc} *

* Do not call this method to add input streams! The input streams, if any, - * will be taken directly from the {@link FileEntry}s and the stream you set - * here will be overridden! + * will be taken directly from the {@link FileEntry}s and the stream you + * set here will be overridden! */ @Override public void setPayloadInputStream(InputStream payloadInputStream) { diff --git a/src/main/java/net/pterodactylus/fcp/ClientPutDiskDir.java b/src/main/java/net/pterodactylus/fcp/ClientPutDiskDir.java index 6c78e84..67022e5 100644 --- a/src/main/java/net/pterodactylus/fcp/ClientPutDiskDir.java +++ b/src/main/java/net/pterodactylus/fcp/ClientPutDiskDir.java @@ -78,8 +78,8 @@ public class ClientPutDiskDir extends FcpMessage { } /** - * Determines whether the node should really insert the data or generate the - * final CHK only. + * Determines whether the node should really insert the data or generate + * the final CHK only. * * @param getCHKOnly * true to generate the final CHK only, @@ -93,8 +93,8 @@ public class ClientPutDiskDir extends FcpMessage { * Sets whether an insert request should be forked when it is cached. * * @param forkOnCacheable - * {@code true} to fork the insert when it is cached, {@code - * false} otherwise + * {@code true} to fork the insert when it is cached, + * {@code false} otherwise */ public void setForkOnCacheable(boolean forkOnCacheable) { setField("ForkOnCacheable", String.valueOf(forkOnCacheable)); @@ -136,17 +136,17 @@ public class ClientPutDiskDir extends FcpMessage { * already been compressed. * * @param dontCompress - * true to skip compression of the data in the node, - * false to allow compression + * true to skip compression of the data in the + * node, false to allow compression */ public void setDontCompress(boolean dontCompress) { setField("DontCompress", String.valueOf(dontCompress)); } /** - * Sets an optional client token. This client token is mentioned in progress - * and other request-related messages and can be used to identify this - * request. + * Sets an optional client token. This client token is mentioned in + * progress and other request-related messages and can be used to identify + * this request. * * @param clientToken * The client token @@ -166,8 +166,8 @@ public class ClientPutDiskDir extends FcpMessage { } /** - * Sets the name of the default file. The default file is shown when the key - * is requested with an additional name. + * Sets the name of the default file. The default file is shown when the + * key is requested with an additional name. * * @param defaultName * The name of the default file diff --git a/src/main/java/net/pterodactylus/fcp/DSAGroup.java b/src/main/java/net/pterodactylus/fcp/DSAGroup.java index 4674e66..b9f1fcd 100644 --- a/src/main/java/net/pterodactylus/fcp/DSAGroup.java +++ b/src/main/java/net/pterodactylus/fcp/DSAGroup.java @@ -21,8 +21,8 @@ package net.pterodactylus.fcp; import java.security.interfaces.DSAParams; /** - * Container for the DSA group of a peer. A DSA group consists of a base (called - * “g”), a prime (called “p”) and a subprime (called “q”). + * Container for the DSA group of a peer. A DSA group consists of a base + * (called “g”), a prime (called “p”) and a subprime (called “q”). * * @see DSAParams * @author David ‘Bombe’ Roden <bombe@freenetproject.org> diff --git a/src/main/java/net/pterodactylus/fcp/DataFound.java b/src/main/java/net/pterodactylus/fcp/DataFound.java index 5151efd..742f6ac 100644 --- a/src/main/java/net/pterodactylus/fcp/DataFound.java +++ b/src/main/java/net/pterodactylus/fcp/DataFound.java @@ -20,8 +20,8 @@ package net.pterodactylus.fcp; /** * A “DataFound” message signals the client that the data requested by a - * {@link ClientGet} operation has been found. This message does not include the - * actual data, though. + * {@link ClientGet} operation has been found. This message does not include + * the actual data, though. * * @author David ‘Bombe’ Roden <bombe@freenetproject.org> */ diff --git a/src/main/java/net/pterodactylus/fcp/EndListPeerNotes.java b/src/main/java/net/pterodactylus/fcp/EndListPeerNotes.java index 5c381f6..31a52af 100644 --- a/src/main/java/net/pterodactylus/fcp/EndListPeerNotes.java +++ b/src/main/java/net/pterodactylus/fcp/EndListPeerNotes.java @@ -27,7 +27,8 @@ package net.pterodactylus.fcp; public class EndListPeerNotes extends BaseMessage { /** - * Creates a new “EndListPeerNotes” message that wraps the received message. + * Creates a new “EndListPeerNotes” message that wraps the received + * message. * * @param fcpMessage * The received message diff --git a/src/main/java/net/pterodactylus/fcp/EndListPersistentRequests.java b/src/main/java/net/pterodactylus/fcp/EndListPersistentRequests.java index 893f2f1..baa8de2 100644 --- a/src/main/java/net/pterodactylus/fcp/EndListPersistentRequests.java +++ b/src/main/java/net/pterodactylus/fcp/EndListPersistentRequests.java @@ -27,8 +27,8 @@ package net.pterodactylus.fcp; public class EndListPersistentRequests extends BaseMessage { /** - * Creates a new “EndListPersistentRequests” message that wraps the received - * message. + * Creates a new “EndListPersistentRequests” message that wraps the + * received message. * * @param receivedMessage * The received message diff --git a/src/main/java/net/pterodactylus/fcp/FCPPluginMessage.java b/src/main/java/net/pterodactylus/fcp/FCPPluginMessage.java index c167411..99cb0d0 100644 --- a/src/main/java/net/pterodactylus/fcp/FCPPluginMessage.java +++ b/src/main/java/net/pterodactylus/fcp/FCPPluginMessage.java @@ -38,9 +38,9 @@ public class FCPPluginMessage extends FcpMessage { } /** - * Sets the identifier of the request. Though this is still optional you are - * encouraged to include it because the plugin might reply in random order - * to requests. + * Sets the identifier of the request. Though this is still optional you + * are encouraged to include it because the plugin might reply in random + * order to requests. * * @param identifier * The identifier of the request @@ -63,8 +63,8 @@ public class FCPPluginMessage extends FcpMessage { /** * Sets the length of data of the optional payload. If you call this method - * you also have to call {@link #setPayloadInputStream(java.io.InputStream)} - * ! + * you also have to call + * {@link #setPayloadInputStream(java.io.InputStream)} ! * * @param dataLength * The length of data in the payload input stream diff --git a/src/main/java/net/pterodactylus/fcp/FcpConnection.java b/src/main/java/net/pterodactylus/fcp/FcpConnection.java index 2688d21..858b783 100644 --- a/src/main/java/net/pterodactylus/fcp/FcpConnection.java +++ b/src/main/java/net/pterodactylus/fcp/FcpConnection.java @@ -193,8 +193,8 @@ public class FcpConnection implements Closeable { } /** - * Closes the connection. If there is no connection to the node, this method - * does nothing. + * Closes the connection. If there is no connection to the node, this + * method does nothing. */ @Override public void close() { @@ -324,8 +324,8 @@ public class FcpConnection implements Closeable { * Handles a disconnect from the node. * * @param throwable - * The exception that caused the disconnect, or null - * if there was no exception + * The exception that caused the disconnect, or + * null if there was no exception */ synchronized void handleDisconnect(Throwable throwable) { FcpUtils.close(remoteInputStream); @@ -373,8 +373,8 @@ public class FcpConnection implements Closeable { } /** - * A wrapper around an {@link InputStream} that only supplies a limit number - * of bytes from the underlying input stream. + * A wrapper around an {@link InputStream} that only supplies a limit + * number of bytes from the underlying input stream. * * @author David ‘Bombe’ Roden <bombe@freenetproject.org> */ diff --git a/src/main/java/net/pterodactylus/fcp/FcpConnectionHandler.java b/src/main/java/net/pterodactylus/fcp/FcpConnectionHandler.java index 263860a..e46966a 100644 --- a/src/main/java/net/pterodactylus/fcp/FcpConnectionHandler.java +++ b/src/main/java/net/pterodactylus/fcp/FcpConnectionHandler.java @@ -101,7 +101,7 @@ class FcpConnectionHandler implements Runnable { } String field = line.substring(0, equalSign); String value = line.substring(equalSign + 1); - assert fcpMessage != null : "fcp message is null"; + assert fcpMessage != null: "fcp message is null"; fcpMessage.setField(field, value); } catch (IOException ioe1) { throwable = ioe1; diff --git a/src/main/java/net/pterodactylus/fcp/FcpListener.java b/src/main/java/net/pterodactylus/fcp/FcpListener.java index 4f0c77a..02eeed5 100644 --- a/src/main/java/net/pterodactylus/fcp/FcpListener.java +++ b/src/main/java/net/pterodactylus/fcp/FcpListener.java @@ -401,9 +401,10 @@ public interface FcpListener extends EventListener { public void receivedProtocolError(FcpConnection fcpConnection, ProtocolError protocolError); /** - * Notifies a listener that a message has been received. This method is only - * called if {@link FcpConnection#handleMessage(FcpMessage)} does not - * recognize the message. Should that ever happen, please file a bug report! + * Notifies a listener that a message has been received. This method is + * only called if {@link FcpConnection#handleMessage(FcpMessage)} does not + * recognize the message. Should that ever happen, please file a bug + * report! * * @param fcpConnection * The connection that received the message @@ -413,15 +414,15 @@ public interface FcpListener extends EventListener { public void receivedMessage(FcpConnection fcpConnection, FcpMessage fcpMessage); /** - * Notifies a listener that a connection was closed. A closed connection can - * be reestablished by calling {@link FcpConnection#connect()} on the same - * object again. + * Notifies a listener that a connection was closed. A closed connection + * can be reestablished by calling {@link FcpConnection#connect()} on the + * same object again. * * @param fcpConnection * The connection that was closed. * @param throwable - * The exception that caused the disconnect, or null - * if there was no exception + * The exception that caused the disconnect, or + * null if there was no exception */ public void connectionClosed(FcpConnection fcpConnection, Throwable throwable); diff --git a/src/main/java/net/pterodactylus/fcp/FcpListenerManager.java b/src/main/java/net/pterodactylus/fcp/FcpListenerManager.java index a312ec6..4f3b9dd 100644 --- a/src/main/java/net/pterodactylus/fcp/FcpListenerManager.java +++ b/src/main/java/net/pterodactylus/fcp/FcpListenerManager.java @@ -291,7 +291,8 @@ public class FcpListenerManager extends AbstractListenerManagernull - * if there was no exception + * The exception that caused the disconnect, or + * null if there was no exception * @see FcpListener#connectionClosed(FcpConnection, Throwable) */ public void fireConnectionClosed(Throwable throwable) { diff --git a/src/main/java/net/pterodactylus/fcp/FcpMessage.java b/src/main/java/net/pterodactylus/fcp/FcpMessage.java index 9b5d926..ed4ae46 100644 --- a/src/main/java/net/pterodactylus/fcp/FcpMessage.java +++ b/src/main/java/net/pterodactylus/fcp/FcpMessage.java @@ -59,9 +59,9 @@ public class FcpMessage implements Iterable { } /** - * Creates a new FCP message with the given name and the given payload input - * stream. The payload input stream is not read until the message is sent to - * the node using {@link FcpConnection#sendMessage(FcpMessage)}. + * Creates a new FCP message with the given name and the given payload + * input stream. The payload input stream is not read until the message is + * sent to the node using {@link FcpConnection#sendMessage(FcpMessage)}. * * @param name * The name of the message @@ -87,8 +87,8 @@ public class FcpMessage implements Iterable { * * @param field * The name of the field to check for - * @return true if the message has a field with the given name, - * false otherwise + * @return true if the message has a field with the given + * name, false otherwise */ public boolean hasField(String field) { return fields.containsKey(field); @@ -153,8 +153,8 @@ public class FcpMessage implements Iterable { * Writes this message to the given output stream. If the message has a * payload (i.e. {@link #payloadInputStream} is not null) the * payload is written to the given output stream after the message as well. - * That means that this method can only be called once because on the second - * invocation the payload input stream could not be read (again). + * That means that this method can only be called once because on the + * second invocation the payload input stream could not be read (again). * * @param outputStream * The output stream to write the message to diff --git a/src/main/java/net/pterodactylus/fcp/FcpUtils.java b/src/main/java/net/pterodactylus/fcp/FcpUtils.java index 0957083..415cf1a 100644 --- a/src/main/java/net/pterodactylus/fcp/FcpUtils.java +++ b/src/main/java/net/pterodactylus/fcp/FcpUtils.java @@ -110,8 +110,8 @@ public class FcpUtils { } /** - * Tries to parse the given string into an int, returning -1 if - * the string can not be parsed. + * Tries to parse the given string into an int, returning -1 + * if the string can not be parsed. * * @param value * The string to parse diff --git a/src/main/java/net/pterodactylus/fcp/GetConfig.java b/src/main/java/net/pterodactylus/fcp/GetConfig.java index 11e4cc6..230a790 100644 --- a/src/main/java/net/pterodactylus/fcp/GetConfig.java +++ b/src/main/java/net/pterodactylus/fcp/GetConfig.java @@ -58,8 +58,8 @@ public class GetConfig extends FcpMessage { } /** - * Sets whether the {@link ConfigData} result message shall include the long - * descriptions. + * Sets whether the {@link ConfigData} result message shall include the + * long descriptions. * * @param withLongDescription * true to include the long descriptions in the @@ -70,8 +70,8 @@ public class GetConfig extends FcpMessage { } /** - * Sets whether the {@link ConfigData} result message shall include the data - * types. + * Sets whether the {@link ConfigData} result message shall include the + * data types. * * @param withDataTypes * true to include the data types in the result, @@ -94,8 +94,8 @@ public class GetConfig extends FcpMessage { } /** - * Sets whether the {@link ConfigData} result message shall include the sort - * order. + * Sets whether the {@link ConfigData} result message shall include the + * sort order. * * @param withSortOrder * true to include the sort order in the result, diff --git a/src/main/java/net/pterodactylus/fcp/GetFailed.java b/src/main/java/net/pterodactylus/fcp/GetFailed.java index 837aa6b..01ec1c8 100644 --- a/src/main/java/net/pterodactylus/fcp/GetFailed.java +++ b/src/main/java/net/pterodactylus/fcp/GetFailed.java @@ -45,8 +45,8 @@ public class GetFailed extends BaseMessage implements Identifiable { /** * Returns the code of the error. * - * @return The code of the error, or -1 if the error code could - * not be parsed + * @return The code of the error, or -1 if the error code + * could not be parsed */ public int getCode() { return FcpUtils.safeParseInt(getField("Code")); @@ -119,10 +119,11 @@ public class GetFailed extends BaseMessage implements Identifiable { } /** - * Returns whether the expected values (see {@link #getExpectedDataLength()} - * and {@link #getExpectedMetadataContentType()}) have already been - * finalized and can be trusted. If the values have not been finalized that - * can change over time. + * Returns whether the expected values (see + * {@link #getExpectedDataLength()} and + * {@link #getExpectedMetadataContentType()}) have already been finalized + * and can be trusted. If the values have not been finalized that can + * change over time. * * @return true if the expected values have already been * finalized, false otherwise @@ -143,8 +144,8 @@ public class GetFailed extends BaseMessage implements Identifiable { } /** - * Returns whether the request failed fatally. If a request fails fatally it - * can never complete, even with inifinite retries. + * Returns whether the request failed fatally. If a request fails fatally + * it can never complete, even with inifinite retries. * * @return true if the request failed fatally, * false otherwise diff --git a/src/main/java/net/pterodactylus/fcp/GetNode.java b/src/main/java/net/pterodactylus/fcp/GetNode.java index 799b44b..3419860 100644 --- a/src/main/java/net/pterodactylus/fcp/GetNode.java +++ b/src/main/java/net/pterodactylus/fcp/GetNode.java @@ -27,17 +27,18 @@ package net.pterodactylus.fcp; public class GetNode extends FcpMessage { /** - * Creates a “GetNode” command that returns the darknet noderef of the node. + * Creates a “GetNode” command that returns the darknet noderef of the + * node. */ public GetNode() { this(null, null, null); } /** - * Creates a “GetNode” command that returns the request noderef of the node, - * including private and volatile data, if requested. If any of the Boolean - * parameters are null the parameter is ignored and the node’s - * default value is used. + * Creates a “GetNode” command that returns the request noderef of the + * node, including private and volatile data, if requested. If any of the + * Boolean parameters are null the parameter is ignored and + * the node’s default value is used. * * @param giveOpennetRef * true to request the opennet noderef, diff --git a/src/main/java/net/pterodactylus/fcp/GetRequestStatus.java b/src/main/java/net/pterodactylus/fcp/GetRequestStatus.java index 5e2d63b..14a0555 100644 --- a/src/main/java/net/pterodactylus/fcp/GetRequestStatus.java +++ b/src/main/java/net/pterodactylus/fcp/GetRequestStatus.java @@ -20,8 +20,9 @@ package net.pterodactylus.fcp; /** * The “GetRequestStatus” message is used request status information about a - * running request. It is also the only way to trigger a download of a persisted - * completed {@link ClientGet} with a return type of {@link ReturnType#direct}. + * running request. It is also the only way to trigger a download of a + * persisted completed {@link ClientGet} with a return type of + * {@link ReturnType#direct}. * * @author David ‘Bombe’ Roden <bombe@freenetproject.org> */ diff --git a/src/main/java/net/pterodactylus/fcp/ListPeer.java b/src/main/java/net/pterodactylus/fcp/ListPeer.java index f16f385..e96a389 100644 --- a/src/main/java/net/pterodactylus/fcp/ListPeer.java +++ b/src/main/java/net/pterodactylus/fcp/ListPeer.java @@ -27,9 +27,9 @@ public class ListPeer extends FcpMessage { /** * Creates a new “ListPeer” request that returns information about the node - * specified by nodeIdentifier. nodeIdentifier can - * be of several formats: The node’s name, its identity, or its IP address - * and port (connection with a ‘:’). + * specified by nodeIdentifier. nodeIdentifier + * can be of several formats: The node’s name, its identity, or its IP + * address and port (connection with a ‘:’). * * @param nodeIdentifier * The identifier of the node to get details about diff --git a/src/main/java/net/pterodactylus/fcp/ListPeers.java b/src/main/java/net/pterodactylus/fcp/ListPeers.java index b0cbd1b..b69e5ee 100644 --- a/src/main/java/net/pterodactylus/fcp/ListPeers.java +++ b/src/main/java/net/pterodactylus/fcp/ListPeers.java @@ -37,7 +37,8 @@ public class ListPeers extends FcpMessage { } /** - * Creates a new “ListPeers” request that includes wanted data of the peers. + * Creates a new “ListPeers” request that includes wanted data of the + * peers. * * @param identifier * The identifier of the request @@ -45,8 +46,8 @@ public class ListPeers extends FcpMessage { * If true metadata of the peers is included in the * reply * @param withVolatile - * if true volatile data of the peers is included in - * the reply + * if true volatile data of the peers is included + * in the reply */ public ListPeers(String identifier, boolean withMetadata, boolean withVolatile) { super("ListPeers"); diff --git a/src/main/java/net/pterodactylus/fcp/ModifyPeer.java b/src/main/java/net/pterodactylus/fcp/ModifyPeer.java index dc9af6b..dfc5aa2 100644 --- a/src/main/java/net/pterodactylus/fcp/ModifyPeer.java +++ b/src/main/java/net/pterodactylus/fcp/ModifyPeer.java @@ -26,12 +26,12 @@ package net.pterodactylus.fcp; public class ModifyPeer extends FcpMessage { /** - * Creates a new “ModifyPeer” request. All Boolean parameters may be null to - * not influence the current setting. + * Creates a new “ModifyPeer” request. All Boolean parameters may be null + * to not influence the current setting. * * @param nodeIdentifier - * The identifier of the node, i.e. name, identity, or IP address - * and port + * The identifier of the node, i.e. name, identity, or IP + * address and port * @param allowLocalAddresses * Whether to allow local addresses from this node * @param disabled diff --git a/src/main/java/net/pterodactylus/fcp/ModifyPeerNote.java b/src/main/java/net/pterodactylus/fcp/ModifyPeerNote.java index dbb2ea7..6fcc088 100644 --- a/src/main/java/net/pterodactylus/fcp/ModifyPeerNote.java +++ b/src/main/java/net/pterodactylus/fcp/ModifyPeerNote.java @@ -31,8 +31,8 @@ public class ModifyPeerNote extends FcpMessage { * * @see PeerNote * @param nodeIdentifier - * The identifier of the node, i.e. name, identity, or IP address - * and port + * The identifier of the node, i.e. name, identity, or IP + * address and port * @param noteText * The base64-encoded text * @param peerNoteType diff --git a/src/main/java/net/pterodactylus/fcp/NodeData.java b/src/main/java/net/pterodactylus/fcp/NodeData.java index 5425833..f73bbd5 100644 --- a/src/main/java/net/pterodactylus/fcp/NodeData.java +++ b/src/main/java/net/pterodactylus/fcp/NodeData.java @@ -159,10 +159,10 @@ public class NodeData extends BaseMessage { } /** - * Returns one of the volatile fields from the message. The given field name - * is prepended with “volatile.” so if you want to get the value of the - * field with the name “volatile.freeJavaMemory” you only need to specify - * “freeJavaMemory”. + * Returns one of the volatile fields from the message. The given field + * name is prepended with “volatile.” so if you want to get the value of + * the field with the name “volatile.freeJavaMemory” you only need to + * specify “freeJavaMemory”. * * @param field * The name of the field diff --git a/src/main/java/net/pterodactylus/fcp/NodeHello.java b/src/main/java/net/pterodactylus/fcp/NodeHello.java index 01b0515..7409d9b 100644 --- a/src/main/java/net/pterodactylus/fcp/NodeHello.java +++ b/src/main/java/net/pterodactylus/fcp/NodeHello.java @@ -36,8 +36,8 @@ public class NodeHello extends BaseMessage { } /** - * Returns the build of the node. This may not be a number but also a string - * like “@custom@” in case you built the node yourself. + * Returns the build of the node. This may not be a number but also a + * string like “@custom@” in case you built the node yourself. * * @return The build of the node */ @@ -46,8 +46,8 @@ public class NodeHello extends BaseMessage { } /** - * Returns the build number of the node. This may not be a number but also a - * string like “@custom@” in case you built the node yourself. + * Returns the build number of the node. This may not be a number but also + * a string like “@custom@” in case you built the node yourself. * * @return The build number of the node, or -1 if the build * number could not be determined @@ -96,8 +96,8 @@ public class NodeHello extends BaseMessage { /** * Returns the build number of the external library file. * - * @return The build number of the external library file, or -1 - * if the build number could not be determined + * @return The build number of the external library file, or + * -1 if the build number could not be determined */ public int getExtBuildNumber() { return FcpUtils.safeParseInt(getExtBuild()); diff --git a/src/main/java/net/pterodactylus/fcp/NodeRef.java b/src/main/java/net/pterodactylus/fcp/NodeRef.java index 64ca56c..e96d15f 100644 --- a/src/main/java/net/pterodactylus/fcp/NodeRef.java +++ b/src/main/java/net/pterodactylus/fcp/NodeRef.java @@ -138,8 +138,8 @@ public class NodeRef { } /** - * Returns the name of the node. If the node is an opennet peer, it will not - * have a name! + * Returns the name of the node. If the node is an opennet peer, it will + * not have a name! * * @return The name of the node, or null if the node is an * opennet peer diff --git a/src/main/java/net/pterodactylus/fcp/Peer.java b/src/main/java/net/pterodactylus/fcp/Peer.java index fff70cb..df1c8f0 100644 --- a/src/main/java/net/pterodactylus/fcp/Peer.java +++ b/src/main/java/net/pterodactylus/fcp/Peer.java @@ -213,9 +213,10 @@ public class Peer extends BaseMessage implements Identifiable { } /** - * Returns one of the volatile fields from the message. The given field name - * is prepended with “volatile.” so if you want to get the value of the - * field with the name “volatile.status” you only need to specify “status”. + * Returns one of the volatile fields from the message. The given field + * name is prepended with “volatile.” so if you want to get the value of + * the field with the name “volatile.status” you only need to specify + * “status”. * * @param field * The name of the field @@ -242,10 +243,10 @@ public class Peer extends BaseMessage implements Identifiable { } /** - * Returns one of the metadata fields from the message. The given field name - * is prepended with “metadata.” so if you want to get the value of the - * field with the name “metadata.timeLastRoutable” you only need to specify - * “timeLastRoutable”. + * Returns one of the metadata fields from the message. The given field + * name is prepended with “metadata.” so if you want to get the value of + * the field with the name “metadata.timeLastRoutable” you only need to + * specify “timeLastRoutable”. * * @param field * The name of the field diff --git a/src/main/java/net/pterodactylus/fcp/PeerNote.java b/src/main/java/net/pterodactylus/fcp/PeerNote.java index 7b32207..67cdfa6 100644 --- a/src/main/java/net/pterodactylus/fcp/PeerNote.java +++ b/src/main/java/net/pterodactylus/fcp/PeerNote.java @@ -60,8 +60,8 @@ public class PeerNote extends BaseMessage { /** * Returns the type of the peer note. * - * @return The type of the peer note, or -1 if the type can not - * be parsed + * @return The type of the peer note, or -1 if the type can + * not be parsed */ public int getPeerNoteType() { return FcpUtils.safeParseInt(getField("PeerNoteType")); diff --git a/src/main/java/net/pterodactylus/fcp/PersistentGet.java b/src/main/java/net/pterodactylus/fcp/PersistentGet.java index 73a043a..c7bfe20 100644 --- a/src/main/java/net/pterodactylus/fcp/PersistentGet.java +++ b/src/main/java/net/pterodactylus/fcp/PersistentGet.java @@ -20,7 +20,8 @@ package net.pterodactylus.fcp; /** * The “PersistentGet” message is sent to the client to inform it about a - * persistent download, either in the client-local queue or in the global queue. + * persistent download, either in the client-local queue or in the global + * queue. * * @author David ‘Bombe’ Roden <bombe@freenetproject.org> */ @@ -118,8 +119,8 @@ public class PersistentGet extends BaseMessage implements Identifiable { /** * Returns the persistence of the request. * - * @return The persistence of the request, or {@link Persistence#unknown} if - * the persistence could not be parsed + * @return The persistence of the request, or {@link Persistence#unknown} + * if the persistence could not be parsed */ public Persistence getPersistence() { try { @@ -143,9 +144,9 @@ public class PersistentGet extends BaseMessage implements Identifiable { /** * Returns the maximum number of retries for a failed block. * - * @return The maximum number of retries for a failed block, -1 - * for endless retries, -2 if the number could not be - * parsed + * @return The maximum number of retries for a failed block, + * -1 for endless retries, -2 if the + * number could not be parsed */ public int getMaxRetries() { return FcpUtils.safeParseInt(getField("MaxRetries"), -2); diff --git a/src/main/java/net/pterodactylus/fcp/PersistentPutDir.java b/src/main/java/net/pterodactylus/fcp/PersistentPutDir.java index 6d59d6d..b68c84c 100644 --- a/src/main/java/net/pterodactylus/fcp/PersistentPutDir.java +++ b/src/main/java/net/pterodactylus/fcp/PersistentPutDir.java @@ -28,7 +28,8 @@ package net.pterodactylus.fcp; public class PersistentPutDir extends BaseMessage implements Identifiable { /** - * Creates a new “PersistentPutDir” message that wraps the received message. + * Creates a new “PersistentPutDir” message that wraps the received + * message. * * @param receivedMessage * The received message diff --git a/src/main/java/net/pterodactylus/fcp/PersistentRequestModified.java b/src/main/java/net/pterodactylus/fcp/PersistentRequestModified.java index 78f73bc..f1d2371 100644 --- a/src/main/java/net/pterodactylus/fcp/PersistentRequestModified.java +++ b/src/main/java/net/pterodactylus/fcp/PersistentRequestModified.java @@ -27,8 +27,8 @@ package net.pterodactylus.fcp; public class PersistentRequestModified extends BaseMessage implements Identifiable { /** - * Creates a new “PersistentRequestModified” message that wraps the received - * message. + * Creates a new “PersistentRequestModified” message that wraps the + * received message. * * @param receivedMessage * The received message diff --git a/src/main/java/net/pterodactylus/fcp/PersistentRequestRemoved.java b/src/main/java/net/pterodactylus/fcp/PersistentRequestRemoved.java index becf346..c9ec826 100644 --- a/src/main/java/net/pterodactylus/fcp/PersistentRequestRemoved.java +++ b/src/main/java/net/pterodactylus/fcp/PersistentRequestRemoved.java @@ -51,8 +51,8 @@ public class PersistentRequestRemoved extends BaseMessage implements Identifiabl * Returns whether the request was removed from the global queue. * * @return true if the request was removed from the global - * queue, false if it was removed from the client-local - * queue + * queue, false if it was removed from the + * client-local queue */ public boolean isGlobal() { return Boolean.valueOf(getField("Global")); diff --git a/src/main/java/net/pterodactylus/fcp/ProtocolError.java b/src/main/java/net/pterodactylus/fcp/ProtocolError.java index f59d1fe..8b7b510 100644 --- a/src/main/java/net/pterodactylus/fcp/ProtocolError.java +++ b/src/main/java/net/pterodactylus/fcp/ProtocolError.java @@ -48,8 +48,8 @@ public class ProtocolError extends BaseMessage { /** * Returns the error code. * - * @return The error code, or -1 if the error code could not be - * parsed + * @return The error code, or -1 if the error code could not + * be parsed */ public int getCode() { return FcpUtils.safeParseInt(getField("Code")); diff --git a/src/main/java/net/pterodactylus/fcp/PutFailed.java b/src/main/java/net/pterodactylus/fcp/PutFailed.java index 375d924..8535bcb 100644 --- a/src/main/java/net/pterodactylus/fcp/PutFailed.java +++ b/src/main/java/net/pterodactylus/fcp/PutFailed.java @@ -45,8 +45,8 @@ public class PutFailed extends BaseMessage implements Identifiable { /** * Returns the code of the error. * - * @return The code of the error, or -1 if the error code could - * not be parsed + * @return The code of the error, or -1 if the error code + * could not be parsed */ public int getCode() { return FcpUtils.safeParseInt(getField("Code")); @@ -109,8 +109,8 @@ public class PutFailed extends BaseMessage implements Identifiable { } /** - * Returns whether the request failed fatally. If a request fails fatally it - * can never complete, even with inifinite retries. + * Returns whether the request failed fatally. If a request fails fatally + * it can never complete, even with inifinite retries. * * @return true if the request failed fatally, * false otherwise diff --git a/src/main/java/net/pterodactylus/fcp/ReceivedBookmarkFeed.java b/src/main/java/net/pterodactylus/fcp/ReceivedBookmarkFeed.java index 02369f0..3b54177 100644 --- a/src/main/java/net/pterodactylus/fcp/ReceivedBookmarkFeed.java +++ b/src/main/java/net/pterodactylus/fcp/ReceivedBookmarkFeed.java @@ -57,16 +57,16 @@ public class ReceivedBookmarkFeed extends BaseMessage { /** * Returns whether the bookmark has an active link image. * - * @return {@code true} if the bookmark has an active link image, {@code - * false} otherwise + * @return {@code true} if the bookmark has an active link image, + * {@code false} otherwise */ public boolean hasActiveLink() { return Boolean.parseBoolean(getField("HasAnActiveLink")); } /** - * Returns the description of the bookmark. Note that the description may be - * {@code null} and if it is not, it is base64-encoded! + * Returns the description of the bookmark. Note that the description may + * be {@code null} and if it is not, it is base64-encoded! * * @return The bookmark’s description, or {@code null} if the bookmark has * no description diff --git a/src/main/java/net/pterodactylus/fcp/SendBookmarkFeed.java b/src/main/java/net/pterodactylus/fcp/SendBookmarkFeed.java index 522e830..69191fc 100644 --- a/src/main/java/net/pterodactylus/fcp/SendBookmarkFeed.java +++ b/src/main/java/net/pterodactylus/fcp/SendBookmarkFeed.java @@ -39,8 +39,8 @@ public class SendBookmarkFeed extends AbstractSendFeedMessage { * @param description * The description of the bookmark (may be {@code null}) * @param hasActiveLink - * {@code true} if the bookmark has an activelink image, {@code - * false} otherwise + * {@code true} if the bookmark has an activelink image, + * {@code false} otherwise */ public SendBookmarkFeed(String identifier, String nodeIdentifier, String name, String uri, String description, boolean hasActiveLink) { super("SendBookmarkFeed", identifier, nodeIdentifier); diff --git a/src/main/java/net/pterodactylus/fcp/SubscribedUSKUpdate.java b/src/main/java/net/pterodactylus/fcp/SubscribedUSKUpdate.java index 7d25c2d..d2e132d 100644 --- a/src/main/java/net/pterodactylus/fcp/SubscribedUSKUpdate.java +++ b/src/main/java/net/pterodactylus/fcp/SubscribedUSKUpdate.java @@ -19,11 +19,11 @@ package net.pterodactylus.fcp; /** - * A “SubscribedUSKUpdate” message is sent each time a new edition of a USK that - * was previously subscribed to with {@link SubscribeUSK} was found. Note that - * if the new edition that was found is several editions ahead of the currently - * last known edition, you will received a SubscribedUSKUpdate for each edition - * inbetween as welL! + * A “SubscribedUSKUpdate” message is sent each time a new edition of a USK + * that was previously subscribed to with {@link SubscribeUSK} was found. Note + * that if the new edition that was found is several editions ahead of the + * currently last known edition, you will received a SubscribedUSKUpdate for + * each edition inbetween as welL! * * @author David ‘Bombe’ Roden <bombe@freenetproject.org> */ diff --git a/src/main/java/net/pterodactylus/fcp/TestDDAReply.java b/src/main/java/net/pterodactylus/fcp/TestDDAReply.java index bf102d6..9764a02 100644 --- a/src/main/java/net/pterodactylus/fcp/TestDDAReply.java +++ b/src/main/java/net/pterodactylus/fcp/TestDDAReply.java @@ -22,8 +22,9 @@ package net.pterodactylus.fcp; * The “TestDDAReply” is sent as a response to {@link TestDDARequest}. If you * specified that you wanted to read files from that directory * {@link #getReadFilename()} will give you a filename. Similarly, if you - * specified that you want to write in the directory {@link #getWriteFilename()} - * will give you a filename to write {@link #getContentToWrite()} to. + * specified that you want to write in the directory + * {@link #getWriteFilename()} will give you a filename to write + * {@link #getContentToWrite()} to. * * @author David ‘Bombe’ Roden <bombe@freenetproject.org> */ diff --git a/src/main/java/net/pterodactylus/fcp/TestDDARequest.java b/src/main/java/net/pterodactylus/fcp/TestDDARequest.java index 89a0202..4f5c9a0 100644 --- a/src/main/java/net/pterodactylus/fcp/TestDDARequest.java +++ b/src/main/java/net/pterodactylus/fcp/TestDDARequest.java @@ -31,7 +31,8 @@ public class TestDDARequest extends FcpMessage { * @param directory * The directory you want to access files in * @param wantReadDirectory - * true if you want to read files from the directory + * true if you want to read files from the + * directory * @param wantWriteDirectory * true if you want to write files to the directory */ diff --git a/src/main/java/net/pterodactylus/fcp/TestDDAResponse.java b/src/main/java/net/pterodactylus/fcp/TestDDAResponse.java index 76660c5..2d6d2a4 100644 --- a/src/main/java/net/pterodactylus/fcp/TestDDAResponse.java +++ b/src/main/java/net/pterodactylus/fcp/TestDDAResponse.java @@ -21,15 +21,16 @@ package net.pterodactylus.fcp; /** * A “TestDDAResponse” is sent to let the node know that either created a file * with the content from {@link TestDDAReply#getContentToWrite()} or that you - * read the content of the file given by {@link TestDDAReply#getReadFilename()}. + * read the content of the file given by {@link TestDDAReply#getReadFilename()} + * . * * @author David ‘Bombe’ Roden <bombe@freenetproject.org> */ public class TestDDAResponse extends FcpMessage { /** - * Creates a new “TestDDAResponse” message that signals that you created the - * file given by {@link TestDDAReply#getWriteFilename()} and wrote the + * Creates a new “TestDDAResponse” message that signals that you created + * the file given by {@link TestDDAReply#getWriteFilename()} and wrote the * contents given by {@link TestDDAReply#getContentToWrite()} to it. * * @param directory @@ -40,11 +41,11 @@ public class TestDDAResponse extends FcpMessage { } /** - * Creates a new “TestDDAResponse” message that signals that you created the - * file given by {@link TestDDAReply#getWriteFilename()} with the contents - * given by {@link TestDDAReply#getContentToWrite()} to it (when you - * specified that you want to write to the directory) and/or that you read - * the file given by {@link TestDDAReply#getReadFilename()} (when you + * Creates a new “TestDDAResponse” message that signals that you created + * the file given by {@link TestDDAReply#getWriteFilename()} with the + * contents given by {@link TestDDAReply#getContentToWrite()} to it (when + * you specified that you want to write to the directory) and/or that you + * read the file given by {@link TestDDAReply#getReadFilename()} (when you * specified you wanted to read the directory). * * @param directory diff --git a/src/main/java/net/pterodactylus/fcp/URIGenerated.java b/src/main/java/net/pterodactylus/fcp/URIGenerated.java index 663148f..4939570 100644 --- a/src/main/java/net/pterodactylus/fcp/URIGenerated.java +++ b/src/main/java/net/pterodactylus/fcp/URIGenerated.java @@ -19,9 +19,9 @@ package net.pterodactylus.fcp; /** - * The “URIGenerated” message signals the client that an URI was generated for a - * {@link ClientPut} (or {@link ClientPutDiskDir} or {@link ClientPutComplexDir} - * ) request. + * The “URIGenerated” message signals the client that an URI was generated for + * a {@link ClientPut} (or {@link ClientPutDiskDir} or + * {@link ClientPutComplexDir} ) request. * * @author David ‘Bombe’ Roden <bombe@freenetproject.org> */ @@ -57,8 +57,8 @@ public class URIGenerated extends BaseMessage implements Identifiable { } /** - * Returns whether the request that generated the URI is on the global queue - * or on the client-local queue. + * Returns whether the request that generated the URI is on the global + * queue or on the client-local queue. * * @return true if the request is on the global queue, * false if it is on the client-local queue diff --git a/src/main/java/net/pterodactylus/fcp/Verbosity.java b/src/main/java/net/pterodactylus/fcp/Verbosity.java index 62a2da8..0dac50c 100644 --- a/src/main/java/net/pterodactylus/fcp/Verbosity.java +++ b/src/main/java/net/pterodactylus/fcp/Verbosity.java @@ -20,8 +20,8 @@ package net.pterodactylus.fcp; /** * Convenicence class for verbosity handling. This might come in handy with the - * {@link ClientPut} and {@link ClientGet} requests. The verbosity is a bit-mask - * that can be composed of several bits. {@link #PROGRESS} and + * {@link ClientPut} and {@link ClientGet} requests. The verbosity is a + * bit-mask that can be composed of several bits. {@link #PROGRESS} and * {@link #COMPRESSION} are single bits in that mask and can be combined into a * new verbosity using {@link #add(Verbosity)}. * @@ -91,8 +91,8 @@ public class Verbosity { * * @param s * The string to parse - * @return The parsed verbosity, or {@link #NONE} if the string could not be - * parsed + * @return The parsed verbosity, or {@link #NONE} if the string could not + * be parsed */ public static Verbosity valueOf(String s) { try { diff --git a/src/main/java/net/pterodactylus/fcp/Version.java b/src/main/java/net/pterodactylus/fcp/Version.java index 0f1d5cb..0f1de3e 100644 --- a/src/main/java/net/pterodactylus/fcp/Version.java +++ b/src/main/java/net/pterodactylus/fcp/Version.java @@ -41,8 +41,8 @@ public class Version { /** * Creates a new Version from the given string. The string consists of the - * four required fields node name, tree version, protocol version, and build - * number, separated by a comma. + * four required fields node name, tree version, protocol version, and + * build number, separated by a comma. * * @param version * The version string diff --git a/src/main/java/net/pterodactylus/fcp/highlevel/FcpClient.java b/src/main/java/net/pterodactylus/fcp/highlevel/FcpClient.java index 7364aa8..56fb90d 100644 --- a/src/main/java/net/pterodactylus/fcp/highlevel/FcpClient.java +++ b/src/main/java/net/pterodactylus/fcp/highlevel/FcpClient.java @@ -602,8 +602,8 @@ public class FcpClient implements Closeable { /** * Adds a peer, reading the noderef of the peer from the given file. - * Note: the file to read the noderef from has to reside on - * the same machine as the node! + * Note: the file to read the noderef from has to reside + * on the same machine as the node! * * @param file * The name of the file containing the peer’s noderef @@ -913,8 +913,8 @@ public class FcpClient implements Closeable { * * @param global * true to return requests from the global queue, - * false to only show requests from the client-local - * queue + * false to only show requests from the + * client-local queue * @return All requests * @throws IOException * if an I/O error occurs diff --git a/src/main/java/net/pterodactylus/fcp/highlevel/Request.java b/src/main/java/net/pterodactylus/fcp/highlevel/Request.java index 2038523..4b73398 100644 --- a/src/main/java/net/pterodactylus/fcp/highlevel/Request.java +++ b/src/main/java/net/pterodactylus/fcp/highlevel/Request.java @@ -132,7 +132,8 @@ public abstract class Request { * Sets whether this request is complete. * * @param complete - * true if this request is complete, false otherwise + * true if this request is complete, false + * otherwise */ void setComplete(boolean complete) { this.complete = complete; @@ -219,8 +220,8 @@ public abstract class Request { } /** - * Returns whether this request has fatally failed, i.e. repitition will not - * cause the request to succeed. + * Returns whether this request has fatally failed, i.e. repitition will + * not cause the request to succeed. * * @return true if this request can not be made succeed by * repeating, false otherwise @@ -260,8 +261,8 @@ public abstract class Request { } /** - * Returns the number of required blocks. Any progress percentages should be - * calculated against this value as 100%. Also, as long as + * Returns the number of required blocks. Any progress percentages should + * be calculated against this value as 100%. Also, as long as * {@link #isFinalizedTotal()} returns {@code false} this value might * change. * diff --git a/src/main/java/net/pterodactylus/fcp/package-info.java b/src/main/java/net/pterodactylus/fcp/package-info.java index dbda870..04b0cc6 100644 --- a/src/main/java/net/pterodactylus/fcp/package-info.java +++ b/src/main/java/net/pterodactylus/fcp/package-info.java @@ -1,33 +1,33 @@ /** * Package that holds all the message types that are used in the communication * with a Freenet Node. - * + * *

Usage

- * + * * This library was designed to implement the full range of the Freenet Client * Protocol, Version 2.0. At the moment the library provides a rather low-level * approach, wrapping each FCP message into its own object but some kind of * high-level client that does not require any interfaces to be implemented * will probably provided as well. - * + * * First, create a connection to the node: - * + * *
  * FcpConnection fcpConnection = new FcpConnection();
  * 
- * + * * Now implement the {@link net.pterodactylus.fcp.FcpListener} interface * and handle all incoming events. - * + * *
  * public class MyClass implements FcpListener {
- * 
+ *
  * 	public void receivedProtocolError(FcpConnection fcpConnection, ProtocolError protocolError) {
  * 		…
  * 	}
- * 
+ *
  * 	// implement all further methods here
- * 
+ *
  * }
  * 
*/ -- 2.7.4