|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Chat
Method Summary | |
---|---|
void |
addPlayer(String playerName,
NiftyImage playerIcon)
This method is called when a new player enters the room. |
void |
addPlayer(String playerName,
NiftyImage playerIcon,
String style)
This method is called when a new player enters the room. |
List<ChatEntryModelClass> |
getLines()
This method returns all the chatlines in the chat. |
List<ChatEntryModelClass> |
getPlayers()
This method returns the current list of players in the chat. |
void |
receivedChatLine(String text,
NiftyImage icon)
This method is called when a chat line is received which should be displayed in the chat control. |
void |
receivedChatLine(String text,
NiftyImage icon,
String style)
This method is called when a chat line is received which should be displayed in the chat control. |
void |
removePlayer(String playerName)
This method is called when a player leaves the rome and needs to be removed from the list. |
void |
update()
Updates the lists to reflecct any changes made to them, outside of the addPlayer, removePlayer and |
Methods inherited from interface de.lessvoid.nifty.controls.NiftyControl |
---|
disable, enable, getElement, getHeight, getId, getStyle, getWidth, hasFocus, isBound, isEnabled, layoutCallback, setEnabled, setFocus, setFocusable, setHeight, setId, setStyle, setWidth |
Method Detail |
---|
void receivedChatLine(String text, NiftyImage icon)
text
- The text to display.icon
- Optionally, an icon can be supplied which is then displayed at
the start of the chat line.void receivedChatLine(String text, NiftyImage icon, String style)
text
- The text to display.icon
- Optionally, an icon can be supplied which is then displayed at
the start of the chat line.style
- The custom style for this particular chatline.void addPlayer(String playerName, NiftyImage playerIcon)
playerName
- The player to add.playerIcon
- Optionally, an icon can be supplied which is then displayed in
front of the player name.void addPlayer(String playerName, NiftyImage playerIcon, String style)
playerName
- The player to add.playerIcon
- Optionally, an icon can be supplied which is then displayed in
front of the player name.style
- The custom style for this player. This style is depicted in the
player list.void removePlayer(String playerName)
playerName
- The player name to remove.List<ChatEntryModelClass> getPlayers()
List<ChatEntryModelClass> getLines()
void update()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |