2 * © 2008 INA Service GmbH
4 package net.pterodactylus.util.fcp;
7 * The “GetNode” command returns the darknet or opennet noderef of the node,
8 * optionally including private and volatile data.
10 * @author David ‘Bombe’ Roden <bombe@freenetproject.org>
13 public class GetNode extends FcpMessage {
16 * Creates a “GetNode” command that returns the darknet noderef of the node.
19 this(null, null, null);
23 * Creates a “GetNode” command that returns the request noderef of the node,
24 * including private and volatile data, if requested. If any of the Boolean
25 * parameters are <code>null</code> the parameter is ignored and the
26 * node’s default value is used.
28 * @param giveOpennetRef
29 * <code>true</code> to request the opennet noderef,
30 * <code>false</code> for darknet
32 * <code>true</code> to include private data in the noderef
34 * <code>true</code> to include volatile data in the noderef
36 public GetNode(Boolean giveOpennetRef, Boolean withPrivate, Boolean withVolatile) {
38 if (giveOpennetRef != null) {
39 setField("GiveOpennetRef", String.valueOf(giveOpennetRef));
41 if (withPrivate != null) {
42 setField("WithPrivate", String.valueOf(withPrivate));
44 if (withVolatile != null) {
45 setField("WithVolatile", String.valueOf(withVolatile));