[java-identity-provider] branch master updated: Fix accidental non-public factory methods.

Scott Cantor cantor.2 at osu.edu
Thu Oct 24 08:17:06 EDT 2019


This is an automated email from the git hooks/post-receive script.

scantor pushed a commit to branch master
in repository java-identity-provider.

View the commit online:
http://git.shibboleth.net/view/?p=java-identity-provider.git;a=commit;h=66579ffe92450e688d087701d76e0552a05a3cdd

The following commit(s) were added to refs/heads/master by this push:
       new  66579ff   Fix accidental non-public factory methods.
66579ff is described below

commit 66579ffe92450e688d087701d76e0552a05a3cdd
Author: Scott Cantor <cantor.2 at osu.edu>
AuthorDate: Thu Oct 24 08:17:03 2019 -0400

    Fix accidental non-public factory methods.
---
 .../navigate/ScriptedContextLookupFunction.java    | 48 ++++++++++++++--------
 .../idp/profile/logic/ScriptedPredicate.java       |  8 ++--
 2 files changed, 36 insertions(+), 20 deletions(-)

diff --git a/idp-profile-api/src/main/java/net/shibboleth/idp/profile/context/navigate/ScriptedContextLookupFunction.java b/idp-profile-api/src/main/java/net/shibboleth/idp/profile/context/navigate/ScriptedContextLookupFunction.java
index 9f87b76..961bf5b 100644
--- a/idp-profile-api/src/main/java/net/shibboleth/idp/profile/context/navigate/ScriptedContextLookupFunction.java
+++ b/idp-profile-api/src/main/java/net/shibboleth/idp/profile/context/navigate/ScriptedContextLookupFunction.java
@@ -124,7 +124,8 @@ public class ScriptedContextLookupFunction<T extends BaseContext> extends Abstra
      * @throws ScriptException if the compile fails
      * @throws IOException if the file doesn't exist.
      */
-    @Nonnull static ScriptedContextLookupFunction<ProfileRequestContext> resourceScript(
+    @Nonnull
+    public static ScriptedContextLookupFunction<ProfileRequestContext> resourceScript(
             @Nonnull @NotEmpty final String engineName, @Nonnull final Resource resource) throws ScriptException,
             IOException {
         return resourceScript(engineName, resource, null);
@@ -141,7 +142,8 @@ public class ScriptedContextLookupFunction<T extends BaseContext> extends Abstra
      * @throws ScriptException if the compile fails
      * @throws IOException if the file doesn't exist.
      */
-    @Nonnull static ScriptedContextLookupFunction<ProfileRequestContext> resourceScript(
+    @Nonnull
+    public static ScriptedContextLookupFunction<ProfileRequestContext> resourceScript(
             @Nonnull @NotEmpty final String engineName, @Nonnull final Resource resource,
             @Nullable final Class<?> outputType) throws ScriptException, IOException {
         try (InputStream is = resource.getInputStream()) {
@@ -159,7 +161,8 @@ public class ScriptedContextLookupFunction<T extends BaseContext> extends Abstra
      * @throws ScriptException if the compile fails
      * @throws IOException if the file doesn't exist.
      */
-    @Nonnull static ScriptedContextLookupFunction<ProfileRequestContext> resourceScript(final Resource resource)
+    @Nonnull
+    public static ScriptedContextLookupFunction<ProfileRequestContext> resourceScript(final Resource resource)
             throws ScriptException, IOException {
         return resourceScript(DEFAULT_ENGINE, resource, null);
     }
@@ -174,7 +177,8 @@ public class ScriptedContextLookupFunction<T extends BaseContext> extends Abstra
      * @throws ScriptException if the compile fails
      * @throws IOException if the file doesn't exist.
      */
-    @Nonnull static ScriptedContextLookupFunction<ProfileRequestContext> resourceScript(final Resource resource,
+    @Nonnull
+    public static ScriptedContextLookupFunction<ProfileRequestContext> resourceScript(final Resource resource,
             @Nullable final Class<?> outputType) throws ScriptException, IOException {
         return resourceScript(DEFAULT_ENGINE, resource, outputType);
     }
@@ -187,7 +191,8 @@ public class ScriptedContextLookupFunction<T extends BaseContext> extends Abstra
      * @return the function
      * @throws ScriptException if the compile fails
      */
-    @Nonnull static ScriptedContextLookupFunction<ProfileRequestContext> inlineScript(
+    @Nonnull
+    public static ScriptedContextLookupFunction<ProfileRequestContext> inlineScript(
             @Nonnull @NotEmpty final String engineName, @Nonnull @NotEmpty final String scriptSource)
             throws ScriptException {
         final EvaluableScript script = new EvaluableScript(engineName, scriptSource);
@@ -203,7 +208,8 @@ public class ScriptedContextLookupFunction<T extends BaseContext> extends Abstra
      * @return the function
      * @throws ScriptException if the compile fails
      */
-    @Nonnull static ScriptedContextLookupFunction<ProfileRequestContext> inlineScript(
+    @Nonnull
+    public static ScriptedContextLookupFunction<ProfileRequestContext> inlineScript(
             @Nonnull @NotEmpty final String engineName, @Nonnull @NotEmpty final String scriptSource,
             @Nullable final Class<?> outputType) throws ScriptException {
         final EvaluableScript script = new EvaluableScript(engineName, scriptSource);
@@ -217,7 +223,8 @@ public class ScriptedContextLookupFunction<T extends BaseContext> extends Abstra
      * @return the function
      * @throws ScriptException if the compile fails
      */
-    @Nonnull static ScriptedContextLookupFunction<ProfileRequestContext> inlineScript(
+    @Nonnull
+    public static ScriptedContextLookupFunction<ProfileRequestContext> inlineScript(
             @Nonnull @NotEmpty final String scriptSource) throws ScriptException {
         final EvaluableScript script = new EvaluableScript(DEFAULT_ENGINE, scriptSource);
         return new ScriptedContextLookupFunction<>(ProfileRequestContext.class, script, "Inline");
@@ -231,7 +238,8 @@ public class ScriptedContextLookupFunction<T extends BaseContext> extends Abstra
      * @return the function
      * @throws ScriptException if the compile fails
      */
-    @Nonnull static ScriptedContextLookupFunction<ProfileRequestContext> inlineScript(
+    @Nonnull
+    public static ScriptedContextLookupFunction<ProfileRequestContext> inlineScript(
             @Nonnull @NotEmpty final String scriptSource, @Nullable final Class<?> outputType) throws ScriptException {
         final EvaluableScript script = new EvaluableScript(DEFAULT_ENGINE, scriptSource);
         return new ScriptedContextLookupFunction<>(ProfileRequestContext.class, script, "Inline", outputType);
@@ -246,7 +254,8 @@ public class ScriptedContextLookupFunction<T extends BaseContext> extends Abstra
      * @throws ScriptException if the compile fails
      * @throws IOException if the file doesn't exist.
      */
-    @Nonnull static ScriptedContextLookupFunction<MessageContext> resourceMessageContextScript(
+    @Nonnull
+    public static ScriptedContextLookupFunction<MessageContext> resourceMessageContextScript(
             @Nonnull @NotEmpty final String engineName, @Nonnull final Resource resource) throws ScriptException,
             IOException {
         return resourceMessageContextScript(engineName, resource, null);
@@ -262,7 +271,8 @@ public class ScriptedContextLookupFunction<T extends BaseContext> extends Abstra
      * @throws ScriptException if the compile fails
      * @throws IOException if the file doesn't exist.
      */
-    @Nonnull static ScriptedContextLookupFunction<MessageContext> resourceMessageContextScript(
+    @Nonnull
+    public static ScriptedContextLookupFunction<MessageContext> resourceMessageContextScript(
             @Nonnull @NotEmpty final String engineName, @Nonnull final Resource resource,
             @Nullable final Class<?> outputType) throws ScriptException, IOException {
         try (InputStream is = resource.getInputStream()) {
@@ -280,7 +290,8 @@ public class ScriptedContextLookupFunction<T extends BaseContext> extends Abstra
      * @throws ScriptException if the compile fails
      * @throws IOException if the file doesn't exist.
      */
-    @Nonnull static ScriptedContextLookupFunction<MessageContext> resourceMessageContextScript(final Resource resource)
+    @Nonnull
+    public static ScriptedContextLookupFunction<MessageContext> resourceMessageContextScript(final Resource resource)
             throws ScriptException, IOException {
         return resourceMessageContextScript(DEFAULT_ENGINE, resource, null);
     }
@@ -294,7 +305,8 @@ public class ScriptedContextLookupFunction<T extends BaseContext> extends Abstra
      * @throws ScriptException if the compile fails
      * @throws IOException if the file doesn't exist.
      */
-    @Nonnull static ScriptedContextLookupFunction<MessageContext> resourceMessageContextScript(final Resource resource,
+    @Nonnull
+    public static ScriptedContextLookupFunction<MessageContext> resourceMessageContextScript(final Resource resource,
             @Nullable final Class<?> outputType) throws ScriptException, IOException {
         return resourceMessageContextScript(DEFAULT_ENGINE, resource, outputType);
     }
@@ -307,7 +319,8 @@ public class ScriptedContextLookupFunction<T extends BaseContext> extends Abstra
      * @return the function
      * @throws ScriptException if the compile fails
      */
-    @Nonnull static ScriptedContextLookupFunction<MessageContext> inlineMessageContextScript(
+    @Nonnull
+    public static ScriptedContextLookupFunction<MessageContext> inlineMessageContextScript(
             @Nonnull @NotEmpty final String engineName, @Nonnull @NotEmpty final String scriptSource)
             throws ScriptException {
         final EvaluableScript script = new EvaluableScript(engineName, scriptSource);
@@ -323,7 +336,8 @@ public class ScriptedContextLookupFunction<T extends BaseContext> extends Abstra
      * @return the function
      * @throws ScriptException if the compile fails
      */
-    @Nonnull static ScriptedContextLookupFunction<MessageContext> inlineMessageContextScript(
+    @Nonnull
+    public static ScriptedContextLookupFunction<MessageContext> inlineMessageContextScript(
             @Nonnull @NotEmpty final String engineName, @Nonnull @NotEmpty final String scriptSource,
             @Nullable final Class<?> outputType) throws ScriptException {
         final EvaluableScript script = new EvaluableScript(engineName, scriptSource);
@@ -337,7 +351,8 @@ public class ScriptedContextLookupFunction<T extends BaseContext> extends Abstra
      * @return the function
      * @throws ScriptException if the compile fails
      */
-    @Nonnull static ScriptedContextLookupFunction<MessageContext> inlineMessageContextScript(
+    @Nonnull
+    public static ScriptedContextLookupFunction<MessageContext> inlineMessageContextScript(
             @Nonnull @NotEmpty final String scriptSource) throws ScriptException {
         final EvaluableScript script = new EvaluableScript(DEFAULT_ENGINE, scriptSource);
         return new ScriptedContextLookupFunction<>(MessageContext.class, script, "Inline");
@@ -351,7 +366,8 @@ public class ScriptedContextLookupFunction<T extends BaseContext> extends Abstra
      * @return the function
      * @throws ScriptException if the compile fails
      */
-    @Nonnull static ScriptedContextLookupFunction<MessageContext> inlineMessageContextScript(
+    @Nonnull
+    public static ScriptedContextLookupFunction<MessageContext> inlineMessageContextScript(
             @Nonnull @NotEmpty final String scriptSource, @Nullable final Class<?> outputType) throws ScriptException {
         final EvaluableScript script = new EvaluableScript(DEFAULT_ENGINE, scriptSource);
         return new ScriptedContextLookupFunction<>(MessageContext.class, script, "Inline", outputType);
diff --git a/idp-profile-api/src/main/java/net/shibboleth/idp/profile/logic/ScriptedPredicate.java b/idp-profile-api/src/main/java/net/shibboleth/idp/profile/logic/ScriptedPredicate.java
index bcc34a9..c29ae45 100644
--- a/idp-profile-api/src/main/java/net/shibboleth/idp/profile/logic/ScriptedPredicate.java
+++ b/idp-profile-api/src/main/java/net/shibboleth/idp/profile/logic/ScriptedPredicate.java
@@ -80,7 +80,7 @@ public class ScriptedPredicate
      * @throws ScriptException if the compile fails
      * @throws IOException if the file doesn't exist.
      */
-    static ScriptedPredicate resourceScript(@Nonnull @NotEmpty final String engineName,
+    public static ScriptedPredicate resourceScript(@Nonnull @NotEmpty final String engineName,
             @Nonnull final Resource resource) throws ScriptException, IOException {
         try (final InputStream is = resource.getInputStream()) {
             final EvaluableScript script = new EvaluableScript(engineName, is);
@@ -96,7 +96,7 @@ public class ScriptedPredicate
      * @throws ScriptException if the compile fails
      * @throws IOException if the file doesn't exist.
      */
-    static ScriptedPredicate resourceScript(final Resource resource) throws ScriptException, IOException {
+    public static ScriptedPredicate resourceScript(final Resource resource) throws ScriptException, IOException {
         return resourceScript(DEFAULT_ENGINE, resource);
     }
 
@@ -108,7 +108,7 @@ public class ScriptedPredicate
      * @return the predicate
      * @throws ScriptException if the compile fails
      */
-    static ScriptedPredicate inlineScript(@Nonnull @NotEmpty final String engineName,
+    public static ScriptedPredicate inlineScript(@Nonnull @NotEmpty final String engineName,
             @Nonnull @NotEmpty final String scriptSource) throws ScriptException {
         final EvaluableScript script = new EvaluableScript(engineName, scriptSource);
         return new ScriptedPredicate(script, "Inline");
@@ -121,7 +121,7 @@ public class ScriptedPredicate
      * @return the predicate
      * @throws ScriptException if the compile fails
      */
-    static ScriptedPredicate inlineScript(@Nonnull @NotEmpty final String scriptSource) throws ScriptException {
+    public static ScriptedPredicate inlineScript(@Nonnull @NotEmpty final String scriptSource) throws ScriptException {
         final EvaluableScript script = new EvaluableScript(DEFAULT_ENGINE, scriptSource);
         return new ScriptedPredicate(script, "Inline");
     }

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the commits mailing list