You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@beam.apache.org by GitBox <gi...@apache.org> on 2021/11/03 23:20:11 UTC

[GitHub] [beam] robertwb commented on a change in pull request #15857: Allow wildcards for java class lookup transform providers.

robertwb commented on a change in pull request #15857:
URL: https://github.com/apache/beam/pull/15857#discussion_r742418804



##########
File path: sdks/java/expansion-service/src/main/java/org/apache/beam/sdk/expansion/service/JavaClassLookupTransformProvider.java
##########
@@ -508,12 +523,32 @@ static AllowList create(
   @AutoValue
   public abstract static class AllowedClass {
 
+    public static final List<String> WILDCARD = Collections.singletonList("*");
+
     public abstract String getClassName();
 
     public abstract List<String> getAllowedBuilderMethods();
 
     public abstract List<String> getAllowedConstructorMethods();
 
+    public boolean isAllowedClass(String className) {
+      String pattern = getClassName();

Review comment:
       I could find documentation of this file anywhere, but I think the code is self explanatory enough (for both non-wildcard and wild-card containing lists).




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@beam.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org