|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.osgi.internal.signedcontent.SignedBundleHook
public class SignedBundleHook
Implements signed bundle hook support for the framework
| Constructor Summary | |
|---|---|
SignedBundleHook()
|
|
| Method Summary | |
|---|---|
void |
addHooks(HookRegistry hookRegistry)
Adds hooks to the specified hook registry. |
void |
addProperties(java.util.Properties properties)
Gets called by the adaptor during FrameworkAdaptor.getProperties(). |
FrameworkLog |
createFrameworkLog()
Gets called by the adaptor during FrameworkAdaptor.getFrameworkLog(). |
void |
frameworkStart(BundleContext context)
Gets called by the adaptor during FrameworkAdaptor.frameworkStart(BundleContext). |
void |
frameworkStop(BundleContext context)
Gets called by the adaptor during FrameworkAdaptor.frameworkStop(BundleContext). |
void |
frameworkStopping(BundleContext context)
Gets called by the adaptor during FrameworkAdaptor.frameworkStopping(BundleContext). |
SignedContent |
getSignedContent(Bundle bundle)
Returns a SignedContent object for the specified bundle. |
SignedContent |
getSignedContent(java.io.File content)
Returns a SignedContent object for the specified content of a repository. |
void |
handleRuntimeError(java.lang.Throwable error)
Gets called by the adaptor during FrameworkAdaptor.handleRuntimeError(Throwable). |
void |
initialize(BaseAdaptor adaptor)
Gets called by the adaptor during FrameworkAdaptor.initialize(EventPublisher). |
static void |
log(java.lang.String msg,
int severity,
java.lang.Throwable t)
|
java.net.URLConnection |
mapLocationToURLConnection(java.lang.String location)
Gets called by the adaptor during FrameworkAdaptor.mapLocationToURLConnection(String). |
BundleFile |
wrapBundleFile(BundleFile bundleFile,
java.lang.Object content,
BaseData data,
boolean base)
Wraps a bundle file for the given content and base data. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SignedBundleHook()
| Method Detail |
|---|
public void initialize(BaseAdaptor adaptor)
AdaptorHookFrameworkAdaptor.initialize(EventPublisher).
This method allows an adaptor hook to save the adaptor object for later.
initialize in interface AdaptorHookadaptor - the adaptor object associated with this AdaptorHook.
public void frameworkStart(BundleContext context)
throws BundleException
AdaptorHookFrameworkAdaptor.frameworkStart(BundleContext).
This method allows an adaptor hook to execute code when the framework is starting
(e.g. to register services).
frameworkStart in interface AdaptorHookcontext - the system bundle context
BundleException
public void frameworkStop(BundleContext context)
throws BundleException
AdaptorHookFrameworkAdaptor.frameworkStop(BundleContext).
This method allows an adaptor hook to execute code when the framework is stopped
(e.g. to unregister services).
frameworkStop in interface AdaptorHookcontext - the system bundle context
BundleExceptionpublic void frameworkStopping(BundleContext context)
AdaptorHookFrameworkAdaptor.frameworkStopping(BundleContext).
This method allows an adaptor hook to execute code when the framework is about to start
the shutdown process.
frameworkStopping in interface AdaptorHookcontext - the system bundle contextpublic void addProperties(java.util.Properties properties)
AdaptorHookFrameworkAdaptor.getProperties().
This method allows an adaptor hook to add property values to the adaptor
properties object.
addProperties in interface AdaptorHookproperties - the adaptor properties object.
public java.net.URLConnection mapLocationToURLConnection(java.lang.String location)
throws java.io.IOException
AdaptorHookFrameworkAdaptor.mapLocationToURLConnection(String).
The adaptor will call this method for each configured adaptor hook until one
adaptor hook returns a non-null value. If no adaptor hook returns a non-null value
then the adaptor will perform the default behavior.
mapLocationToURLConnection in interface AdaptorHooklocation - a bundle location string to be converted to a URLConnection
java.io.IOExceptionpublic void handleRuntimeError(java.lang.Throwable error)
AdaptorHookFrameworkAdaptor.handleRuntimeError(Throwable).
The adaptor will call this method for each configured adaptor hook.
handleRuntimeError in interface AdaptorHookerror - the unexpected error that occured.public FrameworkLog createFrameworkLog()
AdaptorHookFrameworkAdaptor.getFrameworkLog().
The adaptor will call this method for each configured adaptor hook until one
adaptor hook returns a non-null value. If no adaptor hook returns a non-null value
then the adaptor will return null.
createFrameworkLog in interface AdaptorHook
public BundleFile wrapBundleFile(BundleFile bundleFile,
java.lang.Object content,
BaseData data,
boolean base)
BundleFileWrapperFactoryHook
wrapBundleFile in interface BundleFileWrapperFactoryHookbundleFile - the bundle file to be wrappedcontent - The object which contains the content of a bundle file.data - The base data associated with the contentbase - true if the content is for the base bundle (not an inner jar, directory etc.)
public void addHooks(HookRegistry hookRegistry)
HookConfigurator
addHooks in interface HookConfiguratorhookRegistry - the hook registry used to add hooks
public SignedContent getSignedContent(java.io.File content)
throws java.io.IOException,
java.security.InvalidKeyException,
java.security.SignatureException,
java.security.cert.CertificateException,
java.security.NoSuchAlgorithmException,
java.security.NoSuchProviderException
SignedContentFactorySignedContent object for the specified content of a repository.
getSignedContent in interface SignedContentFactorycontent - the content of the repository
java.io.IOException - if an IO exception occurs while reading the repository
java.security.InvalidKeyException - if there is a problem with one of the certificate keys of the signed content
java.security.SignatureException - if there is a problem with one of the signatures of the signed content
java.security.cert.CertificateException - if there is a problem with one of the certificates of the signed content
java.security.NoSuchAlgorithmException - if the cryptographic algorithm is not available for the signed content
java.security.NoSuchProviderException - if there's no security provider for the signed content
public SignedContent getSignedContent(Bundle bundle)
throws java.io.IOException,
java.security.InvalidKeyException,
java.security.SignatureException,
java.security.cert.CertificateException,
java.security.NoSuchAlgorithmException,
java.security.NoSuchProviderException,
java.lang.IllegalArgumentException
SignedContentFactorySignedContent object for the specified bundle.
getSignedContent in interface SignedContentFactorybundle - the bundle to get a signed content for.
java.io.IOException - if an IO exception occurs while reading the bundle content
java.security.InvalidKeyException - if there is a problem with one of the certificate keys of the signed content
java.security.SignatureException - if there is a problem with one of the signatures of the signed content
java.security.cert.CertificateException - if there is a problem with one of the certificates of the signed content
java.security.NoSuchAlgorithmException - if the cryptographic algorithm is not available for the signed content
java.security.NoSuchProviderException - if there's no security provider for the signed content
java.lang.IllegalArgumentException
public static void log(java.lang.String msg,
int severity,
java.lang.Throwable t)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||