Class ChatProxy
- java.lang.Object
-
- de.uplanet.lucy.server.auxiliaries.ChatProxy
-
@VelocityCallable("instance") public final class ChatProxy extends Object
-
-
Constructor Summary
Constructors Constructor Description ChatProxy()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ChatMessagesgetMessages(String p_strRecipientId)booleanhasChatPermission()Test if the current user has the permission to chat.booleanhasChatPermission(String p_strUserId)booleansendMessage(String p_strSenderId, String p_strRecipientId, String p_strBody, String p_strStyle)Send a chat message to a specific user.booleansendMessage(String p_strSenderId, List<String> p_recipients, String p_strBody, String p_strStyle)Send a chat message to a specific user.StringsendPersistentMessage(String p_strSenderId, List<String> p_recipients, String p_strSubject, String p_strBody, Date p_dtExpiration)Send a persistent (NewsAgent) message to a specific user.
-
-
-
Method Detail
-
hasChatPermission
public boolean hasChatPermission()
Test if the current user has the permission to chat.- Returns:
trueif the current user has the permission to chat, orfalseotherwise.
-
hasChatPermission
public boolean hasChatPermission(String p_strUserId)
- Parameters:
p_strUserId- The unique unique identifier.- Returns:
trueif the given user has the permission to chat, orfalseotherwise.
-
sendMessage
public boolean sendMessage(String p_strSenderId, String p_strRecipientId, String p_strBody, String p_strStyle)
Send a chat message to a specific user.- Parameters:
p_strSenderId- The sender's unique identifier.p_strRecipientId- The recipient's unique identifier.p_strBody- The message body.p_strStyle- Additional rendering information for the message.- Returns:
trueif the message was enqueued for delivery,falseotherwise.
-
sendMessage
public boolean sendMessage(String p_strSenderId, List<String> p_recipients, String p_strBody, String p_strStyle)
Send a chat message to a specific user.- Parameters:
p_strSenderId- The sender's unique identifier.p_recipients- A list that contains the recipient's unique identifiers.p_strBody- The message body.p_strStyle- Additional rendering information for the message.- Returns:
trueif the message was enqueued for delivery,falseotherwise.
-
sendPersistentMessage
public String sendPersistentMessage(String p_strSenderId, List<String> p_recipients, String p_strSubject, String p_strBody, Date p_dtExpiration)
Send a persistent (NewsAgent) message to a specific user.- Parameters:
p_strSenderId- The sender's unique identifier.p_recipients- A list that contains the recipient's unique identifiers.p_strSubject- The subject of the message.p_strBody- The message body.p_dtExpiration- The message's expiration date.- Returns:
- The unique identifier of the sent message.
-
getMessages
public ChatMessages getMessages(String p_strRecipientId)
- Parameters:
p_strRecipientId- The unique identifier of the user whose messages should be retrieved.- Returns:
- A collection of chat messages for this recipient.
-
-