[java-support] 02/03: IDP-1595 Change class name, add external download

Rod Widdowson rdw at steadingsoftware.com
Tue Jun 9 09:52:12 UTC 2020


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

rdw pushed a commit to branch master
in repository java-support.

View the commit online:
http://git.shibboleth.net/view/?p=java-support.git;a=commit;h=5779a0452a0885f4ee16b9d885236393d2f09b6d

commit 5779a0452a0885f4ee16b9d885236393d2f09b6d
Author: Rod Widdowson <rdw at steadingsoftware.com>
AuthorDate: Tue May 12 16:28:43 2020 +0100

    IDP-1595 Change class name, add external download
    
    https://issues.shibboleth.net/jira/browse/IDP-1595
---
 ...PluginInstaller.java => PluginDescription.java} | 27 +++++++++++++++++-----
 1 file changed, 21 insertions(+), 6 deletions(-)

diff --git a/src/main/java/net/shibboleth/utilities/java/support/plugin/PluginInstaller.java b/src/main/java/net/shibboleth/utilities/java/support/plugin/PluginDescription.java
similarity index 83%
rename from src/main/java/net/shibboleth/utilities/java/support/plugin/PluginInstaller.java
rename to src/main/java/net/shibboleth/utilities/java/support/plugin/PluginDescription.java
index 8b2f403..fb3dc18 100644
--- a/src/main/java/net/shibboleth/utilities/java/support/plugin/PluginInstaller.java
+++ b/src/main/java/net/shibboleth/utilities/java/support/plugin/PluginDescription.java
@@ -17,7 +17,6 @@
 
 package net.shibboleth.utilities.java.support.plugin;
 
-import java.net.URL;
 import java.nio.file.Path;
 import java.util.Collections;
 import java.util.List;
@@ -34,7 +33,7 @@ import net.shibboleth.utilities.java.support.resource.Resource;
 /**
  * This class is exported (via the service API) by every plugin.
  */
-public abstract class PluginInstaller {
+public abstract class PluginDescription {
     
     /** Return the unique identifier for the plugin.  This name <em>MUST</em> be
      * <ul>
@@ -56,18 +55,34 @@ public abstract class PluginInstaller {
     }
     
     /** Return the list of (idp.home) relative paths (of files, <em>not directories </em>) 
-     * to copy from the distribution into the IdP installation.<p>
-     * 
-     * These files are copied non-destructively (if the file already exists
-     * then it is not copied).  Some paths are disallowed (for instance dist and system).</p>
+     * to copy from the distribution into the IdP installation.
+     *
+     * <p>These files are copied non-destructively (if the file already exists
+     * then it is not copied).  Some paths are disallowed (for instance dist and system).
+     * Directories are created if needed</p>
      * <p>
      * The dist folder is always copied, so no files from it should be included.</p>
+     *
      * @return The list of paths.
      */
     @Nonnull public List<Path> getFilePathsToCopy() {
         return Collections.emptyList();
     }
     
+    /** <p>Return the list of files <em>not directories </em> to get from 'external'
+     * sources. This allows external content to be downloaded during installation.</p>
+     *
+     * <p>The first part of the pair is the source (usually an HTTPResource),
+     * the second is a path relative to idp.home.  These can include files
+     * going to dist\edit-webapp in which case the path is expected to have the
+     * plugin id appended. Sub directories are created if needed</p>
+     *
+     * @return The list.
+     */
+    @Nonnull public List<Pair<Resource, Path>> getExternalFilePathsToCopy() {
+        return Collections.emptyList();
+    }
+
     /** Return the places to look for updates for this plugin package.
      * The format of the paths below this point is fixed.
      * 

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


More information about the commits mailing list