From 654dee8cd6fd09314289e9bba92719d57001c539 Mon Sep 17 00:00:00 2001 From: Juergen Hoeller Date: Thu, 29 Jun 2023 18:15:38 +0200 Subject: [PATCH] Additional notes on module access via ClassPathResource See gh-28507 --- .../main/java/org/springframework/core/io/ModuleResource.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/spring-core/src/main/java/org/springframework/core/io/ModuleResource.java b/spring-core/src/main/java/org/springframework/core/io/ModuleResource.java index 3c2e2aeb6296..2953a995c548 100644 --- a/spring-core/src/main/java/org/springframework/core/io/ModuleResource.java +++ b/spring-core/src/main/java/org/springframework/core/io/ModuleResource.java @@ -29,9 +29,11 @@ * performing {@link #getInputStream()} access via {@link Module#getResourceAsStream}. * *

Alternatively, consider accessing resources in a module path layout via - * @link ClassPathResource} for exported resources, or specifically relative to + * {@link ClassPathResource} for exported resources, or specifically relative to * a {@code Class} via {@link ClassPathResource#ClassPathResource(String, Class)} * for local resolution within the containing module of that specific class. + * In common scenarios, module resources will simply be transparently visible as + * classpath resources and therefore do not need any special treatment at all. * * @author Juergen Hoeller * @author Sam Brannen