Package org.signal.libsignal.net
Class UnauthenticatedChatConnection
-
- All Implemented Interfaces:
-
org.signal.libsignal.internal.NativeHandleGuard.Owner
public class UnauthenticatedChatConnection extends ChatConnection
Represents an unauthenticated (i.e. hopefully anonymous) communication channel with the Chat service.
Created by the factory method connectUnauthChat rather than instantiated directly.
Note that a newly-created instance of this class won't be usable for sending messages or receiving events until start is called.
-
-
Method Summary
Modifier and Type Method Description KeyTransparencyClientkeyTransparencyClient()High-level key transparency subsystem client on top using thisto communicate with the chat server.static Pair<UnauthenticatedChatConnection, FakeChatRemote>fakeConnect(TokioAsyncContext tokioAsyncContext, ChatConnectionListener listener, Network.Environment ktEnvironment)Test-only method to create a UnauthenticatedChatConnectionconnected to a fake remote.-
Methods inherited from class org.signal.libsignal.net.ChatConnection
disconnect, send, start -
Methods inherited from class org.signal.libsignal.internal.NativeHandleGuard.SimpleOwner
unsafeNativeHandleWithoutGuard -
Methods inherited from class org.signal.libsignal.internal.NativeHandleGuard.Owner
guard, guardedMap, guardedMapChecked, guardedRun, guardedRunChecked -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
keyTransparencyClient
KeyTransparencyClient keyTransparencyClient()
High-level key transparency subsystem client on top using
thisto communicate with the chat server.- Returns:
an instance of KeyTransparencyClient
-
fakeConnect
static Pair<UnauthenticatedChatConnection, FakeChatRemote> fakeConnect(TokioAsyncContext tokioAsyncContext, ChatConnectionListener listener, Network.Environment ktEnvironment)
Test-only method to create a
UnauthenticatedChatConnectionconnected to a fake remote.The returned FakeChatRemote can be used to send messages to the connection.
-
-
-
-