org.infinispan.loaders.jdbc.stringbased
Class DefaultKey2StringMapper

java.lang.Object
  extended by org.infinispan.loaders.jdbc.stringbased.DefaultKey2StringMapper
All Implemented Interfaces:
Key2StringMapper

public class DefaultKey2StringMapper
extends Object
implements Key2StringMapper

Default implementation for Key2StringMapper. It supports all the primitive wrappers(e.g. Integer, Long etc).

Author:
Mircea.Markus@jboss.com

Constructor Summary
DefaultKey2StringMapper()
           
 
Method Summary
 String getStringMapping(Object key)
          Returns key.toString.
 boolean isSupportedType(Class key)
          Returns true if this is an primitive wrapper, false otherwise.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultKey2StringMapper

public DefaultKey2StringMapper()
Method Detail

isSupportedType

public boolean isSupportedType(Class key)
Returns true if this is an primitive wrapper, false otherwise.

Specified by:
isSupportedType in interface Key2StringMapper

getStringMapping

public String getStringMapping(Object key)
Returns key.toString. As key being a primitive wrapper, this will ensure that it is unique.

Specified by:
getStringMapping in interface Key2StringMapper

Google Analytics

Copyright © 2010 JBoss, a division of Red Hat. All Rights Reserved.