Package aQute.bnd.build
Class WorkspaceNotifier
- java.lang.Object
-
- aQute.bnd.build.WorkspaceNotifier
-
- All Implemented Interfaces:
java.io.Closeable,java.lang.AutoCloseable
class WorkspaceNotifier extends java.lang.Object implements java.io.CloseableImplements the event bus for the workspace, projects and repositories. It can createOnWorkspaceobjects that client can use to get events. Clients can close and this will clean up. The class is private to the workspace.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static classWorkspaceNotifier.ET(package private) classWorkspaceNotifier.Receipt
-
Field Summary
Fields Modifier and Type Field Description (package private) booleanclosed(package private) java.util.List<java.lang.Runnable>events(package private) java.util.Map<WorkspaceNotifier.ET,java.lang.Object>last(package private) java.lang.Objectlock(package private) booleanmute(package private) MultiMap<WorkspaceNotifier.ET,WorkspaceNotifier.Receipt>ons(package private) intrevision(package private) SerialExecutorserial(package private) Workspaceworkspace
-
Constructor Summary
Constructors Constructor Description WorkspaceNotifier(Workspace workspace)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private <T> voidbroadcast(WorkspaceNotifier.ET type, T arg)(package private) voidbuild(BuildInfo buildInfo)voidchangedProject(Project project)voidclose()(package private) voidclosing(Workspace workspace)(package private) <T> voidifSameRevision(int revision, WorkspaceNotifier.ET type, T arg)(package private) intinitialized()(package private) voidmessage(Workspace workspace)(package private) OnWorkspaceon(java.lang.String name)voidprojects(java.util.Collection<Project> projects)(package private) voidrepos(java.util.List<RepositoryPlugin> repos)
-
-
-
Field Detail
-
ons
final MultiMap<WorkspaceNotifier.ET,WorkspaceNotifier.Receipt> ons
-
last
final java.util.Map<WorkspaceNotifier.ET,java.lang.Object> last
-
lock
final java.lang.Object lock
-
workspace
final Workspace workspace
-
events
final java.util.List<java.lang.Runnable> events
-
serial
final SerialExecutor serial
-
revision
int revision
-
closed
boolean closed
-
mute
volatile boolean mute
-
-
Constructor Detail
-
WorkspaceNotifier
WorkspaceNotifier(Workspace workspace)
-
-
Method Detail
-
initialized
int initialized()
-
message
void message(Workspace workspace)
-
closing
void closing(Workspace workspace)
-
repos
void repos(java.util.List<RepositoryPlugin> repos)
-
build
void build(BuildInfo buildInfo)
-
projects
public void projects(java.util.Collection<Project> projects)
-
changedProject
public void changedProject(Project project)
-
broadcast
private <T> void broadcast(WorkspaceNotifier.ET type, T arg)
-
on
OnWorkspace on(java.lang.String name)
-
ifSameRevision
<T> void ifSameRevision(int revision, WorkspaceNotifier.ET type, T arg)
-
close
public void close() throws java.io.IOException- Specified by:
closein interfacejava.lang.AutoCloseable- Specified by:
closein interfacejava.io.Closeable- Throws:
java.io.IOException
-
-