Package com.cetsoft.imcache.bytebuffer

Examples of com.cetsoft.imcache.bytebuffer.Pointer


   *
   * @see com.cetsoft.imcache.cache.Cache#put(java.lang.Object, java.lang.Object)
   */
  public void put(K key, V value) {
    writeLock(key);
    Pointer pointer = pointerMap.get(key);
    try {
      if (pointer == null) {
        pointer = bufferStore.store(serializer.serialize(value));
      } else {
        synchronized (pointer) {
View Full Code Here


   * (non-Javadoc)
   *
   * @see com.cetsoft.imcache.cache.Cache#get(java.lang.Object)
   */
  public V get(K key) {
    Pointer pointer = pointerMap.get(key);
    if (pointer != null) {
      readLock(key);
      try {
        hit.incrementAndGet();
        synchronized (pointer) {
View Full Code Here

   * @see com.cetsoft.imcache.cache.Cache#invalidate(java.lang.Object)
   */
  public V invalidate(K key) {
    writeLock(key);
    try{
      Pointer pointer = pointerMap.get(key);
      if (pointer != null) {
        synchronized (pointer) {
          byte[] payload = bufferStore.remove(pointer);
          return serializer.deserialize(payload);
        }
View Full Code Here

TOP

Related Classes of com.cetsoft.imcache.bytebuffer.Pointer

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.