public class StackExchangeClient extends Object implements AutoCloseable
close() method.| Constructor and Description |
|---|
StackExchangeClient(String email,
String password)
Constructs the client with the provided credentials.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Closes this client by making the logged-in user leave all the chat rooms they joined.
|
boolean |
getAutoCreateAccount()
true, if the account for a user should automatically be created when logging in to a new site
|
Room |
joinRoom(ChatHost host,
int roomId)
Joins the given room for the given chat host.
|
void |
setAutoCreateAccount(boolean autoCreateAccount)
Controls, if the account for a user should automatically be created when logging in to a new site
|
public Room joinRoom(ChatHost host, int roomId)
Trying to join a room in which you are already in results in a ChatOperationException.
host - Host of the chat room to join.roomId - Id of the room to join.Room joined.public boolean getAutoCreateAccount()
public void setAutoCreateAccount(boolean autoCreateAccount)
autoCreateAccount - new valuepublic void close()
Multiple invocations of this method has no further effect.
close in interface AutoCloseable