Class X509CertificateFactoryBean
java.lang.Object
org.springframework.beans.factory.config.AbstractFactoryBean<X509Certificate>
se.swedenconnect.security.credential.factory.X509CertificateFactoryBean
- All Implemented Interfaces:
Aware
,BeanClassLoaderAware
,BeanFactoryAware
,DisposableBean
,FactoryBean<X509Certificate>
,InitializingBean
A factory bean for creating X.509 certificates read from a resource.
For Shibboleth users:
Basically this class is the same as net.shibboleth.ext.spring.factory.X509CertificateFactoryBean
residing in the
net.shibboleth.ext:spring-extensions
.
- Author:
- Martin Lindström (martin@idsec.se)
-
Field Summary
Fields inherited from class org.springframework.beans.factory.config.AbstractFactoryBean
logger
Fields inherited from interface org.springframework.beans.factory.FactoryBean
OBJECT_TYPE_ATTRIBUTE
-
Constructor Summary
ConstructorDescriptionDefault constructor.X509CertificateFactoryBean
(Resource resource) Constructor taking a resource/path to a DER- or PEM-encoded certificate. -
Method Summary
Modifier and TypeMethodDescriptionvoid
protected X509Certificate
Class<?>
void
setResource
(Resource resource) Assigns the resource holding the certificate.Methods inherited from class org.springframework.beans.factory.config.AbstractFactoryBean
destroy, destroyInstance, getBeanFactory, getBeanTypeConverter, getEarlySingletonInterfaces, getObject, isSingleton, setBeanClassLoader, setBeanFactory, setSingleton
-
Constructor Details
-
X509CertificateFactoryBean
public X509CertificateFactoryBean()Default constructor. -
X509CertificateFactoryBean
Constructor taking a resource/path to a DER- or PEM-encoded certificate.- Parameters:
resource
- the location of the certificate
-
-
Method Details
-
createInstance
- Specified by:
createInstance
in classAbstractFactoryBean<X509Certificate>
- Throws:
Exception
-
getObjectType
- Specified by:
getObjectType
in interfaceFactoryBean<X509Certificate>
- Specified by:
getObjectType
in classAbstractFactoryBean<X509Certificate>
-
setResource
Assigns the resource holding the certificate.- Parameters:
resource
- the certificate resource
-
afterPropertiesSet
- Specified by:
afterPropertiesSet
in interfaceInitializingBean
- Overrides:
afterPropertiesSet
in classAbstractFactoryBean<X509Certificate>
- Throws:
Exception
-