Package org.codehaus.mojo.keytool
Class ImportKeystoreMojo
- java.lang.Object
-
- org.apache.maven.plugin.AbstractMojo
-
- org.codehaus.mojo.keytool.AbstractKeyToolMojo
-
- org.codehaus.mojo.keytool.AbstractKeyToolRequestMojo<KeyToolImportKeystoreRequest>
-
- org.codehaus.mojo.keytool.ImportKeystoreMojo
-
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo
@Mojo(name="importKeystore", requiresProject=true) public class ImportKeystoreMojo extends AbstractKeyToolRequestMojo<KeyToolImportKeystoreRequest>To import all entries of a keystore to another keystore. Implemented as a wrapper around the SDKkeytool -importkeystorecommand. Note This operation was not implemented by the keytool before jdk 1.6. See keystore documentation.- Since:
- 1.2
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.StringdestaliasDestination alias.private java.lang.StringdestkeypassDestination key password.private java.lang.StringdestkeystoreDestination keystore name.private java.lang.StringdestprovidernameDestination keystore provider name.private java.lang.StringdeststorepassDestination keystore password.private java.lang.StringdeststoretypeDestination keystore type.private booleannopromptDo not prompt.private java.lang.StringproviderargProvider argument.private java.lang.StringproviderclassProvider class name.private java.lang.StringproviderpathProvider classpath.private booleanskipIfExistIf value istrue, then will do nothing if keystore already exists.private java.lang.StringsrcaliasSource alias.private java.lang.StringsrckeypassSource key password.private java.lang.StringsrckeystoreSource keystore name.private booleansrcprotectedSource keystore password protected.private java.lang.StringsrcprovidernameSource keystore provider name.private java.lang.StringsrcstorepassSource keystore password.private java.lang.StringsrcstoretypeSource keystore type.
-
Constructor Summary
Constructors Constructor Description ImportKeystoreMojo()Default contructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected KeyToolImportKeystoreRequestcreateKeytoolRequest()To prepare the incoming request, says fill it with mojo parameters.voidexecute()protected java.lang.StringgetCommandlineInfo(org.apache.maven.shared.utils.cli.Commandline commandLine)Gets a string representation of aCommandline.-
Methods inherited from class org.codehaus.mojo.keytool.AbstractKeyToolRequestMojo
consumeResult
-
Methods inherited from class org.codehaus.mojo.keytool.AbstractKeyToolMojo
getMessage, getMessage, getMessage, isSkip, isVerbose, setSkip, setVerbose
-
-
-
-
Field Detail
-
srckeystore
@Parameter private java.lang.String srckeystore
Source keystore name. See options.- Since:
- 1.2
-
destkeystore
@Parameter private java.lang.String destkeystore
Destination keystore name. See options.- Since:
- 1.2
-
srcstoretype
@Parameter private java.lang.String srcstoretype
Source keystore type. See options.- Since:
- 1.2
-
deststoretype
@Parameter private java.lang.String deststoretype
Destination keystore type. See options.- Since:
- 1.2
-
srcstorepass
@Parameter private java.lang.String srcstorepass
Source keystore password. See options.- Since:
- 1.2
-
deststorepass
@Parameter private java.lang.String deststorepass
Destination keystore password. See options.- Since:
- 1.2
-
srcprotected
@Parameter private boolean srcprotected
Source keystore password protected. See options.- Since:
- 1.2
-
srcprovidername
@Parameter private java.lang.String srcprovidername
Source keystore provider name. See options.- Since:
- 1.2
-
destprovidername
@Parameter private java.lang.String destprovidername
Destination keystore provider name. See options.- Since:
- 1.2
-
srcalias
@Parameter private java.lang.String srcalias
Source alias. See options.- Since:
- 1.2
-
destalias
@Parameter private java.lang.String destalias
Destination alias. See options.- Since:
- 1.2
-
srckeypass
@Parameter private java.lang.String srckeypass
Source key password. See options.- Since:
- 1.2
-
destkeypass
@Parameter private java.lang.String destkeypass
Destination key password. See options.- Since:
- 1.2
-
noprompt
@Parameter private boolean noprompt
Do not prompt. See options.- Since:
- 1.2
-
providerclass
@Parameter private java.lang.String providerclass
Provider class name. See options.- Since:
- 1.2
-
providerarg
@Parameter private java.lang.String providerarg
Provider argument. See options.- Since:
- 1.2
-
providerpath
@Parameter private java.lang.String providerpath
Provider classpath. See options.- Since:
- 1.2
-
skipIfExist
@Parameter private boolean skipIfExist
If value istrue, then will do nothing if keystore already exists.- Since:
- 1.3
-
-
Method Detail
-
execute
public void execute() throws org.apache.maven.plugin.MojoExecutionExceptionDescription copied from class:AbstractKeyToolRequestMojo- Specified by:
executein interfaceorg.apache.maven.plugin.Mojo- Overrides:
executein classAbstractKeyToolRequestMojo<KeyToolImportKeystoreRequest>- Throws:
org.apache.maven.plugin.MojoExecutionException
-
createKeytoolRequest
protected KeyToolImportKeystoreRequest createKeytoolRequest()
To prepare the incoming request, says fill it with mojo parameters.- Overrides:
createKeytoolRequestin classAbstractKeyToolRequestMojo<KeyToolImportKeystoreRequest>- Returns:
- the created keytool request
- See Also:
KeyToolRequest
-
getCommandlineInfo
protected java.lang.String getCommandlineInfo(org.apache.maven.shared.utils.cli.Commandline commandLine)
Gets a string representation of aCommandline.This method creates the string representation by calling
commandLine.toString()by default.- Overrides:
getCommandlineInfoin classAbstractKeyToolRequestMojo<KeyToolImportKeystoreRequest>- Parameters:
commandLine- TheCommandlineto get a string representation of (can not be null).- Returns:
- The string representation of
commandLine.
-
-