X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;ds=inline;f=src%2Fnet%2Fpterodactylus%2Futil%2Ffcp%2FModifyPeerNote.java;fp=src%2Fnet%2Fpterodactylus%2Futil%2Ffcp%2FModifyPeerNote.java;h=452f0eaf18db32ae8c93917a723dca214ca8cdda;hb=289aef70eee27a2c70a4e7c0f13adfcfd315ddc3;hp=0000000000000000000000000000000000000000;hpb=95f0f5420b656638731a6c4ea2ae3c7aa7a5a967;p=jSite2.git diff --git a/src/net/pterodactylus/util/fcp/ModifyPeerNote.java b/src/net/pterodactylus/util/fcp/ModifyPeerNote.java new file mode 100644 index 0000000..452f0ea --- /dev/null +++ b/src/net/pterodactylus/util/fcp/ModifyPeerNote.java @@ -0,0 +1,35 @@ +/** + * © 2008 INA Service GmbH + */ +package net.pterodactylus.util.fcp; + +/** + * The “ModifyPeerNote” command modifies a peer note. + * + * @author David Roden + * @version $Id$ + */ +public class ModifyPeerNote extends FcpMessage { + + /** + * Creates a new “ModifyPeerNote” request that changes peer note of the + * given type and node to the given text. + * + * @see PeerNote + * @param nodeIdentifier + * The identifier of the node, i.e. name, identity, or IP address + * and port + * @param noteText + * The base64-encoded text + * @param peerNoteType + * The type of the note to change, possible values are only + * {@link PeerNote#TYPE_PRIVATE_PEER_NOTE} at the moment + */ + public ModifyPeerNote(String nodeIdentifier, String noteText, int peerNoteType) { + super("ModifyPeer"); + setField("NodeIdentifier", nodeIdentifier); + setField("NoteText", noteText); + setField("PeerNoteType", String.valueOf(peerNoteType)); + } + +}