mirror of
https://github.com/AsamK/signal-cli
synced 2025-08-29 18:40:39 +00:00
Add PlainTextWriter interface
This commit is contained in:
parent
641dc7577c
commit
15e8029715
16 changed files with 69 additions and 66 deletions
|
@ -10,7 +10,6 @@ import org.asamk.signal.JsonWriter;
|
|||
import org.asamk.signal.OutputType;
|
||||
import org.asamk.signal.OutputWriter;
|
||||
import org.asamk.signal.PlainTextWriter;
|
||||
import org.asamk.signal.PlainTextWriterImpl;
|
||||
import org.asamk.signal.ReceiveMessageHandler;
|
||||
import org.asamk.signal.commands.exceptions.CommandException;
|
||||
import org.asamk.signal.commands.exceptions.IOErrorException;
|
||||
|
@ -79,7 +78,7 @@ public class ReceiveCommand implements ExtendedDbusCommand, LocalCommand {
|
|||
jsonWriter.write(object);
|
||||
});
|
||||
} else {
|
||||
final var writer = (PlainTextWriterImpl) outputWriter;
|
||||
final var writer = (PlainTextWriter) outputWriter;
|
||||
|
||||
dbusconnection.addSigHandler(Signal.MessageReceived.class, signal, messageReceived -> {
|
||||
writer.println("Envelope from: {}", messageReceived.getSender());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue