X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=src%2Fde%2Ftodesbaum%2Futil%2Ffreenet%2Ffcp2%2FMessage.java;h=6c934ec578adb54fc98792e9d5596844d0be970c;hb=refs%2Ftags%2F0.10;hp=a8460f80d1a8699bcec0cbf21b9decad5d56a1d2;hpb=6f1a8216cfba28add0ef365b46a08d16d4eb87fe;p=jSite.git
diff --git a/src/de/todesbaum/util/freenet/fcp2/Message.java b/src/de/todesbaum/util/freenet/fcp2/Message.java
index a8460f8..6c934ec 100644
--- a/src/de/todesbaum/util/freenet/fcp2/Message.java
+++ b/src/de/todesbaum/util/freenet/fcp2/Message.java
@@ -1,6 +1,5 @@
/*
- * todesbaum-lib -
- * Copyright (C) 2006 David Roden
+ * jSite - Message.java - Copyright © 2006â2012 David Roden
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -22,17 +21,17 @@ package de.todesbaum.util.freenet.fcp2;
import java.io.InputStream;
import java.util.HashMap;
import java.util.Map;
-import java.util.Set;
import java.util.Map.Entry;
+import java.util.Set;
/**
* Contains replies sent by the Freenet node. A message always has a name, and
* most of the messages also have an identifier which binds it to a specific
* command. Exceptions are among others NodeHello
,
* SSKKeypair
, and EndListPersistentRequests
.
- *
+ *
* @author David Roden <droden@gmail.com>
- * @version $Id: Message.java 413 2006-03-29 12:22:31Z bombe $
+ * @version $Id$
* @see de.todesbaum.util.freenet.fcp2.Client
*/
public class Message {
@@ -51,7 +50,7 @@ public class Message {
/**
* Creates a new message with the specified name.
- *
+ *
* @param name
* The name of this message
*/
@@ -61,7 +60,7 @@ public class Message {
/**
* Returns the identifier of this message.
- *
+ *
* @return The identifier
*/
public String getIdentifier() {
@@ -70,7 +69,7 @@ public class Message {
/**
* Sets the identifier of this message.
- *
+ *
* @param identifier
* The identifier of this message
*/
@@ -80,7 +79,7 @@ public class Message {
/**
* Returns the name of this message.
- *
+ *
* @return The name of this message
*/
public String getName() {
@@ -90,7 +89,7 @@ public class Message {
/**
* Tests whether this message contains the parameter with the specified key.
* Key names are compared ignoring case.
- *
+ *
* @param key
* The name of the parameter
* @return true
if this parameter exists in this message,
@@ -104,7 +103,7 @@ public class Message {
* Returns all parameters of this message. The keys of the entries are all
* lower case so if you want to match the parameter names you have to watch
* out.
- *
+ *
* @return All parameters of this message
*/
public Set> entrySet() {
@@ -114,7 +113,7 @@ public class Message {
/**
* Returns the value of the parameter with the name specified by
* key
.
- *
+ *
* @param key
* The name of the parameter
* @return The value of the parameter
@@ -126,7 +125,7 @@ public class Message {
/**
* Stores the specified value as parameter with the name specified by
* key
.
- *
+ *
* @param key
* The name of the parameter
* @param value
@@ -140,7 +139,7 @@ public class Message {
/**
* Returns the number of parameters in this message.
- *
+ *
* @return The number of parameters
*/
public int size() {
@@ -165,9 +164,10 @@ public class Message {
/**
* Returns a textual representation of this message, containing its name,
* the identifier, and the parameters.
- *
+ *
* @return A textual representation of this message
*/
+ @Override
public String toString() {
return name + "[identifier=" + identifier + ",parameters=" + parameters.toString() + "]";
}