--- /dev/null
+/**
+ * © 2008 INA Service GmbH
+ */
+package net.pterodactylus.util.fcp;
+
+/**
+ * The “ModifyPeer” request lets you modify certain properties of a peer.
+ *
+ * @author <a href="mailto:dr@ina-germany.de">David Roden</a>
+ * @version $Id$
+ */
+public class ModifyPeer extends FcpMessage {
+
+ /**
+ * 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
+ * @param allowLocalAddresses
+ * Whether to allow local addresses from this node
+ * @param disabled
+ * Whether the node is disabled
+ * @param listenOnly
+ * Whether your node should not try to connect the node
+ */
+ public ModifyPeer(String nodeIdentifier, Boolean allowLocalAddresses, Boolean disabled, Boolean listenOnly) {
+ super("ModifyPeer");
+ setField("NodeIdentifier", nodeIdentifier);
+ if (allowLocalAddresses != null) {
+ setField("AllowLocalAddresses", String.valueOf(allowLocalAddresses));
+ }
+ if (disabled != null) {
+ setField("IsDisabled", String.valueOf(disabled));
+ }
+ if (listenOnly != null) {
+ setField("IsListenOnly", String.valueOf(listenOnly));
+ }
+ }
+
+}