01: package com.completex.objective.components.ocache;
02:
03: /**
04: * Create key out of the value object
05: *
06: * @author Gennady Krizhevsky
07: */
08: public interface OdalKeyFactory {
09:
10: /**
11: * Returns key created out of the value object
12: *
13: * @param value value used to generate the key
14: * @return key created out of the value object
15: */
16: Object key(Object value);
17:
18: /**
19: * Null OdalKeyFactory
20: */
21: public static final OdalKeyFactory NULL_ODAL_KEY_FACTORY = new OdalKeyFactory() {
22: public Object key(Object seed) {
23: return seed;
24: }
25: };
26:
27: }
|