--- /dev/null
+/**
+ * © 2008 INA Service GmbH
+ */
+package net.pterodactylus.util.fcp;
+
+/**
+ * The “GetNode” command returns the darknet or opennet noderef of the node,
+ * optionally including private and volatile data.
+ *
+ * @author <a href="mailto:dr@ina-germany.de">David Roden</a>
+ * @version $Id$
+ */
+public class GetNode extends FcpMessage {
+
+ /**
+ * 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 <code>null</code> the parameter is ignored and the
+ * node’s default value is used.
+ *
+ * @param giveOpennetRef
+ * <code>true</code> to request the opennet noderef,
+ * <code>false</code> for darknet
+ * @param withPrivate
+ * <code>true</code> to include private data in the noderef
+ * @param withVolatile
+ * <code>true</code> to include volatile data in the noderef
+ */
+ public GetNode(Boolean giveOpennetRef, Boolean withPrivate, Boolean withVolatile) {
+ super("GetNode");
+ if (giveOpennetRef != null) {
+ setField("GiveOpennetRef", String.valueOf(giveOpennetRef));
+ }
+ if (withPrivate != null) {
+ setField("WithPrivate", String.valueOf(withPrivate));
+ }
+ if (withVolatile != null) {
+ setField("WithVolatile", String.valueOf(withVolatile));
+ }
+ }
+
+}