mirror of
https://github.com/jenkinsci/jenkins.git
synced 2026-11-13 20:12:14 +00:00
Replace some anonymous classes with lambdas
This commit is contained in:
1 parent
ded6e2d531
commit
27d7acc810
26 files changed
+29
-171
No files matched your search
@@ -543,12 +543,7 @@ public abstract class ExtensionFinder implements ExtensionPoint {
|
||||
// make unique key, because Guice wants that.
|
||||
Key key = Key.get(extType, Names.named(item.className() + "." + item.memberName()));
|
||||
annotations.put(key,a);
|
||||
bind(key).toProvider(new Provider() {
|
||||
@Override
|
||||
public Object get() {
|
||||
return instantiate(item);
|
||||
}
|
||||
}).in(scope);
|
||||
bind(key).toProvider(() -> instantiate(item)).in(scope);
|
||||
}
|
||||
loadedIndex.add(item);
|
||||
} catch (Exception|LinkageError e) {
|
||||
|
||||
Reference in new issue
Block a user