[java-identity-provider] 01/02: Code tidy
Rod Widdowson
rdw at steadingsoftware.com
Sat Oct 10 14:22:12 UTC 2020
This is an automated email from the git hooks/post-receive script.
rdw pushed a commit to branch main
in repository java-identity-provider.
View the commit online:
http://git.shibboleth.net/view/?p=java-identity-provider.git;a=commit;h=91ddb8686e80d3e47f2edec97deeb6141913216e
commit 91ddb8686e80d3e47f2edec97deeb6141913216e
Author: Rod Widdowson <rdw at steadingsoftware.com>
AuthorDate: Sat Oct 10 14:21:59 2020 +0100
Code tidy
---
.../idp/installer/plugin/impl/PluginInstallerSupport.java | 6 ++----
.../idp/installer/plugin/impl/RollbackPluginInstall.java | 12 ++++++------
2 files changed, 8 insertions(+), 10 deletions(-)
diff --git a/idp-installer/src/main/java/net/shibboleth/idp/installer/plugin/impl/PluginInstallerSupport.java b/idp-installer/src/main/java/net/shibboleth/idp/installer/plugin/impl/PluginInstallerSupport.java
index c9b00eb5b..351b413c6 100644
--- a/idp-installer/src/main/java/net/shibboleth/idp/installer/plugin/impl/PluginInstallerSupport.java
+++ b/idp-installer/src/main/java/net/shibboleth/idp/installer/plugin/impl/PluginInstallerSupport.java
@@ -128,19 +128,17 @@ public final class PluginInstallerSupport {
pathsCopied.addAll(visitor.getCopiedList());
}
- /** Rename Files into the provided tree.
+ /** Rename Files into the provided tree.
* @param fromBase The root directory of the from files
* @param toBase The root directory to rename to
- * @param fromFiles The list of files (inside fromBase) to rename
+ * @param fromFiles The list of files (inside fromBase) to rename
* @param renames All the work as it is done
* @throws IOException If any of the file operations fail
*/
-
public static void renameToTree(@Nonnull final Path fromBase,
@Nonnull final Path toBase,
@Nonnull final List<String> fromFiles,
@Nonnull @Live final List<Pair<Path, Path>> renames) throws IOException {
-
if (!Files.exists(toBase)) {
Files.createDirectories(toBase);
}
diff --git a/idp-installer/src/main/java/net/shibboleth/idp/installer/plugin/impl/RollbackPluginInstall.java b/idp-installer/src/main/java/net/shibboleth/idp/installer/plugin/impl/RollbackPluginInstall.java
index a00acd4c8..a8b2b3fdb 100644
--- a/idp-installer/src/main/java/net/shibboleth/idp/installer/plugin/impl/RollbackPluginInstall.java
+++ b/idp-installer/src/main/java/net/shibboleth/idp/installer/plugin/impl/RollbackPluginInstall.java
@@ -50,16 +50,16 @@ public class RollbackPluginInstall implements AutoCloseable {
@Nonnull private final Logger log = LoggerFactory.getLogger(RollbackPluginInstall.class);
/** The modules enabled when the {@link IdPPlugin} was installed. */
- @Nonnull private List<IdPModule> modulesEnabled = new ArrayList<>();
+ @Live @Nonnull private List<IdPModule> modulesEnabled = new ArrayList<>();
/** The modules disabled when the {@link IdPPlugin} was installed. */
- @Nonnull private List<IdPModule> modulesDisabled = new ArrayList<>();
+ @Live @Nonnull private List<IdPModule> modulesDisabled = new ArrayList<>();
/** The files copied in as the {@link IdPPlugin} was installed. */
- @Nonnull private List<Path> filesCopied = new ArrayList<>();
+ @Live @Nonnull private List<Path> filesCopied = new ArrayList<>();
/** The files renamed away during the installation. */
- @Nonnull private List<Pair<Path, Path>> filesRenamedAway = new ArrayList<>();
+ @Live @Nonnull private List<Pair<Path, Path>> filesRenamedAway = new ArrayList<>();
/** The {@link ModuleContext} that the module subsystem needs.*/
@Nonnull private final ModuleContext moduleContext;
@@ -69,7 +69,7 @@ public class RollbackPluginInstall implements AutoCloseable {
* @param context The Module Context
*/
public RollbackPluginInstall(final ModuleContext context) {
- moduleContext = Constraint.isNotNull(context, "Context should ne non null");
+ moduleContext = Constraint.isNotNull(context, "Module context should ne non null");
}
/** What was enabled?
@@ -201,7 +201,7 @@ public class RollbackPluginInstall implements AutoCloseable {
/** Signal that the operation completed and that rollback won't be needed. */
public void completed() {
modulesEnabled = Collections.emptyList();
- modulesDisabled = modulesEnabled;
+ modulesDisabled = Collections.emptyList();
filesCopied = Collections.emptyList();
filesRenamedAway = Collections.emptyList();
}
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the commits
mailing list