From scm-return-37404-apmail-geronimo-scm-archive=geronimo.apache.org@geronimo.apache.org Mon Jul 06 19:50:59 2009 Return-Path: Delivered-To: apmail-geronimo-scm-archive@www.apache.org Received: (qmail 35755 invoked from network); 6 Jul 2009 19:50:48 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 6 Jul 2009 19:50:48 -0000 Received: (qmail 40314 invoked by uid 500); 6 Jul 2009 19:50:58 -0000 Delivered-To: apmail-geronimo-scm-archive@geronimo.apache.org Received: (qmail 40239 invoked by uid 500); 6 Jul 2009 19:50:58 -0000 Mailing-List: contact scm-help@geronimo.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: dev@geronimo.apache.org List-Id: Delivered-To: mailing list scm@geronimo.apache.org Received: (qmail 40230 invoked by uid 99); 6 Jul 2009 19:50:58 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Jul 2009 19:50:58 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Jul 2009 19:50:50 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id 10A7923888DD; Mon, 6 Jul 2009 19:50:29 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r791585 [1/3] - in /geronimo/sandbox/blueprint: blueprint-api/src/main/java/org/osgi/service/blueprint/container/ blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ blueprint-bundle/ blueprint-cm/src/main/resources/org/apache/g... Date: Mon, 06 Jul 2009 19:50:27 -0000 To: scm@geronimo.apache.org From: gnodet@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20090706195029.10A7923888DD@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: gnodet Date: Mon Jul 6 19:50:26 2009 New Revision: 791585 URL: http://svn.apache.org/viewvc?rev=791585&view=rev Log: Upgrade to latest api / schemas Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/BlueprintContainer.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/BlueprintEvent.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/BlueprintListener.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ComponentDefinitionException.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/Converter.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/EventConstants.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/NoSuchComponentException.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ReifiedType.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ServiceUnavailableException.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/package.html geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/packageinfo geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/BeanArgument.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/BeanMetadata.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/BeanProperty.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/CollectionMetadata.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ComponentMetadata.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/IdRefMetadata.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/MapEntry.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/MapMetadata.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/Metadata.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/NonNullMetadata.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/NullMetadata.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/PropsMetadata.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/RefMetadata.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ReferenceListMetadata.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ReferenceListener.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ReferenceMetadata.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/RegistrationListener.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ServiceMetadata.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ServiceReferenceMetadata.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/Target.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ValueMetadata.java geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/package.html geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/packageinfo geronimo/sandbox/blueprint/blueprint-bundle/pom.xml geronimo/sandbox/blueprint/blueprint-cm/src/main/resources/org/apache/geronimo/blueprint/compendium/cm/blueprint-cm.xsd geronimo/sandbox/blueprint/blueprint-core/src/main/java/org/apache/geronimo/blueprint/container/BlueprintEventDispatcher.java geronimo/sandbox/blueprint/blueprint-core/src/main/resources/org/apache/geronimo/blueprint/blueprint.xsd Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/BlueprintContainer.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/BlueprintContainer.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/BlueprintContainer.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/BlueprintContainer.java Mon Jul 6 19:50:26 2009 @@ -15,88 +15,85 @@ */ package org.osgi.service.blueprint.container; -import java.util.*; +import java.util.Collection; +import java.util.Set; -import org.osgi.service.blueprint.reflect.*; +import org.osgi.service.blueprint.reflect.BeanMetadata; +import org.osgi.service.blueprint.reflect.ComponentMetadata; +import org.osgi.service.blueprint.reflect.ReferenceListMetadata; +import org.osgi.service.blueprint.reflect.ReferenceMetadata; +import org.osgi.service.blueprint.reflect.ServiceMetadata; +import org.osgi.service.blueprint.reflect.ServiceReferenceMetadata; /** - * Blueprint Container provides access to all the managers. These are the beans, - * registered services, and service references. Only bundles in the - * ACTIVE (or also STARTING for bundles with a - * lazy activation policy) state can have an associated Blueprint Container. A - * given Bundle Context has at most one associated Blueprint Container. + * A Blueprint Container represents the managed state of a Blueprint bundle. * - * A Blueprint Container can be obtained by injecting the predefined - * "blueprintContainer" environment manager. Alternatively the Blueprint - * Container is registered as a service and its managers can be looked up. + * A Blueprint Container provides access to all managed components. These are + * the beans, services, and service references. Only bundles in the + * ACTIVE state (and also the STARTING state for + * bundles awaiting lazy activation) can have an associated Blueprint Container. + * A given Bundle Context has at most one associated Blueprint Container. * - * @see org.osgi.framework.Constants + * A Blueprint Container can be obtained by injecting the predefined + * "blueprintContainer" component id. The Blueprint Container is also + * registered as a service and its managed components can be queried. * * @ThreadSafe + * @version $Revision$ */ public interface BlueprintContainer { /** - * The set of manager ids recognized by the Blueprint Container. + * Returns the set of component ids managed by this Blueprint Container. * - * @return an immutable Set of Strings, containing the ids of all of the - * managers within the Blueprint Container. + * @return An immutable Set of Strings, containing the ids of all of the + * components managed within this Blueprint Container. */ Set getComponentIds(); /** - * Get the component instance for a given named component. If the manager - * has not yet been activated, calling this operation will cause the - * component instance to be created and initialized. If the component has a - * prototype scope then each call to the getComponentInstance - * method will return a new component instance. - * - * Calling {link #getComponentInstance} from logic executing during the - * construction of a component, before the initMethod (if - * specified) has returned, may trigger a circular dependency. - * - * @param id - * The id of the manager for which the instance is to be - * provided. + * Return the component instance for the specified component id. * - * @return The component instance, the type of the returned object is - * dependent on the manager, and may be determined with the - * Metadata. + * If the component's manager has not yet been activated, calling this + * operation will atomically activate it. If the component has singleton + * scope, the activation will cause the component instance to be created and + * initialized. If the component has prototype scope, then each call to this + * method will return a new component instance. * - * @throws NoSuchComponentException - * If the id specified is not the id of a manager within the - * context. + * @param id The component id for the requested component instance. + * @return A component instance for the component with the specified + * component id. + * @throws NoSuchComponentException If no component with the specified + * component id is managed by this Blueprint Container. */ Object getComponentInstance(String id); /** - * Get the Metadata for a given manager id. - * - * @param id - * the id of the manager for which the Metadata is to be - * retrieved. - * - * @return the Metadata for the manager with the given id. + * Return the Component Metadata object for the component with the specified + * component id. * - * @throws NoSuchComponentException - * if the id specified is not the id of a manager within the - * Blueprint Container. + * @param id The component id for the requested Component Metadata. + * @return The Component Metadata object for the component with the + * specified component id. + * @throws NoSuchComponentException If no component with the specified + * component id is managed by this Blueprint Container. */ ComponentMetadata getComponentMetadata(String id); /** - * Returns all {@link ComponentMetadata} instances of the given type. The - * supported Metadata types are {@link ComponentMetadata} (which returns the - * Metadata for all defined manager types), {@link BeanMetadata}, + * Return all {@link ComponentMetadata} objects of the specified Component + * Metadata type. The supported Component Metadata types are + * {@link ComponentMetadata} (which returns the Component Metadata for all + * defined manager types), {@link BeanMetadata} , * {@link ServiceReferenceMetadata} (which returns both - * {@link ReferenceMetadata} and {@link ReferenceListMetadata} instances), - * and {@link ServiceMetadata}. The collection will include all Metadata - * instances of the requested type, including components that are declared - * as inline values. - * - * @param type The super type or type of all returned Metadata - * - * @return An immutable collection of {@link ComponentMetadata} objects of the - * matching type. + * {@link ReferenceMetadata} and {@link ReferenceListMetadata} objects), and + * {@link ServiceMetadata}. The collection will include all Component + * Metadata objects of the requested type, including components that are + * declared inline. + * + * @param type The super type or type of the requested Component Metadata + * objects. + * @return An immutable collection of Component Metadata objects of the + * specified type. */ Collection getMetadata( Class type); Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/BlueprintEvent.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/BlueprintEvent.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/BlueprintEvent.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/BlueprintEvent.java Mon Jul 6 19:50:26 2009 @@ -22,44 +22,44 @@ * *

* BlueprintEvent objects are delivered to all registered - * BlueprintListener service objects. Blueprint Events must be - * asynchronously delivered in chronological order with respect to each - * listener. + * {@link BlueprintListener} services. Blueprint Events must be asynchronously + * delivered in chronological order with respect to each listener. * *

- * In addition, when a listener is registered, the Blueprint extender will - * synchronously send to this listener the last event for each ready Blueprint bundle - * managed by this extender. This replay of events is designed so that the new - * listener can be informed of the state of each Blueprint bundle. Events sent - * during this replay will have the {@link #isReplay()} flag set. The Blueprint - * extender must ensure that this replay phase does not interfere with new - * events so that the chronological order of all events received by the listener - * is preserved. If the last event for a given Blueprint bundle is - * {@link #DESTROYED}, the extender must not send it during this replay phase. + * In addition, after a Blueprint Listener is registered, the Blueprint extender + * will synchronously send to this Blueprint Listener the last Blueprint Event + * for each ready Blueprint bundle managed by this extender. This + * replay of Blueprint Events is designed so that the new Blueprint + * Listener can be informed of the state of each Blueprint bundle. Blueprint + * Events sent during this replay will have the {@link #isReplay()} flag set. + * The Blueprint extender must ensure that this replay phase does not interfere + * with new Blueprint Events so that the chronological order of all Blueprint + * Events received by the Blueprint Listener is preserved. If the last Blueprint + * Event for a given Blueprint bundle is {@link #DESTROYED}, the extender must + * not send it during this replay phase. * *

* A type code is used to identify the type of event. The following event types * are defined: *

    - *
  • {@link #CREATING} - *
  • {@link #CREATED} - *
  • {@link #DESTROYING} - *
  • {@link #DESTROYED} - *
  • {@link #FAILURE} - *
  • {@link #GRACE_PERIOD} - *
  • {@link #WAITING} + *
  • {@link #CREATING}
  • + *
  • {@link #CREATED}
  • + *
  • {@link #DESTROYING}
  • + *
  • {@link #DESTROYED}
  • + *
  • {@link #FAILURE}
  • + *
  • {@link #GRACE_PERIOD}
  • + *
  • {@link #WAITING}
  • *
* *

- *

Blueprint Events and Event Admin service

* In addition to calling the registered {@link BlueprintListener} services, the * Blueprint extender must also send those events to the Event Admin service, if - * it is available.
See {@link EventConstants} for more informations. + * it is available. * * @see BlueprintListener * @see EventConstants - * * @Immutable + * @version $Revision$ */ public class BlueprintEvent { @@ -67,33 +67,33 @@ * The Blueprint extender has started creating a Blueprint Container for the * bundle. */ - public static final int CREATING = 1; + public static final int CREATING = 1; /** * The Blueprint extender has created a Blueprint Container for the bundle. - * This event is sent after the Blueprint Container service has been - * registered. + * This event is sent after the Blueprint Container has been registered as a + * service. */ - public static final int CREATED = 2; + public static final int CREATED = 2; /** * The Blueprint extender has started destroying the Blueprint Container for * the bundle. */ - public static final int DESTROYING = 3; + public static final int DESTROYING = 3; /** * The Blueprint Container for the bundle has been completely destroyed. - * This event is sent after the Blueprint Container service has been - * unregistered. + * This event is sent after the Blueprint Container has been unregistered as + * a service. */ - public static final int DESTROYED = 4; + public static final int DESTROYED = 4; /** * The Blueprint Container creation for the bundle has failed. If this event * is sent after a timeout in the Grace Period, the * {@link #getDependencies()} method must return an array of missing * mandatory dependencies. The event must also contain the cause of the - * failure as a Throwable through the {@link #getException()} + * failure as a Throwable through the {@link #getCause()} * method. */ - public static final int FAILURE = 5; + public static final int FAILURE = 5; /** * The Blueprint Container has entered the grace period. The list of missing * dependencies must be made available through the @@ -101,68 +101,67 @@ * {@link #GRACE_PERIOD} event is sent each time the set of unsatisfied * dependencies changes. */ - public static final int GRACE_PERIOD = 6; + public static final int GRACE_PERIOD = 6; /** - * The Blueprint Extender is waiting on the availability of a service to + * The Blueprint Container is waiting on the availability of a service to * satisfy an invocation on a referenced service. The missing dependency * must be made available through the {@link #getDependencies()} method * which will return an array containing one filter object as a String. */ - public static final int WAITING = 7; + public static final int WAITING = 7; /** * Type of this event. * * @see #getType() */ - private final int type; + private final int type; /** * The time when the event occurred. * * @see #getTimestamp() */ - private final long timestamp; + private final long timestamp; /** * The Blueprint bundle. * * @see #getBundle() */ - private final Bundle bundle; + private final Bundle bundle; /** * The Blueprint extender bundle. * * @see #getExtenderBundle() */ - private final Bundle extenderBundle; + private final Bundle extenderBundle; /** - * An array containing filters identifying the missing dependencies. + * An array containing filters identifying the missing dependencies. Must + * not be null when the event type requires it. * * @see #getDependencies() */ - private final String[] dependencies; + private final String[] dependencies; /** * Cause of the failure. * - * @see #getException() + * @see #getCause() */ - private final Throwable exception; + private final Throwable cause; /** * Indicate if this event is a replay event or not. * * @see #isReplay() */ - private final boolean replay; + private final boolean replay; /** * Create a simple BlueprintEvent object. * - * @param type - * The type of the event. - * @param bundle - * The Blueprint bundle this event is originating from. - * @param extenderBundle - * The bundle of the Blueprint extender that is generating the - * event. + * @param type The type of this event. + * @param bundle The Blueprint bundle associated with this event. This + * parameter must not be null. + * @param extenderBundle The Blueprint extender bundle that is generating + * this event. This parameter must not be null. */ public BlueprintEvent(int type, Bundle bundle, Bundle extenderBundle) { this(type, bundle, extenderBundle, null, null); @@ -172,16 +171,15 @@ * Create a BlueprintEvent object associated with a set of * dependencies. * - * @param type - * The type of the event. - * @param bundle - * The Blueprint bundle this event is originating from. - * @param extenderBundle - * The bundle of the Blueprint extender that is generating the - * event. - * @param dependencies - * An array of String filters for each dependency - * associated with this event. + * @param type The type of this event. + * @param bundle The Blueprint bundle associated with this event. This + * parameter must not be null. + * @param extenderBundle The Blueprint extender bundle that is generating + * this event. This parameter must not be null. + * @param dependencies An array of String filters for each + * dependency associated with this event. Must be a non-empty array + * for event types {@link #FAILURE}, {@link #GRACE_PERIOD} and + * {@link #WAITING}. Must be null for other event types. */ public BlueprintEvent(int type, Bundle bundle, Bundle extenderBundle, String[] dependencies) { @@ -192,60 +190,82 @@ * Create a BlueprintEvent object associated with a failure * cause. * - * @param type - * The type of the event. - * @param bundle - * The Blueprint bundle this event is originating from. - * @param extenderBundle - * The bundle of the Blueprint extender that is generating the - * event. - * @param exception - * A Throwable object describing the root cause of - * the event. + * @param type The type of this event. + * @param bundle The Blueprint bundle associated with this event. This + * parameter must not be null. + * @param extenderBundle The Blueprint extender bundle that is generating + * this event. This parameter must not be null. + * @param cause A Throwable object describing the root cause of + * the event. May be null. */ public BlueprintEvent(int type, Bundle bundle, Bundle extenderBundle, - Throwable exception) { - this(type, bundle, extenderBundle, null, exception); + Throwable cause) { + this(type, bundle, extenderBundle, null, cause); } /** * Create a BlueprintEvent object associated with a failure * cause and related to a set of dependencies. * - * @param type - * The type of the event. - * @param bundle - * The Blueprint bundle this event is originating from. - * @param extenderBundle - * The bundle of the Blueprint extender that is generating the - * event. - * @param dependencies - * An array of String filters for each dependency - * associated with this event. - * @param exception - * A Throwable object describing the root cause of - * the event. + * @param type The type of this event. + * @param bundle The Blueprint bundle associated with this event. This + * parameter must not be null. + * @param extenderBundle The Blueprint extender bundle that is generating + * this event. This parameter must not be null. + * @param dependencies An array of String filters for each + * dependency associated with this event. Must be a non-empty array + * for event types {@link #FAILURE}, {@link #GRACE_PERIOD} and + * {@link #WAITING}. Must be null for other event types. + * @param cause A Throwable object describing the root cause of + * this event. May be null. */ public BlueprintEvent(int type, Bundle bundle, Bundle extenderBundle, - String[] dependencies, Throwable exception) { + String[] dependencies, Throwable cause) { this.type = type; this.timestamp = System.currentTimeMillis(); this.bundle = bundle; this.extenderBundle = extenderBundle; this.dependencies = dependencies; - this.exception = exception; + this.cause = cause; this.replay = false; + if (bundle == null) { + throw new NullPointerException("bundle must not be null"); + } + if (extenderBundle == null) { + throw new NullPointerException("extenderBundle must not be null"); + } + switch (type) { + case WAITING : + case GRACE_PERIOD : + case FAILURE : + if (dependencies == null) { + throw new NullPointerException( + "dependencies must not be null"); + } + if (dependencies.length == 0) { + throw new IllegalArgumentException( + "dependencies must not be length zero"); + } + break; + default : + if (dependencies != null) { + throw new IllegalArgumentException( + "dependencies must be null"); + } + break; + } } /** - * Create a new Blueprint Event from the given Blueprint event. The - * timestamp property will be copied from the original event - * and only the replay property will be overridden with the given value. - * - * @param event - * the original event to copy - * @param replay - * if the copied event should be used as a replay event + * Create a new BlueprintEvent from the specified + * BlueprintEvent. The timestamp property will be + * copied from the original event and only the replay property will be + * overridden with the given value. + * + * @param event The original BlueprintEvent to copy. Must not + * be null. + * @param replay true if this event should be used as a replay + * event. */ public BlueprintEvent(BlueprintEvent event, boolean replay) { this.type = event.type; @@ -253,7 +273,7 @@ this.bundle = event.bundle; this.extenderBundle = event.extenderBundle; this.dependencies = event.dependencies; - this.exception = event.exception; + this.cause = event.cause; this.replay = replay; } @@ -262,13 +282,13 @@ *

* The type values are: *

    - *
  • {@link #CREATING} - *
  • {@link #CREATED} - *
  • {@link #DESTROYING} - *
  • {@link #DESTROYED} - *
  • {@link #FAILURE} - *
  • {@link #GRACE_PERIOD} - *
  • {@link #WAITING} + *
  • {@link #CREATING}
  • + *
  • {@link #CREATED}
  • + *
  • {@link #DESTROYING}
  • + *
  • {@link #DESTROYED}
  • + *
  • {@link #FAILURE}
  • + *
  • {@link #GRACE_PERIOD}
  • + *
  • {@link #WAITING}
  • *
* * @return The type of this event. @@ -278,27 +298,27 @@ } /** - * Return the time at which this event occured. + * Return the time at which this event was created. * - * @return The time at which this event occured. + * @return The time at which this event was created. */ public long getTimestamp() { return timestamp; } /** - * Return the Blueprint bundle. + * Return the Blueprint bundle associated with this event. * - * @return The Blueprint bundle. Never null. + * @return The Blueprint bundle associated with this event. */ public Bundle getBundle() { return bundle; } /** - * Return the Bundle of the Blueprint extender. + * Return the Blueprint extender bundle that is generating this event. * - * @return The Bundle of the Blueprint extender. Never null. + * @return The Blueprint extender bundle that is generating this event. */ public Bundle getExtenderBundle() { return extenderBundle; @@ -307,32 +327,33 @@ /** * Return the filters identifying the missing dependencies that caused this * event. - *

- * This field is only valid for {@link #WAITING}, {@link #GRACE_PERIOD} and - * {@link #FAILURE} events. * - * @return The missing dependencies informations. May be null. + * @return The filters identifying the missing dependencies that caused this + * event if the event type is one of {@link #WAITING}, + * {@link #GRACE_PERIOD} or {@link #FAILURE} or null + * for the other event types. */ public String[] getDependencies() { - return dependencies != null ? (String[]) dependencies.clone() : null; + return dependencies == null ? null : (String[]) dependencies.clone(); } /** - * Return the cause for a {@link #FAILURE} event. + * Return the cause for this {@link #FAILURE} event. * - * @return The cause of the failure. May be null. + * @return The cause of the failure for this event. May be null + * . */ - public Throwable getException() { - return exception; + public Throwable getCause() { + return cause; } /** - * Return the fact that this event is a replay event or not. + * Return whether this event is a replay event. * - * @return a boolean indicating if this event is a replay event. + * @return true if this event is a replay event and + * false otherwise. */ public boolean isReplay() { return replay; } - } Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/BlueprintListener.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/BlueprintListener.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/BlueprintListener.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/BlueprintListener.java Mon Jul 6 19:50:26 2009 @@ -16,27 +16,36 @@ package org.osgi.service.blueprint.container; /** - * Listener for BlueprintEvents. Implementers should register - * this a Blueprint Event Listener service. The Blueprint extender must inform - * the Blueprint Event Listener synchronously with the registration the last - * non-DESTROYED event of all managed bundles with the replay flag set before - * any of the other events are delivered. The delivery must maintain the time - * ordering. + * A BlueprintEvent Listener. * - * @see BlueprintEvent + *

+ * To receive Blueprint Events, a bundle must register a Blueprint Listener + * service. + * + * After a Blueprint Listener is registered, the Blueprint extender + * must synchronously send to this Blueprint Listener the last Blueprint Event + * for each ready Blueprint bundle managed by this extender. This replay of + * Blueprint Events is designed so that the new Blueprint Listener can be + * informed of the state of each Blueprint bundle. Blueprint Events sent during + * this replay will have the {@link BlueprintEvent#isReplay()} flag set. The + * Blueprint extender must ensure that this replay phase does not interfere with + * new Blueprint Events so that the chronological order of all Blueprint Events + * received by the Blueprint Listener is preserved. If the last Blueprint Event + * for a given Blueprint bundle is {@link BlueprintEvent#DESTROYED}, the + * extender must not send it during this replay phase. * + * @see BlueprintEvent * @ThreadSafe + * @version $Revision$ */ public interface BlueprintListener { /** - * Receives synchronous notifications of a Blueprint Event. + * Receives notifications of a Blueprint Event. * - * Implementers should quickly process the events and return. + * Implementers should quickly process the event and return. * - * @param event - * The BlueprintEvent. + * @param event The {@link BlueprintEvent}. */ void blueprintEvent(BlueprintEvent event); - } Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ComponentDefinitionException.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ComponentDefinitionException.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ComponentDefinitionException.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ComponentDefinitionException.java Mon Jul 6 19:50:26 2009 @@ -16,53 +16,50 @@ package org.osgi.service.blueprint.container; /** - * Exception thrown when a configuration-related error occurs during creation of - * a Blueprint Container. + * A Blueprint exception indicating that a component definition is in error. + * + * This exception is thrown when a configuration-related error occurs during + * creation of a Blueprint Container. + * + * @version $Revision$ */ public class ComponentDefinitionException extends RuntimeException { - private static final long serialVersionUID = 1L; + private static final long serialVersionUID = 1L; /** - * Creates a ComponentDefinitionException with no message or - * exception cause. + * Creates a Component Definition Exception with no message or exception + * cause. */ public ComponentDefinitionException() { super(); } /** - * Creates a ComponentDefinitionException with the specified - * message + * Creates a Component Definition Exception with the specified message * - * @param explanation - * The associated message. + * @param explanation The associated message. */ public ComponentDefinitionException(String explanation) { super(explanation); } /** - * Creates a ComponentDefinitionException with the specified - * message and exception cause. + * Creates a Component Definition Exception with the specified message and + * exception cause. * - * @param explanation - * The associated message. - * @param cause - * The cause of this exception. + * @param explanation The associated message. + * @param cause The cause of this exception. */ public ComponentDefinitionException(String explanation, Throwable cause) { super(explanation, cause); } /** - * Creates a ComponentDefinitionException with the exception - * cause. + * Creates a Component Definition Exception with the exception cause. * - * @param cause - * The cause of this exception. + * @param cause The cause of this exception. */ public ComponentDefinitionException(Throwable cause) { super(cause); } - } Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/Converter.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/Converter.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/Converter.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/Converter.java Mon Jul 6 19:50:26 2009 @@ -16,38 +16,36 @@ package org.osgi.service.blueprint.container; /** - * Provides access to the type conversions (both predefined and user registered) - * that are defined for the Blueprint Container. + * Type converter to convert an object to a target type. + * + * @ThreadSafe + * @version $Revision$ */ public interface Converter { /** - * Check if the converter is able to convert the given value to the + * Return if this converter is able to convert the specified object to the * specified type. * - * @param s - * The source object to convert from - * @param T - * The target type + * @param sourceObject The source object s to convert. + * @param targetType The target type T. * * @return true if the conversion is possible, * false otherwise. */ - boolean canConvert(Object s, ReifiedType T); + boolean canConvert(Object sourceObject, ReifiedType targetType); /** - * Convert an object to an instance of the given class. + * Convert the specified object to an instance of the specified type. * - * @param s - * The source object to convert from - * @param T - * The target type - * @return an instance with a type that is assignable from T's raw class - * @throws Exception - * If the conversion cannot succeed. This exception should not - * be thrown when the {@link #canConvert} method has returned - * true. + * @param sourceObject The source object s to convert. + * @param targetType The target type T. + * @return An instance with a type that is assignable from targetType's raw + * class + * @throws Exception If the conversion cannot succeed. This exception should + * not be thrown when the {@link #canConvert} method has returned + * true. */ - Object convert(Object s, ReifiedType T) throws Exception; - + Object convert(Object sourceObject, ReifiedType targetType) + throws Exception; } \ No newline at end of file Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/EventConstants.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/EventConstants.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/EventConstants.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/EventConstants.java Mon Jul 6 19:50:26 2009 @@ -15,39 +15,44 @@ */ package org.osgi.service.blueprint.container; -import org.osgi.framework.*; - /** * Event property names used in Event Admin events published by a Blueprint - * container. + * Container. + * + * Each type of event is sent to a different topic: * - * Each type of event is sent to a different topic:
+ * org/osgi/service/blueprint/container/<event-type> * - *

- *   org/osgi/service/blueprint/container/<event-type>
- * 
+ * where <event-type> can have the values + * {@link BlueprintEvent#CREATING CREATING}, {@link BlueprintEvent#CREATED + * CREATED}, {@link BlueprintEvent#DESTROYING DESTROYING}, + * {@link BlueprintEvent#DESTROYED DESTROYED}, {@link BlueprintEvent#FAILURE + * FAILURE}, {@link BlueprintEvent#GRACE_PERIOD GRACE_PERIOD}, or + * {@link BlueprintEvent#WAITING WAITING}. * - * where <event-type> can have the values - * CREATING, CREATED, DESTROYING, - * DESTROYED, FAILURE, GRACE_PERIOD - * or WAITING.
Such events have the following properties: + * Such events have the following properties: *
    - *
  • type - *
  • event - *
  • timestamp - *
  • bundle - *
  • bundle.symbolicName - *
  • bundle.id - *
  • bundle.version - *
  • extender.bundle - *
  • extender.bundle.symbolicName - *
  • extender.bundle.id - *
  • extender.bundle.version - *
  • dependencies - *
  • cause + *
  • {@link #TYPE type}
  • + *
  • {@link #EVENT event}
  • + *
  • {@link #TIMESTAMP timestamp}
  • + *
  • {@link #BUNDLE bundle}
  • + *
  • {@link #BUNDLE_SYMBOLICNAME bundle.symbolicName}
  • + *
  • {@link #BUNDLE_ID bundle.id}
  • + *
  • {@link #BUNDLE_VERSION bundle.version}
  • + *
  • {@link #EXTENDER_BUNDLE_SYMBOLICNAME extender.bundle.symbolicName}
  • + *
  • {@link #EXTENDER_BUNDLE_ID extender.bundle.id}
  • + *
  • {@link #EXTENDER_BUNDLE_VERSION extender.bundle.version}
  • + *
  • {@link #DEPENDENCIES dependencies}
  • + *
  • {@link #CAUSE cause}
  • *
+ * + * @Immutable + * @version $Revision$ */ -public interface EventConstants { +public class EventConstants { + private EventConstants() { + // non-instantiable class + } /** * The type of the event that has been issued. This property is of type @@ -63,126 +68,118 @@ public static final String EVENT = "event"; /** - * The type of the event that has been issued. This property is of type + * The time the event was created. This property is of type * Long. */ public static final String TIMESTAMP = "timestamp"; /** - * The bundle property defining the blueprint bundle for which an event has - * been issued. This property is of type {@link org.osgi.framework.Bundle}. - * - * @see Bundle + * The Blueprint bundle associated with this event. This property is of type + * Bundle. */ public static final String BUNDLE = "bundle"; /** - * The bundle id property defining the id of the blueprint bundle for which - * an event has been issued. This property is of type Long. + * The bundle id of the Blueprint bundle associated with this event. This + * property is of type Long. */ public static final String BUNDLE_ID = "bundle.id"; /** - * The bundle symbolic name property defining the symbolic name of the - * blueprint bundle for which an event has been issued. This property is of - * type String. + * The bundle symbolic name of the Blueprint bundle associated with this + * event. This property is of type String. */ public static final String BUNDLE_SYMBOLICNAME = "bundle.symbolicName"; /** - * The bundle id property defining the id of the blueprint bundle for which - * an event has been issued. This property is of type Version. + * The bundle version of the Blueprint bundle associated with this event. + * This property is of type Version. */ public static final String BUNDLE_VERSION = "bundle.version"; /** - * The extender bundle property defining the extender bundle processing the - * Blueprint Container for which an event has been issued. This property is - * of type {@link org.osgi.framework.Bundle}. - * - * @see Bundle + * The Blueprint extender bundle that is generating this event. This + * property is of type Bundle. */ public static final String EXTENDER_BUNDLE = "extender.bundle"; /** - * The Blueprint extender bundle id property defining the id of the extender bundle - * processing the Blueprint Container for which an event has been issued. - * This property is of type Long. + * The bundle id of the Blueprint extender bundle that is generating this + * event. This property is of type Long. */ public static final String EXTENDER_BUNDLE_ID = "extender.bundle.id"; /** - * The extender bundle symbolic name property defining the symbolic name of - * the extender bundle processing the Blueprint Container for which an event - * has been issued. This property is of type String. + * The bundle symbolic of the Blueprint extender bundle that is generating + * this event. This property is of type String. */ public static final String EXTENDER_BUNDLE_SYMBOLICNAME = "extender.bundle.symbolicName"; /** - * The Blueprint extender bundle version property defining the version of the Blueprint extender - * bundle processing the Blueprint Container for which an event has been - * issued. This property is of type Version. + * The bundle version of the Blueprint extender bundle that is generating + * this event. This property is of type Version. */ public static final String EXTENDER_BUNDLE_VERSION = "extender.bundle.version"; /** - * The dependencies property containing an array of filters describing the - * missing mandatory dependencies for a FAILED, GRACE_PERIOD or WAITING - * event. This property is an array of String. + * The filters identifying the missing dependencies that caused this event + * for a {@link BlueprintEvent#FAILURE FAILURE}, + * {@link BlueprintEvent#GRACE_PERIOD GRACE_PERIOD}, or + * {@link BlueprintEvent#WAITING WAITING} event. This property type is an + * array of String. */ public static final String DEPENDENCIES = "dependencies"; /** - * The exception property containing the cause for a FAILED event. This + * The cause for a {@link BlueprintEvent#FAILURE FAILURE} event. This * property is of type Throwable. */ - public static final String EXCEPTION = "exception"; + public static final String CAUSE = "cause"; /** * Topic prefix for all events issued by the Blueprint Container */ - public static final String TOPIC_BLUEPRINT_EVENTS = "org/osgi/service/blueprint"; + public static final String TOPIC_BLUEPRINT_EVENTS = "org/osgi/service/blueprint/container"; /** * Topic for Blueprint Container CREATING events */ public static final String TOPIC_CREATING = TOPIC_BLUEPRINT_EVENTS - + "/container/CREATING"; + + "/CREATING"; /** * Topic for Blueprint Container CREATED events */ public static final String TOPIC_CREATED = TOPIC_BLUEPRINT_EVENTS - + "/container/CREATED"; + + "/CREATED"; /** * Topic for Blueprint Container DESTROYING events */ public static final String TOPIC_DESTROYING = TOPIC_BLUEPRINT_EVENTS - + "/container/DESTROYING"; + + "/DESTROYING"; /** * Topic for Blueprint Container DESTROYED events */ public static final String TOPIC_DESTROYED = TOPIC_BLUEPRINT_EVENTS - + "/container/DESTROYED"; + + "/DESTROYED"; /** * Topic for Blueprint Container FAILURE events */ public static final String TOPIC_FAILURE = TOPIC_BLUEPRINT_EVENTS - + "/container/FAILURE"; + + "/FAILURE"; /** * Topic for Blueprint Container GRACE_PERIOD events */ public static final String TOPIC_GRACE_PERIOD = TOPIC_BLUEPRINT_EVENTS - + "/container/GRACE_PERIOD"; + + "/GRACE_PERIOD"; /** * Topic for Blueprint Container WAITING events */ public static final String TOPIC_WAITING = TOPIC_BLUEPRINT_EVENTS - + "/container/WAITING"; - + + "/WAITING"; } Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/NoSuchComponentException.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/NoSuchComponentException.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/NoSuchComponentException.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/NoSuchComponentException.java Mon Jul 6 19:50:26 2009 @@ -16,45 +16,50 @@ package org.osgi.service.blueprint.container; /** - * Thrown when an attempt is made to lookup a component by id and no such - * component exists in the Blueprint Container. + * A Blueprint exception indicating that a component does not exist in a + * Blueprint Container. + * + * This exception is thrown when an attempt is made to create a component + * instance or lookup Component Metadata using a component id that does not + * exist in the Blueprint Container. + * + * @version $Revision$ */ public class NoSuchComponentException extends RuntimeException { - private static final long serialVersionUID = 1L; - + private static final long serialVersionUID = 1L; /** - * The id of the component request that generated the exception. + * The requested component id that generated the exception. */ - private final String managerId; + private final String componentId; /** - * Create an exception for a single manager id request. + * Create a No Such Component Exception for a non-existent component. * - * @param id - * The id of the non-existent manager. + * @param msg The associated message. + * @param id The id of the non-existent component. */ - public NoSuchComponentException(String id) { - this.managerId = id; + public NoSuchComponentException(String msg, String id) { + super(msg); + this.componentId = id; } /** - * Returns the manager id that generated the Exception. + * Create a No Such Component Exception for a non-existent component. * - * @return The id of the component associated with an unresolved - * request. + * @param id The id of the non-existent component. */ - public String getComponentId() { - return this.managerId; + public NoSuchComponentException(String id) { + super("No component with id '" + (id == null ? "" : id) + + "' could be found"); + this.componentId = id; } /** - * Returns a human readable message associated with the exception. + * Returns the id of the non-existent component. * - * @return The descriptive message for the exception. + * @return The id of the non-existent component. */ - public String getMessage() { - return "No manager with id '" - + (this.managerId == null ? "" : this.managerId) - + "' could be found"; + public String getComponentId() { + return componentId; } } Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ReifiedType.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ReifiedType.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ReifiedType.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ReifiedType.java Mon Jul 6 19:50:26 2009 @@ -16,99 +16,107 @@ package org.osgi.service.blueprint.container; /** - * Provides access to a concrete type and its optional generic type arguments. + * Provides access to a concrete type and its optional generic type parameters. * * Java 5 and later support generic types. These types consist of a raw class - * with type arguments. This class models such a Type class but + * with type parameters. This class models such a Type class but * ensures that the type is reified. Reification means that the Type - * graph associated with a Java 5 Type instance is traversed - * until the type becomes a concrete class. In Java 1.4 a class has no - * arguments. This concrete class implements the Reified Type for Java 1.4. + * graph associated with a Java 5 Type instance is traversed until + * the type becomes a concrete class. This class is available with the + * {@link #getRawClass()} method. The optional type parameters are recursively + * represented as Reified Types. + * + * In Java 1.4, a class has by definition no type parameters. This class + * implementation provides the Reified Type for Java 1.4 by making the raw class + * the Java 1.4 class and using a Reified Type based on the Object + * class for any requested type parameter. + * + * A Blueprint extender implementations can subclass this class and provide + * access to the generic type parameter graph for conversion. Such a subclass + * must reify the different Java 5 Type instances into the + * reified form. That is, a form where the raw Class is available with its + * optional type parameters as Reified Types. * - * In Java 1.4, this class works with non-generic types. In that cases, a - * Reified Type provides access to the class and has zero type arguments, though - * a subclass that provide type arguments should be respected. Blueprint - * extender implementations can subclass this class and provide access to the - * generics type graph if used in a conversion. Such a subclass must - * reify the different Java 5 Type instances into the - * reified form. That is, a form where the raw Class is available with its optional type arguments as Reified Types. - * * @Immutable + * @version $Revision$ */ public class ReifiedType { - final static ReifiedType ALL = new ReifiedType(Object.class); + private final static ReifiedType OBJECT = new ReifiedType(Object.class); - private final Class clazz; + private final Class clazz; /** - * Create a Reified Type for a raw Java class without any generic arguments. - * Subclasses can provide the optional generic argument information. Without - * subclassing, this instance has no type arguments. + * Create a Reified Type for a raw Java class without any generic type + * parameters. Subclasses can provide the optional generic type parameter + * information. Without subclassing, this instance has no type parameters. * - * @param clazz - * The raw class of the Reified Type. + * @param clazz The raw class of the Reified Type. */ public ReifiedType(Class clazz) { this.clazz = clazz; } /** - * Access to the raw class. + * Return the raw class represented by this type. * * The raw class represents the concrete class that is associated with a * type declaration. This class could have been deduced from the generics - * type graph of the declaration. For example, in the following example: + * type parameter graph of the declaration. For example, in the following + * example: * *
-	 * Map<String, Object> map;
+	 * Map<String, ? extends Metadata>	map;
 	 * 
* * The raw class is the Map class. * - * @return the collapsed raw class that represents this type. + * @return The raw class represented by this type. */ public Class getRawClass() { return clazz; } /** - * Access to a type argument. + * Return a type parameter for this type. * - * The type argument refers to a argument in a generic type declaration - * given by index i. This method returns a Reified Type that - * has Object as class when no generic type information is available. Any - * object is assignable to Object and therefore no conversion is then - * necessary, this is compatible with older Javas than 5. For this reason, - * the implementation in this class always returns the - * Object class, regardless of the given index. - * - * This method should be overridden by a subclass that provides access to - * the generic information. + * The type parameter refers to a parameter in a generic type declaration + * given by the zero-based index i. * * For example, in the following example: * *
-	 * Map<String, Object> map;
+	 * Map<String, ? extends Metadata>	map;
 	 * 
* - * The type argument 0 is String, and type argument 1 is - * Object. + * type parameter 0 is String, and type parameter 1 is + * Metadata. + * + *

+ * This implementation returns a Reified Type that has Object + * as class. Any object is assignable to Object and therefore no conversion + * is then necessary. This is compatible with versions of Java language + * prior to Java 5. + * + * This method should be overridden by a subclass that provides access to + * the generic type parameter information for Java 5 and later. * - * @param i - * The index of the type argument - * @return ReifiedType(Object.class), subclasses must override this and return the generic argument at index i + * @param i The zero-based index of the requested type parameter. + * @return The ReifiedType for the generic type parameter at + * the specified index. */ public ReifiedType getActualTypeArgument(int i) { - return ALL; + return OBJECT; } /** - * Return the number of type arguments. + * Return the number of type parameters for this type. * - * This method should be overridden by a subclass to support Java 5 types. + *

+ * This implementation returns 0. This method should be + * overridden by a subclass that provides access to the generic type + * parameter information for Java 5 and later. * - * @return 0, subclasses must override this and return the number of generic - * arguments + * @return The number of type parameters for this type. */ public int size() { return 0; Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ServiceUnavailableException.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ServiceUnavailableException.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ServiceUnavailableException.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/ServiceUnavailableException.java Mon Jul 6 19:50:26 2009 @@ -18,24 +18,25 @@ import org.osgi.framework.ServiceException; /** - * Thrown when an invocation is made on a service reference, and - * a backing service is not available. + * A Blueprint exception indicating that a service is unavailable. + * + * This exception is thrown when an invocation is made on a service reference + * and a backing service is not available. + * + * @version $Revision$ */ public class ServiceUnavailableException extends ServiceException { - private static final long serialVersionUID = 1L; - + private static final long serialVersionUID = 1L; /** * The filter string associated with the exception. */ - private final String filter; + private final String filter; /** * Creates a Service Unavailable Exception with the specified message. * - * @param message - * The associated message. - * @param filter - * The filter used for the service lookup. + * @param message The associated message. + * @param filter The filter used for the service lookup. */ public ServiceUnavailableException(String message, String filter) { super(message, UNREGISTERED); @@ -46,12 +47,9 @@ * Creates a Service Unavailable Exception with the specified message and * exception cause. * - * @param message - * The associated message. - * @param filter - * The filter used for the service lookup. - * @param cause - * The cause of this exception. + * @param message The associated message. + * @param filter The filter used for the service lookup. + * @param cause The cause of this exception. */ public ServiceUnavailableException(String message, String filter, Throwable cause) { Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/package.html URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/package.html?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/package.html (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/package.html Mon Jul 6 19:50:26 2009 @@ -1,6 +1,6 @@ - + -

Blueprint Service Container Package Version 1.0.

+

Blueprint Container Package Version 1.0.

Bundles wishing to use this package must list the package in the Import-Package header of the bundle's manifest. For example:

@@ -8,14 +8,14 @@ Import-Package: org.osgi.service.blueprint.container; version="[1.0,2.0)"

- This package defines the primary interface to a blueprint container, + This package defines the primary interface to a Blueprint Container, BlueprintContainer. An instance of this type is available - inside a blueprint context as an implicitly defined component with name - "blueprintContainer". + inside a Blueprint Container as an implicitly defined component with the name + "blueprintContainer".

- This package also declares the supporting exception types, listener, and constants for working with a blueprint - container. + This package also declares the supporting exception types, listener, and constants for working with a Blueprint + Container.

Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/packageinfo URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/packageinfo?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/packageinfo (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/container/packageinfo Mon Jul 6 19:50:26 2009 @@ -1 +1 @@ -version 1.0 +version 1.0 Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/BeanArgument.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/BeanArgument.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/BeanArgument.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/BeanArgument.java Mon Jul 6 19:50:26 2009 @@ -16,41 +16,49 @@ package org.osgi.service.blueprint.reflect; /** - * Metadata used in a Bean Manager to inject arguments in a method or - * constructor. This Metadata class describes the argument + * Metadata for a Bean Manager to describe the injection of arguments in a + * method or constructor, it is obtained from the + * {@link BeanMetadata#getArguments()}. This Metadata class describes the + * argument element of the bean element. + * + * @ThreadSafe + * @version $Revision$ */ public interface BeanArgument { /** * The Metadata for the value to inject into the argument. - * + * * This is the value attribute. - * + * * @return the Metadata for the value */ Metadata getValue(); /** - * The type to convert the value into when invoking the constructor or - * factory method. If no explicit type was specified on the - * definition then this method returns null. - * + * The type to match the argument and convert the value into when invoking + * the constructor or factory method. If no explicit type was specified on + * the definition then this method returns null. + * * This is the type attribute. - * - * @return the explicitly specified type to convert the value into, or null - * if no type was specified in the definition. + * + * @return the explicitly specified type to convert the value into, or + * null if no type was specified in the definition. */ String getValueType(); /** * The (zero-based) index into the parameter list of the method or - * constructor to be invoked for this argument. This is determined either - * by explicitly specifying the index attribute in the component - * declaration. If not explicitly set, this will return -1. - * + * constructor to be invoked for this argument. This is determined either by + * explicitly specifying the index attribute in the component + * declaration. If not explicitly set, this will return -1 and the initial + * ordering is defined by its position in the + * {@link BeanMetadata#getArguments()} list. + * * This is the index attribute. - * - * @return the zero-based parameter index, or -1 if the argument position was not set. + * + * @return the zero-based parameter index, or -1 if the argument position + * was not set. */ int getIndex(); } Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/BeanMetadata.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/BeanMetadata.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/BeanMetadata.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/BeanMetadata.java Mon Jul 6 19:50:26 2009 @@ -20,6 +20,8 @@ /** * Metadata for a Bean Manager. * + * @ThreadSafe + * @version $Revision$ */ public interface BeanMetadata extends Target, ComponentMetadata { @@ -71,13 +73,14 @@ * * Specified in all the child * argument elements. The return is a list of {@link BeanArgument} objects. - * - * @return The arguments Metadata for the factory method or constructor, can be empty if no arguments are specified + * + * @return List of Bean Arguments for the factory method or constructor, can + * be empty if no arguments are specified */ List getArguments(); /** - * The property injection Metadata for this component. + * The property injection {@link BeanProperty} Metadata for this bean. * * Specified in all the child property elements. * @@ -101,7 +104,8 @@ * The component instance on which to invoke the factory method (if * specified). * - * The component is defined in the factory-component. + * The to be used component instance is referred to by the + * factory-component. * * When a factory method and factory ref has been specified for this * component, this operation returns the Metadata specifying the manager on @@ -109,12 +113,13 @@ * factory component has been specified this operation will return * null. * - * A return value of null with a non-null factory method indicates that the - * factory method should be invoked as a static method on the given - * class itself. For a non-null return value, the Metadata returned - * will be a {@link Target} instance. + * A return value of null with a non-null factory method + * indicates that the factory method should be invoked as a static method on + * the given class itself. For a non-null return value, the + * Metadata returned will be a {@link Target} instance. * - * @return A {@link Target} or null if no factory component was specified. + * @return A {@link Target} or null if no factory component was + * specified. */ Target getFactoryComponent(); Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/BeanProperty.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/BeanProperty.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/BeanProperty.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/BeanProperty.java Mon Jul 6 19:50:26 2009 @@ -17,12 +17,16 @@ /** * Metadata describing a property to be injected. Properties are defined - * following Java Beans conventions. + * according to the Java Beans conventions. + * + * @ThreadSafe + * @version $Revision$ */ public interface BeanProperty { /** - * The name of the property to be injected, following Java Beans conventions. + * The name of the property to be injected, following Java Beans + * conventions. * * Defined in the name attribute. * Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/CollectionMetadata.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/CollectionMetadata.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/CollectionMetadata.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/CollectionMetadata.java Mon Jul 6 19:50:26 2009 @@ -19,8 +19,11 @@ /** * Metadata for a collection based value. Members of the collection are - * instances of Metadata. This Metadata can constrain the members to a specific - * type. + * instances of Metadata. This Collection Metadata can constrain the members of + * its collection to a specific type. + * + * @ThreadSafe + * @version $Revision$ */ public interface CollectionMetadata extends NonNullMetadata { @@ -47,7 +50,7 @@ String getValueType(); /** - * The of Metadata that describe the actual Collection or array. + * The Metadata that describe the member values of the Collection or array. * * @return A list of Metadata for the values of a collection or array. */ Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ComponentMetadata.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ComponentMetadata.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ComponentMetadata.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ComponentMetadata.java Mon Jul 6 19:50:26 2009 @@ -19,51 +19,53 @@ /** * Base class for all managers. - * + * * @see BeanMetadata * @see ServiceReferenceMetadata * @see ServiceMetadata * @see Target + * @ThreadSafe + * @version $Revision$ */ public interface ComponentMetadata extends NonNullMetadata { /** * The manager will be eagerly activate */ - static final int ACTIVATION_EAGER = 1; + static final int ACTIVATION_EAGER = 1; /** - * The manager will be lazily activated - */ - static final int ACTIVATION_LAZY = 2; + * The manager will be lazily activated + */ + static final int ACTIVATION_LAZY = 2; /** * The id of the manager. - * - * @return manager id. The manager id can be null if this - * is an anonymously defined and/or inlined manager. + * + * @return manager id. The manager id can be null if this is an + * anonymously defined and/or inlined manager. */ String getId(); /** - * Activation strategy for this manager. - * - * This is the activation attribute or the - * default-activation in the blueprint element - * if not set. If this is also not set, it is {@link #ACTIVATION_EAGER}. - * - * @return the activation method - * @see #ACTIVATION_EAGER - * @see #ACTIVATION_LAZY - */ + * Activation strategy for this manager. + * + * This is the activation attribute or the + * default-activation in the blueprint element if + * not set. If this is also not set, it is {@link #ACTIVATION_EAGER}. + * + * @return the activation method + * @see #ACTIVATION_EAGER + * @see #ACTIVATION_LAZY + */ int getActivation(); /** - * The id of any managers listed in a depends-on attribute for this - * manager. - * - * @return an immutable List of manager ids that are - * explicitly declared as a dependency, or an empty List if none. + * The id of any managers listed in a depends-on attribute for + * this manager. + * + * @return an immutable List of manager ids that are explicitly declared as + * a dependency, or an empty List if none. */ List getDependsOn(); } Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/IdRefMetadata.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/IdRefMetadata.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/IdRefMetadata.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/IdRefMetadata.java Mon Jul 6 19:50:26 2009 @@ -16,9 +16,12 @@ package org.osgi.service.blueprint.reflect; /** - * A value which represents the id of another manager in the Blueprint Container. - * The id itself will be injected, not the manager that the id refers to. + * A value which represents the verified id of another manager in the Blueprint + * Container. The id itself will be injected, not the manager that the id refers + * to. No implicit dependency is created. * + * @ThreadSafe + * @version $Revision$ */ public interface IdRefMetadata extends NonNullMetadata { /** Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/MapEntry.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/MapEntry.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/MapEntry.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/MapEntry.java Mon Jul 6 19:50:26 2009 @@ -17,17 +17,18 @@ package org.osgi.service.blueprint.reflect; /** - * Metadata for an entry. An entry is the member of a {@link MapMetadata} so that it can - * be treated as a {@link CollectionMetadata} with entries. + * Metadata for a map entry. A map entry is the member of a {@link MapMetadata} List, so + * that it can be treated as a {@link CollectionMetadata} with entries. * * Defined in the entry element. * + * @ThreadSafe + * @version $Revision$ */ public interface MapEntry { /** * Keys must be non-null. * - * * Defined in the key attribute or element. * * @return the Metadata for the key Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/MapMetadata.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/MapMetadata.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/MapMetadata.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/MapMetadata.java Mon Jul 6 19:50:26 2009 @@ -22,6 +22,8 @@ * * A Map is defined in the map element. * + * @ThreadSafe + * @version $Revision$ */ public interface MapMetadata extends NonNullMetadata { /** Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/Metadata.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/Metadata.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/Metadata.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/Metadata.java Mon Jul 6 19:50:26 2009 @@ -18,7 +18,9 @@ /** * Top level Metadata. * + * @ThreadSafe + * @version $Revision$ */ public interface Metadata { - + // marker interface } Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/NonNullMetadata.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/NonNullMetadata.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/NonNullMetadata.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/NonNullMetadata.java Mon Jul 6 19:50:26 2009 @@ -16,9 +16,13 @@ package org.osgi.service.blueprint.reflect; /** - * Base interfaces for Metadata that cannot result in a null - * value. The {@link NullMetadata} is the only element not implementing this. - * Mainly used for keys in Maps because they cannot be null. + * Base interfaces for Metadata that cannot result in a null value. + * The {@link NullMetadata} is the only element not implementing this. Mainly + * used for keys in Maps because they cannot be null. + * + * @ThreadSafe + * @version $Revision$ */ public interface NonNullMetadata extends Metadata { + // marker interface } Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/NullMetadata.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/NullMetadata.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/NullMetadata.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/NullMetadata.java Mon Jul 6 19:50:26 2009 @@ -17,12 +17,16 @@ /** * A value specified to be null via the <null/> element. + * + * @ThreadSafe + * @version $Revision$ */ public interface NullMetadata extends Metadata { /** * Singleton instance of the NULL Metadata. */ - static final NullMetadata NULL = new NullMetadata() { - }; + static final NullMetadata NULL = new NullMetadata() { + // empty body + }; } Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/PropsMetadata.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/PropsMetadata.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/PropsMetadata.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/PropsMetadata.java Mon Jul 6 19:50:26 2009 @@ -18,11 +18,13 @@ import java.util.List; /** - * A java.util.Properties based value. The properties are - * defined as string to string. + * A java.util.Properties based value. The properties are defined + * as string to string. * * Defined in the props element. * + * @ThreadSafe + * @version $Revision$ */ public interface PropsMetadata extends NonNullMetadata { Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/RefMetadata.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/RefMetadata.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/RefMetadata.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/RefMetadata.java Mon Jul 6 19:50:26 2009 @@ -17,6 +17,9 @@ /** * A value which refers by its id to another manager in the Blueprint Container. + * + * @ThreadSafe + * @version $Revision$ */ public interface RefMetadata extends Target, NonNullMetadata { /** Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ReferenceListMetadata.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ReferenceListMetadata.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ReferenceListMetadata.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ReferenceListMetadata.java Mon Jul 6 19:50:26 2009 @@ -16,26 +16,28 @@ package org.osgi.service.blueprint.reflect; /** - * A reference-list Metadata + * A reference-list Metadata. + * + * @ThreadSafe + * @version $Revision$ */ public interface ReferenceListMetadata extends ServiceReferenceMetadata { /** * The List member types must be the proxies to the service objects */ - public static final int USE_SERVICE_OBJECT = 1; + public static final int USE_SERVICE_OBJECT = 1; /** - * The List member types must be Service Reference objects - */ - public static final int USE_SERVICE_REFERENCE = 2; + * The List member types must be Service Reference objects + */ + public static final int USE_SERVICE_REFERENCE = 2; /** * Whether the collection will contain service objects, or service - * references - * Defined in the member-type attribute. - * - * @return one of USE_SERVICE_OBJECT and USE_SERVICE_REFERENCE + * references Defined in the member-type attribute. + * + * @return one of {@link #USE_SERVICE_OBJECT} and {@link #USE_SERVICE_REFERENCE} * @see #USE_SERVICE_OBJECT * @see #USE_SERVICE_REFERENCE */ Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ReferenceListener.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ReferenceListener.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ReferenceListener.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ReferenceListener.java Mon Jul 6 19:50:26 2009 @@ -16,15 +16,18 @@ package org.osgi.service.blueprint.reflect; /** - * Metadata for a reference listener interested in the reference bind and unbind events for a - * service reference. + * Metadata for a reference listener interested in the reference bind and unbind + * events for a service reference. + * + * @ThreadSafe + * @version $Revision$ */ public interface ReferenceListener { /** * The component instance that will receive bind and unbind events. The - * returned value must reference a {@link Target} either directly - * or indirectly. + * returned value must reference a {@link Target} either directly or + * indirectly. * * Defined in the ref attribute or via an inlined manager. * Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ReferenceMetadata.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ReferenceMetadata.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ReferenceMetadata.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ReferenceMetadata.java Mon Jul 6 19:50:26 2009 @@ -22,12 +22,14 @@ * * Defines the reference element. * + * @ThreadSafe + * @version $Revision$ */ public interface ReferenceMetadata extends ServiceReferenceMetadata, Target { /** - * Timeout for service invocations when a backing service is - * is unavailable. Defined in the timeout attribute. + * Timeout for service invocations when a backing service is is unavailable. + * Defined in the timeout attribute. * * @return service invocation timeout in milliseconds */ Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/RegistrationListener.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/RegistrationListener.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/RegistrationListener.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/RegistrationListener.java Mon Jul 6 19:50:26 2009 @@ -17,7 +17,11 @@ /** * Metadata for a registration listener interested in service registration and - * unregistration events. + * unregistration events. Available from the + * {@link ServiceMetadata#getRegistrationListeners()} method. + * + * @ThreadSafe + * @version $Revision$ */ public interface RegistrationListener { @@ -27,7 +31,8 @@ * directly or indirectly. The return type will be a {@link Target} * instance. * - * Defined in the registration-listener child element. + * Defined in the registration-listener child element of the + * service element. * * @return The registration listener target. */ Modified: geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ServiceMetadata.java URL: http://svn.apache.org/viewvc/geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ServiceMetadata.java?rev=791585&r1=791584&r2=791585&view=diff ============================================================================== --- geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ServiceMetadata.java (original) +++ geronimo/sandbox/blueprint/blueprint-api/src/main/java/org/osgi/service/blueprint/reflect/ServiceMetadata.java Mon Jul 6 19:50:26 2009 @@ -19,8 +19,11 @@ import java.util.List; /** - * Metadata representing a service to registered by the Blueprint Container. + * Metadata representing a service to registered by the Blueprint Container when + * enabled. * + * @ThreadSafe + * @version $Revision$ */ public interface ServiceMetadata extends ComponentMetadata { @@ -72,8 +75,8 @@ * Defined in the interface attribute or * interfaces element. * - * @return an immutable set of (String) interface names, or an - * empty set if using auto-export or not set. + * @return an immutable set of (String) interface names, or + * an empty set if using auto-export or not set. */ List getInterfaces(); @@ -94,7 +97,8 @@ * * Defined in the service-properties element. * - * @return List containing {@link MapEntry} objects, can be empty. + * @return List containing {@link MapEntry} objects, can be + * empty. */ List getServiceProperties(); @@ -109,8 +113,8 @@ int getRanking(); /** - * The registration listeners to be notified when the - * service is registered and unregistered with the framework. + * The registration listeners to be notified when the service is registered + * and unregistered with the framework. * * Defined in the registration-listener elements. *