01: /*
02: * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright notice. All rights reserved.
03: */
04: package com.tc.objectserver.persistence.sleepycat;
05:
06: import com.sleepycat.bind.serial.ClassCatalog;
07: import com.tc.io.serializer.impl.StringUTFSerializer;
08: import com.tc.objectserver.managedobject.ManagedObjectSerializer;
09: import com.tc.objectserver.managedobject.ManagedObjectStateSerializer;
10:
11: public class CustomSerializationAdapterFactory implements
12: SerializationAdapterFactory {
13:
14: public SerializationAdapter newAdapter(ClassCatalog classCatalog) {
15: ManagedObjectStateSerializer stateSerializer = new ManagedObjectStateSerializer();
16: ManagedObjectSerializer moSerializer = new ManagedObjectSerializer(
17: stateSerializer);
18: StringUTFSerializer stringSerializer = new StringUTFSerializer();
19: return new CustomSerializationAdapter(moSerializer,
20: stringSerializer);
21: }
22: }
|