Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.mina.integration.spring.ssl
Class KeyStoreFactoryBean

    java.lang.Object
      org.springframework.beans.factory.config.AbstractFactoryBean
          org.apache.mina.integration.spring.ssl.KeyStoreFactoryBean

All Implemented Interfaces:
  BeanFactoryAware, DisposableBean, FactoryBean, InitializingBean

    public class KeyStoreFactoryBean

extends AbstractFactoryBean

Spring `FactoryBean` implementation which makes it possible to configure `KeyStore` instances using Spring.

Version:
  $Rev: 555855 $, $Date: 2007-07-13 05:19:00 +0200 (Fri, 13 Jul 2007) $
Author:
  The Apache Directory Project (mina-dev@directory.apache.org)

Field Summary

Fields inherited from class org.springframework.beans.factory.config.AbstractFactoryBean
`logger`

Constructor Summary
`KeyStoreFactoryBean()`

Method Summary
`protected Object` | `createInstance()` Creates a new `KeyStore`.
`Class` | `getObjectType()`
`void` | `setFile(File file)` Sets the file which contains the key store.
`void` | `setPassword(String password)` Sets the key store password.
`void` | `setProvider(String provider)` Sets the name of the provider to use when creating the key store.
`void` | `setResource(Resource resource)` Sets a Spring `Resource` which contains the key store.
`void` | `setType(String type)` Sets the type of key store to create.

Methods inherited from class org.springframework.beans.factory.config.AbstractFactoryBean
`afterPropertiesSet, destroy, destroyInstance, getBeanFactory, getBeanTypeConverter, getEarlySingletonInterfaces, getObject, isSingleton, setBeanFactory, setSingleton`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### KeyStoreFactoryBean

    public KeyStoreFactoryBean()

Method Detail

### createInstance

    protected Object createInstance()
                             throws Exception

  Creates a new `KeyStore`. This method will be called by the base class when Spring creates a bean using this FactoryBean.

  Specified by:
    `createInstance` in class `AbstractFactoryBean`
  Returns:
    the `KeyStore` instance.
  Throws:
    `Exception`

### getObjectType

    public Class getObjectType()

  Specified by:
    `getObjectType` in interface `FactoryBean`
  Specified by:
    `getObjectType` in class `AbstractFactoryBean`

### setFile

    public void setFile(File file)

  Sets the file which contains the key store. Either this property or `setProvider(String)` have to be set.

  Parameters:
    `file` - the file to load the key store from.

### setPassword

    public void setPassword(String password)

  Sets the key store password. If this value is `null` no password will be used to check the integrity of the key store.

  Parameters:
    `password` - the password or `null` if no password is needed.

### setProvider

    public void setProvider(String provider)

  Sets the name of the provider to use when creating the key store. The default is to use the platform default provider.

  Parameters:
    `provider` - the name of the provider, e.g. SUN.

### setResource

    public void setResource(Resource resource)

  Sets a Spring `Resource` which contains the key store. Either this property or `setFile(File)` have to be set.

  Parameters:
    `resource` - the resource to load the key store from.

### setType

    public void setType(String type)

  Sets the type of key store to create. The default is to create a JKS key store.

  Parameters:
    `type` - the type to use when creating the key store.
  Throws:
    `IllegalArgumentException` - if the specified value is `null`.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2004-2008 Apache MINA Project. All Rights Reserved.