|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.electrotank.electroserver.plugins.utilities.BaseExtensionHelper com.electrotank.electroserver.plugins.utilities.PluginHelper
The plugin helper class provides commonly used functionality to all plugins. It is available in script plugins as the "server" object. In Java plugins, you can access it via the getPluginHelper method on the AbstractPlugin object. See any of the example plugins included with the server to see how to use this object.
Constructor Summary | |
PluginHelper(Room room,
String name,
People people,
Places places)
This is an internal constructor. |
Method Summary | |
String |
getRoomName()
Gets the name of the room that contains this plugin. |
String |
getZoneName()
Gets the name of the zone that contains this plugin. |
void |
sendPublicMessage(String message,
Map variables)
Sends a message to the room that this plugin is in. |
void |
sendRawPrivateMessage(String userName,
String message)
Sends a private message to the user. |
void |
sendRawPrivateMessgeToMany(String[] users,
String message)
Sends a private message to the specified users. |
void |
sendRawPublicMessage(String message)
Sends a message to the room that this plugin is in. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public PluginHelper(Room room, String name, People people, Places places)
room
- the room this plugin is associated withname
- the name of the pluginpeople
- the People object of the serverplaces
- the Places object of the serverMethod Detail |
public void sendPublicMessage(String message, Map variables)
message
- text of the message to sendvariables
- variables to be sent along with the messagepublic void sendRawPublicMessage(String message)
message
- text of the message to sendpublic void sendRawPrivateMessgeToMany(String[] users, String message)
users
- string array representing the names of users to receive this messagemessage
- text of the message to sendpublic void sendRawPrivateMessage(String userName, String message)
userName
- the name of this messages recipientmessage
- text of the message to sendpublic String getRoomName()
public String getZoneName()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |