projects
/
jFCPlib.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
e591c64
)
Rename all remaining occurences of “sequence” to “dialog”
author
David ‘Bombe’ Roden
<bombe@freenetproject.org>
Mon, 13 Jul 2015 18:45:35 +0000
(20:45 +0200)
committer
David ‘Bombe’ Roden
<bombe@freenetproject.org>
Mon, 13 Jul 2015 18:45:35 +0000
(20:45 +0200)
src/main/java/net/pterodactylus/fcp/quelaton/AddPeerCommandImpl.java
patch
|
blob
|
history
src/main/java/net/pterodactylus/fcp/quelaton/ClientHelloImpl.java
patch
|
blob
|
history
src/main/java/net/pterodactylus/fcp/quelaton/FcpDialog.java
patch
|
blob
|
history
src/main/java/net/pterodactylus/fcp/quelaton/GenerateKeypairCommandImpl.java
patch
|
blob
|
history
src/main/java/net/pterodactylus/fcp/quelaton/GetNodeCommandImpl.java
patch
|
blob
|
history
src/main/java/net/pterodactylus/fcp/quelaton/ListPeerCommandImpl.java
patch
|
blob
|
history
src/main/java/net/pterodactylus/fcp/quelaton/ListPeerNotesCommandImpl.java
patch
|
blob
|
history
src/main/java/net/pterodactylus/fcp/quelaton/ListPeersCommandImpl.java
patch
|
blob
|
history
src/main/java/net/pterodactylus/fcp/quelaton/ModifyPeerCommandImpl.java
patch
|
blob
|
history
diff --git
a/src/main/java/net/pterodactylus/fcp/quelaton/AddPeerCommandImpl.java
b/src/main/java/net/pterodactylus/fcp/quelaton/AddPeerCommandImpl.java
index
a54f166
..
4fab83c
100644
(file)
--- a/
src/main/java/net/pterodactylus/fcp/quelaton/AddPeerCommandImpl.java
+++ b/
src/main/java/net/pterodactylus/fcp/quelaton/AddPeerCommandImpl.java
@@
-55,10
+55,10
@@
public class AddPeerCommandImpl implements AddPeerCommand {
}
private ListenableFuture<Optional<Peer>> execute() {
}
private ListenableFuture<Optional<Peer>> execute() {
- return threadPool.submit(this::execute
Sequence
);
+ return threadPool.submit(this::execute
Dialog
);
}
}
- private Optional<Peer> execute
Sequence
() throws IOException, ExecutionException, InterruptedException {
+ private Optional<Peer> execute
Dialog
() throws IOException, ExecutionException, InterruptedException {
AddPeer addPeer;
if (file.get() != null) {
addPeer = new AddPeer(new RandomIdentifierGenerator().generate(), file.get().getPath());
AddPeer addPeer;
if (file.get() != null) {
addPeer = new AddPeer(new RandomIdentifierGenerator().generate(), file.get().getPath());
@@
-67,17
+67,17
@@
public class AddPeerCommandImpl implements AddPeerCommand {
} else {
addPeer = new AddPeer(new RandomIdentifierGenerator().generate(), nodeRef.get());
}
} else {
addPeer = new AddPeer(new RandomIdentifierGenerator().generate(), nodeRef.get());
}
- try (AddPeer
Sequence addPeerSequence = new AddPeerSequence
()) {
- return addPeer
Sequence
.send(addPeer).get();
+ try (AddPeer
Dialog addPeerDialog = new AddPeerDialog
()) {
+ return addPeer
Dialog
.send(addPeer).get();
}
}
}
}
- private class AddPeer
Sequence
extends FcpDialog<Optional<Peer>> {
+ private class AddPeer
Dialog
extends FcpDialog<Optional<Peer>> {
private final AtomicBoolean finished = new AtomicBoolean();
private final AtomicReference<Peer> peer = new AtomicReference<>();
private final AtomicBoolean finished = new AtomicBoolean();
private final AtomicReference<Peer> peer = new AtomicReference<>();
- public AddPeer
Sequence
() throws IOException {
+ public AddPeer
Dialog
() throws IOException {
super(threadPool, connectionSupplier.get());
}
super(threadPool, connectionSupplier.get());
}
diff --git
a/src/main/java/net/pterodactylus/fcp/quelaton/ClientHelloImpl.java
b/src/main/java/net/pterodactylus/fcp/quelaton/ClientHelloImpl.java
index
3ded685
..
cb85f60
100644
(file)
--- a/
src/main/java/net/pterodactylus/fcp/quelaton/ClientHelloImpl.java
+++ b/
src/main/java/net/pterodactylus/fcp/quelaton/ClientHelloImpl.java
@@
-44,8
+44,8
@@
public class ClientHelloImpl {
FcpConnection connection = new FcpConnection(hostname, port);
connection.connect();
ClientHello clientHello = new ClientHello(clientName.get(), "2.0");
FcpConnection connection = new FcpConnection(hostname, port);
connection.connect();
ClientHello clientHello = new ClientHello(clientName.get(), "2.0");
- try (ClientHelloDialog
nodeHelloSequence
= new ClientHelloDialog(connection)) {
- if (
nodeHelloSequence
.send(clientHello).get()) {
+ try (ClientHelloDialog
clientHelloDialog
= new ClientHelloDialog(connection)) {
+ if (
clientHelloDialog
.send(clientHello).get()) {
return connection;
}
} catch (InterruptedException | ExecutionException e) {
return connection;
}
} catch (InterruptedException | ExecutionException e) {
diff --git
a/src/main/java/net/pterodactylus/fcp/quelaton/FcpDialog.java
b/src/main/java/net/pterodactylus/fcp/quelaton/FcpDialog.java
index
2aa003c
..
47319f0
100644
(file)
--- a/
src/main/java/net/pterodactylus/fcp/quelaton/FcpDialog.java
+++ b/
src/main/java/net/pterodactylus/fcp/quelaton/FcpDialog.java
@@
-57,7
+57,7
@@
import com.google.common.util.concurrent.ListeningExecutorService;
import com.google.common.util.concurrent.MoreExecutors;
/**
import com.google.common.util.concurrent.MoreExecutors;
/**
- * An FCP
reply sequence
enables you to conveniently wait for a specific set of FCP replies.
+ * An FCP
dialog
enables you to conveniently wait for a specific set of FCP replies.
*
* @author <a href="bombe@freenetproject.org">David ‘Bombe’ Roden</a>
*/
*
* @author <a href="bombe@freenetproject.org">David ‘Bombe’ Roden</a>
*/
diff --git
a/src/main/java/net/pterodactylus/fcp/quelaton/GenerateKeypairCommandImpl.java
b/src/main/java/net/pterodactylus/fcp/quelaton/GenerateKeypairCommandImpl.java
index
5f8cd5b
..
69fcf63
100644
(file)
--- a/
src/main/java/net/pterodactylus/fcp/quelaton/GenerateKeypairCommandImpl.java
+++ b/
src/main/java/net/pterodactylus/fcp/quelaton/GenerateKeypairCommandImpl.java
@@
-30,10
+30,10
@@
class GenerateKeypairCommandImpl implements GenerateKeypairCommand {
@Override
public ListenableFuture<FcpKeyPair> execute() {
@Override
public ListenableFuture<FcpKeyPair> execute() {
- return threadPool.submit(this::execute
Sequence
);
+ return threadPool.submit(this::execute
Dialog
);
}
}
- private FcpKeyPair execute
Sequence
() throws InterruptedException, ExecutionException, IOException {
+ private FcpKeyPair execute
Dialog
() throws InterruptedException, ExecutionException, IOException {
try (FcpKeyPairDialog fcpKeyPairDialog = new FcpKeyPairDialog()) {
return fcpKeyPairDialog.send(new GenerateSSK()).get();
}
try (FcpKeyPairDialog fcpKeyPairDialog = new FcpKeyPairDialog()) {
return fcpKeyPairDialog.send(new GenerateSSK()).get();
}
diff --git
a/src/main/java/net/pterodactylus/fcp/quelaton/GetNodeCommandImpl.java
b/src/main/java/net/pterodactylus/fcp/quelaton/GetNodeCommandImpl.java
index
025cddc
..
3e9e850
100644
(file)
--- a/
src/main/java/net/pterodactylus/fcp/quelaton/GetNodeCommandImpl.java
+++ b/
src/main/java/net/pterodactylus/fcp/quelaton/GetNodeCommandImpl.java
@@
-51,10
+51,10
@@
public class GetNodeCommandImpl implements GetNodeCommand {
@Override
public ListenableFuture<NodeData> execute() {
@Override
public ListenableFuture<NodeData> execute() {
- return threadPool.submit(this::execute
Sequence
);
+ return threadPool.submit(this::execute
Dialog
);
}
}
- private NodeData execute
Sequence
() throws InterruptedException, ExecutionException, IOException {
+ private NodeData execute
Dialog
() throws InterruptedException, ExecutionException, IOException {
GetNode getNode = new GetNode(new RandomIdentifierGenerator().generate(), giveOpennetRef.get(),
includePrivate.get(), includeVolatile.get());
try (GetNodeDialog getNodeDialog = new GetNodeDialog()) {
GetNode getNode = new GetNode(new RandomIdentifierGenerator().generate(), giveOpennetRef.get(),
includePrivate.get(), includeVolatile.get());
try (GetNodeDialog getNodeDialog = new GetNodeDialog()) {
diff --git
a/src/main/java/net/pterodactylus/fcp/quelaton/ListPeerCommandImpl.java
b/src/main/java/net/pterodactylus/fcp/quelaton/ListPeerCommandImpl.java
index
44648c3
..
3fb6b74
100644
(file)
--- a/
src/main/java/net/pterodactylus/fcp/quelaton/ListPeerCommandImpl.java
+++ b/
src/main/java/net/pterodactylus/fcp/quelaton/ListPeerCommandImpl.java
@@
-48,22
+48,22
@@
public class ListPeerCommandImpl implements ListPeerCommand {
}
private ListenableFuture<Optional<Peer>> execute() {
}
private ListenableFuture<Optional<Peer>> execute() {
- return threadPool.submit(this::execute
Sequence
);
+ return threadPool.submit(this::execute
Dialog
);
}
}
- private Optional<Peer> execute
Sequence
() throws IOException, ExecutionException, InterruptedException {
+ private Optional<Peer> execute
Dialog
() throws IOException, ExecutionException, InterruptedException {
ListPeer listPeer = new ListPeer(new RandomIdentifierGenerator().generate(), nodeIdentifier.get());
ListPeer listPeer = new ListPeer(new RandomIdentifierGenerator().generate(), nodeIdentifier.get());
- try (ListPeer
Sequence listPeerSequence = new ListPeerSequence
()) {
- return Optional.ofNullable(listPeer
Sequence
.send(listPeer).get());
+ try (ListPeer
Dialog listPeerDialog = new ListPeerDialog
()) {
+ return Optional.ofNullable(listPeer
Dialog
.send(listPeer).get());
}
}
}
}
- private class ListPeer
Sequence
extends FcpDialog<Peer> {
+ private class ListPeer
Dialog
extends FcpDialog<Peer> {
private final AtomicBoolean finished = new AtomicBoolean();
private final AtomicReference<Peer> peer = new AtomicReference<>();
private final AtomicBoolean finished = new AtomicBoolean();
private final AtomicReference<Peer> peer = new AtomicReference<>();
- public ListPeer
Sequence
() throws IOException {
+ public ListPeer
Dialog
() throws IOException {
super(threadPool, connectionSupplier.get());
}
super(threadPool, connectionSupplier.get());
}
diff --git
a/src/main/java/net/pterodactylus/fcp/quelaton/ListPeerNotesCommandImpl.java
b/src/main/java/net/pterodactylus/fcp/quelaton/ListPeerNotesCommandImpl.java
index
426917a
..
0cd0483
100644
(file)
--- a/
src/main/java/net/pterodactylus/fcp/quelaton/ListPeerNotesCommandImpl.java
+++ b/
src/main/java/net/pterodactylus/fcp/quelaton/ListPeerNotesCommandImpl.java
@@
-51,10
+51,10
@@
public class ListPeerNotesCommandImpl implements ListPeerNotesCommand {
}
private ListenableFuture<Optional<PeerNote>> execute() {
}
private ListenableFuture<Optional<PeerNote>> execute() {
- return threadPool.submit(this::execute
Sequence
);
+ return threadPool.submit(this::execute
Dialog
);
}
}
- private Optional<PeerNote> execute
Sequence
() throws IOException, ExecutionException, InterruptedException {
+ private Optional<PeerNote> execute
Dialog
() throws IOException, ExecutionException, InterruptedException {
ListPeerNotes listPeerNotes =
new ListPeerNotes(new RandomIdentifierGenerator().generate(), nodeIdentifier.get());
try (ListPeerNotesDialog listPeerNotesDialog = new ListPeerNotesDialog()) {
ListPeerNotes listPeerNotes =
new ListPeerNotes(new RandomIdentifierGenerator().generate(), nodeIdentifier.get());
try (ListPeerNotesDialog listPeerNotesDialog = new ListPeerNotesDialog()) {
diff --git
a/src/main/java/net/pterodactylus/fcp/quelaton/ListPeersCommandImpl.java
b/src/main/java/net/pterodactylus/fcp/quelaton/ListPeersCommandImpl.java
index
921c0fa
..
f4907f0
100644
(file)
--- a/
src/main/java/net/pterodactylus/fcp/quelaton/ListPeersCommandImpl.java
+++ b/
src/main/java/net/pterodactylus/fcp/quelaton/ListPeersCommandImpl.java
@@
-46,10
+46,10
@@
public class ListPeersCommandImpl implements ListPeersCommand {
@Override
public ListenableFuture<Collection<Peer>> execute() {
@Override
public ListenableFuture<Collection<Peer>> execute() {
- return threadPool.submit(this::execute
Sequence
);
+ return threadPool.submit(this::execute
Dialog
);
}
}
- private Collection<Peer> execute
Sequence
() throws InterruptedException, ExecutionException, IOException {
+ private Collection<Peer> execute
Dialog
() throws InterruptedException, ExecutionException, IOException {
String identifier = new RandomIdentifierGenerator().generate();
ListPeers listPeers = new ListPeers(identifier, includeMetadata.get(), includeVolatile.get());
try (ListPeersDialog listPeersDialog = new ListPeersDialog()) {
String identifier = new RandomIdentifierGenerator().generate();
ListPeers listPeers = new ListPeers(identifier, includeMetadata.get(), includeVolatile.get());
try (ListPeersDialog listPeersDialog = new ListPeersDialog()) {
diff --git
a/src/main/java/net/pterodactylus/fcp/quelaton/ModifyPeerCommandImpl.java
b/src/main/java/net/pterodactylus/fcp/quelaton/ModifyPeerCommandImpl.java
index
5dd2bf9
..
a675280
100644
(file)
--- a/
src/main/java/net/pterodactylus/fcp/quelaton/ModifyPeerCommandImpl.java
+++ b/
src/main/java/net/pterodactylus/fcp/quelaton/ModifyPeerCommandImpl.java
@@
-115,10
+115,10
@@
public class ModifyPeerCommandImpl implements ModifyPeerCommand {
}
private ListenableFuture<Optional<Peer>> execute() {
}
private ListenableFuture<Optional<Peer>> execute() {
- return threadPool.submit(this::execute
Sequence
);
+ return threadPool.submit(this::execute
Dialog
);
}
}
- private Optional<Peer> execute
Sequence
() throws IOException, ExecutionException, InterruptedException {
+ private Optional<Peer> execute
Dialog
() throws IOException, ExecutionException, InterruptedException {
ModifyPeer modifyPeer = new ModifyPeer(new RandomIdentifierGenerator().generate(), nodeIdentifier.get());
Optional.ofNullable(enabled.get()).ifPresent(enabled -> modifyPeer.setEnabled(enabled));
Optional.ofNullable(allowLocalAddresses.get()).ifPresent(allowed -> modifyPeer.setAllowLocalAddresses(allowed));
ModifyPeer modifyPeer = new ModifyPeer(new RandomIdentifierGenerator().generate(), nodeIdentifier.get());
Optional.ofNullable(enabled.get()).ifPresent(enabled -> modifyPeer.setEnabled(enabled));
Optional.ofNullable(allowLocalAddresses.get()).ifPresent(allowed -> modifyPeer.setAllowLocalAddresses(allowed));