Class ClanChat
- java.lang.Object
-
- org.dreambot.api.methods.clan.chat.ClanChat
-
public class ClanChat extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description ClanChat()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.util.List<ClanChatMember>getMembers()Gets a list of the clan members in your chatstatic java.lang.StringgetName()Gets clan chat namestatic java.lang.StringgetOwner()Gets clan chat owner's namestatic ClanChatTabgetSelected()Gets the currently selected ClanChatTab, Clan Tab open/closed is irrelevantstatic intgetSize()Gets the current size of the clan chatstatic booleaninChat()Checks whether you're in any clan chatstatic booleaninChat(java.lang.String name)Checks whether you're in a given clan chat Names are formatted to replace all non-alphabetical/numerical characters with spacesstatic booleanisOpen(ClanChatTab tab)Checks to see if a given clan chat tab is currently open, including checking the clan tab itselfstatic booleanjoin(java.lang.String clanChat)Joins a clan chat specified by the name If you're already in a chat but not the specified chat, it will leave your current chatstatic booleanleave()Leaves the current clan chat you're instatic booleanopenChatTab(ClanChatTab tab)Opens a given clan chat tab
-
-
-
Method Detail
-
openChatTab
public static boolean openChatTab(ClanChatTab tab)
Opens a given clan chat tab- Parameters:
tab- tab of the chat to open- Returns:
- true if tab is already open or if successfully opens the tab
-
isOpen
public static boolean isOpen(ClanChatTab tab)
Checks to see if a given clan chat tab is currently open, including checking the clan tab itself- Parameters:
tab- Clan chat tab to check- Returns:
- True if Clan tab is open and ClanChatTab is selected
-
getSelected
public static ClanChatTab getSelected()
Gets the currently selected ClanChatTab, Clan Tab open/closed is irrelevant- Returns:
- Currently selected ClanChatTab based on varbits
-
join
public static boolean join(java.lang.String clanChat)
Joins a clan chat specified by the name If you're already in a chat but not the specified chat, it will leave your current chat- Parameters:
clanChat- Name of the chat owner to join- Returns:
- True if successfully joined chat or already in given chat, false if failed to join given chat or failed to leave wrong existing chat
-
leave
public static boolean leave()
Leaves the current clan chat you're in- Returns:
- True if not in chat or successfully leaves chat, false if failed to leave chat
-
inChat
public static boolean inChat()
Checks whether you're in any clan chat- Returns:
- True if in chat, false if not
-
inChat
public static boolean inChat(java.lang.String name)
Checks whether you're in a given clan chat Names are formatted to replace all non-alphabetical/numerical characters with spaces- Parameters:
name- Name of clan chat to check - if null will ignore the channel name comparison- Returns:
- True if in given chat or if in any chat and given name is null, else false
-
getMembers
public static java.util.List<ClanChatMember> getMembers()
Gets a list of the clan members in your chat- Returns:
- List of
ClanChatMember, empty List if not in chat
-
getSize
public static int getSize()
Gets the current size of the clan chat- Returns:
- 0 if not in chat, otherwise count of how many people are in clan chat
-
getName
public static java.lang.String getName()
Gets clan chat name- Returns:
- Clan chat name, null if not in chat
-
getOwner
public static java.lang.String getOwner()
Gets clan chat owner's name- Returns:
- Clan chat owner's name, null if not in chat
-
-