org.ehcache.spi.copy
Class DefaultCopyProvider

java.lang.Object
  extended by org.ehcache.internal.classes.ClassInstanceProvider<java.lang.Class<?>,Copier<?>>
      extended by org.ehcache.spi.copy.DefaultCopyProvider
All Implemented Interfaces:
CopyProvider, Service

public class DefaultCopyProvider
extends ClassInstanceProvider<java.lang.Class<?>,Copier<?>>
implements CopyProvider


Field Summary
 
Fields inherited from class org.ehcache.internal.classes.ClassInstanceProvider
preconfigured, providedVsCount
 
Constructor Summary
DefaultCopyProvider(DefaultCopyProviderConfiguration configuration)
           
 
Method Summary
<T> Copier<T>
createKeyCopier(java.lang.Class<T> clazz, Serializer<T> serializer, ServiceConfiguration<?>... configs)
          Creates a key Copier with the given parameters.
<T> Copier<T>
createValueCopier(java.lang.Class<T> clazz, Serializer<T> serializer, ServiceConfiguration<?>... configs)
          Creates a value Copier with the given parameters.
 
Methods inherited from class org.ehcache.internal.classes.ClassInstanceProvider
getPreconfigured, newInstance, newInstance, releaseInstance, start, stop
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.ehcache.spi.service.Service
start, stop
 

Constructor Detail

DefaultCopyProvider

public DefaultCopyProvider(DefaultCopyProviderConfiguration configuration)
Method Detail

createKeyCopier

public <T> Copier<T> createKeyCopier(java.lang.Class<T> clazz,
                                     Serializer<T> serializer,
                                     ServiceConfiguration<?>... configs)
Description copied from interface: CopyProvider
Creates a key Copier with the given parameters.

Specified by:
createKeyCopier in interface CopyProvider
Type Parameters:
T - the type to copy to/from
Parameters:
clazz - the class of the type to copy to/from
serializer - the serializer that can be used to perform the copying. The usage is optional though.
configs - specific configurations
Returns:
a Copier instance

createValueCopier

public <T> Copier<T> createValueCopier(java.lang.Class<T> clazz,
                                       Serializer<T> serializer,
                                       ServiceConfiguration<?>... configs)
Description copied from interface: CopyProvider
Creates a value Copier with the given parameters.

Specified by:
createValueCopier in interface CopyProvider
Type Parameters:
T - the type to copy to/from
Parameters:
clazz - the class of the type to copy to/from
serializer - the serializer that can be used to perform the copying. The usage is optional though.
configs - specific configurations
Returns:
a Copier instance