com.liferay.portlet.messageboards.util
Class MBUtil
java.lang.Object
com.liferay.portlet.messageboards.util.MBUtil
public class MBUtil
- extends Object
|
Method Summary |
static void |
addPortletBreadcrumbEntries(long categoryId,
javax.servlet.http.HttpServletRequest request,
RenderResponse renderResponse)
|
static void |
addPortletBreadcrumbEntries(MBCategory category,
javax.servlet.http.HttpServletRequest request,
RenderResponse renderResponse)
|
static void |
addPortletBreadcrumbEntries(MBMessage message,
javax.servlet.http.HttpServletRequest request,
RenderResponse renderResponse)
|
static void |
collectMultipartContent(javax.mail.internet.MimeMultipart multipart,
MBMailMessage collector)
|
static void |
collectPartContent(javax.mail.Part part,
MBMailMessage mbMailMessage)
|
static String |
getAbsolutePath(PortletRequest portletRequest,
long mbCategoryId)
|
static String |
getBBCodeHTML(String msgBody,
String pathThemeImages)
|
static long |
getCategoryId(javax.servlet.http.HttpServletRequest request,
MBCategory category)
|
static long |
getCategoryId(javax.servlet.http.HttpServletRequest request,
MBMessage message)
|
static Set<Long> |
getCategorySubscriptionClassPKs(long userId)
|
static Map<String,String> |
getEmailDefinitionTerms(PortletRequest portletRequest,
String emailFromAddress,
String emailFromName)
|
static Map<String,String> |
getEmailFromDefinitionTerms(PortletRequest portletRequest)
|
static List<Object> |
getEntries(Hits hits)
|
static long |
getMessageId(String mailId)
|
static long |
getParentMessageId(javax.mail.Message message)
|
static String |
getParentMessageIdString(javax.mail.Message message)
|
static String |
getReplyToAddress(long categoryId,
long messageId,
String mx,
String defaultMailingListAddress)
|
static String |
getSubjectForEmail(javax.mail.Message message)
|
static String |
getSubjectWithoutMessageId(javax.mail.Message message)
|
static String[] |
getThreadPriority(MBSettings mbSettings,
String languageId,
double value,
ThemeDisplay themeDisplay)
|
static Set<Long> |
getThreadSubscriptionClassPKs(long userId)
|
static Date |
getUnbanDate(MBBan ban,
int expireInterval)
|
static String |
getUserRank(MBSettings mbSettings,
String languageId,
int posts)
|
static String[] |
getUserRank(MBSettings mbSettings,
String languageId,
MBStatsUser statsUser)
|
static boolean |
hasMailIdHeader(javax.mail.Message message)
|
static boolean |
isValidMessageFormat(String messageFormat)
|
static boolean |
isViewableMessage(ThemeDisplay themeDisplay,
MBMessage message)
|
static boolean |
isViewableMessage(ThemeDisplay themeDisplay,
MBMessage message,
MBMessage parentMessage)
|
static void |
propagatePermissions(long companyId,
long groupId,
long parentMessageId,
ServiceContext serviceContext)
|
static String |
replaceMessageBodyPaths(ThemeDisplay themeDisplay,
String messageBody)
|
static void |
updateCategoryMessageCount(long companyId,
long categoryId)
|
static void |
updateCategoryStatistics(long companyId,
long categoryId)
|
static void |
updateCategoryThreadCount(long companyId,
long categoryId)
|
static void |
updateThreadMessageCount(long companyId,
long threadId)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BB_CODE_EDITOR_WYSIWYG_IMPL_KEY
public static final String BB_CODE_EDITOR_WYSIWYG_IMPL_KEY
- See Also:
- Constant Field Values
EMOTICONS
public static final String EMOTICONS
- See Also:
- Constant Field Values
MESSAGE_POP_PORTLET_PREFIX
public static final String MESSAGE_POP_PORTLET_PREFIX
- See Also:
- Constant Field Values
MBUtil
public MBUtil()
addPortletBreadcrumbEntries
public static void addPortletBreadcrumbEntries(long categoryId,
javax.servlet.http.HttpServletRequest request,
RenderResponse renderResponse)
throws Exception
- Throws:
Exception
addPortletBreadcrumbEntries
public static void addPortletBreadcrumbEntries(MBCategory category,
javax.servlet.http.HttpServletRequest request,
RenderResponse renderResponse)
throws Exception
- Throws:
Exception
addPortletBreadcrumbEntries
public static void addPortletBreadcrumbEntries(MBMessage message,
javax.servlet.http.HttpServletRequest request,
RenderResponse renderResponse)
throws Exception
- Throws:
Exception
collectMultipartContent
public static void collectMultipartContent(javax.mail.internet.MimeMultipart multipart,
MBMailMessage collector)
throws Exception
- Throws:
Exception
collectPartContent
public static void collectPartContent(javax.mail.Part part,
MBMailMessage mbMailMessage)
throws Exception
- Throws:
Exception
getAbsolutePath
public static String getAbsolutePath(PortletRequest portletRequest,
long mbCategoryId)
throws PortalException
- Throws:
PortalException
getBBCodeHTML
public static String getBBCodeHTML(String msgBody,
String pathThemeImages)
getCategoryId
public static long getCategoryId(javax.servlet.http.HttpServletRequest request,
MBCategory category)
getCategoryId
public static long getCategoryId(javax.servlet.http.HttpServletRequest request,
MBMessage message)
getCategorySubscriptionClassPKs
public static Set<Long> getCategorySubscriptionClassPKs(long userId)
getEmailDefinitionTerms
public static Map<String,String> getEmailDefinitionTerms(PortletRequest portletRequest,
String emailFromAddress,
String emailFromName)
getEmailFromDefinitionTerms
public static Map<String,String> getEmailFromDefinitionTerms(PortletRequest portletRequest)
getEntries
public static List<Object> getEntries(Hits hits)
getMessageId
public static long getMessageId(String mailId)
getParentMessageId
public static long getParentMessageId(javax.mail.Message message)
throws Exception
- Throws:
Exception
getParentMessageIdString
public static String getParentMessageIdString(javax.mail.Message message)
throws Exception
- Throws:
Exception
getReplyToAddress
public static String getReplyToAddress(long categoryId,
long messageId,
String mx,
String defaultMailingListAddress)
getSubjectForEmail
public static String getSubjectForEmail(javax.mail.Message message)
throws Exception
- Throws:
Exception
getSubjectWithoutMessageId
public static String getSubjectWithoutMessageId(javax.mail.Message message)
throws Exception
- Throws:
Exception
getThreadPriority
public static String[] getThreadPriority(MBSettings mbSettings,
String languageId,
double value,
ThemeDisplay themeDisplay)
throws Exception
- Throws:
Exception
getThreadSubscriptionClassPKs
public static Set<Long> getThreadSubscriptionClassPKs(long userId)
getUnbanDate
public static Date getUnbanDate(MBBan ban,
int expireInterval)
getUserRank
public static String getUserRank(MBSettings mbSettings,
String languageId,
int posts)
throws Exception
- Throws:
Exception
getUserRank
public static String[] getUserRank(MBSettings mbSettings,
String languageId,
MBStatsUser statsUser)
throws Exception
- Throws:
Exception
hasMailIdHeader
public static boolean hasMailIdHeader(javax.mail.Message message)
throws Exception
- Throws:
Exception
isValidMessageFormat
public static boolean isValidMessageFormat(String messageFormat)
isViewableMessage
public static boolean isViewableMessage(ThemeDisplay themeDisplay,
MBMessage message)
throws Exception
- Throws:
Exception
isViewableMessage
public static boolean isViewableMessage(ThemeDisplay themeDisplay,
MBMessage message,
MBMessage parentMessage)
throws Exception
- Throws:
Exception
propagatePermissions
public static void propagatePermissions(long companyId,
long groupId,
long parentMessageId,
ServiceContext serviceContext)
throws PortalException
- Throws:
PortalException
replaceMessageBodyPaths
public static String replaceMessageBodyPaths(ThemeDisplay themeDisplay,
String messageBody)
updateCategoryMessageCount
public static void updateCategoryMessageCount(long companyId,
long categoryId)
updateCategoryStatistics
public static void updateCategoryStatistics(long companyId,
long categoryId)
updateCategoryThreadCount
public static void updateCategoryThreadCount(long companyId,
long categoryId)
updateThreadMessageCount
public static void updateThreadMessageCount(long companyId,
long threadId)