0da990816484cdc7ba23d10fef59c6c7e4b5b6d7
[jSite2.git] / src / net / pterodactylus / util / fcp / ModifyPeerNote.java
1 /**
2  * © 2008 INA Service GmbH
3  */
4 package net.pterodactylus.util.fcp;
5
6 /**
7  * The “ModifyPeerNote” command modifies a peer note.
8  * 
9  * @author David ‘Bombe’ Roden <bombe@freenetproject.org>
10  * @version $Id$
11  */
12 public class ModifyPeerNote extends FcpMessage {
13
14         /**
15          * Creates a new “ModifyPeerNote” request that changes peer note of the
16          * given type and node to the given text.
17          * 
18          * @see PeerNote
19          * @param nodeIdentifier
20          *            The identifier of the node, i.e. name, identity, or IP address
21          *            and port
22          * @param noteText
23          *            The base64-encoded text
24          * @param peerNoteType
25          *            The type of the note to change, possible values are only
26          *            {@link PeerNote#TYPE_PRIVATE_PEER_NOTE} at the moment
27          */
28         public ModifyPeerNote(String nodeIdentifier, String noteText, int peerNoteType) {
29                 super("ModifyPeer");
30                 setField("NodeIdentifier", nodeIdentifier);
31                 setField("NoteText", noteText);
32                 setField("PeerNoteType", String.valueOf(peerNoteType));
33         }
34
35 }