Package com.devonfw.cobigen.cli.commands
Class UpdateCommand
- java.lang.Object
-
- com.devonfw.cobigen.cli.commands.CommandCommons
-
- com.devonfw.cobigen.cli.commands.UpdateCommand
-
- All Implemented Interfaces:
java.util.concurrent.Callable<java.lang.Integer>
public class UpdateCommand extends CommandCommons
This class handles the update command
-
-
Constructor Summary
Constructors Constructor Description UpdateCommand()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.IntegerdoAction()booleanprintOutdatedPlugin(java.util.List<org.apache.maven.model.Dependency> localPomDependencies, java.util.List<java.lang.String> centralMavenVersionList, java.util.HashMap<java.lang.String,java.lang.String> updatePluginVersions, java.util.HashMap<java.lang.Integer,java.lang.String> listOfArtifacts)This method is printing the outdated plug-insvoidupdateOutdatedPlugins(java.util.List<org.apache.maven.model.Dependency> localPomDependencies, java.util.HashMap<java.lang.Integer,java.lang.String> listOfArtifacts, java.util.List<java.lang.String> centralMavenVersionList, org.apache.maven.model.Model model, java.util.ArrayList<java.lang.String> userInputPluginForUpdate)This method is updating the outdated plug-ins-
Methods inherited from class com.devonfw.cobigen.cli.commands.CommandCommons
call
-
-
-
-
Method Detail
-
doAction
public java.lang.Integer doAction() throws java.lang.Exception- Specified by:
doActionin classCommandCommons- Throws:
java.lang.Exception
-
printOutdatedPlugin
public boolean printOutdatedPlugin(java.util.List<org.apache.maven.model.Dependency> localPomDependencies, java.util.List<java.lang.String> centralMavenVersionList, java.util.HashMap<java.lang.String,java.lang.String> updatePluginVersions, java.util.HashMap<java.lang.Integer,java.lang.String> listOfArtifacts)This method is printing the outdated plug-ins- Parameters:
localPomDependencies- This parameter holds the artificial dependenciescentralMavenVersionList- This parameter holds version listupdatePluginVersions- This parameter contains the key, value pair of versionslistOfArtifacts- This holds a list of artifact ids which need to be updated- Returns:
trueif all plugins are up-to-date andfalseif update is needed
-
updateOutdatedPlugins
public void updateOutdatedPlugins(java.util.List<org.apache.maven.model.Dependency> localPomDependencies, java.util.HashMap<java.lang.Integer,java.lang.String> listOfArtifacts, java.util.List<java.lang.String> centralMavenVersionList, org.apache.maven.model.Model model, java.util.ArrayList<java.lang.String> userInputPluginForUpdate)This method is updating the outdated plug-ins- Parameters:
localPomDependencies- This is holding the dependencies of artificial pomlistOfArtifacts- This parameter holds the value of updated plug-ins versioncentralMavenVersionList- This parameter holds the version listmodel- This parameter holds the after pom file reader dependenciesuserInputPluginForUpdate- This is holding user input for update plug-ins
-
-