Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

3.x: Remove unused methods 'produce' and 'dispose' from PersistenceExtension.ReferenceCountingProducer #9422

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2023 Oracle and/or its affiliates.
* Copyright (c) 2023, 2024 Oracle and/or its affiliates.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -27,7 +27,6 @@
import java.net.URLClassLoader;
import java.security.CodeSource;
import java.security.ProtectionDomain;
import java.util.Arrays;
import java.util.Collection;
import java.util.Collections;
import java.util.Enumeration;
Expand Down Expand Up @@ -1569,34 +1568,6 @@ private <T> T produce(Supplier<? extends T> supplier,
return this.produce(supplier, disposer, Set.of(type), qualifiers);
}

private <T> T produce(Supplier<? extends T> supplier,
Consumer<? super T> disposer,
Class<T> type,
Annotation... qualifiers) {
return this.produce(supplier, disposer, Set.of(type), Set.copyOf(Arrays.asList(qualifiers)));
}

private <T> T produce(Supplier<? extends T> supplier,
Consumer<? super T> disposer,
TypeLiteral<T> type,
Set<Annotation> qualifiers) {
return this.produce(supplier, disposer, Set.of(type.getType()), qualifiers);
}

private <T> T produce(Supplier<? extends T> supplier,
Consumer<? super T> disposer,
TypeLiteral<T> type,
Annotation... qualifiers) {
return this.produce(supplier, disposer, Set.of(type.getType()), Set.copyOf(Arrays.asList(qualifiers)));
}

private <T> T produce(Supplier<? extends T> supplier,
Consumer<? super T> disposer,
Set<Type> types,
Annotation... qualifiers) {
return this.produce(supplier, disposer, types, Set.copyOf(Arrays.asList(qualifiers)));
}

private <T> T produce(Supplier<? extends T> supplier,
Consumer<? super T> disposer,
Set<Type> types,
Expand All @@ -1617,22 +1588,6 @@ private <T> void dispose(Class<T> type, Set<Annotation> qualifiers) {
this.dispose(Set.of(type), qualifiers);
}

private <T> void dispose(Class<T> type, Annotation... qualifiers) {
this.dispose(Set.of(type), Set.copyOf(Arrays.asList(qualifiers)));
}

private <T> void dispose(TypeLiteral<T> type, Set<Annotation> qualifiers) {
this.dispose(Set.of(type.getType()), qualifiers);
}

private <T> void dispose(TypeLiteral<T> type, Annotation... qualifiers) {
this.dispose(Set.of(type.getType()), Set.copyOf(Arrays.asList(qualifiers)));
}

private <T> void dispose(Set<Type> types, Annotation... qualifiers) {
this.dispose(types, Set.copyOf(Arrays.asList(qualifiers)));
}

private <T> void dispose(Set<Type> types, Set<Annotation> qualifiers) {
Map<ReferenceCountingProducer, Map<ProductionId, Production<?>>> tlMap = TL.get();
Map<ProductionId, Production<?>> map = tlMap.get(this);
Expand Down
Loading