Skip to content

Commit

Permalink
Adjust signature.
Browse files Browse the repository at this point in the history
  • Loading branch information
raphw committed Sep 25, 2024
1 parent cdbe5ec commit 27e12fe
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions byte-buddy-dep/src/main/java/net/bytebuddy/build/Plugin.java
Original file line number Diff line number Diff line change
Expand Up @@ -2953,7 +2953,7 @@ public static Source ofTypes(Class<?>... type) {
* @return A source representing the supplied types.
*/
public static Source ofTypes(Collection<? extends Class<?>> types) {
return ofTypes(types, Collections.<ClassFileVersion, Collection<Class<?>>>emptyMap());
return ofTypes(types, Collections.<ClassFileVersion, Collection<? extends Class<?>>>emptyMap());
}

/**
Expand All @@ -2963,9 +2963,9 @@ public static Source ofTypes(Collection<? extends Class<?>> types) {
* @param versionedTypes A versioned mapping of types to represent.
* @return A source representing the supplied types.
*/
public static Source ofTypes(Collection<? extends Class<?>> types, Map<ClassFileVersion, Collection<Class<?>>> versionedTypes) {
public static Source ofTypes(Collection<? extends Class<?>> types, Map<ClassFileVersion, Collection<? extends Class<?>>> versionedTypes) {
Map<ClassFileVersion, Map<TypeDescription, byte[]>> versionedBinaryRepresentations = new HashMap<ClassFileVersion, Map<TypeDescription, byte[]>>();
for (Map.Entry<ClassFileVersion, Collection<Class<?>>> entry : versionedTypes.entrySet()) {
for (Map.Entry<ClassFileVersion, Collection<? extends Class<?>>> entry : versionedTypes.entrySet()) {
Map<TypeDescription, byte[]> binaryRepresentations = new HashMap<TypeDescription, byte[]>();
for (Class<?> type : entry.getValue()) {
binaryRepresentations.put(TypeDescription.ForLoadedType.of(type), ClassFileLocator.ForClassLoader.read(type));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ public void testSimpleTransformationMultiRelease() throws Exception {
Plugin plugin = eager
? new SimplePlugin()
: new PreprocessingPlugin(new SimplePlugin());
Plugin.Engine.Source source = Plugin.Engine.Source.InMemory.ofTypes(Collections.<Class<?>>emptyList(), Collections.<ClassFileVersion, Collection<Class<?>>>singletonMap(
Plugin.Engine.Source source = Plugin.Engine.Source.InMemory.ofTypes(Collections.<Class<?>>emptyList(), Collections.<ClassFileVersion, Collection<? extends Class<?>>>singletonMap(
ClassFileVersion.JAVA_V11,
Collections.singletonList(Sample.class)));
Plugin.Engine.Target.InMemory target = new Plugin.Engine.Target.InMemory();
Expand Down

0 comments on commit 27e12fe

Please sign in to comment.