Package com.github.stormbit.sdk.clients
Class Client
- java.lang.Object
-
- com.github.stormbit.sdk.clients.Client
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classClient.CommandCommand object
-
Field Summary
Fields Modifier and Type Field Description CopyOnWriteArrayList<Client.Command>commandsstatic ScheduledExecutorServiceschedulerstatic ExecutorServiceservice
-
Method Summary
-
-
-
Field Detail
-
service
public static final ExecutorService service
-
scheduler
public static final ScheduledExecutorService scheduler
-
commands
public CopyOnWriteArrayList<Client.Command> commands
-
-
Method Detail
-
setLongPoll
public void setLongPoll(LongPoll LP)
-
longPoll
public LongPoll longPoll()
Get longpoll of current client- Returns:
- longpoll object
-
get_auth
public Auth get_auth()
-
api
public API api()
Get API for making requests- Returns:
- api object
-
enableTyping
public void enableTyping(boolean enable)
If the client need to start typing after receiving message and until client's message is sent- Parameters:
enable- true or false
-
onLongPollEvent
public void onLongPollEvent(Callback<org.json.JSONArray> callback)
-
onChatJoin
public void onChatJoin(CallbackTriple<Integer,Integer,Integer> callback)
-
onChatLeave
public void onChatLeave(CallbackTriple<Integer,Integer,Integer> callback)
-
onChatTitleChanged
public void onChatTitleChanged(CallbackFourth<String,String,Integer,Integer> callback)
-
onChatPhotoChanged
public void onChatPhotoChanged(CallbackTriple<org.json.JSONObject,Integer,Integer> callback)
-
onChatPhotoRemoved
public void onChatPhotoRemoved(CallbackDouble<Integer,Integer> callback)
-
onChatCreated
public void onChatCreated(CallbackTriple<String,Integer,Integer> callback)
-
onFriendOnline
public void onFriendOnline(CallbackDouble<Integer,Integer> callback)
-
onFriendOffline
public void onFriendOffline(CallbackDouble<Integer,Integer> callback)
-
enableLoggingUpdates
public void enableLoggingUpdates(boolean enable)
If true, all updates from longpoll server will be logged to level 'INFO'- Parameters:
enable- true or false
-
getId
public Integer getId()
-
setId
public void setId(Integer id)
-
-