@ProviderType @Transactional(isolation=PORTAL, rollbackFor={PortalException.class,SystemException.class}) public interface MBThreadLocalService extends BaseLocalService, PersistedModelLocalService
MBThreadLocalServiceUtil
,
MBThreadLocalServiceBaseImpl
,
MBThreadLocalServiceImpl
Modifier and Type | Method and Description |
---|---|
MBThread |
addMBThread(MBThread mbThread)
Adds the message boards thread to the database.
|
MBThread |
addThread(long categoryId,
MBMessage message,
ServiceContext serviceContext) |
MBThread |
createMBThread(long threadId)
Creates a new message boards thread with the primary key.
|
MBThread |
deleteMBThread(long threadId)
Deletes the message boards thread with the primary key from the database.
|
MBThread |
deleteMBThread(MBThread mbThread)
Deletes the message boards thread from the database.
|
PersistedModel |
deletePersistedModel(PersistedModel persistedModel) |
void |
deleteThread(long threadId) |
void |
deleteThread(MBThread thread) |
void |
deleteThreads(long groupId,
long categoryId) |
void |
deleteThreads(long groupId,
long categoryId,
boolean includeTrashedEntries) |
DynamicQuery |
dynamicQuery() |
<T> List<T> |
dynamicQuery(DynamicQuery dynamicQuery)
Performs a dynamic query on the database and returns the matching rows.
|
<T> List<T> |
dynamicQuery(DynamicQuery dynamicQuery,
int start,
int end)
Performs a dynamic query on the database and returns a range of the matching rows.
|
<T> List<T> |
dynamicQuery(DynamicQuery dynamicQuery,
int start,
int end,
OrderByComparator<T> orderByComparator)
Performs a dynamic query on the database and returns an ordered range of the matching rows.
|
long |
dynamicQueryCount(DynamicQuery dynamicQuery)
Returns the number of rows matching the dynamic query.
|
long |
dynamicQueryCount(DynamicQuery dynamicQuery,
Projection projection)
Returns the number of rows matching the dynamic query.
|
MBThread |
fetchMBThread(long threadId) |
MBThread |
fetchMBThreadByUuidAndGroupId(String uuid,
long groupId)
Returns the message boards thread matching the UUID and group.
|
MBThread |
fetchThread(long threadId) |
ActionableDynamicQuery |
getActionableDynamicQuery() |
int |
getCategoryThreadsCount(long groupId,
long categoryId,
int status) |
ExportActionableDynamicQuery |
getExportActionableDynamicQuery(PortletDataContext portletDataContext) |
List<MBThread> |
getGroupThreads(long groupId,
long userId,
boolean subscribed,
boolean includeAnonymous,
QueryDefinition<MBThread> queryDefinition) |
List<MBThread> |
getGroupThreads(long groupId,
long userId,
boolean subscribed,
QueryDefinition<MBThread> queryDefinition) |
List<MBThread> |
getGroupThreads(long groupId,
long userId,
QueryDefinition<MBThread> queryDefinition) |
List<MBThread> |
getGroupThreads(long groupId,
QueryDefinition<MBThread> queryDefinition) |
int |
getGroupThreadsCount(long groupId,
long userId,
boolean subscribed,
boolean includeAnonymous,
QueryDefinition<MBThread> queryDefinition) |
int |
getGroupThreadsCount(long groupId,
long userId,
boolean subscribed,
QueryDefinition<MBThread> queryDefinition) |
int |
getGroupThreadsCount(long groupId,
long userId,
QueryDefinition<MBThread> queryDefinition) |
int |
getGroupThreadsCount(long groupId,
QueryDefinition<MBThread> queryDefinition) |
IndexableActionableDynamicQuery |
getIndexableActionableDynamicQuery() |
MBThread |
getMBThread(long threadId)
Returns the message boards thread with the primary key.
|
MBThread |
getMBThreadByUuidAndGroupId(String uuid,
long groupId)
Returns the message boards thread matching the UUID and group.
|
List<MBThread> |
getMBThreads(int start,
int end)
Returns a range of all the message boards threads.
|
List<MBThread> |
getMBThreadsByUuidAndCompanyId(String uuid,
long companyId)
Returns all the message boards threads matching the UUID and company.
|
List<MBThread> |
getMBThreadsByUuidAndCompanyId(String uuid,
long companyId,
int start,
int end,
OrderByComparator<MBThread> orderByComparator)
Returns a range of message boards threads matching the UUID and company.
|
int |
getMBThreadsCount()
Returns the number of message boards threads.
|
List<MBThread> |
getNoAssetThreads() |
String |
getOSGiServiceIdentifier()
Returns the OSGi service identifier.
|
PersistedModel |
getPersistedModel(Serializable primaryKeyObj) |
List<MBThread> |
getPriorityThreads(long categoryId,
double priority) |
List<MBThread> |
getPriorityThreads(long categoryId,
double priority,
boolean inherit) |
MBThread |
getThread(long threadId) |
List<MBThread> |
getThreads(long groupId,
long categoryId,
int status,
int start,
int end) |
int |
getThreadsCount(long groupId,
long categoryId,
int status) |
boolean |
hasAnswerMessage(long threadId) |
void |
incrementViewCounter(long threadId,
int increment) |
void |
moveDependentsToTrash(long groupId,
long threadId,
long trashEntryId) |
MBThread |
moveThread(long groupId,
long categoryId,
long threadId) |
MBThread |
moveThreadFromTrash(long userId,
long categoryId,
long threadId) |
void |
moveThreadsToTrash(long groupId,
long userId) |
MBThread |
moveThreadToTrash(long userId,
long threadId) |
MBThread |
moveThreadToTrash(long userId,
MBThread thread) |
void |
restoreDependentsFromTrash(long groupId,
long threadId) |
void |
restoreDependentsFromTrash(long groupId,
long threadId,
long trashEntryId)
Deprecated.
As of Wilberforce (7.0.x), replaced by
restoreDependentsFromTrash(long, long) |
void |
restoreThreadFromTrash(long userId,
long threadId) |
Hits |
search(long groupId,
long userId,
long creatorUserId,
int status,
int start,
int end) |
Hits |
search(long groupId,
long userId,
long creatorUserId,
long startDate,
long endDate,
int status,
int start,
int end) |
MBThread |
splitThread(long userId,
long messageId,
String subject,
ServiceContext serviceContext) |
MBThread |
updateMBThread(MBThread mbThread)
Updates the message boards thread in the database or adds it if it does not yet exist.
|
MBThread |
updateMessageCount(long threadId) |
void |
updateQuestion(long threadId,
boolean question) |
MBThread |
updateStatus(long userId,
long threadId,
int status) |
@Indexable(type=REINDEX) MBThread addMBThread(MBThread mbThread)
mbThread
- the message boards threadMBThread addThread(long categoryId, MBMessage message, ServiceContext serviceContext) throws PortalException
PortalException
@Transactional(enabled=false) MBThread createMBThread(long threadId)
threadId
- the primary key for the new message boards thread@Indexable(type=DELETE) MBThread deleteMBThread(long threadId) throws PortalException
threadId
- the primary key of the message boards threadPortalException
- if a message boards thread with the primary key could not be found@Indexable(type=DELETE) MBThread deleteMBThread(MBThread mbThread)
mbThread
- the message boards threadPersistedModel deletePersistedModel(PersistedModel persistedModel) throws PortalException
deletePersistedModel
in interface PersistedModelLocalService
PortalException
void deleteThread(long threadId) throws PortalException
PortalException
@SystemEvent(action=1, type=1) void deleteThread(MBThread thread) throws PortalException
PortalException
void deleteThreads(long groupId, long categoryId) throws PortalException
PortalException
void deleteThreads(long groupId, long categoryId, boolean includeTrashedEntries) throws PortalException
PortalException
@Transactional(propagation=SUPPORTS, readOnly=true) DynamicQuery dynamicQuery()
@Transactional(propagation=SUPPORTS, readOnly=true) <T> List<T> dynamicQuery(DynamicQuery dynamicQuery)
dynamicQuery
- the dynamic query@Transactional(propagation=SUPPORTS, readOnly=true) <T> List<T> dynamicQuery(DynamicQuery dynamicQuery, int start, int end)
Useful when paginating results. Returns a maximum of end - start
instances. start
and end
are not primary keys, they are indexes in the result set. Thus, 0
refers to the first result in the set. Setting both start
and end
to QueryUtil.ALL_POS
will return the full result set. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil.ALL_POS
), then the query will include the default ORDER BY logic from MBThreadModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
dynamicQuery
- the dynamic querystart
- the lower bound of the range of model instancesend
- the upper bound of the range of model instances (not inclusive)@Transactional(propagation=SUPPORTS, readOnly=true) <T> List<T> dynamicQuery(DynamicQuery dynamicQuery, int start, int end, OrderByComparator<T> orderByComparator)
Useful when paginating results. Returns a maximum of end - start
instances. start
and end
are not primary keys, they are indexes in the result set. Thus, 0
refers to the first result in the set. Setting both start
and end
to QueryUtil.ALL_POS
will return the full result set. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil.ALL_POS
), then the query will include the default ORDER BY logic from MBThreadModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
dynamicQuery
- the dynamic querystart
- the lower bound of the range of model instancesend
- the upper bound of the range of model instances (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)@Transactional(propagation=SUPPORTS, readOnly=true) long dynamicQueryCount(DynamicQuery dynamicQuery)
dynamicQuery
- the dynamic query@Transactional(propagation=SUPPORTS, readOnly=true) long dynamicQueryCount(DynamicQuery dynamicQuery, Projection projection)
dynamicQuery
- the dynamic queryprojection
- the projection to apply to the query@Transactional(propagation=SUPPORTS, readOnly=true) MBThread fetchMBThread(long threadId)
@Transactional(propagation=SUPPORTS, readOnly=true) MBThread fetchMBThreadByUuidAndGroupId(String uuid, long groupId)
uuid
- the message boards thread's UUIDgroupId
- the primary key of the groupnull
if a matching message boards thread could not be found@Transactional(propagation=SUPPORTS, readOnly=true) MBThread fetchThread(long threadId)
@Transactional(propagation=SUPPORTS, readOnly=true) ActionableDynamicQuery getActionableDynamicQuery()
@Transactional(propagation=SUPPORTS, readOnly=true) int getCategoryThreadsCount(long groupId, long categoryId, int status)
@Transactional(propagation=SUPPORTS, readOnly=true) ExportActionableDynamicQuery getExportActionableDynamicQuery(PortletDataContext portletDataContext)
@Transactional(propagation=SUPPORTS, readOnly=true) List<MBThread> getGroupThreads(long groupId, long userId, boolean subscribed, boolean includeAnonymous, QueryDefinition<MBThread> queryDefinition)
@Transactional(propagation=SUPPORTS, readOnly=true) List<MBThread> getGroupThreads(long groupId, long userId, boolean subscribed, QueryDefinition<MBThread> queryDefinition)
@Transactional(propagation=SUPPORTS, readOnly=true) List<MBThread> getGroupThreads(long groupId, long userId, QueryDefinition<MBThread> queryDefinition)
@Transactional(propagation=SUPPORTS, readOnly=true) List<MBThread> getGroupThreads(long groupId, QueryDefinition<MBThread> queryDefinition)
@Transactional(propagation=SUPPORTS, readOnly=true) int getGroupThreadsCount(long groupId, long userId, boolean subscribed, boolean includeAnonymous, QueryDefinition<MBThread> queryDefinition)
@Transactional(propagation=SUPPORTS, readOnly=true) int getGroupThreadsCount(long groupId, long userId, boolean subscribed, QueryDefinition<MBThread> queryDefinition)
@Transactional(propagation=SUPPORTS, readOnly=true) int getGroupThreadsCount(long groupId, long userId, QueryDefinition<MBThread> queryDefinition)
@Transactional(propagation=SUPPORTS, readOnly=true) int getGroupThreadsCount(long groupId, QueryDefinition<MBThread> queryDefinition)
@Transactional(propagation=SUPPORTS, readOnly=true) IndexableActionableDynamicQuery getIndexableActionableDynamicQuery()
@Transactional(propagation=SUPPORTS, readOnly=true) MBThread getMBThread(long threadId) throws PortalException
threadId
- the primary key of the message boards threadPortalException
- if a message boards thread with the primary key could not be found@Transactional(propagation=SUPPORTS, readOnly=true) MBThread getMBThreadByUuidAndGroupId(String uuid, long groupId) throws PortalException
uuid
- the message boards thread's UUIDgroupId
- the primary key of the groupPortalException
- if a matching message boards thread could not be found@Transactional(propagation=SUPPORTS, readOnly=true) List<MBThread> getMBThreads(int start, int end)
Useful when paginating results. Returns a maximum of end - start
instances. start
and end
are not primary keys, they are indexes in the result set. Thus, 0
refers to the first result in the set. Setting both start
and end
to QueryUtil.ALL_POS
will return the full result set. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil.ALL_POS
), then the query will include the default ORDER BY logic from MBThreadModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
start
- the lower bound of the range of message boards threadsend
- the upper bound of the range of message boards threads (not inclusive)@Transactional(propagation=SUPPORTS, readOnly=true) List<MBThread> getMBThreadsByUuidAndCompanyId(String uuid, long companyId)
uuid
- the UUID of the message boards threadscompanyId
- the primary key of the company@Transactional(propagation=SUPPORTS, readOnly=true) List<MBThread> getMBThreadsByUuidAndCompanyId(String uuid, long companyId, int start, int end, OrderByComparator<MBThread> orderByComparator)
uuid
- the UUID of the message boards threadscompanyId
- the primary key of the companystart
- the lower bound of the range of message boards threadsend
- the upper bound of the range of message boards threads (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)@Transactional(propagation=SUPPORTS, readOnly=true) int getMBThreadsCount()
@Transactional(propagation=SUPPORTS, readOnly=true) List<MBThread> getNoAssetThreads()
String getOSGiServiceIdentifier()
@Transactional(propagation=SUPPORTS, readOnly=true) PersistedModel getPersistedModel(Serializable primaryKeyObj) throws PortalException
getPersistedModel
in interface PersistedModelLocalService
PortalException
@Transactional(propagation=SUPPORTS, readOnly=true) List<MBThread> getPriorityThreads(long categoryId, double priority) throws PortalException
PortalException
@Transactional(propagation=SUPPORTS, readOnly=true) List<MBThread> getPriorityThreads(long categoryId, double priority, boolean inherit) throws PortalException
PortalException
@Transactional(propagation=SUPPORTS, readOnly=true) MBThread getThread(long threadId) throws PortalException
PortalException
@Transactional(propagation=SUPPORTS, readOnly=true) List<MBThread> getThreads(long groupId, long categoryId, int status, int start, int end)
@Transactional(propagation=SUPPORTS, readOnly=true) int getThreadsCount(long groupId, long categoryId, int status)
@Transactional(propagation=SUPPORTS, readOnly=true) boolean hasAnswerMessage(long threadId)
@BufferedIncrement(configuration="MBThread", incrementClass=NumberIncrement.class) void incrementViewCounter(long threadId, int increment) throws PortalException
PortalException
void moveDependentsToTrash(long groupId, long threadId, long trashEntryId) throws PortalException
PortalException
MBThread moveThread(long groupId, long categoryId, long threadId) throws PortalException
PortalException
MBThread moveThreadFromTrash(long userId, long categoryId, long threadId) throws PortalException
PortalException
void moveThreadsToTrash(long groupId, long userId) throws PortalException
PortalException
MBThread moveThreadToTrash(long userId, long threadId) throws PortalException
PortalException
MBThread moveThreadToTrash(long userId, MBThread thread) throws PortalException
PortalException
void restoreDependentsFromTrash(long groupId, long threadId) throws PortalException
PortalException
@Deprecated void restoreDependentsFromTrash(long groupId, long threadId, long trashEntryId) throws PortalException
restoreDependentsFromTrash(long, long)
PortalException
void restoreThreadFromTrash(long userId, long threadId) throws PortalException
PortalException
@Transactional(propagation=SUPPORTS, readOnly=true) Hits search(long groupId, long userId, long creatorUserId, int status, int start, int end) throws PortalException
PortalException
@Transactional(propagation=SUPPORTS, readOnly=true) Hits search(long groupId, long userId, long creatorUserId, long startDate, long endDate, int status, int start, int end) throws PortalException
PortalException
MBThread splitThread(long userId, long messageId, String subject, ServiceContext serviceContext) throws PortalException
PortalException
@Indexable(type=REINDEX) MBThread updateMBThread(MBThread mbThread)
mbThread
- the message boards threadMBThread updateMessageCount(long threadId)
void updateQuestion(long threadId, boolean question) throws PortalException
PortalException
MBThread updateStatus(long userId, long threadId, int status) throws PortalException
PortalException