Apache Geode Native C++ Reference 1.15.0
Delta.hpp
Go to the documentation of this file.
1/*
2 * Licensed to the Apache Software Foundation (ASF) under one or more
3 * contributor license agreements. See the NOTICE file distributed with
4 * this work for additional information regarding copyright ownership.
5 * The ASF licenses this file to You under the Apache License, Version 2.0
6 * (the "License"); you may not use this file except in compliance with
7 * the License. You may obtain a copy of the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
16 */
17
18#pragma once
19
20#ifndef GEODE_DELTA_H_
21#define GEODE_DELTA_H_
22
27#include <memory>
28
29#include "internal/geode_globals.hpp"
30
31namespace apache {
32namespace geode {
33namespace client {
34
35class DataInput;
36class DataOutput;
37
50class APACHE_GEODE_EXPORT Delta {
51 public:
61 virtual bool hasDelta() const = 0;
62
70 virtual void toDelta(DataOutput& out) const = 0;
71
83 virtual void fromDelta(DataInput& in) = 0;
84
91 virtual std::shared_ptr<Delta> clone() const = 0;
92
93 virtual ~Delta() = default;
94
95 protected:
96 Delta() = default;
97};
98} // namespace client
99} // namespace geode
100} // namespace apache
101
102#endif // GEODE_DELTA_H_
Provide operations for reading primitive data values, byte arrays, strings, Serializable objects from...
Definition: DataInput.hpp:59
Provide operations for writing primitive data values, byte arrays, strings, Serializable objects to a...
Definition: DataOutput.hpp:48
This interface is used for delta propagation.
Definition: Delta.hpp:50
virtual void fromDelta(DataInput &in)=0
Reads in delta information to this object in a user-defined format.
virtual std::shared_ptr< Delta > clone() const =0
Creates a copy of the object on which delta is to be applied via notification.
virtual bool hasDelta() const =0
hasDelta( ) is invoked by Geode during Region::put( std::shared_ptr<CacheableKey>,...
virtual void toDelta(DataOutput &out) const =0
Writes out delta information to out in a user-defined format.

Apache Geode C++ Cache API Documentation