|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objecteclipseme.core.model.impl.SignatureProperties
This is a simple container class (bean) designed to hold the various project-specific properties relating to potential signing operations. It is used by the dialog class that allows the user to manipulate the settings, as well as the project properties persistance stuff.
Note: This class/interface is part of an interim API that is still under development and expected to change before reaching stability. It is being made available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken as the API evolves.
| Field Summary |
| Fields inherited from interface eclipseme.core.model.ISignatureProperties |
PASSMETHOD_IN_KEYRING, PASSMETHOD_IN_PROJECT, PASSMETHOD_PROMPT, PROJECT_RELATIVE_PREFIX |
| Constructor Summary | |
SignatureProperties()
Standard constructor |
|
| Method Summary | |
void |
clear()
Resets the class to its default values |
void |
copy(ISignatureProperties other)
Indicates whether or not the project is to be signed. |
java.lang.String |
getAbsoluteKeyStorePath(org.eclipse.core.resources.IProject project)
Returns the absolute file system path to the keystore file. |
java.lang.String |
getKeyAlias()
Returns the "alias" string identifying the key and certificate that will be used to sign the project. |
java.lang.String |
getKeyPassword()
Returns the key password, if passwords are being saved. |
java.lang.String |
getKeyStoreDisplayPath()
Returns the display string representing the keystore path. |
java.lang.String |
getKeyStorePassword()
Returns the password for the keystore file, if passwords are being saved. |
java.lang.String |
getKeyStoreProvider()
Returns the crypto provider string. |
java.lang.String |
getKeyStoreType()
Type of the keystore file. |
int |
getPasswordStorageMethod()
Returns the password storage method. |
boolean |
getSignProject()
Indicates whether or not the project is to be signed. |
boolean |
isKeyStorePathExternal()
Indicates whether the keystore path is external to the project or project-relative. |
void |
setKeyAlias(java.lang.String strValue)
Sets the "alias" string identifying the key and certificate that will be used to sign the project. |
void |
setKeyPassword(java.lang.String strValue)
Sets the key password, if passwords are being saved. |
void |
setKeyStoreDisplayPath(java.lang.String path)
Sets the display string representing the keystore path. |
void |
setKeyStorePassword(java.lang.String strValue)
Sets the password for the keystore file. |
void |
setKeyStoreProvider(java.lang.String strValue)
Sets the crypto provider string. |
void |
setKeyStoreType(java.lang.String strValue)
Type of the keystore file. |
void |
setPasswordStorageMethod(int nMethod)
Sets the password storage method. |
void |
setSignProject(boolean bValue)
Indicates whether or not the project is to be signed. |
static java.lang.String |
toAbsolute(java.lang.String path,
org.eclipse.core.resources.IProject project)
Converts a project-relative path into an absolute one, based on the location of the project containing the file. |
static java.lang.String |
toRelative(java.lang.String path)
Converts a basic project-relative path into the format that we recognize internally. |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public SignatureProperties()
| Method Detail |
public void copy(ISignatureProperties other)
copy in interface ISignaturePropertiesother - ISignatureProperties object to be copied.
true if the project is to be signed, false otherwisepublic void clear()
clear in interface ISignaturePropertiespublic boolean getSignProject()
getSignProject in interface ISignaturePropertiestrue if the project is to be signed, false otherwiseISignatureProperties.setSignProject(boolean)public void setSignProject(boolean bValue)
setSignProject in interface ISignaturePropertiesbValue - true if the project is to be signed, false otherwise.ISignatureProperties.getSignProject()public int getPasswordStorageMethod()
getPasswordStorageMethod in interface ISignaturePropertiesPASSMETHOD_PROMPT, PASSMETHOD_IN_KEYRING or
PASSMETHOD_IN_PROJECT.ISignatureProperties.setPasswordStorageMethod(int),
ISignatureProperties.PASSMETHOD_IN_KEYRING,
ISignatureProperties.PASSMETHOD_IN_PROJECT,
ISignatureProperties.PASSMETHOD_PROMPTpublic void setPasswordStorageMethod(int nMethod)
setPasswordStorageMethod in interface ISignaturePropertiesnMethod - One of PASSMETHOD_PROMPT, PASSMETHOD_IN_KEYRING orISignatureProperties.getPasswordStorageMethod(),
ISignatureProperties.PASSMETHOD_IN_KEYRING,
ISignatureProperties.PASSMETHOD_IN_PROJECT,
ISignatureProperties.PASSMETHOD_PROMPTpublic java.lang.String getKeyStoreType()
null indicates
the system standard type. This string is passed to
KeyStore.getInstance as part of loading the
keystore.
getKeyStoreType in interface ISignaturePropertiesString indicating keystore file type.java.security.KeyStore#getInstance(java.lang.String),
java.security.KeyStore#getInstance(java.lang.String, java.lang.String)public void setKeyStoreType(java.lang.String strValue)
null indicates
the system standard type. This string is passed to
KeyStore.getInstance as part of loading the
keystore.
setKeyStoreType in interface ISignaturePropertiesstrValue - KeyStore type string, or null to
use the system default type.java.security.KeyStore#getInstance(java.lang.String),
java.security.KeyStore#getInstance(java.lang.String, java.lang.String)public java.lang.String getKeyStoreProvider()
null indicates the system
standard type. This string is passed to
KeyStore.getInstance as part of loading the
keystore.
getKeyStoreProvider in interface ISignaturePropertiesnull to use
the system default provider.java.security.KeyStore#getInstance(java.lang.String, java.lang.String)public void setKeyStoreProvider(java.lang.String strValue)
null indicates the system
standard type.
setKeyStoreProvider in interface ISignaturePropertiesstrValue - KeyStore provider string, or null to use
the system default provider.java.security.KeyStore#getInstance(java.lang.String, java.lang.String)public java.lang.String getKeyStorePassword()
getKeyStorePassword in interface ISignaturePropertiesString containing keystore password.ISignatureProperties.setKeyStorePassword(String)public void setKeyStorePassword(java.lang.String strValue)
setKeyStorePassword in interface ISignaturePropertiesstrValue - String containing keystore password.ISignatureProperties.getKeyStorePassword()public java.lang.String getKeyAlias()
getKeyAlias in interface ISignaturePropertiesString containing the alias identifying the key
and certificate.ISignatureProperties.setKeyAlias(String)public void setKeyAlias(java.lang.String strValue)
setKeyAlias in interface ISignaturePropertiesstrValue - String containing the alias identifying the key
and certificate.ISignatureProperties.getKeyAlias()public java.lang.String getKeyPassword()
null
if passwords are not being saved.
getKeyPassword in interface ISignaturePropertiesString containing the key password.ISignatureProperties.setKeyPassword(String)public void setKeyPassword(java.lang.String strValue)
setKeyPassword in interface ISignaturePropertiesstrValue - String containing the key password.ISignatureProperties.getKeyPassword()public java.lang.String getKeyStoreDisplayPath()
$/[Folder[/Folder...]]filename".
Absolute paths have OS-dependent form.
getKeyStoreDisplayPath in interface ISignaturePropertiesString containing displayed path.isKeyStorePathExternal()public void setKeyStoreDisplayPath(java.lang.String path)
setKeyStoreDisplayPath in interface ISignaturePropertiespath - String containing displayed path.getKeyStoreDisplayPath()public java.lang.String getAbsoluteKeyStorePath(org.eclipse.core.resources.IProject project)
project instance
is used to convert a project-relative path to an absolute
path.
getAbsoluteKeyStorePath in interface ISignaturePropertiesproject - IProject to which this
ISignatureProperties belongs.
String containing absolute path to
keystore file.ISignatureProperties.setKeyStoreDisplayPath(String)public boolean isKeyStorePathExternal()
isKeyStorePathExternal in interface ISignaturePropertiestrue if the keystore path is external
to the project, false if it's relative
to the current project.ISignatureProperties.setKeyStoreDisplayPath(String)
public static java.lang.String toAbsolute(java.lang.String path,
org.eclipse.core.resources.IProject project)
path - Relative path to be converted.project - IProject instance containing
the relative path.
String containing the absolute path
to the file.public static java.lang.String toRelative(java.lang.String path)
path - String containing the path to be
converted.
String with the converted value.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||