This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

View | Details | Raw Unified | Return to bug 34699
Collapse All | Expand All

(-)ant/manifest.mf (-3 lines)
Lines 4-12 Link Here
4
OpenIDE-Module-Localizing-Bundle: org/apache/tools/ant/module/Bundle.properties
4
OpenIDE-Module-Localizing-Bundle: org/apache/tools/ant/module/Bundle.properties
5
OpenIDE-Module-Install: org/apache/tools/ant/module/AntModule.class
5
OpenIDE-Module-Install: org/apache/tools/ant/module/AntModule.class
6
OpenIDE-Module-Layer: org/apache/tools/ant/module/resources/AntModuleLayer.xml
6
OpenIDE-Module-Layer: org/apache/tools/ant/module/resources/AntModuleLayer.xml
7
OpenIDE-Module-Requires: 
8
  org.openide.execution.ExecutionEngine,
9
  org.openide.windows.IOProvider
10
7
11
Name: org/apache/tools/ant/module/loader/AntProjectDataLoader.class
8
Name: org/apache/tools/ant/module/loader/AntProjectDataLoader.class
12
OpenIDE-Module-Class: Loader
9
OpenIDE-Module-Class: Loader
(-)ant/nbproject/project.xml (-1 / +1 lines)
Lines 138-144 Link Here
138
                    <build-prerequisite/>
138
                    <build-prerequisite/>
139
                    <compile-dependency/>
139
                    <compile-dependency/>
140
                    <run-dependency>
140
                    <run-dependency>
141
                        <specification-version>1.5</specification-version>
141
                        <specification-version>1.11</specification-version>
142
                    </run-dependency>
142
                    </run-dependency>
143
                </dependency>
143
                </dependency>
144
                <dependency>
144
                <dependency>
(-)contrib/docbook/manifest.mf (-1 lines)
Lines 1-6 Link Here
1
Manifest-Version: 1.0
1
Manifest-Version: 1.0
2
OpenIDE-Module: org.netbeans.modules.docbook
2
OpenIDE-Module: org.netbeans.modules.docbook
3
OpenIDE-Module-Requires: org.openide.windows.IOProvider
4
OpenIDE-Module-Java-Dependencies: Java > 1.4
3
OpenIDE-Module-Java-Dependencies: Java > 1.4
5
OpenIDE-Module-Specification-Version: 1.4
4
OpenIDE-Module-Specification-Version: 1.4
6
OpenIDE-Module-Layer: org/netbeans/modules/docbook/layer.xml
5
OpenIDE-Module-Layer: org/netbeans/modules/docbook/layer.xml
(-)contrib/docbook/nbproject/project.xml (-1 / +1 lines)
Lines 87-93 Link Here
87
                    <build-prerequisite/>
87
                    <build-prerequisite/>
88
                    <compile-dependency/>
88
                    <compile-dependency/>
89
                    <run-dependency>
89
                    <run-dependency>
90
                        <specification-version>1.0</specification-version>
90
                        <specification-version>1.11</specification-version>
91
                    </run-dependency>
91
                    </run-dependency>
92
                </dependency>
92
                </dependency>
93
                <dependency>
93
                <dependency>
(-)core/bootstrap/src/org/netbeans/Module.java (+2 lines)
Lines 399-404 Link Here
399
                dependencies.addAll(Dependency.create(Dependency.TYPE_PACKAGE, pkgdeps)); // NOI18N
399
                dependencies.addAll(Dependency.create(Dependency.TYPE_PACKAGE, pkgdeps)); // NOI18N
400
            }
400
            }
401
            dependencies.addAll(Dependency.create(Dependency.TYPE_REQUIRES, attr.getValue("OpenIDE-Module-Requires"))); // NOI18N
401
            dependencies.addAll(Dependency.create(Dependency.TYPE_REQUIRES, attr.getValue("OpenIDE-Module-Requires"))); // NOI18N
402
            dependencies.addAll(Dependency.create(Dependency.TYPE_NEEDS, attr.getValue("OpenIDE-Module-Needs"))); // NOI18N
403
            dependencies.addAll(Dependency.create(Dependency.TYPE_RECOMMENDS, attr.getValue("OpenIDE-Module-Recommends"))); // NOI18N
402
            // Permit the concrete installer to make some changes:
404
            // Permit the concrete installer to make some changes:
403
            mgr.refineDependencies(this, dependencies);
405
            mgr.refineDependencies(this, dependencies);
404
            dependenciesA = dependencies.toArray(new Dependency[dependencies.size()]);
406
            dependenciesA = dependencies.toArray(new Dependency[dependencies.size()]);
(-)core/bootstrap/src/org/netbeans/ModuleManager.java (-9 / +86 lines)
Lines 1071-1080 Link Here
1071
                if (! other.isEnabled()) {
1071
                if (! other.isEnabled()) {
1072
                    maybeAddToEnableList(willEnable, mightEnable, other, false);
1072
                    maybeAddToEnableList(willEnable, mightEnable, other, false);
1073
                }
1073
                }
1074
            } else if (dep.getType() == Dependency.TYPE_REQUIRES) {
1074
            } else if (
1075
                dep.getType() == Dependency.TYPE_REQUIRES || 
1076
                dep.getType() == Dependency.TYPE_NEEDS ||
1077
                dep.getType() == Dependency.TYPE_RECOMMENDS
1078
            ) {
1075
                String token = dep.getName();
1079
                String token = dep.getName();
1076
                Set<Module> providers = providersOf.get(token);
1080
                Set<Module> providers = providersOf.get(token);
1077
                if (providers == null) throw new IllegalStateException("Should have found a provider of: " + token); // NOI18N
1081
                if (providers == null) {
1082
                    if (dep.getType() != Dependency.TYPE_RECOMMENDS) {
1083
                        throw new IllegalStateException("Should have found a provider of: " + token); // NOI18N
1084
                    } else {
1085
                        continue;
1086
                    }
1087
                }
1078
                // First check if >= 1 is already enabled or will be soon. If so, great.
1088
                // First check if >= 1 is already enabled or will be soon. If so, great.
1079
                boolean foundOne = false;
1089
                boolean foundOne = false;
1080
                for (Module other : providers) {
1090
                for (Module other : providers) {
Lines 1241-1247 Link Here
1241
                        // No need to scan the rest of its dependencies.
1251
                        // No need to scan the rest of its dependencies.
1242
                        break;
1252
                        break;
1243
                    }
1253
                    }
1244
                } else if (dep.getType() == Dependency.TYPE_REQUIRES) {
1254
                } else if (
1255
                    dep.getType() == Dependency.TYPE_REQUIRES || 
1256
                    dep.getType() == Dependency.TYPE_NEEDS
1257
                ) {
1245
                    if (m.provides(dep.getName())) {
1258
                    if (m.provides(dep.getName())) {
1246
                        // Careful. There may be some third module still enabled which
1259
                        // Careful. There may be some third module still enabled which
1247
                        // provides this same token too.
1260
                        // provides this same token too.
Lines 1284-1290 Link Here
1284
                                // Still used, skip it.
1297
                                // Still used, skip it.
1285
                                continue FIND_AUTOLOADS;
1298
                                continue FIND_AUTOLOADS;
1286
                            }
1299
                            }
1287
                        } else if (dep.getType() == Dependency.TYPE_REQUIRES) {
1300
                        } else if (
1301
                            dep.getType() == Dependency.TYPE_REQUIRES ||
1302
                            dep.getType() == Dependency.TYPE_NEEDS ||
1303
                            dep.getType() == Dependency.TYPE_RECOMMENDS
1304
                        ) {
1288
                            // Here we play it safe and leave autoloads on if they provide
1305
                            // Here we play it safe and leave autoloads on if they provide
1289
                            // something used by some module - even if technically it would
1306
                            // something used by some module - even if technically it would
1290
                            // be possible to turn off the autoload because there is another
1307
                            // be possible to turn off the autoload because there is another
Lines 1315-1324 Link Here
1315
        // where moduleProblems are used are write-mutex only and so do not have
1332
        // where moduleProblems are used are write-mutex only and so do not have
1316
        // to worry about contention.
1333
        // to worry about contention.
1317
        synchronized (moduleProblems) {
1334
        synchronized (moduleProblems) {
1318
            return _missingDependencies(probed);
1335
            Set<Union2<Dependency,InvalidException>> result;
1336
            ArrayList<NeedsCheck> check = new ArrayList<NeedsCheck>();
1337
            result = _missingDependencies(probed, check);
1338
            LOOP: while (result.isEmpty()) {
1339
                for (NeedsCheck needs : check) {
1340
                    String token = needs.dep.getName();
1341
                    Set<Module> providers = providersOf.get(token);
1342
                    if (providers == null) {
1343
                        if (needs.dep.getType() == Dependency.TYPE_NEEDS) {
1344
                            // Nobody provides it. This dep failed.
1345
                            result.add(Union2.<Dependency,InvalidException>createFirst(needs.dep));
1346
                        } else {
1347
                            // TYPE_RECOMMENDS is ok if not present
1348
                            assert needs.dep.getType() == Dependency.TYPE_RECOMMENDS;
1349
                        }
1350
                    } else {
1351
                        // We have some possible providers. Check that at least one is good.
1352
                        boolean foundOne = false;
1353
                        Set<Module> possibleModules = new HashSet<Module>();
1354
                        for (Module other : providers) {
1355
                            if (other.isEnabled()) {
1356
                                foundOne = true;
1357
                                break;
1358
                            }
1359
                        }
1360
                        if (!foundOne) {
1361
                            for (Module m : providers) {
1362
                                ArrayList<NeedsCheck> arr = new ArrayList<NeedsCheck>();
1363
                                if (!_missingDependencies(m, arr).isEmpty()) {
1364
                                    continue;
1365
                                }
1366
                                
1367
                                if (!arr.isEmpty()) {
1368
                                    check.addAll(arr);
1369
                                    // restart the check
1370
                                    continue LOOP;
1371
                                }
1372
                            }
1373
                            
1374
                        }
1375
                    }
1376
                }
1377
                break LOOP;
1378
            }
1379
            return result;
1380
        }
1381
    }
1382
    
1383
    private static class NeedsCheck {
1384
        public final Module module;
1385
        public final Dependency dep;
1386
        
1387
        public NeedsCheck(Module m, Dependency d) {
1388
            this.module = m;
1389
            this.dep = d;
1319
        }
1390
        }
1320
    }
1391
    }
1321
    private Set<Union2<Dependency,InvalidException>> _missingDependencies(Module probed) {
1392
    
1393
    private Set<Union2<Dependency,InvalidException>> _missingDependencies(Module probed, Collection<NeedsCheck> nonOrderingCheck) {
1322
            Set<Union2<Dependency,InvalidException>> probs = moduleProblems.get(probed);
1394
            Set<Union2<Dependency,InvalidException>> probs = moduleProblems.get(probed);
1323
            if (probs == null) {
1395
            if (probs == null) {
1324
                probs = new HashSet<Union2<Dependency,InvalidException>>(8);
1396
                probs = new HashSet<Union2<Dependency,InvalidException>>(8);
Lines 1388-1394 Link Here
1388
                        if (! other.isEnabled()) {
1460
                        if (! other.isEnabled()) {
1389
                            // Need to make sure the other one is not missing anything either.
1461
                            // Need to make sure the other one is not missing anything either.
1390
                            // Nor that it depends (directly on indirectly) on this one.
1462
                            // Nor that it depends (directly on indirectly) on this one.
1391
                            if (! _missingDependencies(other).isEmpty()) {
1463
                            if (! _missingDependencies(other, nonOrderingCheck).isEmpty()) {
1392
                                // This is a little subtle. Either the other module had real
1464
                                // This is a little subtle. Either the other module had real
1393
                                // problems, in which case our dependency on it is not legit.
1465
                                // problems, in which case our dependency on it is not legit.
1394
                                // Or, the other actually depends cyclically on this one. In
1466
                                // Or, the other actually depends cyclically on this one. In
Lines 1422-1428 Link Here
1422
                                if (other.isEnabled()) {
1494
                                if (other.isEnabled()) {
1423
                                    foundOne = true;
1495
                                    foundOne = true;
1424
                                } else {
1496
                                } else {
1425
                                    if (_missingDependencies(other).isEmpty()) {
1497
                                    if (_missingDependencies(other, nonOrderingCheck).isEmpty()) {
1426
                                        // See comment above for regular module deps
1498
                                        // See comment above for regular module deps
1427
                                        // re. use of PROBING_IN_PROCESS.
1499
                                        // re. use of PROBING_IN_PROCESS.
1428
                                        foundOne = true;
1500
                                        foundOne = true;
Lines 1434-1439 Link Here
1434
                                probs.add(Union2.<Dependency,InvalidException>createFirst(dep));
1506
                                probs.add(Union2.<Dependency,InvalidException>createFirst(dep));
1435
                            }
1507
                            }
1436
                        }
1508
                        }
1509
                    } else if (dep.getType() == Dependency.TYPE_NEEDS || dep.getType() == Dependency.TYPE_RECOMMENDS) {
1510
                        nonOrderingCheck.add(new NeedsCheck(probed, dep));
1437
                    } else {
1511
                    } else {
1438
                        assert dep.getType() == Dependency.TYPE_JAVA;
1512
                        assert dep.getType() == Dependency.TYPE_JAVA;
1439
                        // Java dependency. Fixed for whole VM session, safe to check once and keep.
1513
                        // Java dependency. Fixed for whole VM session, safe to check once and keep.
Lines 1474-1480 Link Here
1474
                        }
1548
                        }
1475
                        Dependency dep = problem.first();
1549
                        Dependency dep = problem.first();
1476
                        if (dep.getType() != Dependency.TYPE_MODULE &&
1550
                        if (dep.getType() != Dependency.TYPE_MODULE &&
1477
                                dep.getType() != Dependency.TYPE_REQUIRES) {
1551
                            dep.getType() != Dependency.TYPE_REQUIRES && 
1552
                            dep.getType() != Dependency.TYPE_NEEDS &&
1553
                            dep.getType() != Dependency.TYPE_RECOMMENDS 
1554
                        ) {
1478
                            // Also a hard problem.
1555
                            // Also a hard problem.
1479
                            continue;
1556
                            continue;
1480
                        }
1557
                        }
(-)core/execution/manifest.mf (-1 lines)
Lines 4-8 Link Here
4
OpenIDE-Module-Layer: org/netbeans/core/execution/resources/layer.xml
4
OpenIDE-Module-Layer: org/netbeans/core/execution/resources/layer.xml
5
OpenIDE-Module-Install: org/netbeans/core/execution/Install.class
5
OpenIDE-Module-Install: org/netbeans/core/execution/Install.class
6
OpenIDE-Module-Provides: org.openide.execution.ExecutionEngine
6
OpenIDE-Module-Provides: org.openide.execution.ExecutionEngine
7
OpenIDE-Module-Requires: org.openide.windows.IOProvider
8
7
(-)core/execution/nbproject/project.xml (-1 / +1 lines)
Lines 94-100 Link Here
94
                    <build-prerequisite/>
94
                    <build-prerequisite/>
95
                    <compile-dependency/>
95
                    <compile-dependency/>
96
                    <run-dependency>
96
                    <run-dependency>
97
                        <specification-version>1.0</specification-version>
97
                        <specification-version>1.11</specification-version>
98
                    </run-dependency>
98
                    </run-dependency>
99
                </dependency>
99
                </dependency>
100
                <dependency>
100
                <dependency>
(-)core/output/nbproject/project.xml (-13 / +13 lines)
Lines 24-38 Link Here
24
            <code-name-base>org.netbeans.core.output</code-name-base>
24
            <code-name-base>org.netbeans.core.output</code-name-base>
25
            <module-dependencies>
25
            <module-dependencies>
26
                <dependency>
26
                <dependency>
27
                    <code-name-base>org.openide.util</code-name-base>
27
                    <code-name-base>org.netbeans.lib.terminalemulator</code-name-base>
28
                    <build-prerequisite/>
28
                    <build-prerequisite/>
29
                    <compile-dependency/>
29
                    <compile-dependency/>
30
                    <run-dependency>
30
                    <run-dependency>
31
                        <specification-version>6.2</specification-version>
31
                        <specification-version>1.0</specification-version>
32
                    </run-dependency>
32
                    </run-dependency>
33
                </dependency>
33
                </dependency>
34
                <dependency>
34
                <dependency>
35
                    <code-name-base>org.openide.nodes</code-name-base>
35
                    <code-name-base>org.openide.actions</code-name-base>
36
                    <build-prerequisite/>
36
                    <build-prerequisite/>
37
                    <compile-dependency/>
37
                    <compile-dependency/>
38
                    <run-dependency>
38
                    <run-dependency>
Lines 48-54 Link Here
48
                    </run-dependency>
48
                    </run-dependency>
49
                </dependency>
49
                </dependency>
50
                <dependency>
50
                <dependency>
51
                    <code-name-base>org.openide.dialogs</code-name-base>
51
                    <code-name-base>org.openide.compat</code-name-base>
52
                    <build-prerequisite/>
52
                    <build-prerequisite/>
53
                    <compile-dependency/>
53
                    <compile-dependency/>
54
                    <run-dependency>
54
                    <run-dependency>
Lines 56-62 Link Here
56
                    </run-dependency>
56
                    </run-dependency>
57
                </dependency>
57
                </dependency>
58
                <dependency>
58
                <dependency>
59
                    <code-name-base>org.openide.compat</code-name-base>
59
                    <code-name-base>org.openide.dialogs</code-name-base>
60
                    <build-prerequisite/>
60
                    <build-prerequisite/>
61
                    <compile-dependency/>
61
                    <compile-dependency/>
62
                    <run-dependency>
62
                    <run-dependency>
Lines 64-78 Link Here
64
                    </run-dependency>
64
                    </run-dependency>
65
                </dependency>
65
                </dependency>
66
                <dependency>
66
                <dependency>
67
                    <code-name-base>org.openide.options</code-name-base>
67
                    <code-name-base>org.openide.io</code-name-base>
68
                    <build-prerequisite/>
68
                    <build-prerequisite/>
69
                    <compile-dependency/>
69
                    <compile-dependency/>
70
                    <run-dependency>
70
                    <run-dependency>
71
                        <specification-version>6.2</specification-version>
71
                        <specification-version>1.11</specification-version>
72
                    </run-dependency>
72
                    </run-dependency>
73
                </dependency>
73
                </dependency>
74
                <dependency>
74
                <dependency>
75
                    <code-name-base>org.openide.windows</code-name-base>
75
                    <code-name-base>org.openide.nodes</code-name-base>
76
                    <build-prerequisite/>
76
                    <build-prerequisite/>
77
                    <compile-dependency/>
77
                    <compile-dependency/>
78
                    <run-dependency>
78
                    <run-dependency>
Lines 80-86 Link Here
80
                    </run-dependency>
80
                    </run-dependency>
81
                </dependency>
81
                </dependency>
82
                <dependency>
82
                <dependency>
83
                    <code-name-base>org.openide.actions</code-name-base>
83
                    <code-name-base>org.openide.options</code-name-base>
84
                    <build-prerequisite/>
84
                    <build-prerequisite/>
85
                    <compile-dependency/>
85
                    <compile-dependency/>
86
                    <run-dependency>
86
                    <run-dependency>
Lines 88-106 Link Here
88
                    </run-dependency>
88
                    </run-dependency>
89
                </dependency>
89
                </dependency>
90
                <dependency>
90
                <dependency>
91
                    <code-name-base>org.openide.io</code-name-base>
91
                    <code-name-base>org.openide.util</code-name-base>
92
                    <build-prerequisite/>
92
                    <build-prerequisite/>
93
                    <compile-dependency/>
93
                    <compile-dependency/>
94
                    <run-dependency>
94
                    <run-dependency>
95
                        <specification-version>1.0</specification-version>
95
                        <specification-version>6.2</specification-version>
96
                    </run-dependency>
96
                    </run-dependency>
97
                </dependency>
97
                </dependency>
98
                <dependency>
98
                <dependency>
99
                    <code-name-base>org.netbeans.lib.terminalemulator</code-name-base>
99
                    <code-name-base>org.openide.windows</code-name-base>
100
                    <build-prerequisite/>
100
                    <build-prerequisite/>
101
                    <compile-dependency/>
101
                    <compile-dependency/>
102
                    <run-dependency>
102
                    <run-dependency>
103
                        <specification-version>1.0</specification-version>
103
                        <specification-version>6.2</specification-version>
104
                    </run-dependency>
104
                    </run-dependency>
105
                </dependency>
105
                </dependency>
106
            </module-dependencies>
106
            </module-dependencies>
(-)core/output2/nbproject/project.xml (-7 / +7 lines)
Lines 24-30 Link Here
24
            <code-name-base>org.netbeans.core.output2</code-name-base>
24
            <code-name-base>org.netbeans.core.output2</code-name-base>
25
            <module-dependencies>
25
            <module-dependencies>
26
                <dependency>
26
                <dependency>
27
                    <code-name-base>org.openide.util</code-name-base>
27
                    <code-name-base>org.openide.actions</code-name-base>
28
                    <build-prerequisite/>
28
                    <build-prerequisite/>
29
                    <compile-dependency/>
29
                    <compile-dependency/>
30
                    <run-dependency>
30
                    <run-dependency>
Lines 40-54 Link Here
40
                    </run-dependency>
40
                    </run-dependency>
41
                </dependency>
41
                </dependency>
42
                <dependency>
42
                <dependency>
43
                    <code-name-base>org.openide.options</code-name-base>
43
                    <code-name-base>org.openide.io</code-name-base>
44
                    <build-prerequisite/>
44
                    <build-prerequisite/>
45
                    <compile-dependency/>
45
                    <compile-dependency/>
46
                    <run-dependency>
46
                    <run-dependency>
47
                        <specification-version>6.2</specification-version>
47
                        <specification-version>1.11</specification-version>
48
                    </run-dependency>
48
                    </run-dependency>
49
                </dependency>
49
                </dependency>
50
                <dependency>
50
                <dependency>
51
                    <code-name-base>org.openide.windows</code-name-base>
51
                    <code-name-base>org.openide.options</code-name-base>
52
                    <build-prerequisite/>
52
                    <build-prerequisite/>
53
                    <compile-dependency/>
53
                    <compile-dependency/>
54
                    <run-dependency>
54
                    <run-dependency>
Lines 56-62 Link Here
56
                    </run-dependency>
56
                    </run-dependency>
57
                </dependency>
57
                </dependency>
58
                <dependency>
58
                <dependency>
59
                    <code-name-base>org.openide.actions</code-name-base>
59
                    <code-name-base>org.openide.util</code-name-base>
60
                    <build-prerequisite/>
60
                    <build-prerequisite/>
61
                    <compile-dependency/>
61
                    <compile-dependency/>
62
                    <run-dependency>
62
                    <run-dependency>
Lines 64-74 Link Here
64
                    </run-dependency>
64
                    </run-dependency>
65
                </dependency>
65
                </dependency>
66
                <dependency>
66
                <dependency>
67
                    <code-name-base>org.openide.io</code-name-base>
67
                    <code-name-base>org.openide.windows</code-name-base>
68
                    <build-prerequisite/>
68
                    <build-prerequisite/>
69
                    <compile-dependency/>
69
                    <compile-dependency/>
70
                    <run-dependency>
70
                    <run-dependency>
71
                        <specification-version>1.5</specification-version>
71
                        <specification-version>6.2</specification-version>
72
                    </run-dependency>
72
                    </run-dependency>
73
                </dependency>
73
                </dependency>
74
            </module-dependencies>
74
            </module-dependencies>
(-)core/startup/src/org/netbeans/core/startup/AutomaticDependencies.java (+2 lines)
Lines 196-201 Link Here
196
                pkgDeps.put(name, d);
196
                pkgDeps.put(name, d);
197
                break;
197
                break;
198
            case Dependency.TYPE_REQUIRES:
198
            case Dependency.TYPE_REQUIRES:
199
            case Dependency.TYPE_NEEDS:
200
            case Dependency.TYPE_RECOMMENDS:
199
                tokDeps.put(d.getName(), d);
201
                tokDeps.put(d.getName(), d);
200
                break;
202
                break;
201
            case Dependency.TYPE_JAVA:
203
            case Dependency.TYPE_JAVA:
(-)core/startup/src/org/netbeans/core/startup/NbProblemDisplayer.java (+1 lines)
Lines 112-117 Link Here
112
                    }
112
                    }
113
                }
113
                }
114
            case Dependency.TYPE_REQUIRES:
114
            case Dependency.TYPE_REQUIRES:
115
            case Dependency.TYPE_NEEDS:
115
                polite = (String)m.getLocalizedAttribute("OpenIDE-Module-Requires-Message"); // NOI18N
116
                polite = (String)m.getLocalizedAttribute("OpenIDE-Module-Requires-Message"); // NOI18N
116
                if (polite != null) {
117
                if (polite != null) {
117
                    return polite;
118
                    return polite;
(-)core/startup/test/unit/src/org/netbeans/core/startup/ModuleManagerTest.java (+430 lines)
Lines 19-26 Link Here
19
19
20
package org.netbeans.core.startup;
20
package org.netbeans.core.startup;
21
21
22
import java.io.ByteArrayInputStream;
22
import java.io.File;
23
import java.io.File;
24
import java.io.FileOutputStream;
23
import java.io.IOException;
25
import java.io.IOException;
26
import java.io.InputStream;
24
import java.lang.ref.WeakReference;
27
import java.lang.ref.WeakReference;
25
import java.lang.reflect.Field;
28
import java.lang.reflect.Field;
26
import java.lang.reflect.Method;
29
import java.lang.reflect.Method;
Lines 32-37 Link Here
32
import java.util.Arrays;
35
import java.util.Arrays;
33
import java.util.Collection;
36
import java.util.Collection;
34
import java.util.Collections;
37
import java.util.Collections;
38
import java.util.Enumeration;
35
import java.util.HashMap;
39
import java.util.HashMap;
36
import java.util.HashSet;
40
import java.util.HashSet;
37
import java.util.Iterator;
41
import java.util.Iterator;
Lines 41-48 Link Here
41
import java.util.Map;
45
import java.util.Map;
42
import java.util.Random;
46
import java.util.Random;
43
import java.util.Set;
47
import java.util.Set;
48
import java.util.jar.JarEntry;
44
import java.util.jar.JarFile;
49
import java.util.jar.JarFile;
50
import java.util.jar.JarOutputStream;
45
import java.util.jar.Manifest;
51
import java.util.jar.Manifest;
52
import junit.framework.Test;
46
import org.netbeans.InvalidException;
53
import org.netbeans.InvalidException;
47
import org.netbeans.Module;
54
import org.netbeans.Module;
48
import org.netbeans.ModuleManager;
55
import org.netbeans.ModuleManager;
Lines 50-60 Link Here
50
import org.netbeans.core.startup.SetupHid.FakeEvents;
57
import org.netbeans.core.startup.SetupHid.FakeEvents;
51
import org.netbeans.core.startup.SetupHid.FakeModuleInstaller;
58
import org.netbeans.core.startup.SetupHid.FakeModuleInstaller;
52
import org.netbeans.core.startup.SetupHid.LoggedPCListener;
59
import org.netbeans.core.startup.SetupHid.LoggedPCListener;
60
import org.netbeans.junit.NbTestSuite;
61
import org.openide.filesystems.FileUtil;
53
import org.openide.modules.Dependency;
62
import org.openide.modules.Dependency;
54
import org.openide.modules.ModuleInfo;
63
import org.openide.modules.ModuleInfo;
55
import org.openide.util.Lookup;
64
import org.openide.util.Lookup;
56
import org.openide.util.LookupEvent;
65
import org.openide.util.LookupEvent;
57
import org.openide.util.LookupListener;
66
import org.openide.util.LookupListener;
67
import org.openide.util.TopologicalSortException;
58
import org.openide.util.Utilities;
68
import org.openide.util.Utilities;
59
69
60
/** Test the module manager as well as the Module class.
70
/** Test the module manager as well as the Module class.
Lines 88-93 Link Here
88
        super(name);
98
        super(name);
89
    }
99
    }
90
100
101
    public static Test suite() {
102
        return new NbTestSuite(ModuleManagerTest.class);
103
        //return new ModuleManagerTest("testNeedsWithAProviderWithoutAProvider");
104
    }
91
    /*
105
    /*
92
    public static void main(String[] args) {
106
    public static void main(String[] args) {
93
        // Turn on verbose logging while developing tests:
107
        // Turn on verbose logging while developing tests:
Lines 1028-1034 Link Here
1028
            mgr.mutexPrivileged().exitWriteAccess();
1042
            mgr.mutexPrivileged().exitWriteAccess();
1029
        }
1043
        }
1030
    }
1044
    }
1045
    
1046
    public void testSimpleProvNeeds() throws Exception {
1047
        doSimpleProvNeeds(false, false);
1048
    }
1049
    
1050
    public void testSimpleProvNeedsReversed() throws Exception {
1051
        doSimpleProvNeeds(true, false);
1052
    }
1053
1054
    public void testSimpleSatisfiedProvRecommends() throws Exception {
1055
        doSimpleProvNeeds(false, true);
1056
    }
1057
    
1058
    public void testSimpleSatisfiedProvRecommendsReversed() throws Exception {
1059
        doSimpleProvNeeds(true, true);
1060
    }
1061
    
1062
    private void doSimpleProvNeeds(boolean reverseOrder, boolean recommends) throws Exception {
1063
        FakeModuleInstaller installer = new FakeModuleInstaller();
1064
        FakeEvents ev = new FakeEvents();
1065
        ModuleManager mgr = new ModuleManager(installer, ev);
1066
        mgr.mutexPrivileged().enterWriteAccess();
1067
        try {
1068
            Module m1 = mgr.create(new File(jars, "prov-foo-depends-needs_foo.jar"), null, false, false, false);
1069
            Module m2;
1070
            if (recommends) {
1071
                m2 = mgr.create(new File(jars, "recommends-foo.jar"), null, false, false, false);
1072
            } else {
1073
                m2 = mgr.create(new File(jars, "needs-foo.jar"), null, false, false, false);
1074
            }
1075
            assertEquals(Collections.singletonList("foo"), Arrays.asList(m1.getProvides()));
1076
            assertEquals(Collections.EMPTY_LIST, Arrays.asList(m2.getProvides()));
1077
            assertEquals(1, m1.getDependencies().size());
1078
            int type = recommends ? Dependency.TYPE_RECOMMENDS : Dependency.TYPE_NEEDS;
1079
            assertEquals(Dependency.create(type, "foo"), m2.getDependencies());
1080
            Map<String,Module> modulesByName = new HashMap<String,Module>();
1081
            modulesByName.put(m1.getCodeNameBase(), m1);
1082
            modulesByName.put(m2.getCodeNameBase(), m2);
1083
            Map<String,Set<Module>> providersOf = new HashMap<String,Set<Module>>();
1084
            providersOf.put("foo", Collections.singleton(m1));
1085
            List<Module> m1m2 = Arrays.asList(new Module[] {m1, m2});
1086
            List<Module> m2m1 = Arrays.asList(new Module[] {m2, m1});
1087
            Map<Module,List<Module>> deps = Util.moduleDependencies(m1m2, modulesByName, providersOf);
1088
            assertEquals(Collections.singletonList(m2), deps.get(m1));
1089
/*            assertEquals(Collections.singletonList(m1), deps.get(m2));
1090
            
1091
            try {
1092
                Utilities.topologicalSort(m1m2, deps);
1093
            } catch (TopologicalSortException ex) {
1094
                Set[] arr = ex.unsortableSets();
1095
                assertEquals("One unsortable set", 1, arr.length);
1096
                assertEquals("It contains two elements", 2, arr[0].size());
1097
                assertTrue("m1 is there", arr[0].contains(m1));
1098
                assertTrue("m2 is there", arr[0].contains(m2));
1099
            }*/
1100
            Set<Module> m1PlusM2 = new LinkedHashSet<Module>();
1101
            if (reverseOrder) {
1102
                m1PlusM2.add(m2);
1103
                m1PlusM2.add(m1);
1104
            } else {
1105
                m1PlusM2.add(m1);
1106
                m1PlusM2.add(m2);
1107
            }
1108
            List<Module> toEnable = mgr.simulateEnable(m1PlusM2);
1109
            assertEquals("correct result of simulateEnable", Arrays.asList(new Module[] {m2, m1}), toEnable);
1110
            toEnable = mgr.simulateEnable(Collections.singleton(m1));
1111
            assertEquals("correct result of simulateEnable #2", Arrays.asList(new Module[] {m2, m1}), toEnable);
1112
            toEnable = mgr.simulateEnable(Collections.singleton(m2));
1113
            assertEquals("correct result of simulateEnable #3", Arrays.asList(new Module[] {m2, m1}), toEnable);
1114
            mgr.enable(m1PlusM2);
1115
            assertEquals(Arrays.asList(new String[] {
1116
                "prepare",
1117
                "prepare",
1118
                "load"
1119
            }), installer.actions);
1120
            assertEquals(Arrays.asList(new Object[] {
1121
                m2,
1122
                m1,
1123
                Arrays.asList(new Module[] {m2, m1})
1124
            }), installer.args);
1125
            Class testclazz = Class.forName("org.prov_foo.Clazz", true, m1.getClassLoader());
1126
            try {
1127
                Class.forName("org.prov_foo.Clazz", true, m2.getClassLoader());
1128
                fail("Should not be able to access classes due to prov-req deps only");
1129
            } catch (ClassNotFoundException cnfe) {
1130
                // OK, good.
1131
            }
1132
            installer.clear();
1133
            List<Module> toDisable = mgr.simulateDisable(Collections.singleton(m1));
1134
            if (!recommends) {
1135
                assertEquals("correct result of simulateDisable", Arrays.asList(new Module[] {m1, m2}), toDisable);
1136
                toDisable = mgr.simulateDisable(m1PlusM2);
1137
                assertEquals("correct result of simulateDisable #2", Arrays.asList(new Module[] {m1, m2}), toDisable);
1138
                mgr.disable(m1PlusM2);
1139
                assertFalse(m1.isEnabled());
1140
                assertFalse(m2.isEnabled());
1141
                assertEquals(Arrays.asList(new String[] {
1142
                    "unload",
1143
                    "dispose",
1144
                    "dispose"
1145
                }), installer.actions);
1146
                assertEquals(Arrays.asList(new Object[] {
1147
                    Arrays.asList(new Module[] {m1, m2}),
1148
                    m1,
1149
                    m2
1150
                }), installer.args);
1151
            } else {
1152
                assertEquals("correct result of simulateDisable", Arrays.asList(new Module[] {m1 }), toDisable);
1153
                toDisable = mgr.simulateDisable(m1PlusM2);
1154
                assertEquals("correct result of simulateDisable #2", Arrays.asList(new Module[] {m1, m2}), toDisable);
1155
                mgr.disable(m1);
1156
                assertFalse(m1.isEnabled());
1157
                assertTrue(m2.isEnabled());
1158
                mgr.disable(m2);
1159
                assertFalse(m2.isEnabled());
1160
                assertEquals(Arrays.asList(new String[] {
1161
                    "unload",
1162
                    "dispose",
1163
                    "unload",
1164
                    "dispose"
1165
                }), installer.actions);
1166
                assertEquals(Arrays.asList(new Object[] {
1167
                    Arrays.asList(new Module[] {m1}),
1168
                    m1,
1169
                    Arrays.asList(new Module[] {m2}),
1170
                    m2
1171
                }), installer.args);
1172
            }
1173
        } finally {
1174
            mgr.mutexPrivileged().exitWriteAccess();
1175
        }
1176
    }
1177
1178
    public void testComplexProvNeeds() throws Exception {
1179
        doComplexProvNeeds(false, false, false);
1180
    }
1181
    
1182
    public void testComplexProvNeedsReversed() throws Exception {
1183
        doComplexProvNeeds(true, false, false);
1184
    }
1185
1186
    public void testComplexSatisfiedProvRecommends() throws Exception {
1187
        doComplexProvNeeds(false, true, false);
1188
    }
1189
    
1190
    public void testComplexSatisfiedProvRecommendsReversed() throws Exception {
1191
        doComplexProvNeeds(true, true, true);
1192
    }
1193
1194
    public void testComplexProvNeeds2() throws Exception {
1195
        doComplexProvNeeds(false, false, true);
1196
    }
1197
    
1198
    public void testComplexProvNeedsReversed2() throws Exception {
1199
        doComplexProvNeeds(true, false, true);
1200
    }
1201
1202
    public void testComplexSatisfiedProvRecommends2() throws Exception {
1203
        doComplexProvNeeds(false, true, true);
1204
    }
1205
    
1206
    public void testComplexSatisfiedProvRecommendsReversed2() throws Exception {
1207
        doComplexProvNeeds(true, true, true);
1208
    }
1209
    
1210
    private void doComplexProvNeeds(boolean reverseOrder, boolean recommends, boolean sndRec) throws Exception {
1211
        FakeModuleInstaller installer = new FakeModuleInstaller();
1212
        FakeEvents ev = new FakeEvents();
1213
        ModuleManager mgr = new ModuleManager(installer, ev);
1214
        mgr.mutexPrivileged().enterWriteAccess();
1215
        try {
1216
            Module m1 = mgr.create(new File(jars, "prov-foo-depends-needs_foo.jar"), null, false, true, false);
1217
            Module m2;
1218
            if (recommends) {
1219
                m2 = mgr.create(new File(jars, "recommends-foo.jar"), null, false, false, false);
1220
            } else {
1221
                m2 = mgr.create(new File(jars, "needs-foo.jar"), null, false, false, false);
1222
            }
1223
            Module m3 = null;
1224
            if (sndRec) {
1225
                String manifest = "Manifest-Version: 1.0\n" +
1226
"OpenIDE-Module: snd.needs_foo\n" +
1227
"OpenIDE-Module-Name: 2nd Needs foo\n" +
1228
"OpenIDE-Module-Needs: foo\n";
1229
                m3 = mgr.create(copyJar(m2.getJarFile(), manifest), null, false, false, false);
1230
            } else {
1231
                String manifest = "Manifest-Version: 1.0\n" +
1232
"OpenIDE-Module: snd.needs_foo\n" +
1233
"OpenIDE-Module-Name: 2nd Needs foo\n" +
1234
"OpenIDE-Module-Recommends: foo\n";
1235
                m3 = mgr.create(copyJar(m2.getJarFile(), manifest), null, false, false, false);
1236
            }
1237
            assertEquals(Collections.singletonList("foo"), Arrays.asList(m1.getProvides()));
1238
            assertEquals(Collections.EMPTY_LIST, Arrays.asList(m2.getProvides()));
1239
            assertEquals(1, m1.getDependencies().size());
1240
            int type = recommends ? Dependency.TYPE_RECOMMENDS : Dependency.TYPE_NEEDS;
1241
            assertEquals(Dependency.create(type, "foo"), m2.getDependencies());
1242
            Map<String,Module> modulesByName = new HashMap<String,Module>();
1243
            modulesByName.put(m1.getCodeNameBase(), m1);
1244
            modulesByName.put(m2.getCodeNameBase(), m2);
1245
            Map<String,Set<Module>> providersOf = new HashMap<String,Set<Module>>();
1246
            providersOf.put("foo", Collections.singleton(m1));
1247
            List<Module> m1m2 = Arrays.asList(new Module[] {m1, m2});
1248
            List<Module> m2m1 = Arrays.asList(new Module[] {m2, m1});
1249
            Map<Module,List<Module>> deps = Util.moduleDependencies(m1m2, modulesByName, providersOf);
1250
            assertEquals(Collections.singletonList(m2), deps.get(m1));
1251
            List<Module> toEnable = mgr.simulateEnable(Collections.singleton(m2));
1252
            assertEquals("correct result of simulateEnable", Arrays.asList(new Module[] {m2, m1}), toEnable);
1253
1254
            mgr.enable(m2);
1255
            assertEquals(Arrays.asList(new String[] {
1256
                "prepare",
1257
                "prepare",
1258
                "load"
1259
            }), installer.actions);
1260
            assertEquals(Arrays.asList(new Object[] {
1261
                m2,
1262
                m1,
1263
                Arrays.asList(new Module[] {m2, m1})
1264
            }), installer.args);
1265
            Class testclazz = Class.forName("org.prov_foo.Clazz", true, m1.getClassLoader());
1266
            try {
1267
                Class.forName("org.prov_foo.Clazz", true, m2.getClassLoader());
1268
                fail("Should not be able to access classes due to prov-req deps only");
1269
            } catch (ClassNotFoundException cnfe) {
1270
                // OK, good.
1271
            }
1272
            
1273
            mgr.enable(m3);
1274
            assertTrue("m3 enabled1", m3.isEnabled());
1275
            
1276
            installer.clear();
1277
            List<Module> toDisable = mgr.simulateDisable(Collections.singleton(m3));
1278
            if (!recommends) {
1279
                mgr.disable(m3);
1280
                assertFalse("M3 enabled", m3.isEnabled());
1281
                assertTrue("Provider enabled", m1.isEnabled());
1282
                assertTrue(m2.isEnabled());
1283
                assertEquals(Arrays.asList(new String[] {
1284
                    "unload",
1285
                    "dispose"
1286
                }), installer.actions);
1287
                assertEquals(Arrays.asList(new Object[] {
1288
                    Arrays.asList(new Module[] { m3 }),
1289
                    m3
1290
                }), installer.args);
1291
            } else {
1292
                mgr.disable(m3);
1293
                assertFalse(m3.isEnabled());
1294
                assertTrue(m2.isEnabled());
1295
                assertTrue(m1.isEnabled());
1296
                assertEquals(Arrays.asList(new String[] {
1297
                    "unload",
1298
                    "dispose"
1299
                }), installer.actions);
1300
                assertEquals(Arrays.asList(new Object[] {
1301
                    Arrays.asList(new Module[] {m3}),
1302
                    m3,
1303
                }), installer.args);
1304
            }
1305
        } finally {
1306
            mgr.mutexPrivileged().exitWriteAccess();
1307
        }
1308
    }
1309
    
1310
    public void testRecommendsWithoutAProvider() throws Exception {
1311
        FakeModuleInstaller installer = new FakeModuleInstaller();
1312
        FakeEvents ev = new FakeEvents();
1313
        ModuleManager mgr = new ModuleManager(installer, ev);
1314
        mgr.mutexPrivileged().enterWriteAccess();
1315
        try {
1316
            Module m2 = mgr.create(new File(jars, "recommends-foo.jar"), null, false, false, false);
1317
            assertEquals(Collections.EMPTY_LIST, Arrays.asList(m2.getProvides()));
1318
            assertEquals(Dependency.create(Dependency.TYPE_RECOMMENDS, "foo"), m2.getDependencies());
1319
            Map<String,Module> modulesByName = new HashMap<String,Module>();
1320
            modulesByName.put(m2.getCodeNameBase(), m2);
1321
            Map<String,Set<Module>> providersOf = new HashMap<String,Set<Module>>();
1322
            List<Module> m2List = Arrays.asList(new Module[] { m2 });
1323
            Map<Module,List<Module>> deps = Util.moduleDependencies(m2List, modulesByName, providersOf);
1324
            assertEquals(null, deps.get(m2));
1325
1326
            List<Module> toEnable = mgr.simulateEnable(new HashSet<Module>(m2List));
1327
            assertEquals("correct result of simulateEnable", Arrays.asList(new Module[] {m2}), toEnable);
1328
            mgr.enable(new HashSet<Module>(m2List));
1329
            assertEquals(Arrays.asList(new String[] {
1330
                "prepare",
1331
                "load"
1332
            }), installer.actions);
1333
            assertEquals(Arrays.asList(new Object[] {
1334
                m2,
1335
//                m1,
1336
                Arrays.asList(new Module[] {m2})
1337
            }), installer.args);
1338
            installer.clear();
1339
            List<Module> toDisable = mgr.simulateDisable(Collections.singleton(m2));
1340
            assertEquals("correct result of simulateDisable", Arrays.asList(new Module[] {m2}), toDisable);
1341
            mgr.disable(m2);
1342
            assertFalse(m2.isEnabled());
1343
            assertEquals(Arrays.asList(new String[] {
1344
                "unload",
1345
                "dispose"
1346
            }), installer.actions);
1347
            assertEquals(Arrays.asList(new Object[] {
1348
                Arrays.asList(new Module[] {m2}),
1349
//                m1,
1350
                m2
1351
            }), installer.args);
1352
        } finally {
1353
            mgr.mutexPrivileged().exitWriteAccess();
1354
        }
1355
    }
1356
1357
    public void testNeedsWithAProviderWithoutAProvider() throws Exception {
1358
        doRecommendsWithAProviderWithoutAProvider(false);
1359
    }
1360
    
1361
    public void testRecommendsWithAProviderWithoutAProvider() throws Exception {
1362
        doRecommendsWithAProviderWithoutAProvider(true);
1363
    }
1031
1364
1365
    private void doRecommendsWithAProviderWithoutAProvider(boolean recommends) throws Exception {
1366
        FakeModuleInstaller installer = new FakeModuleInstaller();
1367
        FakeEvents ev = new FakeEvents();
1368
        ModuleManager mgr = new ModuleManager(installer, ev);
1369
        mgr.mutexPrivileged().enterWriteAccess();
1370
        try {
1371
            Module m2 = mgr.create(new File(jars, "recommends-foo.jar"), null, false, false, false);
1372
            assertEquals(Collections.EMPTY_LIST, Arrays.asList(m2.getProvides()));
1373
            
1374
            Module m1;
1375
            {
1376
                String manifest = "Manifest-Version: 1.0\n" +
1377
"OpenIDE-Module: snd.provides.foo\n" +
1378
"OpenIDE-Module-Name: Provides foo\n" +
1379
"OpenIDE-Module-Provides: foo\n" +
1380
"OpenIDE-Module-Needs: bla\n";
1381
                m1 = mgr.create(copyJar(m2.getJarFile(), manifest), null, false, true, false);
1382
                
1383
            }
1384
            assertEquals(Dependency.create(Dependency.TYPE_RECOMMENDS, "foo"), m2.getDependencies());
1385
            Map<String,Module> modulesByName = new HashMap<String,Module>();
1386
            modulesByName.put(m2.getCodeNameBase(), m2);
1387
            Map<String,Set<Module>> providersOf = new HashMap<String,Set<Module>>();
1388
            List<Module> m2List = Arrays.asList(new Module[] { m2 });
1389
            Map<Module,List<Module>> deps = Util.moduleDependencies(m2List, modulesByName, providersOf);
1390
            assertEquals(null, deps.get(m2));
1391
1392
            List<Module> toEnable = mgr.simulateEnable(new HashSet<Module>(m2List));
1393
            assertEquals("cannot enable while provider of bla is missing", Collections.emptyList(), toEnable);
1394
1395
1396
//            try {
1397
//                mgr.enable(new HashSet<Module>(m2List));
1398
//                fail("Shall not allow enablement as 'bar' is missing");
1399
//            } catch (IllegalArgumentException ex) {
1400
//                // this cannot be enabled
1401
//            }
1402
            
1403
            
1404
            Module m3;
1405
            {
1406
                String manifest = "Manifest-Version: 1.0\n" +
1407
"OpenIDE-Module: snd.provides.bar\n" +
1408
"OpenIDE-Module-Name: Provides bar\n" +
1409
"OpenIDE-Module-Provides: bla\n";
1410
                m3 = mgr.create(copyJar(m2.getJarFile(), manifest), null, false, true, false);
1411
            }
1412
            
1413
            Set allThreeModules = new HashSet(Arrays.asList(new Module[] {m1, m3, m2, }));
1414
            
1415
            toEnable = mgr.simulateEnable(new HashSet<Module>(m2List));
1416
            assertEquals("all 3 need to be enabled", allThreeModules, new HashSet(toEnable));
1417
            
1418
            mgr.enable(new HashSet<Module>(m2List));
1419
            assertEquals(Arrays.asList(new String[] {
1420
                "prepare",
1421
                "prepare",
1422
                "prepare",
1423
                "load"
1424
            }), installer.actions);
1425
            installer.clear();
1426
            List<Module> toDisable = mgr.simulateDisable(Collections.singleton(m2));
1427
            assertEquals("correct result of simulateDisable", allThreeModules, new HashSet(toDisable));
1428
            mgr.disable(m2);
1429
            assertFalse(m2.isEnabled());
1430
            assertEquals(Arrays.asList(new String[] {
1431
                "unload",
1432
                "dispose",
1433
                "dispose",
1434
                "dispose"
1435
            }), installer.actions);
1436
        } finally {
1437
            mgr.mutexPrivileged().exitWriteAccess();
1438
        }
1439
    }
1440
    
1032
    public void testMultipleReqs() throws Exception {
1441
    public void testMultipleReqs() throws Exception {
1033
        FakeModuleInstaller installer = new FakeModuleInstaller();
1442
        FakeModuleInstaller installer = new FakeModuleInstaller();
1034
        FakeEvents ev = new FakeEvents();
1443
        FakeEvents ev = new FakeEvents();
Lines 1877-1882 Link Here
1877
        } finally {
2286
        } finally {
1878
            mgr.mutexPrivileged().exitWriteAccess();
2287
            mgr.mutexPrivileged().exitWriteAccess();
1879
        }
2288
        }
2289
    }
2290
2291
    private File copyJar(File file, String manifest) throws IOException {
2292
        File ret = File.createTempFile(file.getName(), "2ndcopy", file.getParentFile());
2293
        JarFile jar = new JarFile(file);
2294
        JarOutputStream os = new JarOutputStream(new FileOutputStream(ret), new Manifest(
2295
            new ByteArrayInputStream(manifest.getBytes())
2296
        ));
2297
        Enumeration<JarEntry> en = jar.entries();
2298
        while (en.hasMoreElements()) {
2299
            JarEntry elem = en.nextElement();
2300
            if (elem.getName().equals("META-INF/MANIFEST.MF")) {
2301
                continue;
2302
            }
2303
            os.putNextEntry(elem);
2304
            InputStream is = jar.getInputStream(elem);
2305
            FileUtil.copy(is, os);
2306
            is.close();
2307
        }
2308
        os.close();
2309
        return ret;
1880
    }
2310
    }
1881
2311
1882
}
2312
}
(-)core/startup/test/unit/src/org/netbeans/core/startup/build.xml (+6 lines)
Lines 158-163 Link Here
158
        <jar jarfile="jars/dep-on-relvertest-3-4.jar" manifest="jars/dep-on-relvertest-3-4.mf"/>
158
        <jar jarfile="jars/dep-on-relvertest-3-4.jar" manifest="jars/dep-on-relvertest-3-4.mf"/>
159
        <jar jarfile="jars/dep-on-relvertest-some.jar" manifest="jars/dep-on-relvertest-some.mf"/>
159
        <jar jarfile="jars/dep-on-relvertest-some.jar" manifest="jars/dep-on-relvertest-some.mf"/>
160
        <jar jarfile="jars/depends-on-simple-module-2.jar" manifest="jars/depends-on-simple-module-2.mf"/>
160
        <jar jarfile="jars/depends-on-simple-module-2.jar" manifest="jars/depends-on-simple-module-2.mf"/>
161
        <jar jarfile="jars/needs-foo.jar" manifest="jars/needs-foo.mf"/>
162
        <jar jarfile="jars/recommends-foo.jar" manifest="jars/recommends-foo.mf"/>
163
        <antcall target="create-jar">
164
            <param name="name" value="prov-foo-depends-needs_foo"/>
165
            <param name="sourcedir" value="jars/prov-foo"/>
166
        </antcall>
161
        <antcall target="create-jar">
167
        <antcall target="create-jar">
162
            <param name="name" value="api-mod-export-all"/>
168
            <param name="name" value="api-mod-export-all"/>
163
            <param name="sourcedir" value="jars/exposes-api"/>
169
            <param name="sourcedir" value="jars/exposes-api"/>
(-)core/startup/test/unit/src/org/netbeans/core/startup/jars/needs-foo.mf (+4 lines)
Added Link Here
1
Manifest-Version: 1.0
2
OpenIDE-Module: needs_foo
3
OpenIDE-Module-Name: Needs foo
4
OpenIDE-Module-Needs: foo
(-)core/startup/test/unit/src/org/netbeans/core/startup/jars/prov-foo-depends-needs_foo.mf (+5 lines)
Added Link Here
1
Manifest-Version: 1.0
2
OpenIDE-Module: prov_bar_req_foo
3
OpenIDE-Module-Name: Provides bar, requires foo
4
OpenIDE-Module-Provides: foo
5
OpenIDE-Module-Module-Dependencies: needs_foo
(-)core/startup/test/unit/src/org/netbeans/core/startup/jars/recommends-foo.mf (+4 lines)
Added Link Here
1
Manifest-Version: 1.0
2
OpenIDE-Module: needs_foo
3
OpenIDE-Module-Name: Recommends foo
4
OpenIDE-Module-Recommends: foo
(-)db/manifest.mf (-1 / +1 lines)
Lines 3-8 Link Here
3
OpenIDE-Module-Install: org/netbeans/modules/db/DatabaseModule.class
3
OpenIDE-Module-Install: org/netbeans/modules/db/DatabaseModule.class
4
OpenIDE-Module-Implementation-Version: 3
4
OpenIDE-Module-Implementation-Version: 3
5
OpenIDE-Module-Layer: org/netbeans/modules/db/resources/mf-layer.xml
5
OpenIDE-Module-Layer: org/netbeans/modules/db/resources/mf-layer.xml
6
OpenIDE-Module-Requires: org.netbeans.api.javahelp.Help, org.openide.windows.IOProvider
6
OpenIDE-Module-Requires: org.netbeans.api.javahelp.Help
7
OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/db/resources/Bundle.properties
7
OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/db/resources/Bundle.properties
8
8
(-)db/nbproject/project.xml (-1 / +1 lines)
Lines 78-84 Link Here
78
                    <build-prerequisite/>
78
                    <build-prerequisite/>
79
                    <compile-dependency/>
79
                    <compile-dependency/>
80
                    <run-dependency>
80
                    <run-dependency>
81
                        <specification-version>1.7</specification-version>
81
                        <specification-version>1.11</specification-version>
82
                    </run-dependency>
82
                    </run-dependency>
83
                </dependency>
83
                </dependency>
84
                <dependency>
84
                <dependency>
(-)ide/golden/cluster-deps.txt (-3 lines)
Lines 21-27 Link Here
21
  REQUIRES org.openide.awt (platform)
21
  REQUIRES org.openide.awt (platform)
22
  REQUIRES org.openide.dialogs (platform)
22
  REQUIRES org.openide.dialogs (platform)
23
  REQUIRES org.openide.execution (platform)
23
  REQUIRES org.openide.execution (platform)
24
  REQUIRES org.netbeans.core.execution/1 (platform)
25
  REQUIRES org.openide.explorer (platform)
24
  REQUIRES org.openide.explorer (platform)
26
  REQUIRES org.openide.filesystems (platform)
25
  REQUIRES org.openide.filesystems (platform)
27
  REQUIRES org.openide.io (platform)
26
  REQUIRES org.openide.io (platform)
Lines 33-39 Link Here
33
  REQUIRES org.openide.text (platform)
32
  REQUIRES org.openide.text (platform)
34
  REQUIRES org.openide.util (platform)
33
  REQUIRES org.openide.util (platform)
35
  REQUIRES org.openide.windows (platform)
34
  REQUIRES org.openide.windows (platform)
36
  REQUIRES org.netbeans.core.output2/1 (platform)
37
GROUP j2ee
35
GROUP j2ee
38
  REQUIRES javax.jmi.model/1 (ide)
36
  REQUIRES javax.jmi.model/1 (ide)
39
  REQUIRES javax.jmi.reflect/1 (ide)
37
  REQUIRES javax.jmi.reflect/1 (ide)
Lines 104-110 Link Here
104
  REQUIRES org.openide.util (platform)
102
  REQUIRES org.openide.util (platform)
105
  REQUIRES org.netbeans.modules.httpserver/2 (ide)
103
  REQUIRES org.netbeans.modules.httpserver/2 (ide)
106
  REQUIRES org.openide.windows (platform)
104
  REQUIRES org.openide.windows (platform)
107
  REQUIRES org.netbeans.core.output2/1 (platform)
108
GROUP nb
105
GROUP nb
109
  REQUIRES org.netbeans.core.windows/2 (platform)
106
  REQUIRES org.netbeans.core.windows/2 (platform)
110
  REQUIRES org.netbeans.modules.autoupdate/1 (platform)
107
  REQUIRES org.netbeans.modules.autoupdate/1 (platform)
(-)ide/golden/deps.txt (-9 lines)
Lines 15-21 Link Here
15
  REQUIRES org.openide.awt (platform)
15
  REQUIRES org.openide.awt (platform)
16
  REQUIRES org.openide.dialogs (platform)
16
  REQUIRES org.openide.dialogs (platform)
17
  REQUIRES org.openide.execution (platform)
17
  REQUIRES org.openide.execution (platform)
18
  REQUIRES org.netbeans.core.execution/1 (platform)
19
  REQUIRES org.openide.explorer (platform)
18
  REQUIRES org.openide.explorer (platform)
20
  REQUIRES org.openide.filesystems (platform)
19
  REQUIRES org.openide.filesystems (platform)
21
  REQUIRES org.openide.io (platform)
20
  REQUIRES org.openide.io (platform)
Lines 27-33 Link Here
27
  REQUIRES org.openide.text (platform)
26
  REQUIRES org.openide.text (platform)
28
  REQUIRES org.openide.util (platform)
27
  REQUIRES org.openide.util (platform)
29
  REQUIRES org.openide.windows (platform)
28
  REQUIRES org.openide.windows (platform)
30
  REQUIRES org.netbeans.core.output2/1 (platform)
31
MODULE org.jdesktop.layout/1 (platform)
29
MODULE org.jdesktop.layout/1 (platform)
32
  REQUIRES org.openide.modules.ModuleFormat1
30
  REQUIRES org.openide.modules.ModuleFormat1
33
MODULE org.netbeans.api.debugger/1 (ide)
31
MODULE org.netbeans.api.debugger/1 (ide)
Lines 113-119 Link Here
113
  REQUIRES org.openide.nodes (platform)
111
  REQUIRES org.openide.nodes (platform)
114
  REQUIRES org.openide.util (platform)
112
  REQUIRES org.openide.util (platform)
115
  REQUIRES org.openide.windows (platform)
113
  REQUIRES org.openide.windows (platform)
116
  REQUIRES org.netbeans.core.output2/1 (platform)
117
MODULE org.netbeans.core.ide/1 (ide)
114
MODULE org.netbeans.core.ide/1 (ide)
118
  REQUIRES org.netbeans.core/2 (platform)
115
  REQUIRES org.netbeans.core/2 (platform)
119
  REQUIRES org.netbeans.core.ui/1 (platform)
116
  REQUIRES org.netbeans.core.ui/1 (platform)
Lines 387-393 Link Here
387
  REQUIRES org.openide.text (platform)
384
  REQUIRES org.openide.text (platform)
388
  REQUIRES org.openide.util (platform)
385
  REQUIRES org.openide.util (platform)
389
  REQUIRES org.openide.windows (platform)
386
  REQUIRES org.openide.windows (platform)
390
  REQUIRES org.netbeans.core.output2/1 (platform)
391
MODULE org.netbeans.modules.db/0 (ide)
387
MODULE org.netbeans.modules.db/0 (ide)
392
  REQUIRES org.jdesktop.layout/1 (platform)
388
  REQUIRES org.jdesktop.layout/1 (platform)
393
  REQUIRES org.netbeans.modules.javahelp/1 (platform)
389
  REQUIRES org.netbeans.modules.javahelp/1 (platform)
Lines 404-410 Link Here
404
  REQUIRES org.openide.options (platform)
400
  REQUIRES org.openide.options (platform)
405
  REQUIRES org.openide.util (platform)
401
  REQUIRES org.openide.util (platform)
406
  REQUIRES org.openide.windows (platform)
402
  REQUIRES org.openide.windows (platform)
407
  REQUIRES org.netbeans.core.output2/1 (platform)
408
MODULE org.netbeans.modules.db.core (ide)
403
MODULE org.netbeans.modules.db.core (ide)
409
  REQUIRES org.netbeans.api.progress/1 (platform)
404
  REQUIRES org.netbeans.api.progress/1 (platform)
410
  REQUIRES org.netbeans.modules.db/0 (ide)
405
  REQUIRES org.netbeans.modules.db/0 (ide)
Lines 1493-1499 Link Here
1493
  REQUIRES org.netbeans.modules.java.platform/1 (ide)
1488
  REQUIRES org.netbeans.modules.java.platform/1 (ide)
1494
  REQUIRES org.netbeans.modules.project.ant/1 (ide)
1489
  REQUIRES org.netbeans.modules.project.ant/1 (ide)
1495
  REQUIRES org.netbeans.modules.project.libraries/1 (ide)
1490
  REQUIRES org.netbeans.modules.project.libraries/1 (ide)
1496
  REQUIRES org.netbeans.modules.projectui (ide)
1497
  REQUIRES org.netbeans.modules.projectapi/1 (ide)
1491
  REQUIRES org.netbeans.modules.projectapi/1 (ide)
1498
  REQUIRES org.netbeans.modules.projectuiapi/1 (ide)
1492
  REQUIRES org.netbeans.modules.projectuiapi/1 (ide)
1499
  REQUIRES org.netbeans.modules.queries/1 (platform)
1493
  REQUIRES org.netbeans.modules.queries/1 (platform)
Lines 1921-1927 Link Here
1921
  REQUIRES org.openide.text (platform)
1915
  REQUIRES org.openide.text (platform)
1922
  REQUIRES org.openide.util (platform)
1916
  REQUIRES org.openide.util (platform)
1923
  REQUIRES org.openide.windows (platform)
1917
  REQUIRES org.openide.windows (platform)
1924
  REQUIRES org.netbeans.core.output2/1 (platform)
1925
  REQUIRES org.openidex.util/3 (ide)
1918
  REQUIRES org.openidex.util/3 (ide)
1926
MODULE org.netbeans.modules.utilities.project/1 (ide)
1919
MODULE org.netbeans.modules.utilities.project/1 (ide)
1927
  REQUIRES org.netbeans.modules.projectapi/1 (ide)
1920
  REQUIRES org.netbeans.modules.projectapi/1 (ide)
Lines 2120-2126 Link Here
2120
  REQUIRES org.openide.modules.ModuleFormat1
2113
  REQUIRES org.openide.modules.ModuleFormat1
2121
  REQUIRES org.openide.text (platform)
2114
  REQUIRES org.openide.text (platform)
2122
  REQUIRES org.openide.util (platform)
2115
  REQUIRES org.openide.util (platform)
2123
  REQUIRES org.netbeans.core.output2/1 (platform)
2124
MODULE org.netbeans.modules.web.jstl11/1 (j2ee)
2116
MODULE org.netbeans.modules.web.jstl11/1 (j2ee)
2125
  REQUIRES org.netbeans.modules.web.project (j2ee)
2117
  REQUIRES org.netbeans.modules.web.project (j2ee)
2126
  REQUIRES org.openide.modules.ModuleFormat1
2118
  REQUIRES org.openide.modules.ModuleFormat1
Lines 2354-2360 Link Here
2354
  REQUIRES org.openide.text (platform)
2346
  REQUIRES org.openide.text (platform)
2355
  REQUIRES org.openide.util (platform)
2347
  REQUIRES org.openide.util (platform)
2356
  REQUIRES org.openide.windows (platform)
2348
  REQUIRES org.openide.windows (platform)
2357
  REQUIRES org.netbeans.core.output2/1 (platform)
2358
MODULE org.netbeans.modules.xml.multiview/1 (j2ee)
2349
MODULE org.netbeans.modules.xml.multiview/1 (j2ee)
2359
  REQUIRES org.netbeans.core.multiview/1 (platform)
2350
  REQUIRES org.netbeans.core.multiview/1 (platform)
2360
  REQUIRES org.netbeans.modules.xml.core/2 (ide)
2351
  REQUIRES org.netbeans.modules.xml.core/2 (ide)
(-)java/project/manifest.mf (-1 lines)
Lines 3-7 Link Here
3
OpenIDE-Module-Layer: org/netbeans/modules/java/project/layer.xml
3
OpenIDE-Module-Layer: org/netbeans/modules/java/project/layer.xml
4
OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/java/project/Bundle.properties
4
OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/java/project/Bundle.properties
5
OpenIDE-Module-Specification-Version: 1.10
5
OpenIDE-Module-Specification-Version: 1.10
6
OpenIDE-Module-Requires: org.netbeans.modules.project.uiapi.ActionsFactory
7
6
(-)java/project/nbproject/project.xml (+1 lines)
Lines 85-90 Link Here
85
                    <compile-dependency/>
85
                    <compile-dependency/>
86
                    <run-dependency>
86
                    <run-dependency>
87
                        <release-version>1</release-version>
87
                        <release-version>1</release-version>
88
                        <specification-version>1.16</specification-version>
88
                    </run-dependency>
89
                    </run-dependency>
89
                </dependency>
90
                </dependency>
90
                <dependency>
91
                <dependency>
(-)openide/execution/manifest.mf (-2 / +2 lines)
Lines 1-5 Link Here
1
Manifest-Version: 1.0
1
Manifest-Version: 1.0
2
OpenIDE-Module: org.openide.execution
2
OpenIDE-Module: org.openide.execution
3
OpenIDE-Module-Specification-Version: 1.9
3
OpenIDE-Module-Specification-Version: 1.10
4
OpenIDE-Module-Localizing-Bundle: org/openide/execution/Bundle.properties
4
OpenIDE-Module-Localizing-Bundle: org/openide/execution/Bundle.properties
5
5
OpenIDE-Module-Recommends: org.openide.execution.ExecutionEngine
(-)openide/execution/api/doc/changes/apichanges.xml (+18 lines)
Lines 31-36 Link Here
31
    <!-- ACTUAL CHANGES BEGIN HERE: -->
31
    <!-- ACTUAL CHANGES BEGIN HERE: -->
32
32
33
    <changes>
33
    <changes>
34
    <change id="automatic-request-of-engine-impl">
35
      <api name="io"/>
36
      <summary> No need to require ExecutionEngine token anymore</summary>
37
      <version major="1" minor="10"/>
38
      <date day="25" month="7" year="2006"/>
39
      <author login="jtulach"/>
40
      <compatibility addition="yes" binary="compatible" semantic="compatible" />
41
      <description>
42
        <p>If your module depends on <code>org.openide.execution > 1.9</code> or higher
43
        there is no need to specify that it also requires an implementation of
44
        the API by use of <code>OpenIDE-Module-Requires: org.openide.execution.ExecutionEngine</code>,
45
        this token will be requested automatically by the <code>org.openide.execution</code>
46
        module itself.
47
        </p>
48
      </description>
49
      <class package="org.openide.windows" name="IOProvider"/>
50
      <issue number="34699" />
51
    </change>
34
52
35
        <change>
53
        <change>
36
            <api name="execution"/>
54
            <api name="execution"/>
(-)openide/io/manifest.mf (-1 / +2 lines)
Lines 1-5 Link Here
1
Manifest-Version: 1.0
1
Manifest-Version: 1.0
2
OpenIDE-Module: org.openide.io
2
OpenIDE-Module: org.openide.io
3
OpenIDE-Module-Specification-Version: 1.10
3
OpenIDE-Module-Specification-Version: 1.11
4
OpenIDE-Module-Localizing-Bundle: org/openide/io/Bundle.properties
4
OpenIDE-Module-Localizing-Bundle: org/openide/io/Bundle.properties
5
OpenIDE-Module-Recommends: org.openide.windows.IOProvider
5
6
(-)openide/io/api/doc/changes/changes.xml (+19 lines)
Lines 81-86 Link Here
81
    <!-- ACTUAL CHANGES BEGIN HERE: -->
81
    <!-- ACTUAL CHANGES BEGIN HERE: -->
82
82
83
<changes>
83
<changes>
84
    <change id="automatic-request-of-io-impl">
85
      <api name="io"/>
86
      <summary> No need to require IOProvider token anymore</summary>
87
      <version major="1" minor="11"/>
88
      <date day="25" month="7" year="2006"/>
89
      <author login="jtulach"/>
90
      <compatibility addition="yes" binary="compatible" semantic="compatible" />
91
      <description>
92
        <p>If your module depends on <code>org.openide.io > 1.11</code> or higher
93
        there is no need to specify that it also requires an implementation of
94
        the API by use of <code>OpenIDE-Module-Requires: org.openide.windows.IOProvider</code>,
95
        this token will be requested automatically by the <code>org.openide.io</code>
96
        module itself.
97
        </p>
98
      </description>
99
      <class package="org.openide.windows" name="IOProvider"/>
100
      <issue number="34699" />
101
    </change>
102
84
    <change id="allow-to-add-actions-to-toolbar">
103
    <change id="allow-to-add-actions-to-toolbar">
85
      <api name="io"/>
104
      <api name="io"/>
86
      <summary> Added API to add actions to output's toolbar</summary>
105
      <summary> Added API to add actions to output's toolbar</summary>
(-)openide/io/src/org/openide/windows/IOProvider.java (-5 / +1 lines)
Lines 45-54 Link Here
45
     * instance in lookup, a fallback instance is created which just uses the
45
     * instance in lookup, a fallback instance is created which just uses the
46
     * standard system I/O streams. This is useful for unit tests and perhaps
46
     * standard system I/O streams. This is useful for unit tests and perhaps
47
     * for standalone usage of various libraries.
47
     * for standalone usage of various libraries.
48
     * <p>
49
     * Assuming you want to ensure that a real output window implementation is actually
50
     * installed and enabled, you must require the token <code>org.openide.windows.IOProvider</code>
51
     * from the module calling this method.
52
     * @return the default instance (never null)
48
     * @return the default instance (never null)
53
     */
49
     */
54
    public static IOProvider getDefault() {
50
    public static IOProvider getDefault() {
Lines 67-73 Link Here
67
     * the output window.  Streams for reading/writing can be accessed via
63
     * the output window.  Streams for reading/writing can be accessed via
68
     * getters on the returned instance.
64
     * getters on the returned instance.
69
     *
65
     *
70
     * @param name A localized display name for the tab
66
     * @param name A localised display name for the tab
71
     * @param newIO if <tt>true</tt>, a new <code>InputOutput</code> is returned, else an existing <code>InputOutput</code> of the same name may be returned
67
     * @param newIO if <tt>true</tt>, a new <code>InputOutput</code> is returned, else an existing <code>InputOutput</code> of the same name may be returned
72
     * @return an <code>InputOutput</code> instance for accessing the new tab
68
     * @return an <code>InputOutput</code> instance for accessing the new tab
73
     * @see InputOutput
69
     * @see InputOutput
(-)openide/modules/apichanges.xml (+16 lines)
Lines 24-29 Link Here
24
  	<apidef name="modules">Modules API</apidef>
24
  	<apidef name="modules">Modules API</apidef>
25
  </apidefs>
25
  </apidefs>
26
<changes>
26
<changes>
27
    <change id="needs">
28
        <api name="modules"/>
29
        <summary>Requires/Provides and Needs</summary>
30
        <version major="7" minor="1"/>
31
        <date day="12" month="7" year="2006"/>
32
        <author login="jtulach"/>
33
        <compatibility binary="compatible" source="compatible" semantic="compatible" deprecation="no" addition="yes" deletion="no" modification="no"/>
34
        <description>
35
            It is possible to require some implementation using
36
            <code>OpenIDE-Module-Needs: token</code> which is slightly
37
            less restrictive than usual
38
            <code>OpenIDE-Module-Requires: token</code> as
39
            explain in the <a href="@TOP@/org/openide/modules/doc-files/api.html#7.1">documentation</a>.
40
        </description>
41
        <class package="org.openide.modules" name="Dependency"/>
42
    </change>
27
    <change id="generified">
43
    <change id="generified">
28
        <api name="modules"/>
44
        <api name="modules"/>
29
        <summary>Generified Interfaces</summary>
45
        <summary>Generified Interfaces</summary>
(-)openide/modules/manifest.mf (-1 / +1 lines)
Lines 1-5 Link Here
1
Manifest-Version: 1.0
1
Manifest-Version: 1.0
2
OpenIDE-Module: org.openide.modules
2
OpenIDE-Module: org.openide.modules
3
OpenIDE-Module-Localizing-Bundle: org/openide/modules/Bundle.properties
3
OpenIDE-Module-Localizing-Bundle: org/openide/modules/Bundle.properties
4
OpenIDE-Module-Specification-Version: 7.0
4
OpenIDE-Module-Specification-Version: 7.1
5
5
(-)openide/modules/src/org/openide/modules/Dependency.java (+27 lines)
Lines 53-58 Link Here
53
     */
53
     */
54
    public final static int TYPE_REQUIRES = 5;
54
    public final static int TYPE_REQUIRES = 5;
55
55
56
    /** Dependency on a token, but without need to have token provider be initialised sooner.
57
     * @see ModuleInfo#getProvides
58
     * @since 7.1
59
     */
60
    public final static int TYPE_NEEDS = 6;
61
62
    /** An advisory dependency on a token. If at least one provider of such token is 
63
     * available, it is enabled. If there is no such provider, then nothing is done
64
     * or reported.
65
     *
66
     * @see ModuleInfo#getProvides
67
     * @since 7.1
68
     */
69
    public final static int TYPE_RECOMMENDS = 7;
70
56
    /** Comparison by specification version. */
71
    /** Comparison by specification version. */
57
    public final static int COMPARE_SPEC = 1;
72
    public final static int COMPARE_SPEC = 1;
58
73
Lines 316-321 Link Here
316
            } else if (type == Dependency.TYPE_REQUIRES) {
331
            } else if (type == Dependency.TYPE_REQUIRES) {
317
                if (comparison != Dependency.COMPARE_ANY) {
332
                if (comparison != Dependency.COMPARE_ANY) {
318
                    throw new IllegalArgumentException("Cannot give a comparison for a token requires dep: " + body); // NOI18N
333
                    throw new IllegalArgumentException("Cannot give a comparison for a token requires dep: " + body); // NOI18N
334
                }
335
336
                checkCodeName(name, false);
337
            } else if (type == Dependency.TYPE_NEEDS) {
338
                if (comparison != Dependency.COMPARE_ANY) {
339
                    throw new IllegalArgumentException("Cannot give a comparison for a token needs dep: " + body); // NOI18N
340
                }
341
342
                checkCodeName(name, false);
343
            } else if (type == Dependency.TYPE_RECOMMENDS) {
344
                if (comparison != Dependency.COMPARE_ANY) {
345
                    throw new IllegalArgumentException("Cannot give a comparison for a token needs dep: " + body); // NOI18N
319
                }
346
                }
320
347
321
                checkCodeName(name, false);
348
                checkCodeName(name, false);
(-)openide/modules/src/org/openide/modules/doc-files/api.html (-1 / +12 lines)
Lines 774-781 Link Here
774
be supplied to the lookup system, though there could be other meanings. A module
774
be supplied to the lookup system, though there could be other meanings. A module
775
may also <em>require</em> one or more tokens. A module which requires some tokens
775
may also <em>require</em> one or more tokens. A module which requires some tokens
776
may only be enabled by the system if for each such token, there is at least one other
776
may only be enabled by the system if for each such token, there is at least one other
777
module which provides that token and is already enabled.
777
module which provides that token and is already enabled. 
778
778
779
<a name="7.1"></a>
780
Since version 7.1 there is also support for <code>OpenIDE-Module-Needs</code>
781
which is a weaker version of requires as it does not impose any restriction on
782
the ordering of module. The <code>OpenIDE-Module-Needs</code> is useful for
783
modules that define some API and require an implementation of it. Just 
784
specify the <q>need</q> for an implementation and make other modules depend
785
on your module and <code>OpenIDE-Module-Provides</code> the implementation token.
786
Moreover there is also <code>OpenIDE-Module-Recommends</code> which is even
787
weaker version as it creates a conditional dependency - e.g. enables the module
788
providing the token only if it is available, however if it is not, no dependency
789
is broken.
779
</ol>
790
</ol>
780
791
781
At the heart of all these tags are the conventions used in the 
792
At the heart of all these tags are the conventions used in the 
(-)platform/samples/minicomposer/manifest.mf (-1 / +1 lines)
Lines 2-8 Link Here
2
OpenIDE-Module: org.netbeans.examples.modules.minicomposer
2
OpenIDE-Module: org.netbeans.examples.modules.minicomposer
3
OpenIDE-Module-Localizing-Bundle: org/netbeans/examples/modules/minicomposer/resources/Bundle.properties
3
OpenIDE-Module-Localizing-Bundle: org/netbeans/examples/modules/minicomposer/resources/Bundle.properties
4
OpenIDE-Module-Specification-Version: 1.2
4
OpenIDE-Module-Specification-Version: 1.2
5
OpenIDE-Module-Requires: org.netbeans.api.javahelp.Help, org.openide.windows.IOProvider
5
OpenIDE-Module-Requires: org.netbeans.api.javahelp.Help
6
OpenIDE-Module-Layer: org/netbeans/examples/modules/minicomposer/resources/layer.xml
6
OpenIDE-Module-Layer: org/netbeans/examples/modules/minicomposer/resources/layer.xml
7
7
8
Name: org/netbeans/examples/modules/minicomposer/ScoreDataLoader.class
8
Name: org/netbeans/examples/modules/minicomposer/ScoreDataLoader.class
(-)platform/samples/minicomposer/nbproject/project.xml (-1 / +1 lines)
Lines 104-110 Link Here
104
                    <build-prerequisite/>
104
                    <build-prerequisite/>
105
                    <compile-dependency/>
105
                    <compile-dependency/>
106
                    <run-dependency>
106
                    <run-dependency>
107
                        <specification-version>1.0</specification-version>
107
                        <specification-version>1.11</specification-version>
108
                    </run-dependency>
108
                    </run-dependency>
109
                </dependency>
109
                </dependency>
110
                <dependency>
110
                <dependency>
(-)projects/projectui/manifest.mf (-1 / +4 lines)
Lines 4-8 Link Here
4
OpenIDE-Module-Install: org/netbeans/modules/project/ui/ProjectUiModule.class
4
OpenIDE-Module-Install: org/netbeans/modules/project/ui/ProjectUiModule.class
5
OpenIDE-Module-Layer: org/netbeans/modules/project/ui/resources/layer.xml
5
OpenIDE-Module-Layer: org/netbeans/modules/project/ui/resources/layer.xml
6
OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/project/ui/Bundle.properties
6
OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/project/ui/Bundle.properties
7
OpenIDE-Module-Provides: org.netbeans.modules.project.uiapi.ActionsFactory, org.netbeans.modules.project.uiapi.OpenProjectsTrampoline, org.netbeans.modules.project.uiapi.ProjectChooserFactory
7
OpenIDE-Module-Provides: 
8
   org.netbeans.modules.project.uiapi.ActionsFactory, 
9
   org.netbeans.modules.project.uiapi.OpenProjectsTrampoline,
10
   org.netbeans.modules.project.uiapi.ProjectChooserFactory
8
11
(-)projects/projectuiapi/manifest.mf (-1 / +3 lines)
Lines 2-5 Link Here
2
OpenIDE-Module: org.netbeans.modules.projectuiapi/1
2
OpenIDE-Module: org.netbeans.modules.projectuiapi/1
3
OpenIDE-Module-Implementation-Version: 5
3
OpenIDE-Module-Implementation-Version: 5
4
OpenIDE-Module-Localizing-Bundle: org/netbeans/spi/project/ui/Bundle.properties
4
OpenIDE-Module-Localizing-Bundle: org/netbeans/spi/project/ui/Bundle.properties
5
5
OpenIDE-Module-Needs: org.netbeans.modules.project.uiapi.ActionsFactory,
6
    org.netbeans.modules.project.uiapi.OpenProjectsTrampoline,
7
    org.netbeans.modules.project.uiapi.ProjectChooserFactory
(-)projects/projectuiapi/nbproject/project.properties (-1 / +1 lines)
Lines 15-21 Link Here
15
# Software is Sun Microsystems, Inc. Portions Copyright 1997-2006 Sun
15
# Software is Sun Microsystems, Inc. Portions Copyright 1997-2006 Sun
16
# Microsystems, Inc. All Rights Reserved.
16
# Microsystems, Inc. All Rights Reserved.
17
17
18
spec.version.base=1.15.0
18
spec.version.base=1.16.0
19
is.autoload=true
19
is.autoload=true
20
javadoc.title=Project UI API
20
javadoc.title=Project UI API
21
javadoc.arch=${basedir}/arch.xml
21
javadoc.arch=${basedir}/arch.xml
(-)utilities/manifest.mf (-1 / +1 lines)
Lines 4-10 Link Here
4
OpenIDE-Module-Specification-Version: 1.22
4
OpenIDE-Module-Specification-Version: 1.22
5
OpenIDE-Module-Install: org/netbeans/modules/utilities/Installer.class
5
OpenIDE-Module-Install: org/netbeans/modules/utilities/Installer.class
6
OpenIDE-Module-Layer: org/netbeans/modules/utilities/Layer.xml
6
OpenIDE-Module-Layer: org/netbeans/modules/utilities/Layer.xml
7
OpenIDE-Module-Requires: org.openide.windows.IOProvider, org.openide.modules.InstalledFileLocator
7
OpenIDE-Module-Requires: org.openide.modules.InstalledFileLocator
8
8
9
Name: org/netbeans/modules/url/URLDataLoader.class
9
Name: org/netbeans/modules/url/URLDataLoader.class
10
OpenIDE-Module-Class: Loader
10
OpenIDE-Module-Class: Loader
(-)utilities/nbproject/project.xml (-1 / +1 lines)
Lines 85-91 Link Here
85
                    <build-prerequisite/>
85
                    <build-prerequisite/>
86
                    <compile-dependency/>
86
                    <compile-dependency/>
87
                    <run-dependency>
87
                    <run-dependency>
88
                        <specification-version>1.0</specification-version>
88
                        <specification-version>1.11</specification-version>
89
                    </run-dependency>
89
                    </run-dependency>
90
                </dependency>
90
                </dependency>
91
                <dependency>
91
                <dependency>
(-)vcscore/manifest.mf (-1 lines)
Lines 3-8 Link Here
3
OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/vcscore/Bundle.properties
3
OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/vcscore/Bundle.properties
4
OpenIDE-Module-Implementation-Version: 42
4
OpenIDE-Module-Implementation-Version: 42
5
OpenIDE-Module-Layer: org/netbeans/modules/vcscore/resources/mf-layer.xml
5
OpenIDE-Module-Layer: org/netbeans/modules/vcscore/resources/mf-layer.xml
6
OpenIDE-Module-Requires: org.openide.windows.IOProvider
7
OpenIDE-Module-Install: org/netbeans/modules/vcscore/VcsModule.class
6
OpenIDE-Module-Install: org/netbeans/modules/vcscore/VcsModule.class
8
7
(-)vcscore/nbproject/project.xml (-31 / +31 lines)
Lines 24-46 Link Here
24
            <code-name-base>org.netbeans.modules.vcscore</code-name-base>
24
            <code-name-base>org.netbeans.modules.vcscore</code-name-base>
25
            <module-dependencies>
25
            <module-dependencies>
26
                <dependency>
26
                <dependency>
27
                    <code-name-base>org.openide.filesystems</code-name-base>
27
                    <code-name-base>org.netbeans.modules.masterfs</code-name-base>
28
                    <build-prerequisite/>
28
                    <build-prerequisite/>
29
                    <compile-dependency/>
29
                    <compile-dependency/>
30
                    <run-dependency>
30
                    <run-dependency>
31
                        <specification-version>6.2</specification-version>
31
                        <release-version>1</release-version>
32
                        <specification-version>1.1</specification-version>
32
                    </run-dependency>
33
                    </run-dependency>
33
                </dependency>
34
                </dependency>
34
                <dependency>
35
                <dependency>
35
                    <code-name-base>org.openide.util</code-name-base>
36
                    <code-name-base>org.netbeans.modules.queries</code-name-base>
36
                    <build-prerequisite/>
37
                    <build-prerequisite/>
37
                    <compile-dependency/>
38
                    <compile-dependency/>
38
                    <run-dependency>
39
                    <run-dependency>
39
                        <specification-version>6.2</specification-version>
40
                        <release-version>1</release-version>
41
                        <specification-version>1.4</specification-version>
40
                    </run-dependency>
42
                    </run-dependency>
41
                </dependency>
43
                </dependency>
42
                <dependency>
44
                <dependency>
43
                    <code-name-base>org.openide.modules</code-name-base>
45
                    <code-name-base>org.openide.actions</code-name-base>
44
                    <build-prerequisite/>
46
                    <build-prerequisite/>
45
                    <compile-dependency/>
47
                    <compile-dependency/>
46
                    <run-dependency>
48
                    <run-dependency>
Lines 48-54 Link Here
48
                    </run-dependency>
50
                    </run-dependency>
49
                </dependency>
51
                </dependency>
50
                <dependency>
52
                <dependency>
51
                    <code-name-base>org.openide.nodes</code-name-base>
53
                    <code-name-base>org.openide.awt</code-name-base>
52
                    <build-prerequisite/>
54
                    <build-prerequisite/>
53
                    <compile-dependency/>
55
                    <compile-dependency/>
54
                    <run-dependency>
56
                    <run-dependency>
Lines 56-62 Link Here
56
                    </run-dependency>
58
                    </run-dependency>
57
                </dependency>
59
                </dependency>
58
                <dependency>
60
                <dependency>
59
                    <code-name-base>org.openide.explorer</code-name-base>
61
                    <code-name-base>org.openide.compat</code-name-base>
60
                    <build-prerequisite/>
62
                    <build-prerequisite/>
61
                    <compile-dependency/>
63
                    <compile-dependency/>
62
                    <run-dependency>
64
                    <run-dependency>
Lines 64-70 Link Here
64
                    </run-dependency>
66
                    </run-dependency>
65
                </dependency>
67
                </dependency>
66
                <dependency>
68
                <dependency>
67
                    <code-name-base>org.openide.awt</code-name-base>
69
                    <code-name-base>org.openide.dialogs</code-name-base>
68
                    <build-prerequisite/>
70
                    <build-prerequisite/>
69
                    <compile-dependency/>
71
                    <compile-dependency/>
70
                    <run-dependency>
72
                    <run-dependency>
Lines 72-86 Link Here
72
                    </run-dependency>
74
                    </run-dependency>
73
                </dependency>
75
                </dependency>
74
                <dependency>
76
                <dependency>
75
                    <code-name-base>org.openide.dialogs</code-name-base>
77
                    <code-name-base>org.openide.execution</code-name-base>
76
                    <build-prerequisite/>
78
                    <build-prerequisite/>
77
                    <compile-dependency/>
79
                    <compile-dependency/>
78
                    <run-dependency>
80
                    <run-dependency>
79
                        <specification-version>6.2</specification-version>
81
                        <specification-version>1.2</specification-version>
80
                    </run-dependency>
82
                    </run-dependency>
81
                </dependency>
83
                </dependency>
82
                <dependency>
84
                <dependency>
83
                    <code-name-base>org.openide.compat</code-name-base>
85
                    <code-name-base>org.openide.explorer</code-name-base>
84
                    <build-prerequisite/>
86
                    <build-prerequisite/>
85
                    <compile-dependency/>
87
                    <compile-dependency/>
86
                    <run-dependency>
88
                    <run-dependency>
Lines 88-94 Link Here
88
                    </run-dependency>
90
                    </run-dependency>
89
                </dependency>
91
                </dependency>
90
                <dependency>
92
                <dependency>
91
                    <code-name-base>org.openide.options</code-name-base>
93
                    <code-name-base>org.openide.filesystems</code-name-base>
92
                    <build-prerequisite/>
94
                    <build-prerequisite/>
93
                    <compile-dependency/>
95
                    <compile-dependency/>
94
                    <run-dependency>
96
                    <run-dependency>
Lines 96-118 Link Here
96
                    </run-dependency>
98
                    </run-dependency>
97
                </dependency>
99
                </dependency>
98
                <dependency>
100
                <dependency>
99
                    <code-name-base>org.openide.windows</code-name-base>
101
                    <code-name-base>org.openide.io</code-name-base>
100
                    <build-prerequisite/>
102
                    <build-prerequisite/>
101
                    <compile-dependency/>
103
                    <compile-dependency/>
102
                    <run-dependency>
104
                    <run-dependency>
103
                        <specification-version>6.2</specification-version>
105
                        <specification-version>1.11</specification-version>
104
                    </run-dependency>
106
                    </run-dependency>
105
                </dependency>
107
                </dependency>
106
                <dependency>
108
                <dependency>
107
                    <code-name-base>org.openide.text</code-name-base>
109
                    <code-name-base>org.openide.loaders</code-name-base>
108
                    <build-prerequisite/>
110
                    <build-prerequisite/>
109
                    <compile-dependency/>
111
                    <compile-dependency/>
110
                    <run-dependency>
112
                    <run-dependency>
111
                        <specification-version>6.2</specification-version>
113
                        <specification-version>4.11</specification-version>
112
                    </run-dependency>
114
                    </run-dependency>
113
                </dependency>
115
                </dependency>
114
                <dependency>
116
                <dependency>
115
                    <code-name-base>org.openide.actions</code-name-base>
117
                    <code-name-base>org.openide.modules</code-name-base>
116
                    <build-prerequisite/>
118
                    <build-prerequisite/>
117
                    <compile-dependency/>
119
                    <compile-dependency/>
118
                    <run-dependency>
120
                    <run-dependency>
Lines 120-172 Link Here
120
                    </run-dependency>
122
                    </run-dependency>
121
                </dependency>
123
                </dependency>
122
                <dependency>
124
                <dependency>
123
                    <code-name-base>org.openide.execution</code-name-base>
125
                    <code-name-base>org.openide.nodes</code-name-base>
124
                    <build-prerequisite/>
126
                    <build-prerequisite/>
125
                    <compile-dependency/>
127
                    <compile-dependency/>
126
                    <run-dependency>
128
                    <run-dependency>
127
                        <specification-version>1.2</specification-version>
129
                        <specification-version>6.2</specification-version>
128
                    </run-dependency>
130
                    </run-dependency>
129
                </dependency>
131
                </dependency>
130
                <dependency>
132
                <dependency>
131
                    <code-name-base>org.openide.io</code-name-base>
133
                    <code-name-base>org.openide.options</code-name-base>
132
                    <build-prerequisite/>
134
                    <build-prerequisite/>
133
                    <compile-dependency/>
135
                    <compile-dependency/>
134
                    <run-dependency>
136
                    <run-dependency>
135
                        <specification-version>1.0</specification-version>
137
                        <specification-version>6.2</specification-version>
136
                    </run-dependency>
138
                    </run-dependency>
137
                </dependency>
139
                </dependency>
138
                <dependency>
140
                <dependency>
139
                    <code-name-base>org.openide.loaders</code-name-base>
141
                    <code-name-base>org.openide.text</code-name-base>
140
                    <build-prerequisite/>
142
                    <build-prerequisite/>
141
                    <compile-dependency/>
143
                    <compile-dependency/>
142
                    <run-dependency>
144
                    <run-dependency>
143
                        <specification-version>4.11</specification-version>
145
                        <specification-version>6.2</specification-version>
144
                    </run-dependency>
146
                    </run-dependency>
145
                </dependency>
147
                </dependency>
146
                <dependency>
148
                <dependency>
147
                    <code-name-base>org.openidex.util</code-name-base>
149
                    <code-name-base>org.openide.util</code-name-base>
148
                    <build-prerequisite/>
150
                    <build-prerequisite/>
149
                    <compile-dependency/>
151
                    <compile-dependency/>
150
                    <run-dependency>
152
                    <run-dependency>
151
                        <release-version>2-3</release-version>
153
                        <specification-version>6.2</specification-version>
152
                    </run-dependency>
154
                    </run-dependency>
153
                </dependency>
155
                </dependency>
154
                <dependency>
156
                <dependency>
155
                    <code-name-base>org.netbeans.modules.masterfs</code-name-base>
157
                    <code-name-base>org.openide.windows</code-name-base>
156
                    <build-prerequisite/>
158
                    <build-prerequisite/>
157
                    <compile-dependency/>
159
                    <compile-dependency/>
158
                    <run-dependency>
160
                    <run-dependency>
159
                        <release-version>1</release-version>
161
                        <specification-version>6.2</specification-version>
160
                        <specification-version>1.1</specification-version>
161
                    </run-dependency>
162
                    </run-dependency>
162
                </dependency>
163
                </dependency>
163
                <dependency>
164
                <dependency>
164
                    <code-name-base>org.netbeans.modules.queries</code-name-base>
165
                    <code-name-base>org.openidex.util</code-name-base>
165
                    <build-prerequisite/>
166
                    <build-prerequisite/>
166
                    <compile-dependency/>
167
                    <compile-dependency/>
167
                    <run-dependency>
168
                    <run-dependency>
168
                        <release-version>1</release-version>
169
                        <release-version>2-3</release-version>
169
                        <specification-version>1.4</specification-version>
170
                    </run-dependency>
170
                    </run-dependency>
171
                </dependency>
171
                </dependency>
172
            </module-dependencies>
172
            </module-dependencies>
(-)vcsgeneric/manifest.mf (-1 / +1 lines)
Lines 1-7 Link Here
1
Manifest-Version: 1.0
1
Manifest-Version: 1.0
2
OpenIDE-Module: org.netbeans.modules.vcs.advanced/1
2
OpenIDE-Module: org.netbeans.modules.vcs.advanced/1
3
OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/vcs/advanced/config/Bundle.properties
3
OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/vcs/advanced/config/Bundle.properties
4
OpenIDE-Module-Requires: org.openide.windows.IOProvider, org.netbeans.modules.vcscore.javacorebridge, org.netbeans.modules.refactoring.vcs
4
OpenIDE-Module-Requires: org.netbeans.modules.vcscore.javacorebridge, org.netbeans.modules.refactoring.vcs
5
OpenIDE-Module-Layer: org/netbeans/modules/vcs/advanced/config/mf-layer.xml
5
OpenIDE-Module-Layer: org/netbeans/modules/vcs/advanced/config/mf-layer.xml
6
OpenIDE-Module-Install: org/netbeans/modules/vcs/advanced/ModuleLifecycleManager.class
6
OpenIDE-Module-Install: org/netbeans/modules/vcs/advanced/ModuleLifecycleManager.class
7
7
(-)vcsgeneric/nbproject/project.xml (-28 / +28 lines)
Lines 24-54 Link Here
24
            <code-name-base>org.netbeans.modules.vcs.advanced</code-name-base>
24
            <code-name-base>org.netbeans.modules.vcs.advanced</code-name-base>
25
            <module-dependencies>
25
            <module-dependencies>
26
                <dependency>
26
                <dependency>
27
                    <code-name-base>org.openide.filesystems</code-name-base>
27
                    <code-name-base>org.netbeans.modules.diff</code-name-base>
28
                    <build-prerequisite/>
28
                    <build-prerequisite/>
29
                    <compile-dependency/>
29
                    <compile-dependency/>
30
                    <run-dependency>
30
                    <run-dependency>
31
                        <specification-version>6.2</specification-version>
31
                        <release-version>1</release-version>
32
                        <implementation-version/>
32
                    </run-dependency>
33
                    </run-dependency>
33
                </dependency>
34
                </dependency>
34
                <dependency>
35
                <dependency>
35
                    <code-name-base>org.openide.util</code-name-base>
36
                    <code-name-base>org.netbeans.modules.queries</code-name-base>
36
                    <build-prerequisite/>
37
                    <build-prerequisite/>
37
                    <compile-dependency/>
38
                    <compile-dependency/>
38
                    <run-dependency>
39
                    <run-dependency>
39
                        <specification-version>6.2</specification-version>
40
                        <release-version>1</release-version>
41
                        <specification-version>1.3</specification-version>
40
                    </run-dependency>
42
                    </run-dependency>
41
                </dependency>
43
                </dependency>
42
                <dependency>
44
                <dependency>
43
                    <code-name-base>org.openide.modules</code-name-base>
45
                    <code-name-base>org.netbeans.modules.vcscore</code-name-base>
44
                    <build-prerequisite/>
46
                    <build-prerequisite/>
45
                    <compile-dependency/>
47
                    <compile-dependency/>
46
                    <run-dependency>
48
                    <run-dependency>
47
                        <specification-version>6.2</specification-version>
49
                        <release-version>1</release-version>
50
                        <implementation-version/>
48
                    </run-dependency>
51
                    </run-dependency>
49
                </dependency>
52
                </dependency>
50
                <dependency>
53
                <dependency>
51
                    <code-name-base>org.openide.nodes</code-name-base>
54
                    <code-name-base>org.openide.actions</code-name-base>
52
                    <build-prerequisite/>
55
                    <build-prerequisite/>
53
                    <compile-dependency/>
56
                    <compile-dependency/>
54
                    <run-dependency>
57
                    <run-dependency>
Lines 56-62 Link Here
56
                    </run-dependency>
59
                    </run-dependency>
57
                </dependency>
60
                </dependency>
58
                <dependency>
61
                <dependency>
59
                    <code-name-base>org.openide.explorer</code-name-base>
62
                    <code-name-base>org.openide.awt</code-name-base>
60
                    <build-prerequisite/>
63
                    <build-prerequisite/>
61
                    <compile-dependency/>
64
                    <compile-dependency/>
62
                    <run-dependency>
65
                    <run-dependency>
Lines 64-70 Link Here
64
                    </run-dependency>
67
                    </run-dependency>
65
                </dependency>
68
                </dependency>
66
                <dependency>
69
                <dependency>
67
                    <code-name-base>org.openide.awt</code-name-base>
70
                    <code-name-base>org.openide.compat</code-name-base>
68
                    <build-prerequisite/>
71
                    <build-prerequisite/>
69
                    <compile-dependency/>
72
                    <compile-dependency/>
70
                    <run-dependency>
73
                    <run-dependency>
Lines 80-86 Link Here
80
                    </run-dependency>
83
                    </run-dependency>
81
                </dependency>
84
                </dependency>
82
                <dependency>
85
                <dependency>
83
                    <code-name-base>org.openide.compat</code-name-base>
86
                    <code-name-base>org.openide.explorer</code-name-base>
84
                    <build-prerequisite/>
87
                    <build-prerequisite/>
85
                    <compile-dependency/>
88
                    <compile-dependency/>
86
                    <run-dependency>
89
                    <run-dependency>
Lines 88-94 Link Here
88
                    </run-dependency>
91
                    </run-dependency>
89
                </dependency>
92
                </dependency>
90
                <dependency>
93
                <dependency>
91
                    <code-name-base>org.openide.options</code-name-base>
94
                    <code-name-base>org.openide.filesystems</code-name-base>
92
                    <build-prerequisite/>
95
                    <build-prerequisite/>
93
                    <compile-dependency/>
96
                    <compile-dependency/>
94
                    <run-dependency>
97
                    <run-dependency>
Lines 96-157 Link Here
96
                    </run-dependency>
99
                    </run-dependency>
97
                </dependency>
100
                </dependency>
98
                <dependency>
101
                <dependency>
99
                    <code-name-base>org.openide.windows</code-name-base>
102
                    <code-name-base>org.openide.io</code-name-base>
100
                    <build-prerequisite/>
103
                    <build-prerequisite/>
101
                    <compile-dependency/>
104
                    <compile-dependency/>
102
                    <run-dependency>
105
                    <run-dependency>
103
                        <specification-version>6.2</specification-version>
106
                        <specification-version>1.11</specification-version>
104
                    </run-dependency>
107
                    </run-dependency>
105
                </dependency>
108
                </dependency>
106
                <dependency>
109
                <dependency>
107
                    <code-name-base>org.openide.actions</code-name-base>
110
                    <code-name-base>org.openide.loaders</code-name-base>
108
                    <build-prerequisite/>
111
                    <build-prerequisite/>
109
                    <compile-dependency/>
112
                    <compile-dependency/>
110
                    <run-dependency>
113
                    <run-dependency>
111
                        <specification-version>6.2</specification-version>
114
                        <specification-version>4.11</specification-version>
112
                    </run-dependency>
115
                    </run-dependency>
113
                </dependency>
116
                </dependency>
114
                <dependency>
117
                <dependency>
115
                    <code-name-base>org.netbeans.modules.vcscore</code-name-base>
118
                    <code-name-base>org.openide.modules</code-name-base>
116
                    <build-prerequisite/>
119
                    <build-prerequisite/>
117
                    <compile-dependency/>
120
                    <compile-dependency/>
118
                    <run-dependency>
121
                    <run-dependency>
119
                        <release-version>1</release-version>
122
                        <specification-version>6.2</specification-version>
120
                        <implementation-version/>
121
                    </run-dependency>
123
                    </run-dependency>
122
                </dependency>
124
                </dependency>
123
                <dependency>
125
                <dependency>
124
                    <code-name-base>org.netbeans.modules.diff</code-name-base>
126
                    <code-name-base>org.openide.nodes</code-name-base>
125
                    <build-prerequisite/>
127
                    <build-prerequisite/>
126
                    <compile-dependency/>
128
                    <compile-dependency/>
127
                    <run-dependency>
129
                    <run-dependency>
128
                        <release-version>1</release-version>
130
                        <specification-version>6.2</specification-version>
129
                        <implementation-version/>
130
                    </run-dependency>
131
                    </run-dependency>
131
                </dependency>
132
                </dependency>
132
                <dependency>
133
                <dependency>
133
                    <code-name-base>org.openide.io</code-name-base>
134
                    <code-name-base>org.openide.options</code-name-base>
134
                    <build-prerequisite/>
135
                    <build-prerequisite/>
135
                    <compile-dependency/>
136
                    <compile-dependency/>
136
                    <run-dependency>
137
                    <run-dependency>
137
                        <specification-version>1.0</specification-version>
138
                        <specification-version>6.2</specification-version>
138
                    </run-dependency>
139
                    </run-dependency>
139
                </dependency>
140
                </dependency>
140
                <dependency>
141
                <dependency>
141
                    <code-name-base>org.openide.loaders</code-name-base>
142
                    <code-name-base>org.openide.util</code-name-base>
142
                    <build-prerequisite/>
143
                    <build-prerequisite/>
143
                    <compile-dependency/>
144
                    <compile-dependency/>
144
                    <run-dependency>
145
                    <run-dependency>
145
                        <specification-version>4.11</specification-version>
146
                        <specification-version>6.2</specification-version>
146
                    </run-dependency>
147
                    </run-dependency>
147
                </dependency>
148
                </dependency>
148
                <dependency>
149
                <dependency>
149
                    <code-name-base>org.netbeans.modules.queries</code-name-base>
150
                    <code-name-base>org.openide.windows</code-name-base>
150
                    <build-prerequisite/>
151
                    <build-prerequisite/>
151
                    <compile-dependency/>
152
                    <compile-dependency/>
152
                    <run-dependency>
153
                    <run-dependency>
153
                        <release-version>1</release-version>
154
                        <specification-version>6.2</specification-version>
154
                        <specification-version>1.3</specification-version>
155
                    </run-dependency>
155
                    </run-dependency>
156
                </dependency>
156
                </dependency>
157
            </module-dependencies>
157
            </module-dependencies>
(-)web/jspparser/manifest.mf (-1 lines)
Lines 3-7 Link Here
3
OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/web/jspparser/Bundle.properties
3
OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/web/jspparser/Bundle.properties
4
OpenIDE-Module-Layer: org/netbeans/modules/web/jspparser/layer.xml
4
OpenIDE-Module-Layer: org/netbeans/modules/web/jspparser/layer.xml
5
OpenIDE-Module-Specification-Version: 2.6
5
OpenIDE-Module-Specification-Version: 2.6
6
OpenIDE-Module-Requires: org.openide.windows.IOProvider
7
6
(-)xml/core/manifest.mf (-1 lines)
Lines 4-10 Link Here
4
OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/xml/core/resources/Bundle.properties
4
OpenIDE-Module-Localizing-Bundle: org/netbeans/modules/xml/core/resources/Bundle.properties
5
OpenIDE-Module-Install: org/netbeans/modules/xml/core/CoreModuleInstall.class
5
OpenIDE-Module-Install: org/netbeans/modules/xml/core/CoreModuleInstall.class
6
OpenIDE-Module-Layer: org/netbeans/modules/xml/core/resources/mf-layer.xml
6
OpenIDE-Module-Layer: org/netbeans/modules/xml/core/resources/mf-layer.xml
7
OpenIDE-Module-Requires: org.openide.windows.IOProvider
8
7
9
Name: org/netbeans/modules/xml/core/XMLDataLoader.class
8
Name: org/netbeans/modules/xml/core/XMLDataLoader.class
10
OpenIDE-Module-Class: Loader
9
OpenIDE-Module-Class: Loader
(-)xml/core/nbproject/project.xml (-25 / +25 lines)
Lines 24-44 Link Here
24
            <code-name-base>org.netbeans.modules.xml.core</code-name-base>
24
            <code-name-base>org.netbeans.modules.xml.core</code-name-base>
25
            <module-dependencies>
25
            <module-dependencies>
26
                <dependency>
26
                <dependency>
27
                    <code-name-base>org.openide.loaders</code-name-base>
27
                    <code-name-base>org.netbeans.api.xml</code-name-base>
28
                    <build-prerequisite/>
28
                    <build-prerequisite/>
29
                    <compile-dependency/>
29
                    <compile-dependency/>
30
                    <run-dependency/>
30
                    <run-dependency>
31
                        <release-version>1</release-version>
32
                        <specification-version>1.10</specification-version>
33
                    </run-dependency>
31
                </dependency>
34
                </dependency>
32
                <dependency>
35
                <dependency>
33
                    <code-name-base>org.openide.filesystems</code-name-base>
36
                    <code-name-base>org.netbeans.spi.navigator</code-name-base>
34
                    <build-prerequisite/>
37
                    <build-prerequisite/>
35
                    <compile-dependency/>
38
                    <compile-dependency/>
36
                    <run-dependency>
39
                    <run-dependency>
37
                        <specification-version>6.2</specification-version>
40
                        <release-version>1</release-version>
38
                    </run-dependency>
41
                    </run-dependency>
39
                </dependency>
42
                </dependency>
40
                <dependency>
43
                <dependency>
41
                    <code-name-base>org.openide.util</code-name-base>
44
                    <code-name-base>org.openide.actions</code-name-base>
42
                    <build-prerequisite/>
45
                    <build-prerequisite/>
43
                    <compile-dependency/>
46
                    <compile-dependency/>
44
                    <run-dependency>
47
                    <run-dependency>
Lines 46-52 Link Here
46
                    </run-dependency>
49
                    </run-dependency>
47
                </dependency>
50
                </dependency>
48
                <dependency>
51
                <dependency>
49
                    <code-name-base>org.openide.modules</code-name-base>
52
                    <code-name-base>org.openide.awt</code-name-base>
50
                    <build-prerequisite/>
53
                    <build-prerequisite/>
51
                    <compile-dependency/>
54
                    <compile-dependency/>
52
                    <run-dependency>
55
                    <run-dependency>
Lines 54-60 Link Here
54
                    </run-dependency>
57
                    </run-dependency>
55
                </dependency>
58
                </dependency>
56
                <dependency>
59
                <dependency>
57
                    <code-name-base>org.openide.nodes</code-name-base>
60
                    <code-name-base>org.openide.dialogs</code-name-base>
58
                    <build-prerequisite/>
61
                    <build-prerequisite/>
59
                    <compile-dependency/>
62
                    <compile-dependency/>
60
                    <run-dependency>
63
                    <run-dependency>
Lines 62-68 Link Here
62
                    </run-dependency>
65
                    </run-dependency>
63
                </dependency>
66
                </dependency>
64
                <dependency>
67
                <dependency>
65
                    <code-name-base>org.openide.awt</code-name-base>
68
                    <code-name-base>org.openide.filesystems</code-name-base>
66
                    <build-prerequisite/>
69
                    <build-prerequisite/>
67
                    <compile-dependency/>
70
                    <compile-dependency/>
68
                    <run-dependency>
71
                    <run-dependency>
Lines 70-92 Link Here
70
                    </run-dependency>
73
                    </run-dependency>
71
                </dependency>
74
                </dependency>
72
                <dependency>
75
                <dependency>
73
                    <code-name-base>org.openide.dialogs</code-name-base>
76
                    <code-name-base>org.openide.io</code-name-base>
74
                    <build-prerequisite/>
77
                    <build-prerequisite/>
75
                    <compile-dependency/>
78
                    <compile-dependency/>
76
                    <run-dependency>
79
                    <run-dependency>
77
                        <specification-version>6.2</specification-version>
80
                        <specification-version>1.11</specification-version>
78
                    </run-dependency>
81
                    </run-dependency>
79
                </dependency>
82
                </dependency>
80
                <dependency>
83
                <dependency>
81
                    <code-name-base>org.openide.options</code-name-base>
84
                    <code-name-base>org.openide.loaders</code-name-base>
82
                    <build-prerequisite/>
85
                    <build-prerequisite/>
83
                    <compile-dependency/>
86
                    <compile-dependency/>
84
                    <run-dependency>
87
                    <run-dependency/>
85
                        <specification-version>6.2</specification-version>
86
                    </run-dependency>
87
                </dependency>
88
                </dependency>
88
                <dependency>
89
                <dependency>
89
                    <code-name-base>org.openide.windows</code-name-base>
90
                    <code-name-base>org.openide.modules</code-name-base>
90
                    <build-prerequisite/>
91
                    <build-prerequisite/>
91
                    <compile-dependency/>
92
                    <compile-dependency/>
92
                    <run-dependency>
93
                    <run-dependency>
Lines 94-100 Link Here
94
                    </run-dependency>
95
                    </run-dependency>
95
                </dependency>
96
                </dependency>
96
                <dependency>
97
                <dependency>
97
                    <code-name-base>org.openide.text</code-name-base>
98
                    <code-name-base>org.openide.nodes</code-name-base>
98
                    <build-prerequisite/>
99
                    <build-prerequisite/>
99
                    <compile-dependency/>
100
                    <compile-dependency/>
100
                    <run-dependency>
101
                    <run-dependency>
Lines 102-108 Link Here
102
                    </run-dependency>
103
                    </run-dependency>
103
                </dependency>
104
                </dependency>
104
                <dependency>
105
                <dependency>
105
                    <code-name-base>org.openide.actions</code-name-base>
106
                    <code-name-base>org.openide.options</code-name-base>
106
                    <build-prerequisite/>
107
                    <build-prerequisite/>
107
                    <compile-dependency/>
108
                    <compile-dependency/>
108
                    <run-dependency>
109
                    <run-dependency>
Lines 110-139 Link Here
110
                    </run-dependency>
111
                    </run-dependency>
111
                </dependency>
112
                </dependency>
112
                <dependency>
113
                <dependency>
113
                    <code-name-base>org.openide.io</code-name-base>
114
                    <code-name-base>org.openide.text</code-name-base>
114
                    <build-prerequisite/>
115
                    <build-prerequisite/>
115
                    <compile-dependency/>
116
                    <compile-dependency/>
116
                    <run-dependency>
117
                    <run-dependency>
117
                        <specification-version>1.0</specification-version>
118
                        <specification-version>6.2</specification-version>
118
                    </run-dependency>
119
                    </run-dependency>
119
                </dependency>
120
                </dependency>
120
                <dependency>
121
                <dependency>
121
                    <code-name-base>org.netbeans.api.xml</code-name-base>
122
                    <code-name-base>org.openide.util</code-name-base>
122
                    <build-prerequisite/>
123
                    <build-prerequisite/>
123
                    <compile-dependency/>
124
                    <compile-dependency/>
124
                    <run-dependency>
125
                    <run-dependency>
125
                        <release-version>1</release-version>
126
                        <specification-version>6.2</specification-version>
126
                        <specification-version>1.10</specification-version>
127
                    </run-dependency>
127
                    </run-dependency>
128
                </dependency>
128
                </dependency>
129
                <dependency>
129
                <dependency>
130
                    <code-name-base>org.netbeans.spi.navigator</code-name-base>
130
                    <code-name-base>org.openide.windows</code-name-base>
131
                    <build-prerequisite/>
131
                    <build-prerequisite/>
132
                    <compile-dependency/>
132
                    <compile-dependency/>
133
                    <run-dependency>
133
                    <run-dependency>
134
                    	<release-version>1</release-version>
134
                        <specification-version>6.2</specification-version>
135
                    </run-dependency>
135
                    </run-dependency>
136
               </dependency>
136
                </dependency>
137
            </module-dependencies>
137
            </module-dependencies>
138
            <public-packages>
138
            <public-packages>
139
                <package>org.netbeans.modules.xml.api</package>
139
                <package>org.netbeans.modules.xml.api</package>
(-)xml/css/manifest.mf (-1 lines)
Lines 4-10 Link Here
4
OpenIDE-Module-Install: org/netbeans/modules/css/CSSModuleInstall.class
4
OpenIDE-Module-Install: org/netbeans/modules/css/CSSModuleInstall.class
5
OpenIDE-Module-Layer: org/netbeans/modules/css/resources/mf-layer.xml
5
OpenIDE-Module-Layer: org/netbeans/modules/css/resources/mf-layer.xml
6
OpenIDE-Module-Specification-Version: 1.12
6
OpenIDE-Module-Specification-Version: 1.12
7
OpenIDE-Module-Requires: org.openide.windows.IOProvider
8
7
9
Name: org/netbeans/modules/css/CSSLoader.class
8
Name: org/netbeans/modules/css/CSSLoader.class
10
OpenIDE-Module-Class: Loader
9
OpenIDE-Module-Class: Loader
(-)xml/css/nbproject/project.xml (-17 / +17 lines)
Lines 41-47 Link Here
41
                    </run-dependency>
41
                    </run-dependency>
42
                </dependency>
42
                </dependency>
43
                <dependency>
43
                <dependency>
44
                    <code-name-base>org.openide.filesystems</code-name-base>
44
                    <code-name-base>org.openide.actions</code-name-base>
45
                    <build-prerequisite/>
45
                    <build-prerequisite/>
46
                    <compile-dependency/>
46
                    <compile-dependency/>
47
                    <run-dependency>
47
                    <run-dependency>
Lines 49-55 Link Here
49
                    </run-dependency>
49
                    </run-dependency>
50
                </dependency>
50
                </dependency>
51
                <dependency>
51
                <dependency>
52
                    <code-name-base>org.openide.util</code-name-base>
52
                    <code-name-base>org.openide.awt</code-name-base>
53
                    <build-prerequisite/>
53
                    <build-prerequisite/>
54
                    <compile-dependency/>
54
                    <compile-dependency/>
55
                    <run-dependency>
55
                    <run-dependency>
Lines 57-63 Link Here
57
                    </run-dependency>
57
                    </run-dependency>
58
                </dependency>
58
                </dependency>
59
                <dependency>
59
                <dependency>
60
                    <code-name-base>org.openide.modules</code-name-base>
60
                    <code-name-base>org.openide.filesystems</code-name-base>
61
                    <build-prerequisite/>
61
                    <build-prerequisite/>
62
                    <compile-dependency/>
62
                    <compile-dependency/>
63
                    <run-dependency>
63
                    <run-dependency>
Lines 65-87 Link Here
65
                    </run-dependency>
65
                    </run-dependency>
66
                </dependency>
66
                </dependency>
67
                <dependency>
67
                <dependency>
68
                    <code-name-base>org.openide.nodes</code-name-base>
68
                    <code-name-base>org.openide.io</code-name-base>
69
                    <build-prerequisite/>
69
                    <build-prerequisite/>
70
                    <compile-dependency/>
70
                    <compile-dependency/>
71
                    <run-dependency>
71
                    <run-dependency>
72
                        <specification-version>6.2</specification-version>
72
                        <specification-version>1.11</specification-version>
73
                    </run-dependency>
73
                    </run-dependency>
74
                </dependency>
74
                </dependency>
75
                <dependency>
75
                <dependency>
76
                    <code-name-base>org.openide.awt</code-name-base>
76
                    <code-name-base>org.openide.loaders</code-name-base>
77
                    <build-prerequisite/>
77
                    <build-prerequisite/>
78
                    <compile-dependency/>
78
                    <compile-dependency/>
79
                    <run-dependency>
79
                    <run-dependency/>
80
                        <specification-version>6.2</specification-version>
81
                    </run-dependency>
82
                </dependency>
80
                </dependency>
83
                <dependency>
81
                <dependency>
84
                    <code-name-base>org.openide.options</code-name-base>
82
                    <code-name-base>org.openide.modules</code-name-base>
85
                    <build-prerequisite/>
83
                    <build-prerequisite/>
86
                    <compile-dependency/>
84
                    <compile-dependency/>
87
                    <run-dependency>
85
                    <run-dependency>
Lines 89-95 Link Here
89
                    </run-dependency>
87
                    </run-dependency>
90
                </dependency>
88
                </dependency>
91
                <dependency>
89
                <dependency>
92
                    <code-name-base>org.openide.windows</code-name-base>
90
                    <code-name-base>org.openide.nodes</code-name-base>
93
                    <build-prerequisite/>
91
                    <build-prerequisite/>
94
                    <compile-dependency/>
92
                    <compile-dependency/>
95
                    <run-dependency>
93
                    <run-dependency>
Lines 97-103 Link Here
97
                    </run-dependency>
95
                    </run-dependency>
98
                </dependency>
96
                </dependency>
99
                <dependency>
97
                <dependency>
100
                    <code-name-base>org.openide.text</code-name-base>
98
                    <code-name-base>org.openide.options</code-name-base>
101
                    <build-prerequisite/>
99
                    <build-prerequisite/>
102
                    <compile-dependency/>
100
                    <compile-dependency/>
103
                    <run-dependency>
101
                    <run-dependency>
Lines 105-111 Link Here
105
                    </run-dependency>
103
                    </run-dependency>
106
                </dependency>
104
                </dependency>
107
                <dependency>
105
                <dependency>
108
                    <code-name-base>org.openide.actions</code-name-base>
106
                    <code-name-base>org.openide.text</code-name-base>
109
                    <build-prerequisite/>
107
                    <build-prerequisite/>
110
                    <compile-dependency/>
108
                    <compile-dependency/>
111
                    <run-dependency>
109
                    <run-dependency>
Lines 113-130 Link Here
113
                    </run-dependency>
111
                    </run-dependency>
114
                </dependency>
112
                </dependency>
115
                <dependency>
113
                <dependency>
116
                    <code-name-base>org.openide.io</code-name-base>
114
                    <code-name-base>org.openide.util</code-name-base>
117
                    <build-prerequisite/>
115
                    <build-prerequisite/>
118
                    <compile-dependency/>
116
                    <compile-dependency/>
119
                    <run-dependency>
117
                    <run-dependency>
120
                        <specification-version>1.0</specification-version>
118
                        <specification-version>6.2</specification-version>
121
                    </run-dependency>
119
                    </run-dependency>
122
                </dependency>
120
                </dependency>
123
                <dependency>
121
                <dependency>
124
                    <code-name-base>org.openide.loaders</code-name-base>
122
                    <code-name-base>org.openide.windows</code-name-base>
125
                    <build-prerequisite/>
123
                    <build-prerequisite/>
126
                    <compile-dependency/>
124
                    <compile-dependency/>
127
                    <run-dependency/>
125
                    <run-dependency>
126
                        <specification-version>6.2</specification-version>
127
                    </run-dependency>
128
                </dependency>
128
                </dependency>
129
            </module-dependencies>
129
            </module-dependencies>
130
            <public-packages/>
130
            <public-packages/>

Return to bug 34699