projects
/
lgpl
/
argeo-commons.git
/ blobdiff
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Improve A2 provisioning framework.
[lgpl/argeo-commons.git]
/
org.argeo.osgi.boot
/
src
/
org
/
argeo
/
osgi
/
boot
/
a2
/
A2Contribution.java
diff --git
a/org.argeo.osgi.boot/src/org/argeo/osgi/boot/a2/A2Contribution.java
b/org.argeo.osgi.boot/src/org/argeo/osgi/boot/a2/A2Contribution.java
index 84778918641a0b2e8f6dc936dc13720a065a458b..e81ecadc8b9d661b5606a0195dd71f2b07c6ecfa 100644
(file)
--- a/
org.argeo.osgi.boot/src/org/argeo/osgi/boot/a2/A2Contribution.java
+++ b/
org.argeo.osgi.boot/src/org/argeo/osgi/boot/a2/A2Contribution.java
@@
-8,7
+8,7
@@
import java.util.TreeMap;
* A category grouping a set of {@link A2Component}, typically based on the
* provider of these components. This is the equivalent of Maven's group Id.
*/
* A category grouping a set of {@link A2Component}, typically based on the
* provider of these components. This is the equivalent of Maven's group Id.
*/
-class A2Contribution implements Comparable<A2Contribution> {
+
public
class A2Contribution implements Comparable<A2Contribution> {
final static String BOOT = "boot";
final static String RUNTIME = "runtime";
final static String CLASSPATH = "classpath";
final static String BOOT = "boot";
final static String RUNTIME = "runtime";
final static String CLASSPATH = "classpath";
@@
-18,11
+18,16
@@
class A2Contribution implements Comparable<A2Contribution> {
final Map<String, A2Component> components = Collections.synchronizedSortedMap(new TreeMap<>());
final Map<String, A2Component> components = Collections.synchronizedSortedMap(new TreeMap<>());
+ /**
+ * The contribution must be added to the source. Rather use
+ * {@link AbstractProvisioningSource#getOrAddContribution(String)} than this
+ * contructor directly.
+ */
public A2Contribution(ProvisioningSource context, String id) {
this.source = context;
this.id = id;
public A2Contribution(ProvisioningSource context, String id) {
this.source = context;
this.id = id;
-
if (context != null)
-
context.contributions.put(id, this);
+
//
if (context != null)
+
//
context.contributions.put(id, this);
}
A2Component getOrAddComponent(String componentId) {
}
A2Component getOrAddComponent(String componentId) {