Class Version
java.lang.Object
org.springframework.shell.core.command.AbstractCommand
org.springframework.shell.core.command.Version
- All Implemented Interfaces:
org.springframework.beans.factory.Aware,org.springframework.beans.factory.InitializingBean,org.springframework.context.ApplicationContextAware,Command
public class Version
extends AbstractCommand
implements org.springframework.beans.factory.InitializingBean, org.springframework.context.ApplicationContextAware
Command to print the current version of Spring Shell.
- Author:
- Janne Valkealahti, Mahmoud Ben Hassine, Piotr Olaszewski, David Pilar
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordstatic final recordNested classes/interfaces inherited from interface org.springframework.shell.core.command.Command
Command.Builder -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoiddoExecute(CommandContext commandContext) getHelp()Get the help text of the command.voidsetApplicationContext(org.springframework.context.ApplicationContext applicationContext) voidsetBuildProperties(Version.BuildProperties buildProperties) voidsetGitProperties(Version.GitProperties gitProperties) Methods inherited from class org.springframework.shell.core.command.AbstractCommand
equals, execute, getAliases, getAvailabilityProvider, getCompletionProvider, getDescription, getExitStatusExceptionMapper, getGroup, getName, getOptions, hashCode, isHelp, isHidden, println, setAliases, setAvailabilityProvider, setCompletionProvider, setExitStatusExceptionMapper, setOptions
-
Constructor Details
-
Version
public Version()
-
-
Method Details
-
setBuildProperties
-
setGitProperties
-
getHelp
Description copied from interface:CommandGet the help text of the command.- Specified by:
getHelpin interfaceCommand- Overrides:
getHelpin classAbstractCommand- Returns:
- the help text of the command
-
doExecute
- Specified by:
doExecutein classAbstractCommand- Throws:
Exception
-
setApplicationContext
public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext) throws org.springframework.beans.BeansException - Specified by:
setApplicationContextin interfaceorg.springframework.context.ApplicationContextAware- Throws:
org.springframework.beans.BeansException
-
afterPropertiesSet
public void afterPropertiesSet()- Specified by:
afterPropertiesSetin interfaceorg.springframework.beans.factory.InitializingBean
-