public class ControlXmppP2PClient extends Object implements XmppP2PClient<Socket>
| Modifier and Type | Method and Description |
|---|---|
void |
addConnectionListener(org.lastbamboo.common.p2p.P2PConnectionListener listener) |
void |
addMessageListener(org.jivesoftware.smack.MessageListener ml) |
org.jivesoftware.smack.XMPPConnection |
getXmppConnection() |
void |
handleClose() |
boolean |
isLoggedOut() |
String |
login(String user,
String pass) |
String |
login(String user,
String pass,
String id) |
String |
login(String user,
String pass,
String serverHost,
int serverPort,
String serviceName) |
String |
login(String user,
String pass,
String serverHost,
int serverPort,
String serviceName,
String id) |
String |
login(XmppCredentials creds) |
String |
login(XmppCredentials creds,
String serverHost,
int serverPort,
String serviceName) |
void |
logout() |
static ControlXmppP2PClient |
newClient(org.lastbamboo.common.offer.answer.OfferAnswerFactory<Socket> factory,
InetSocketAddress plainTextRelayAddress,
org.littleshoot.util.SessionSocketListener callSocketListener,
int relayWait,
org.littleshoot.util.PublicIp publicIp,
SocketFactory socketFactory,
String host,
int port,
String serviceName) |
protected org.jivesoftware.smack.packet.Message |
newError(org.jivesoftware.smack.packet.Message msg) |
protected org.jivesoftware.smack.packet.Message |
newError(String from,
Long tid) |
static ControlXmppP2PClient |
newGoogleTalkDirectClient(org.lastbamboo.common.offer.answer.OfferAnswerFactory<Socket> factory,
InetSocketAddress plainTextRelayAddress,
org.littleshoot.util.SessionSocketListener callSocketListener,
int relayWait,
org.littleshoot.util.PublicIp publicIp,
SocketFactory socketFactory) |
Socket |
newRawSocket(URI uri) |
Socket |
newRawUnreliableSocket(URI uri) |
Socket |
newSocket(URI uri) |
Socket |
newUnreliableSocket(URI uri) |
void |
offer(URI uri,
byte[] offer,
org.lastbamboo.common.offer.answer.OfferAnswerTransactionListener transactionListener,
org.littleshoot.util.KeyStorage keyStorage) |
void |
stop() |
public static ControlXmppP2PClient newGoogleTalkDirectClient(org.lastbamboo.common.offer.answer.OfferAnswerFactory<Socket> factory, InetSocketAddress plainTextRelayAddress, org.littleshoot.util.SessionSocketListener callSocketListener, int relayWait, org.littleshoot.util.PublicIp publicIp, SocketFactory socketFactory)
public static ControlXmppP2PClient newClient(org.lastbamboo.common.offer.answer.OfferAnswerFactory<Socket> factory, InetSocketAddress plainTextRelayAddress, org.littleshoot.util.SessionSocketListener callSocketListener, int relayWait, org.littleshoot.util.PublicIp publicIp, SocketFactory socketFactory, String host, int port, String serviceName)
public Socket newSocket(URI uri) throws IOException, org.lastbamboo.common.offer.answer.NoAnswerException
newSocket in interface org.lastbamboo.common.p2p.SocketFactory<Socket>IOExceptionorg.lastbamboo.common.offer.answer.NoAnswerExceptionpublic Socket newUnreliableSocket(URI uri) throws IOException, org.lastbamboo.common.offer.answer.NoAnswerException
newUnreliableSocket in interface org.lastbamboo.common.p2p.SocketFactory<Socket>IOExceptionorg.lastbamboo.common.offer.answer.NoAnswerExceptionpublic Socket newRawSocket(URI uri) throws IOException, org.lastbamboo.common.offer.answer.NoAnswerException
newRawSocket in interface org.lastbamboo.common.p2p.SocketFactory<Socket>IOExceptionorg.lastbamboo.common.offer.answer.NoAnswerExceptionpublic Socket newRawUnreliableSocket(URI uri) throws IOException, org.lastbamboo.common.offer.answer.NoAnswerException
newRawUnreliableSocket in interface org.lastbamboo.common.p2p.SocketFactory<Socket>IOExceptionorg.lastbamboo.common.offer.answer.NoAnswerExceptionpublic String login(String user, String pass) throws IOException, CredentialException
login in interface org.lastbamboo.common.p2p.P2PClient<Socket>IOExceptionCredentialExceptionpublic String login(String user, String pass, String serverHost, int serverPort, String serviceName) throws IOException, CredentialException
login in interface XmppP2PClient<Socket>IOExceptionCredentialExceptionpublic String login(String user, String pass, String id) throws IOException, CredentialException
login in interface org.lastbamboo.common.p2p.P2PClient<Socket>IOExceptionCredentialExceptionpublic String login(String user, String pass, String serverHost, int serverPort, String serviceName, String id) throws CredentialException, IOException
login in interface XmppP2PClient<Socket>CredentialExceptionIOExceptionpublic String login(XmppCredentials creds) throws CredentialException, IOException
login in interface XmppP2PClient<Socket>CredentialExceptionIOExceptionpublic String login(XmppCredentials creds, String serverHost, int serverPort, String serviceName) throws CredentialException, IOException
login in interface XmppP2PClient<Socket>CredentialExceptionIOExceptionpublic void offer(URI uri, byte[] offer, org.lastbamboo.common.offer.answer.OfferAnswerTransactionListener transactionListener, org.littleshoot.util.KeyStorage keyStorage) throws IOException
offer in interface org.lastbamboo.common.offer.answer.OffererIOExceptionprotected org.jivesoftware.smack.packet.Message newError(org.jivesoftware.smack.packet.Message msg)
public org.jivesoftware.smack.XMPPConnection getXmppConnection()
getXmppConnection in interface XmppP2PClient<Socket>public void addMessageListener(org.jivesoftware.smack.MessageListener ml)
addMessageListener in interface XmppP2PClient<Socket>public void logout()
logout in interface org.lastbamboo.common.p2p.P2PClient<Socket>public void addConnectionListener(org.lastbamboo.common.p2p.P2PConnectionListener listener)
addConnectionListener in interface org.lastbamboo.common.p2p.P2PClient<Socket>public boolean isLoggedOut()
isLoggedOut in interface XmppP2PClient<Socket>public void handleClose()
handleClose in interface XmppP2PClient<Socket>public void stop()
stop in interface XmppP2PClient<Socket>Copyright © 2013 LittleShoot. All Rights Reserved.