You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@felix.apache.org by pd...@apache.org on 2016/01/30 00:57:18 UTC
svn commit: r1727666 [2/3] - in
/felix/sandbox/pderop/dependencymanager-lambda:
org.apache.felix.dependencymanager.lambda.samples/src/org/apache/felix/dm/lambda/samples/compositefactory/
org.apache.felix.dependencymanager.lambda.samples/src/org/apache/...
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/ServiceCallbacksBuilder.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/ServiceCallbacksBuilder.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/ServiceCallbacksBuilder.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/ServiceCallbacksBuilder.java Fri Jan 29 23:57:17 2016
@@ -31,7 +31,7 @@ import org.apache.felix.dm.lambda.callba
* Builds a service dependency callback (required by default).
*
* A Service may be injected in a bind-method of a component or an object instance using this builder.
- * The builder supports the following kind of method signatures for bind methods: <p>
+ * The builder supports the following kind of method signatures for bind methods:
*
* <pre> {@code
* method(S service)
@@ -49,7 +49,7 @@ import org.apache.felix.dm.lambda.callba
* swapMethod(Component component, ServiceReference<S> oldRef, S old, ServiceReference<S> newRef, S newService)
* }</pre>
*
- * The following families of callbacks are supported:<p>
+ * The following families of callbacks are supported:
*
* <ul>
* <li> "cb(String ... callback)": stands for "callback" and specifies a list of callbacks from the component instances. When using one arg, it stands for the "add" callback.
@@ -106,81 +106,693 @@ import org.apache.felix.dm.lambda.callba
* @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
*/
public interface ServiceCallbacksBuilder<S, B extends ServiceCallbacksBuilder<S, B>> {
+ /**
+ * Sets some <code>callback</code> methods to invoke on the component instance(s). When a service matches the service
+ * filter, then the service is injected using the specified callback methods. When you specify one callback, it stands for the "add" callback.
+ * When you specify two callbacks, the first one corresponds to the "add" callback, and the second one to the "remove" callback. When you specify three
+ * callbacks, the first one stands for the "add" callback, the second one for the "change" callback, and the third one for the "remove" callback.
+ * When you specify four callbacks, it stands for "add"/"change"/"remove"/swap callbacks.
+ *
+ * The following method signature are supported:
+ * {@code
+ * method(S service)
+ * method(S service, Map<String, Object> serviceProperties)
+ * method(S service, Dictionary<String, Object> serviceProperties)
+ * method(ServiceReference<S> serviceRef, S service),
+ * method(ServiceReference<S> serviceRef)
+ * method(Component serviceComponent)
+ * method(Component serviceComponent, ServiceReference<S> serviceRef)
+ * method(Component serviceComponent, S service)
+ * method(Component serviceComponent, ServiceReference<S> serviceRef, S service)
+ * swapMethod(S oldService, S newService)
+ * swapMethod(ServiceReference<S> oldRef, S old, ServiceReference<S> newRef, S newService)
+ * swapMethod(Component component, S oldService, S newService)
+ * swapMethod(Component component, ServiceReference<S> oldRef, S old, ServiceReference<S> newRef, S newService)
+ * }
+ * @param callbacks a list of callbacks (1 param: "add", 2 params: "add"/remove", 3 params: "add"/"change"/"remove", 4 params: "add"/"change"/"remove"/"swap" callbacks).
+ * @return this builder
+ */
B cb(String ... callbacks);
+
+ /**
+ * Sets some <code>callback instance</code> methods to invoke on a given Object instance. When a service matches the service
+ * filter, then the service is injected using the specified callback methods. When you specify one callback, it stands for the "add" callback.
+ * When you specify two callbacks, the first one corresponds to the "add" callback, and the second one to the "remove" callback. When you specify three
+ * callbacks, the first one stands for the "add" callback, the second one for the "change" callback, and the third one for the "remove" callback.
+ *
+ * @param callbackInstance the object on which the callback is invoked.
+ * @param callbacks a list of callbacks (1 param : "add", 2 params : "add"/remove", 3 params : "add"/"change"/"remove", 4 params : "add"/"change"/"remove"/"swap" callbacks).
+ * @see #cb(String...)
+ * @return this builder
+ */
B cbi(Object callbackInstance, String ... callbacks);
+ /**
+ * Sets a <code>callback</code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to a Component implementation class method, and take as argument the service.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
<T> B cb(CbTypeService<T, S> add);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added or removed.
+ * The method references must point to a Component implementation class method, and take as argument the service.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
<T> B cb(CbTypeService<T, S> add, CbTypeService<T, S> remove);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added, changed, or removed.
+ * The method references must point to a Component implementation class method, and take as argument the service.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
<T> B cb(CbTypeService<T, S> add, CbTypeService<T, S> change, CbTypeService<T, S> remove);
+
+ /**
+ * Sets a <code>callback</code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to a Component implementation class method, and take as arguments the service, and a properties map.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
+ <T> B cb(CbTypeServiceMap<T, S> add);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added or removed.
+ * The method references must point to a Component implementation class method, and take as arguments the service, and a properties map.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
+ <T> B cb(CbTypeServiceMap<T, S> add, CbTypeServiceMap<T, S> remove);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added, changed, or removed.
+ * The method references must point to a Component implementation class method, and take as arguments the service, and a properties map.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
+ <T> B cb(CbTypeServiceMap<T, S> add, CbTypeServiceMap<T, S> change, CbTypeServiceMap<T, S> remove);
+
+ /**
+ * Sets a <code>callback</code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to a Component implementation class method, and take as arguments the service, and a properties dictionary.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
+ <T> B cb(CbTypeServiceDict<T, S> add);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added or removed.
+ * The method references must point to a Component implementation class method, and take as arguments the service, and a properties dictionary.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
+ <T> B cb(CbTypeServiceDict<T, S> add, CbTypeServiceDict<T, S> remove);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added, changed, or removed.
+ * The method references must point to a Component implementation class method, and take as arguments the service, and a properties dictionary.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
+ <T> B cb(CbTypeServiceDict<T, S> add, CbTypeServiceDict<T, S> change, CbTypeServiceDict<T, S> remove);
+
+ /**
+ * Sets a <code>callback</code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to a Component implementation class method, and take as arguments the service reference, and the service.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
+ <T> B cb(CbTypeRefService<T, S> add);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added or removed.
+ * The method references must point to a Component implementation class method, and take as arguments the service reference, and the service.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
+ <T> B cb(CbTypeRefService<T, S> add, CbTypeRefService<T, S> remove);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added, changed, or removed.
+ * The method references must point to a Component implementation class method, and take as arguments the service reference, and the service.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
+ <T> B cb(CbTypeRefService<T, S> add, CbTypeRefService<T, S> change, CbTypeRefService<T, S> remove);
+
+ /**
+ * Sets a <code>callback</code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to a Component implementation class method, and take as argument the service reference.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
+ <T> B cb(CbTypeRef<T, S> add);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added or removed.
+ * The method references must point to a Component implementation class method, and take as argument the service reference.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
+ <T> B cb(CbTypeRef<T, S> add, CbTypeRef<T, S> remove);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added, changed, or removed.
+ * The method references must point to a Component implementation class method, and take as argument the service reference.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
+ <T> B cb(CbTypeRef<T, S> add, CbTypeRef<T, S> change, CbTypeRef<T, S> remove);
+
+ /**
+ * Sets a <code>callback</code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to a Component implementation class method, and take as argument the Component.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
+ <T> B cb(CbTypeComponent<T> add);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added or removed.
+ * The method references must point to a Component implementation class method, and take as argument the Component.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
+ <T> B cb(CbTypeComponent<T> add, CbTypeComponent<T> remove);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added, changed, or removed.
+ * The method references must point to a Component implementation class method, and take as argument the Component.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
+ <T> B cb(CbTypeComponent<T> add, CbTypeComponent<T> change, CbTypeComponent<T> remove);
+
+ /**
+ * Sets a <code>callback</code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to a Component implementation class method, and take as arguments the Component, and the service reference.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
+ <T> B cb(CbTypeComponentRef<T, S> add);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added or removed.
+ * The method references must point to a Component implementation class method, and take as arguments the Component, and the service reference.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
+ <T> B cb(CbTypeComponentRef<T, S> add, CbTypeComponentRef<T, S> remove);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added, changed, or removed.
+ * The method references must point to a Component implementation class method, and take as arguments the Component, and the service reference.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
+ <T> B cb(CbTypeComponentRef<T, S> add, CbTypeComponentRef<T, S> change, CbTypeComponentRef<T, S> remove);
+
+ /**
+ * Sets a <code>callback</code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to a Component implementation class method, and take as arguments the Component, and the service.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
+ <T> B cb(CbTypeComponentService<T, S> add);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added or removed.
+ * The method references must point to a Component implementation class method, and take as arguments the Component, and the service.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
+ <T> B cb(CbTypeComponentService<T, S> add, CbTypeComponentService<T, S> remove);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added, changed, or removed.
+ * The method references must point to a Component implementation class method, and take as arguments the Component, and the service.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
+ <T> B cb(CbTypeComponentService<T, S> add, CbTypeComponentService<T, S> change, CbTypeComponentService<T, S> remove);
+
+ /**
+ * Sets a <code>callback</code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to a Component implementation class method, and take as arguments the Component, the service Reference and the service.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
+ <T> B cb(CbTypeComponentRefService<T, S> add);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added or removed.
+ * The method references must point to a Component implementation class method, and take as arguments the Component, the service Reference and the service.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
+ <T> B cb(CbTypeComponentRefService<T, S> add, CbTypeComponentRefService<T, S> remove);
+
+ /**
+ * Sets some <code>callback</code> java8 method references which is invoked when a service is added, changed, or removed.
+ * The method references must point to a Component implementation class method, and take as arguments the Component, the service Reference and the service.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
+ <T> B cb(CbTypeComponentRefService<T, S> add, CbTypeComponentRefService<T, S> change, CbTypeComponentRefService<T, S> remove);
+
+ /**
+ * Sets a swap <code>callback</code> java8 method reference which is invoked when a service is swapped.
+ * The method references must point to a Component implementation class method, and take as arguments the old service and the new replacing service.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param swap the method reference invoked when the service is swapped.
+ * @return this builder
+ */
+ <T> B sw(CbTypeServiceService<T, S> swap);
+
+ /**
+ * Sets a swap <code>callback</code> java8 method reference which is invoked when a service is swapped.
+ * The method references must point to a Component implementation class method, and take as arguments the component, the old service and the new replacing service.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param swap the method reference invoked when the service is swapped.
+ * @return this builder
+ */
+ <T> B sw(CbTypeComponentServiceService<T, S> swap);
+
+ /**
+ * Sets a swap <code>callback</code> java8 method reference which is invoked when a service is swapped.
+ * The method references must point to a Component implementation class method, and take as arguments the old service reference, the old service, the new service reference, and
+ * the new service.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param swap the method reference invoked when the service is swapped.
+ * @return this builder
+ */
+ <T> B sw(CbTypeRefServiceRefService<T, S> swap);
+
+ /**
+ * Sets a swap <code>callback</code> java8 method reference which is invoked when a service is swapped.
+ * The method references must point to a Component implementation class method, and take as arguments the component, the old service reference, the old service, the new service reference, and
+ * the new service.
+ *
+ * @param <T> the type of the component instance class on which the callback is invoked.
+ * @param swap the method reference invoked when the service is swapped.
+ * @return this builder
+ */
+ <T> B sw(CbTypeComponentRefServiceRefService<T, S> swap);
+
+ /**
+ * Sets a <code>callback instance </code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to method from an Object instance, and take as argument a service.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
B cbi(CbService<S> add);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/removed.
+ * The method references must point to method from an Object instance, and take as argument a service.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbService<S> add, CbService<S> remove);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/changed/removed.
+ * The method references must point to method from an Object instance, and take as argument a service.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbService<S> add, CbService<S> change, CbService<S> remove);
- <T> B cb(CbTypeServiceMap<T, S> add);
- <T> B cb(CbTypeServiceMap<T, S> add, CbTypeServiceMap<T, S> remove);
- <T> B cb(CbTypeServiceMap<T, S> add, CbTypeServiceMap<T, S> change, CbTypeServiceMap<T, S> remove);
+ /**
+ * Sets a <code>callback instance </code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to method from an Object instance, and take as arguments a service and a properties Map.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
B cbi(CbServiceMap<S> add);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/removed.
+ * The method references must point to method from an Object instance, and take as arguments a service and a properties Map.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbServiceMap<S> add, CbServiceMap<S> remove);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/changed/removed.
+ * The method references must point to method from an Object instance, and take as arguments a service and a properties Map.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbServiceMap<S> add, CbServiceMap<S> change, CbServiceMap<S> remove);
- <T> B cb(CbTypeServiceDict<T, S> add);
- <T> B cb(CbTypeServiceDict<T, S> add, CbTypeServiceDict<T, S> remove);
- <T> B cb(CbTypeServiceDict<T, S> add, CbTypeServiceDict<T, S> change, CbTypeServiceDict<T, S> remove);
+ /**
+ * Sets a <code>callback instance </code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to method from an Object instance, and take as arguments a service and a properties Dictionary.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
B cbi(CbServiceDict<S> add);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/removed.
+ * The method references must point to method from an Object instance, and take as arguments a service and a properties Dictionary.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbServiceDict<S> add, CbServiceDict<S> remove);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/changed/removed.
+ * The method references must point to method from an Object instance, and take as arguments a service and a properties Dictionary.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbServiceDict<S> add, CbServiceDict<S> change, CbServiceDict<S> remove);
- <T> B cb(CbTypeRefService<T, S> add);
- <T> B cb(CbTypeRefService<T, S> add, CbTypeRefService<T, S> remove);
- <T> B cb(CbTypeRefService<T, S> add, CbTypeRefService<T, S> change, CbTypeRefService<T, S> remove);
+ /**
+ * Sets a <code>callback instance </code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to method from an Object instance, and take as arguments a service reference and a service.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
B cbi(CbRefService<S> add);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/removed.
+ * The method references must point to method from an Object instance, and take as arguments a service reference and a service.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbRefService<S> add, CbRefService<S> remove);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/changed/removed.
+ * The method references must point to method from an Object instance, and take as arguments a service reference and a service.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbRefService<S> add, CbRefService<S> change, CbRefService<S> remove);
- <T> B cb(CbTypeRef<T, S> add);
- <T> B cb(CbTypeRef<T, S> add, CbTypeRef<T, S> remove);
- <T> B cb(CbTypeRef<T, S> add, CbTypeRef<T, S> change, CbTypeRef<T, S> remove);
+ /**
+ * Sets a <code>callback instance </code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to method from an Object instance, and take as argument a service reference.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
B cbi(CbRef<S> add);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/removed.
+ * The method references must point to method from an Object instance, and take as argument a service reference.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbRef<S> add, CbRef<S> remove);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/changed/removed.
+ * The method references must point to method from an Object instance, and take as argument a service reference.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbRef<S> add, CbRef<S> change, CbRef<S> remove);
- <T> B cb(CbTypeComponent<T> add);
- <T> B cb(CbTypeComponent<T> add, CbTypeComponent<T> remove);
- <T> B cb(CbTypeComponent<T> add, CbTypeComponent<T> change, CbTypeComponent<T> remove);
+ /**
+ * Sets a <code>callback instance </code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to method from an Object instance, and take as argument a Component.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
B cbi(CbComponent add);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/removed.
+ * The method references must point to method from an Object instance, and take as argument a Component.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbComponent add, CbComponent remove);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/changed/removed.
+ * The method references must point to method from an Object instance, and take as argument a Component.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbComponent add, CbComponent change, CbComponent remove);
- <T> B cb(CbTypeComponentRef<T, S> add);
- <T> B cb(CbTypeComponentRef<T, S> add, CbTypeComponentRef<T, S> remove);
- <T> B cb(CbTypeComponentRef<T, S> add, CbTypeComponentRef<T, S> change, CbTypeComponentRef<T, S> remove);
+ /**
+ * Sets a <code>callback instance </code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to method from an Object instance, and take as arguments a Component and a service reference.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
B cbi(CbComponentRef<S> add);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/removed.
+ * The method references must point to method from an Object instance, and take as arguments a Component and a service reference.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbComponentRef<S> add, CbComponentRef<S> remove);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/changed/removed.
+ * The method references must point to method from an Object instance, and take as arguments a Component and a service reference.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbComponentRef<S> add, CbComponentRef<S> change, CbComponentRef<S> remove);
- <T> B cb(CbTypeComponentService<T, S> add);
- <T> B cb(CbTypeComponentService<T, S> add, CbTypeComponentService<T, S> remove);
- <T> B cb(CbTypeComponentService<T, S> add, CbTypeComponentService<T, S> change, CbTypeComponentService<T, S> remove);
+ /**
+ * Sets a <code>callback instance </code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to method from an Object instance, and take as arguments a Component and a service.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
B cbi(CbComponentService<S> add);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/removed.
+ * The method references must point to method from an Object instance, and take as arguments a Component and a service.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbComponentService<S> add, CbComponentService<S> remove);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/changed/removed.
+ * The method references must point to method from an Object instance, and take as arguments a Component and a service.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbComponentService<S> add, CbComponentService<S> change, CbComponentService<S> remove);
- <T> B cb(CbTypeComponentRefService<T, S> add);
- <T> B cb(CbTypeComponentRefService<T, S> add, CbTypeComponentRefService<T, S> remove);
- <T> B cb(CbTypeComponentRefService<T, S> add, CbTypeComponentRefService<T, S> change, CbTypeComponentRefService<T, S> remove);
+ /**
+ * Sets a <code>callback instance </code> java8 method reference which is invoked when a service is added.
+ * The method reference must point to method from an Object instance, and take as arguments a Component, a service reference, and a service.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @return this builder
+ */
B cbi(CbComponentRefService<S> add);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/removed.
+ * The method references must point to method from an Object instance, and take as arguments a Component, a service reference, and a service.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbComponentRefService<S> add, CbComponentRefService<S> remove);
+
+ /**
+ * Sets some <code>callback instance </code> java8 method references which are invoked when a service is added/changed/removed.
+ * The method references must point to method from an Object instance, and take as arguments a Component, a service reference, and a service.
+ *
+ * @param add the method reference invoked when a service is added.
+ * @param change the method reference invoked when a service is changed.
+ * @param remove the method reference invoked when a service is removed.
+ * @return this builder
+ */
B cbi(CbComponentRefService<S> add, CbComponentRefService<S> change, CbComponentRefService<S> remove);
- <T> B sw(CbTypeServiceService<T, S> swap);
+ /**
+ * Sets a swap <code>callback instance</code> java8 method reference which is invoked when a service is swapped.
+ * The method references must point to a method from an Object instance, and take as arguments the old service, and the new service.
+ * the new service.
+ *
+ * @param swap the method reference invoked when the service is swapped.
+ * @return this builder
+ */
B swi(CbServiceService<S> swap);
-
- <T> B sw(CbTypeComponentServiceService<T, S> swap);
+
+ /**
+ * Sets a swap <code>callback instance</code> java8 method reference which is invoked when a service is swapped.
+ * The method references must point to a method from an Object instance, and take as arguments the component, the old service, and the new service.
+ * the new service.
+ *
+ * @param swap the method reference invoked when the service is swapped.
+ * @return this builder
+ */
B swi(CbComponentServiceService<S> swap);
-
- <T> B sw(CbTypeRefServiceRefService<T, S> swap);
+
+ /**
+ * Sets a swap <code>callback instance</code> java8 method reference which is invoked when a service is swapped.
+ * The method references must point to a method from an Object instance, and take as arguments the old service reference, the old service, the
+ * new service reference, and the new service.
+ *
+ * @param swap the method reference invoked when the service is swapped.
+ * @return this builder
+ */
B swi(CbRefServiceRefService<S> swap);
-
- <T> B sw(CbTypeComponentRefServiceRefService<T, S> swap);
+
+ /**
+ * Sets a swap <code>callback instance</code> java8 method reference which is invoked when a service is swapped.
+ * The method references must point to a method from an Object instance, and take as arguments the component, old service reference, the old service, the
+ * new service reference, and the new service.
+ *
+ * @param swap the method reference invoked when the service is swapped.
+ * @return this builder
+ */
B swi(CbComponentRefServiceRefService<S> swap);
}
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbBundle.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbBundle.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbBundle.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbBundle.java Fri Jan 29 23:57:17 2016
@@ -4,8 +4,17 @@ import java.util.Objects;
import org.osgi.framework.Bundle;
+/**
+ * Represents a callback(Bundle) on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbBundle extends SerializableLambda {
+ /**
+ * Handles the given argument.
+ * @param bundle the callback parameter
+ */
void accept(Bundle bundle);
default CbBundle andThen(CbBundle after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponent.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponent.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponent.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponent.java Fri Jan 29 23:57:17 2016
@@ -4,8 +4,17 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
+/**
+ * Represents a callback(Component) on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbComponent {
+ /**
+ * Handles the given argument.
+ * @param component the callback parameter
+ */
void accept(Component component);
default CbComponent andThen(CbComponent after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentBundle.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentBundle.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentBundle.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentBundle.java Fri Jan 29 23:57:17 2016
@@ -5,8 +5,18 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
import org.osgi.framework.Bundle;
+/**
+ * Represents a callback(Component, Bundle) on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbComponentBundle {
+ /**
+ * Handles the given arguments.
+ * @param component the callback parameter
+ * @param bundle the callback parameter
+ */
void accept(Component component, Bundle bundle);
default CbComponentBundle andThen(CbComponentBundle after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentDictionary.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentDictionary.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentDictionary.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentDictionary.java Fri Jan 29 23:57:17 2016
@@ -5,8 +5,18 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
+/**
+ * Represents a callback(Component, Dictionary) on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbComponentDictionary {
+ /**
+ * Handles the given arguments.
+ * @param component a Component
+ * @param properties some service properties
+ */
void accept(Component component, Dictionary<String, Object> properties);
default CbComponentDictionary andThen(CbComponentDictionary after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentRef.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentRef.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentRef.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentRef.java Fri Jan 29 23:57:17 2016
@@ -5,8 +5,18 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
import org.osgi.framework.ServiceReference;
+/**
+ * Represents a callback(Component, ServiceReference) on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbComponentRef<S> {
+ /**
+ * Handles the given arguments.
+ * @param c a Component
+ * @param ref the service reference
+ */
void accept(Component c, ServiceReference<S> ref);
default CbComponentRef<S> andThen(CbComponentRef<S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentRefService.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentRefService.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentRefService.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentRefService.java Fri Jan 29 23:57:17 2016
@@ -5,8 +5,19 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
import org.osgi.framework.ServiceReference;
+/**
+ * Represents a callback(Component, ServiceReference, Service) on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbComponentRefService<S> {
+ /**
+ * Handles the given arguments.
+ * @param c a Component
+ * @param ref the service reference
+ * @param service the service
+ */
void accept(Component c, ServiceReference<S> ref, S service);
default CbComponentRefService<S> andThen(CbComponentRefService<S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentRefServiceRefService.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentRefServiceRefService.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentRefServiceRefService.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentRefServiceRefService.java Fri Jan 29 23:57:17 2016
@@ -5,8 +5,21 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
import org.osgi.framework.ServiceReference;
+/**
+ * Represents a callback(Component, ServiceReference, Service, ServiceReference, Service) on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbComponentRefServiceRefService<S> {
+ /**
+ * Handles the given arguments
+ * @param c a Component
+ * @param oldRef an old swapped service reference
+ * @param old an old swapped service
+ * @param replaceRef the new service reference
+ * @param replace the new service
+ */
void accept(Component c, ServiceReference<S> oldRef, S old, ServiceReference<S> replaceRef, S replace);
default CbComponentRefServiceRefService<S> andThen(CbComponentRefServiceRefService<S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentService.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentService.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentService.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentService.java Fri Jan 29 23:57:17 2016
@@ -4,8 +4,18 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
+/**
+ * Represents a callback(Component, Service) on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbComponentService<S> {
+ /**
+ * Handles the given arguments
+ * @param c the component
+ * @param service the service
+ */
void accept(Component c, S service);
default CbComponentService<S> andThen(CbComponentService<S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentServiceService.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentServiceService.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentServiceService.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbComponentServiceService.java Fri Jan 29 23:57:17 2016
@@ -4,8 +4,19 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
+/**
+ * Represents a callback(Component, Service, Service) on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbComponentServiceService<S> extends SerializableLambda {
+ /**
+ * Handles the given arguments.
+ * @param c the component
+ * @param old the old service
+ * @param replace the new service
+ */
void accept(Component c, S old, S replace);
default CbComponentServiceService<S> andThen(CbComponentServiceService<S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbConsumer.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbConsumer.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbConsumer.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbConsumer.java Fri Jan 29 23:57:17 2016
@@ -2,8 +2,18 @@ package org.apache.felix.dm.lambda.callb
import java.util.Objects;
+/**
+ * Represents a callback(T param) on an Object instance.
+ *
+ * @param T the type of the callback parameter.
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbConsumer<T> extends SerializableLambda {
+ /**
+ * Handles the given argument
+ * @param t the argument
+ */
void accept(T t);
default CbConsumer<T> andThen(CbConsumer<? super T> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbDictionary.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbDictionary.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbDictionary.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbDictionary.java Fri Jan 29 23:57:17 2016
@@ -3,8 +3,17 @@ package org.apache.felix.dm.lambda.callb
import java.util.Dictionary;
import java.util.Objects;
+/**
+ * Represents a callback(Dictionary) on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbDictionary {
+ /**
+ * Handles the given argument.
+ * @param conf the properties
+ */
void accept(Dictionary<String, Object> conf);
default CbDictionary andThen(CbDictionary after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbFuture.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbFuture.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbFuture.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbFuture.java Fri Jan 29 23:57:17 2016
@@ -2,8 +2,17 @@ package org.apache.felix.dm.lambda.callb
import java.util.Objects;
+/**
+ * Represents a callback that accepts a the result of a CompletableFuture. The callback is invoked on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbFuture<F> {
+ /**
+ * Handles the result of a CompletableFuture operation.
+ * @param future the result of a CompletableFuture operation.
+ */
void accept(F future);
default CbFuture<F> andThen(CbFuture<? super F> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbRef.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbRef.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbRef.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbRef.java Fri Jan 29 23:57:17 2016
@@ -4,8 +4,17 @@ import java.util.Objects;
import org.osgi.framework.ServiceReference;
+/**
+ * Represents a callback(ServiceReference) on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbRef<S> {
+ /**
+ * Handles the given argument
+ * @param ref a service reference
+ */
void accept(ServiceReference<S> ref);
default CbRef<S> andThen(CbRef<S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbRefService.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbRefService.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbRefService.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbRefService.java Fri Jan 29 23:57:17 2016
@@ -4,8 +4,18 @@ import java.util.Objects;
import org.osgi.framework.ServiceReference;
+/**
+ * Represents a callback(ServiceReference, Service) on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbRefService<S> {
+ /**
+ * Handles the given arguments.
+ * @param ref a Service Reference
+ * @param service a Service
+ */
void accept(ServiceReference<S> ref, S service);
default CbRefService<S> andThen(CbRefService<S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbRefServiceRefService.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbRefServiceRefService.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbRefServiceRefService.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbRefServiceRefService.java Fri Jan 29 23:57:17 2016
@@ -4,8 +4,20 @@ import java.util.Objects;
import org.osgi.framework.ServiceReference;
+/**
+ * Represents a callback(ServiceReference, Service, ServiceReference, Service) on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbRefServiceRefService<S> {
+ /**
+ * Handles the given arguments
+ * @param oldRef a service reference
+ * @param old a service
+ * @param replaceRef a service reference
+ * @param replace a service
+ */
void accept(ServiceReference<S> oldRef, S old, ServiceReference<S> replaceRef, S replace);
default CbRefServiceRefService<S> andThen(CbRefServiceRefService<S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbService.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbService.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbService.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbService.java Fri Jan 29 23:57:17 2016
@@ -2,8 +2,17 @@ package org.apache.felix.dm.lambda.callb
import java.util.Objects;
+/**
+ * Represents a callback(Service) on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbService<S> {
+ /**
+ * Handles the given argument.
+ * @param service a Service
+ */
void accept(S service);
default CbService<S> andThen(CbService<S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbServiceDict.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbServiceDict.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbServiceDict.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbServiceDict.java Fri Jan 29 23:57:17 2016
@@ -3,8 +3,18 @@ package org.apache.felix.dm.lambda.callb
import java.util.Dictionary;
import java.util.Objects;
+/**
+ * Represents a callback(Service, Dictionary) on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbServiceDict<S> {
+ /**
+ * Handles the given arguments.
+ * @param service a Service
+ * @param properties a Dictionary
+ */
void accept(S service, Dictionary<String, Object> properties);
default CbServiceDict<S> andThen(CbServiceDict<S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbServiceMap.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbServiceMap.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbServiceMap.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbServiceMap.java Fri Jan 29 23:57:17 2016
@@ -3,8 +3,18 @@ package org.apache.felix.dm.lambda.callb
import java.util.Map;
import java.util.Objects;
+/**
+ * Represents a callback(Service, Map) on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbServiceMap<S> {
+ /**
+ * Handles the given arguments.
+ * @param service a Service
+ * @param properties a Map
+ */
void accept(S service, Map<String, Object> properties);
default CbServiceMap<S> andThen(CbServiceMap<S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbServiceService.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbServiceService.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbServiceService.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbServiceService.java Fri Jan 29 23:57:17 2016
@@ -2,8 +2,18 @@ package org.apache.felix.dm.lambda.callb
import java.util.Objects;
+/**
+ * Represents a callback(Service, Service) on an Object instance.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbServiceService<S> extends SerializableLambda {
+ /**
+ * Handles the given argument
+ * @param old a Service
+ * @param replace a Service
+ */
void accept(S old, S replace);
default CbServiceService<S> andThen(CbServiceService<S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeBundle.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeBundle.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeBundle.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeBundle.java Fri Jan 29 23:57:17 2016
@@ -4,15 +4,26 @@ import java.util.Objects;
import org.osgi.framework.Bundle;
+/**
+ * Represents a callback(Bundle) that is invoked on a Component implementation class.
+ * The type of the class on which the callback is invoked on is represented by the T generic parameter.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbTypeBundle<T> extends SerializableLambda {
- void accept(T type, Bundle bundle);
+ /**
+ * Handles the given arguments.
+ * @param instance the Component implementation instance on which the callback is invoked on.
+ * @param bundle the callback parameter
+ */
+ void accept(T instance, Bundle bundle);
default CbTypeBundle<T> andThen(CbTypeBundle<? super T> after) {
Objects.requireNonNull(after);
- return (T type, Bundle bundle) -> {
- accept(type, bundle);
- after.accept(type, bundle);
+ return (T instance, Bundle bundle) -> {
+ accept(instance, bundle);
+ after.accept(instance, bundle);
};
}
}
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponent.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponent.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponent.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponent.java Fri Jan 29 23:57:17 2016
@@ -4,9 +4,20 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
+/**
+ * Represents a callback(Component) that is invoked on a Component implementation class.
+ * The type of the class on which the callback is invoked on is represented by the T generic parameter.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbTypeComponent<T> extends SerializableLambda {
- void accept(T instance, Component c);
+ /**
+ * Handles the given arguments
+ * @param instance the Component implementation instance on which the callback is invoked on.
+ * @param component the callback parameter
+ */
+ void accept(T instance, Component component);
default CbTypeComponent<T> andThen(CbTypeComponent<T> after) {
Objects.requireNonNull(after);
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentBundle.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentBundle.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentBundle.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentBundle.java Fri Jan 29 23:57:17 2016
@@ -5,15 +5,27 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
import org.osgi.framework.Bundle;
+/**
+ * Represents a callback(Component, Bundle) that is invoked on a Component implementation class.
+ * The type of the class on which the callback is invoked on is represented by the T generic parameter.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbTypeComponentBundle<T> extends SerializableLambda {
- void accept(T type, Component component, Bundle bundle);
+ /**
+ * Handles the given arguments.
+ * @param instance the Component implementation instance on which the callback is invoked on.
+ * @param component the first callback parameter
+ * @param bundle the second callback parameter
+ */
+ void accept(T instance, Component component, Bundle bundle);
default CbTypeComponentBundle<T> andThen(CbTypeComponentBundle<? super T> after) {
Objects.requireNonNull(after);
- return (T type, Component component, Bundle bundle) -> {
- accept(type, component, bundle);
- after.accept(type, component, bundle);
+ return (T instance, Component component, Bundle bundle) -> {
+ accept(instance, component, bundle);
+ after.accept(instance, component, bundle);
};
}
}
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentDictionary.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentDictionary.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentDictionary.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentDictionary.java Fri Jan 29 23:57:17 2016
@@ -5,8 +5,20 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
+/**
+ * Represents a callback(Component, Dictionary) that is invoked on a Component implementation class.
+ * The type of the class on which the callback is invoked on is represented by the T generic parameter.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbTypeComponentDictionary<T> extends SerializableLambda {
+ /**
+ * Handles the given arguments.
+ * @param instance the Component implementation instance on which the callback is invoked on.
+ * @param component the first callback parameter
+ * @param conf the second callback parameter
+ */
void accept(T instance, Component component, Dictionary<String, Object> conf);
default CbTypeComponentDictionary<T> andThen(CbTypeComponentDictionary<? super T> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentRef.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentRef.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentRef.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentRef.java Fri Jan 29 23:57:17 2016
@@ -5,8 +5,20 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
import org.osgi.framework.ServiceReference;
+/**
+ * Represents a callback(Component, ServiceReference) that is invoked on a Component implementation class.
+ * The type of the class on which the callback is invoked on is represented by the T generic parameter.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbTypeComponentRef<T, S> extends SerializableLambda {
+ /**
+ * Handles the given arguments.
+ * @param instance the Component implementation instance on which the callback is invoked on.
+ * @param c the first callback parameter
+ * @param ref the second callback parameter
+ */
void accept(T instance, Component c, ServiceReference<S> ref);
default CbTypeComponentRef<T, S> andThen(CbTypeComponentRef<T, S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentRefService.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentRefService.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentRefService.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentRefService.java Fri Jan 29 23:57:17 2016
@@ -5,8 +5,21 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
import org.osgi.framework.ServiceReference;
+/**
+ * Represents a callback(Component, ServiceReference, Service) that is invoked on a Component implementation class.
+ * The type of the class on which the callback is invoked on is represented by the T generic parameter.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbTypeComponentRefService<T, S> extends SerializableLambda {
+ /**
+ * Handles the given arguments.
+ * @param instance the Component implementation instance on which the callback is invoked on.
+ * @param c the first callback parameter
+ * @param ref the second callback parameter
+ * @param service the third callback parameter
+ */
void accept(T instance, Component c, ServiceReference<S> ref, S service);
default CbTypeComponentRefService<T, S> andThen(CbTypeComponentRefService<T, S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentRefServiceRefService.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentRefServiceRefService.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentRefServiceRefService.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentRefServiceRefService.java Fri Jan 29 23:57:17 2016
@@ -5,8 +5,23 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
import org.osgi.framework.ServiceReference;
+/**
+ * Represents a callback(Component, ServiceReference, Service, ServiceReference, Service) that is invoked on a Component implementation class.
+ * The type of the class on which the callback is invoked on is represented by the T generic parameter.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbTypeComponentRefServiceRefService<T, S> extends SerializableLambda {
+ /**
+ * Handles the given arguments.
+ * @param instance the Component implementation instance on which the callback is invoked on.
+ * @param c first callback param
+ * @param oldRef second callback param
+ * @param old third callback param
+ * @param replaceRef fourth callback param
+ * @param replace fifth callback param
+ */
void accept(T instance, Component c, ServiceReference<S> oldRef, S old, ServiceReference<S> replaceRef, S replace);
default CbTypeComponentRefServiceRefService<T, S> andThen(CbTypeComponentRefServiceRefService<? super T, S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentService.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentService.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentService.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentService.java Fri Jan 29 23:57:17 2016
@@ -4,8 +4,20 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
+/**
+ * Represents a callback(Component, Service) that is invoked on a Component implementation class.
+ * The type of the class on which the callback is invoked on is represented by the T generic parameter.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbTypeComponentService<T, S> extends SerializableLambda {
+ /**
+ * Handles the given arguments.
+ * @param instance the Component implementation instance on which the callback is invoked on.
+ * @param c first callback param
+ * @param service second callback param
+ */
void accept(T instance, Component c, S service);
default CbTypeComponentService<T, S> andThen(CbTypeComponentService<T, S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentServiceDict.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentServiceDict.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentServiceDict.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentServiceDict.java Fri Jan 29 23:57:17 2016
@@ -5,8 +5,21 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
+/**
+ * Represents a callback(Component, ServiceReference, Dictionary) that is invoked on a Component implementation class.
+ * The type of the class on which the callback is invoked on is represented by the T generic parameter.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbTypeComponentServiceDict<T, S> extends SerializableLambda {
+ /**
+ * Handles the given arguments.
+ * @param instance the Component implementation instance on which the callback is invoked on.
+ * @param c first callback param
+ * @param service second callback param
+ * @param props third callback param
+ */
void accept(T instance, Component c, S service, Dictionary<String, Object> props);
default CbTypeComponentServiceDict<T, S> andThen(CbTypeComponentServiceDict<T, S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentServiceMap.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentServiceMap.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentServiceMap.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentServiceMap.java Fri Jan 29 23:57:17 2016
@@ -5,8 +5,21 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
+/**
+ * Represents a callback(Component, ServiceReference, Service, Service Reference, Service) that is invoked on a Component implementation class.
+ * The type of the class on which the callback is invoked on is represented by the T generic parameter.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbTypeComponentServiceMap<T, S> extends SerializableLambda {
+ /**
+ * Handles the given arguments.
+ * @param instance the Component implementation instance on which the callback is invoked on.
+ * @param c first callback param
+ * @param service second callback param
+ * @param props third callback param
+ */
void accept(T instance, Component c, S service, Map<String, Object> props);
default CbTypeComponentServiceMap<T, S> andThen(CbTypeComponentServiceMap<T, S> after) {
Modified: felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentServiceService.java
URL: http://svn.apache.org/viewvc/felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentServiceService.java?rev=1727666&r1=1727665&r2=1727666&view=diff
==============================================================================
--- felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentServiceService.java (original)
+++ felix/sandbox/pderop/dependencymanager-lambda/org.apache.felix.dependencymanager.lambda/src/org/apache/felix/dm/lambda/callbacks/CbTypeComponentServiceService.java Fri Jan 29 23:57:17 2016
@@ -4,8 +4,21 @@ import java.util.Objects;
import org.apache.felix.dm.Component;
+/**
+ * Represents a callback(Component, Service, Service) that is invoked on a Component implementation class.
+ * The type of the class on which the callback is invoked on is represented by the T generic parameter.
+ *
+ * @author <a href="mailto:dev@felix.apache.org">Felix Project Team</a>
+ */
@FunctionalInterface
public interface CbTypeComponentServiceService<T, S> extends SerializableLambda {
+ /**
+ * Handles the given arguments.
+ * @param instance the Component implementation instance on which the callback is invoked on.
+ * @param c first callback param
+ * @param old second callback param
+ * @param replace third callback param
+ */
void accept(T instance, Component c, S old, S replace);
default CbTypeComponentServiceService<T, S> andThen(CbTypeComponentServiceService<? super T, S> after) {