2 * jSite2 - FcpNodeInformation.java -
3 * Copyright © 2008 David Roden
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
20 package net.pterodactylus.util.fcp.client;
23 * Container for node information. This information is transmitted to the client
24 * in the “NodeHello” response.
26 * @author David Roden <droden@gmail.com>
29 public class FcpNodeInformation {
31 /** The “FCPVersion” field. */
32 private final String fcpVersion;
34 /** The “Version” field. */
35 private final String version;
37 /** The “Node” field. */
38 private final String node;
40 /** The “Testnet” field. */
41 private final boolean testnet;
43 /** The “CompressionCodecs” field. */
44 private final int compressionCodecs;
46 /** The “ConnectionIdentifier” field. */
47 private final String connectionIdentifier;
49 /** The “NodeLanguage” field. */
50 private final String nodeLanguage;
53 * Creates a new node information object.
56 * The “FCPVersion” field
63 * @param compressionCodecs
64 * The “CompressionCodecs” field
65 * @param connectionIdentifier
66 * The “ConnectionIdentifier” field
68 * The “NodeLanguage” field
70 public FcpNodeInformation(String fcpVersion, String version, String node, boolean testnet, int compressionCodecs, String connectionIdentifier, String nodeLanguage) {
71 this.fcpVersion = fcpVersion;
72 this.version = version;
74 this.testnet = testnet;
75 this.compressionCodecs = compressionCodecs;
76 this.connectionIdentifier = connectionIdentifier;
77 this.nodeLanguage = nodeLanguage;
81 * Returns the “FCPVersion” field.
83 * @return The “FCPVersion” field
85 public String getFcpVersion() {
90 * Returns the “Version” field.
92 * @return The “Version” field
94 public String getVersion() {
99 * Returns the “Node” field.
101 * @return The “Node” field
103 public String getNode() {
108 * Returns the “Testnet” field.
110 * @return The “Testnet” field
112 public boolean isTestnet() {
117 * Returns the “CompressionCodecs” field.
119 * @return The “CompressionCodecs” field
121 public int getCompressionCodecs() {
122 return compressionCodecs;
126 * Returns the “ConnectionIdentifier” field.
128 * @return The “ConnectionIdentifier” field
130 public String getConnectionIdentifier() {
131 return connectionIdentifier;
135 * Returns the “NodeLanguage” field.
137 * @return The “NodeLanguage” field
139 public String getNodeLanguage() {