mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
Merged HEAD-BUG-FIX (5.0/Cloud) to HEAD (5.0/Cloud)
75077: Merged WAT2 (5.0/Cloud) to HEAD-BUG-FIX (5.0/Cloud) 73044: The default event publisher can do more, then only 1 method to implement git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@75405 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -46,6 +46,14 @@ public abstract class AbstractEventPublisher implements EventPublisher
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void publishEvent(EventPreparator prep)
|
||||||
|
{
|
||||||
|
ThreadInfo info = getThreadInfo();
|
||||||
|
Event event = prep.prepareEvent(info.user, info.network, info.transaction);
|
||||||
|
publishEvent(event);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Gets userful information from the current thread for use when creating an event
|
* Gets userful information from the current thread for use when creating an event
|
||||||
* @return ThreadInfo
|
* @return ThreadInfo
|
||||||
@@ -62,10 +70,10 @@ public abstract class AbstractEventPublisher implements EventPublisher
|
|||||||
* Basic information from a thread
|
* Basic information from a thread
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
protected static class ThreadInfo {
|
public static class ThreadInfo {
|
||||||
protected final String user;
|
public final String user;
|
||||||
protected final String transaction;
|
public final String transaction;
|
||||||
protected final String network;
|
public final String network;
|
||||||
|
|
||||||
public ThreadInfo(String user, String transaction, String network)
|
public ThreadInfo(String user, String transaction, String network)
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user