Package org.apache.ignite.internal.pagemem.wal.record

## Class UnwrapDataEntry

- java.lang.Object
- - org.apache.ignite.internal.pagemem.wal.record.DataEntry
  - - org.apache.ignite.internal.pagemem.wal.record.UnwrapDataEntry

    public class UnwrapDataEntry
    extends DataEntry

Data Entry for automatic unwrapping key and value from Data Entry

### Field Summary

### Fields inherited from class org.apache.ignite.internal.pagemem.wal.record.DataEntry

`cacheId, EMPTY_FLAGS, expireTime, flags, FROM_STORE_FLAG, key, nearXidVer, op, partCnt, partId, PRELOAD_FLAG, PRIMARY_FLAG, val, writeVer`

### Constructor Summary

Constructors
`UnwrapDataEntry​(int cacheId, KeyCacheObject key, CacheObject val, GridCacheOperation op, GridCacheVersion nearXidVer, GridCacheVersion writeVer, long expireTime, int partId, long partCnt, CacheObjectValueContext cacheObjValCtx, boolean keepBinary, byte flags)`

### Method Summary

All Methods Static Methods Instance Methods Concrete Methods
`String` `toString()`
`static Object` `unwrapKey​(KeyCacheObject key, boolean keepBinary, CacheObjectValueContext cacheObjValCtx)`
`Object` `unwrappedKey()` Unwraps key from cache key object into primitive boxed type or source class.
`Object` `unwrappedValue()` Unwraps value from cache value object into primitive boxed type or source class.
`static Object` `unwrapValue​(CacheObject val, boolean keepBinary, CacheObjectValueContext cacheObjValCtx)`

### Methods inherited from class org.apache.ignite.internal.pagemem.wal.record.DataEntry

`cacheId, expireTime, flags, flags, flags, key, nearXidVersion, op, partitionCounter, partitionCounter, partitionId, value, writeVersion`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Constructor Detail

#### UnwrapDataEntry

    public UnwrapDataEntry​(int cacheId,
                           KeyCacheObject key,
                           CacheObject val,
                           GridCacheOperation op,
                           GridCacheVersion nearXidVer,
                           GridCacheVersion writeVer,
                           long expireTime,
                           int partId,
                           long partCnt,
                           CacheObjectValueContext cacheObjValCtx,
                           boolean keepBinary,
                           byte flags)

Parameters:
  `cacheId` - Cache ID.
  `key` - Key.
  `val` - Value or null for delete operation.
  `op` - Operation.
  `nearXidVer` - Near transaction version.
  `writeVer` - Write version.
  `expireTime` - Expire time.
  `partId` - Partition ID.
  `partCnt` - Partition counter.
  `cacheObjValCtx` - cache object value context for unwrapping objects.
  `keepBinary` - disable unwrapping for non primitive objects, Binary Objects would be returned instead.
  `flags` - Flags.

### Method Detail

#### unwrappedKey

    public Object unwrappedKey()

Unwraps key from cache key object into primitive boxed type or source class. If client classes were used in key, call of this method requires classes to be available in classpath.

Returns:
  Key which was placed into cache. Or null if failed to convert.

#### unwrappedValue

    public Object unwrappedValue()

Unwraps value from cache value object into primitive boxed type or source class. If client classes were used in key, call of this method requires classes to be available in classpath.

Returns:
  Value which was placed into cache. Or null for delete operation or for failure.

#### unwrapKey

    public static Object unwrapKey​(KeyCacheObject key,
                                   boolean keepBinary,
                                   CacheObjectValueContext cacheObjValCtx)

#### unwrapValue

    public static Object unwrapValue​(CacheObject val,
                                     boolean keepBinary,
                                     CacheObjectValueContext cacheObjValCtx)

#### toString

    public String toString()

Overrides:
  `toString` in class `DataEntry`