All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.infinispan.persistence.keymappers.Key2StringMapper Maven / Gradle / Ivy

There is a newer version: 9.1.7.Final
Show newest version
package org.infinispan.persistence.keymappers;

/**
 * Defines the logic of mapping a key object to a String. This is required by certain cache stores, in order
 * to map each key to a String which the underlying store is capable of handling. It should generate a unique String
 * based on the supplied key.
 *
 * @author [email protected]
 * @author Manik Surtani
 */
public interface Key2StringMapper {

   /**
    * Do we support this key type?
    * @param keyType type to test
    * @return true if the type is supported, false otherwise.
    */
   boolean isSupportedType(Class keyType);

   /**
    * Must return an unique String for the supplied key.
    * @param key key to map to a String
    * @return String representation of the key
    */
   String getStringMapping(Object key);
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy