class LazyDataEntry extends DataEntry implements MarshalledDataEntry {
    /** */
    private GridCacheSharedContext cctx;

    /** Data Entry key type code. See {@link CacheObject} for built-in value type codes */
    private byte keyType;

    /** Key value bytes. */
    private byte[] keyBytes;

    /** Data Entry Value type code. See {@link CacheObject} for built-in value type codes */
    private byte valType;

    /** Value value bytes. */
    private byte[] valBytes;

    /**
     * @param cctx Shared context.
     * @param cacheId Cache ID.
     * @param keyType Object type code for Key.
     * @param keyBytes Data Entry Key value bytes.
     * @param valType Object type code for Value.
     * @param valBytes Data Entry Value value bytes.
     * @param op Operation.
     * @param nearXidVer Near transaction version.
     * @param writeVer Write version.
     * @param expireTime Expire time.
     * @param partId Partition ID.
     * @param partCnt Partition counter.
     * @param flags Flags.
     */
    public LazyDataEntry(
        GridCacheSharedContext cctx,
        int cacheId,
        byte keyType,
        byte[] keyBytes,
        byte valType,
        byte[] valBytes,
        GridCacheOperation op,
        GridCacheVersion nearXidVer,
        GridCacheVersion writeVer,
        long expireTime,
        int partId,
        long partCnt,
        byte flags
    ) {
        super(cacheId, null, null, op, nearXidVer, writeVer, expireTime, partId, partCnt, flags);

        this.cctx = cctx;
        this.keyType = keyType;
        this.keyBytes = keyBytes;
        this.valType = valType;
        this.valBytes = valBytes;
    }

    /** {@inheritDoc} */
    @Override public KeyCacheObject key() {<FILL_FUNCTION_BODY>}

    /** {@inheritDoc} */
    @Override public CacheObject value() {
        if (val == null && valBytes != null) {
            GridCacheContext cacheCtx = cctx.cacheContext(cacheId);

            if (cacheCtx == null)
                throw new IgniteException("Failed to find cache context for the given cache ID: " + cacheId);

            IgniteCacheObjectProcessor co = cctx.kernalContext().cacheObjects();

            val = co.toCacheObject(cacheCtx.cacheObjectContext(), valType, valBytes);
        }

        return val;
    }

    /** {@inheritDoc} */
    @Override public byte getKeyType() {
        return keyType;
    }

    /** {@inheritDoc} */
    @Override public byte[] getKeyBytes() {
        return keyBytes;
    }

    /** {@inheritDoc} */
    @Override public byte getValType() {
        return valType;
    }

    /** {@inheritDoc} */
    @Override public byte[] getValBytes() {
        return valBytes;
    }
}

        try {
            if (key == null) {
                GridCacheContext cacheCtx = cctx.cacheContext(cacheId);

                if (cacheCtx == null)
                    throw new IgniteException("Failed to find cache context for the given cache ID: " + cacheId);

                IgniteCacheObjectProcessor co = cctx.kernalContext().cacheObjects();

                key = co.toKeyCacheObject(cacheCtx.cacheObjectContext(), keyType, keyBytes);

                if (key.partition() == -1)
                    key.partition(partId);
            }

            return key;
        }
        catch (IgniteCheckedException e) {
            throw new IgniteException(e);
        }
    
<methods>public void <init>(int, org.apache.ignite.internal.processors.cache.KeyCacheObject, org.apache.ignite.internal.processors.cache.CacheObject, org.apache.ignite.internal.processors.cache.GridCacheOperation, org.apache.ignite.internal.processors.cache.version.GridCacheVersion, org.apache.ignite.internal.processors.cache.version.GridCacheVersion, long, int, long, byte) ,public int cacheId() ,public long expireTime() ,public static byte flags(boolean) ,public static byte flags(boolean, boolean, boolean) ,public byte flags() ,public org.apache.ignite.internal.processors.cache.KeyCacheObject key() ,public org.apache.ignite.internal.processors.cache.version.GridCacheVersion nearXidVersion() ,public org.apache.ignite.internal.processors.cache.GridCacheOperation op() ,public long partitionCounter() ,public org.apache.ignite.internal.pagemem.wal.record.DataEntry partitionCounter(long) ,public int partitionId() ,public java.lang.String toString() ,public org.apache.ignite.internal.processors.cache.CacheObject value() ,public org.apache.ignite.internal.processors.cache.version.GridCacheVersion writeVersion() <variables>public static final byte EMPTY_FLAGS,public static final byte FROM_STORE_FLAG,public static final byte PRELOAD_FLAG,public static final byte PRIMARY_FLAG,protected int cacheId,protected long expireTime,protected byte flags,protected org.apache.ignite.internal.processors.cache.KeyCacheObject key,protected org.apache.ignite.internal.processors.cache.version.GridCacheVersion nearXidVer,protected org.apache.ignite.internal.processors.cache.GridCacheOperation op,protected long partCnt,protected int partId,protected org.apache.ignite.internal.processors.cache.CacheObject val,protected org.apache.ignite.internal.processors.cache.version.GridCacheVersion writeVer