add ListPeerNote command and replies
[jSite2.git] / src / net / pterodactylus / util / fcp / message / ListPeers.java
1 /**
2  * © 2008 INA Service GmbH
3  */
4 package net.pterodactylus.util.fcp.message;
5
6 import net.pterodactylus.util.fcp.FcpMessage;
7
8 /**
9  * The “ListPeer” requests asks the node for a list of all peers it has.
10  * 
11  * @author <a href="mailto:dr@ina-germany.de">David Roden</a>
12  * @version $Id$
13  */
14 public class ListPeers extends FcpMessage {
15
16         /**
17          * Creates a new “ListPeers” request that only includes basic data of the
18          * peers.
19          */
20         public ListPeers() {
21                 this(false, false);
22         }
23
24         /**
25          * Creates a new “ListPeers” request that includes wanted data of the peers.
26          * 
27          * @param withMetadata
28          *            If <code>true</code> metadata of the peers is included in
29          *            the reply
30          * @param withVolatile
31          *            if <code>true</code> volatile data of the peers is included
32          *            in the reply
33          */
34         public ListPeers(boolean withMetadata, boolean withVolatile) {
35                 super("ListPeers");
36                 setField("WithMetadata", String.valueOf(withMetadata));
37                 setField("WithVolatile", String.valueOf(withVolatile));
38         }
39
40 }