Merge remote branch 'upstream/master'

Conflicts:
	GameServer/alert-config.xml
	GameServer/src/org/moparscape/msc/gs/model/mini/CacheObject.java

...
This commit is contained in:
CodeForFame 2011-06-24 16:49:23 -05:00
commit 7fb4b90387
2 changed files with 31 additions and 0 deletions

View File

@ -22,5 +22,9 @@
<priority>1</priority>
</email>
</user>
<<<<<<< HEAD
</alert>
=======
</alert>
>>>>>>> upstream/master

View File

@ -0,0 +1,27 @@
package org.moparscape.msc.gs;
import java.util.Map;
import org.apache.commons.collections.map.LRUMap;
/**
* A basic cache backed by a {@link LRUMap}.
*
* @author CodeForFame
*
*/
public class Cache<K, V> {
// Shitty commons and their failure to support generics...
@SuppressWarnings("unchecked")
private Map<K, V> cache = new LRUMap();
public V get(K key) {
return cache.get(key);
}
public void put(K key, V value) {
cache.put(key, value);
}
}