From 3d89ba7509cc39dbf0c2c6fe2b42497d8b1fc108 Mon Sep 17 00:00:00 2001 From: Benjamin Bentmann Date: Fri, 11 Feb 2011 23:31:17 +0000 Subject: [PATCH] o Extended API docs git-svn-id: https://svn.apache.org/repos/asf/maven/maven-3/trunk@1069983 13f79535-47bb-0310-9956-ffa450edef68 --- .../org/apache/maven/eventspy/EventSpy.java | 26 +++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/maven-core/src/main/java/org/apache/maven/eventspy/EventSpy.java b/maven-core/src/main/java/org/apache/maven/eventspy/EventSpy.java index 16c0d85197..eea83214d4 100644 --- a/maven-core/src/main/java/org/apache/maven/eventspy/EventSpy.java +++ b/maven-core/src/main/java/org/apache/maven/eventspy/EventSpy.java @@ -34,16 +34,42 @@ public interface EventSpy interface Context { + /** + * Gets key-value pairs providing information about the Maven runtime. + * + * @return The key-value pairs, never {@code null}. + */ Map getData(); } + /** + * Initializes the spy. + * + * @param context The event spy context, never {@code null}. + */ void init( Context context ) throws Exception; + /** + * Notifies the spy of some build event/operation. + * + * @param event The event, never {@@code null}. + * @see org.apache.maven.settings.building.SettingsBuildingRequest + * @see org.apache.maven.settings.building.SettingsBuildingResult + * @see org.apache.maven.execution.MavenExecutionRequest + * @see org.apache.maven.execution.MavenExecutionResult + * @see org.apache.maven.project.DependencyResolutionRequest + * @see org.apache.maven.project.DependencyResolutionResultt + * @see org.apache.maven.execution.ExecutionEvent + * @see org.sonatype.aether.RepositoryEvent + */ void onEvent( Object event ) throws Exception; + /** + * Notifies the spy of Maven's termination, allowing it to free any resources allocated by it. + */ void close() throws Exception;