/** {@inheritDoc} */
  @Override
  public void prepareMarshal(GridCacheContext<K, V> ctx) throws GridException {
    super.prepareMarshal(ctx);

    if (entries != null) {
      if (ctx.deploymentEnabled()) prepareObjects(entries, ctx);

      entriesBytes = ctx.marshaller().marshal(entries);
    }
  }
예제 #2
0
  /** {@inheritDoc} */
  @Override
  protected void clone0(GridTcpCommunicationMessageAdapter _msg) {
    super.clone0(_msg);

    GridCacheDgcRequest _clone = (GridCacheDgcRequest) _msg;

    _clone.map = map;
    _clone.mapBytes = mapBytes;
    _clone.rmvLocks = rmvLocks;
  }
  /** {@inheritDoc} */
  @Override
  protected void clone0(GridTcpCommunicationMessageAdapter _msg) {
    super.clone0(_msg);

    GridCacheEvictionRequest _clone = (GridCacheEvictionRequest) _msg;

    _clone.futId = futId;
    _clone.entries = entries;
    _clone.entriesBytes = entriesBytes;
    _clone.topVer = topVer;
  }
  /** {@inheritDoc} */
  @Override
  protected void clone0(GridTcpCommunicationMessageAdapter _msg) {
    super.clone0(_msg);

    GridCacheEvictionResponse _clone = (GridCacheEvictionResponse) _msg;

    _clone.futId = futId;
    _clone.rejectedKeys = rejectedKeys;
    _clone.rejectedKeyBytes = rejectedKeyBytes;
    _clone.err = err;
  }
예제 #5
0
  /** {@inheritDoc} */
  @Override
  public void finishUnmarshal(GridCacheContext<K, V> ctx, ClassLoader ldr) throws GridException {
    super.finishUnmarshal(ctx, ldr);

    if (errBytes != null) err = ctx.marshaller().unmarshal(errBytes, ldr);

    metadata = unmarshalCollection(metaDataBytes, ctx, ldr);
    data =
        fields
            ? unmarshalFieldsCollection(dataBytes, ctx, ldr)
            : unmarshalCollection(dataBytes, ctx, ldr);
  }
예제 #6
0
  /** {@inheritDoc} */
  @Override
  public void prepareMarshal(GridCacheContext<K, V> ctx) throws GridException {
    super.prepareMarshal(ctx);

    if (map != null) {
      if (ctx.deploymentEnabled()) {
        for (K key : map.keySet()) prepareObject(key, ctx);
      }

      mapBytes = CU.marshal(ctx, map);
    }
  }
예제 #7
0
  /** {@inheritDoc} */
  @Override
  protected void clone0(GridTcpCommunicationMessageAdapter _msg) {
    super.clone0(_msg);

    GridCacheQueryResponse _clone = (GridCacheQueryResponse) _msg;

    _clone.finished = finished;
    _clone.reqId = reqId;
    _clone.err = err;
    _clone.errBytes = errBytes;
    _clone.fields = fields;
    _clone.metaDataBytes = metaDataBytes;
    _clone.metadata = metadata;
    _clone.dataBytes = dataBytes;
    _clone.data = data;
  }
예제 #8
0
  /** {@inheritDoc} */
  @Override
  public void prepareMarshal(GridCacheContext<K, V> ctx) throws GridException {
    super.prepareMarshal(ctx);

    if (err != null) errBytes = ctx.marshaller().marshal(err);

    metaDataBytes = marshalCollection(metadata, ctx);
    dataBytes = fields ? marshalFieldsCollection(data, ctx) : marshalCollection(data, ctx);

    if (ctx.deploymentEnabled() && !F.isEmpty(data)) {
      for (Object o : data) {
        if (o instanceof Map.Entry) {
          Map.Entry e = (Map.Entry) o;

          prepareObject(e.getKey(), ctx);
          prepareObject(e.getValue(), ctx);
        }
      }
    }
  }
  /** {@inheritDoc} */
  @Override
  public void finishUnmarshal(GridCacheContext<K, V> ctx, ClassLoader ldr) throws GridException {
    super.finishUnmarshal(ctx, ldr);

    if (entriesBytes != null) entries = ctx.marshaller().unmarshal(entriesBytes, ldr);
  }
  /** {@inheritDoc} */
  @Override
  public void finishUnmarshal(GridCacheContext<K, V> ctx, ClassLoader ldr) throws GridException {
    super.finishUnmarshal(ctx, ldr);

    rejectedKeys = unmarshalCollection(rejectedKeyBytes, ctx, ldr);
  }
  /** {@inheritDoc} */
  @Override
  public void prepareMarshal(GridCacheContext<K, V> ctx) throws GridException {
    super.prepareMarshal(ctx);

    rejectedKeyBytes = marshalCollection(rejectedKeys, ctx);
  }