blob: c1f9f58af0a42768532a1fd3faec52bf62732209 [file] [log] [blame]
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.15"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Apache Geode Native C++ Reference: apache::geode::client::Delta Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(initResizable);
/* @license-end */</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<td id="projectalign" style="padding-left: 0.5em;">
<div id="projectname">Apache Geode Native C++ Reference
&#160;<span id="projectnumber">1.13.0</span>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.15 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
initMenu('',true,false,'search.php','Search');
$(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
<div id="nav-tree">
<div id="nav-tree-contents">
<div id="nav-sync" class="sync"></div>
</div>
</div>
<div id="splitbar" style="-moz-user-select:none;"
class="ui-resizable-handle">
</div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('a00455.html','');});
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0"
name="MSearchResults" id="MSearchResults">
</iframe>
</div>
<div class="header">
<div class="summary">
<a href="#pub-methods">Public Member Functions</a> </div>
<div class="headertitle">
<div class="title">apache::geode::client::Delta Class Reference<span class="mlabels"><span class="mlabel">abstract</span></span></div> </div>
</div><!--header-->
<div class="contents">
<p>This interface is used for delta propagation.
<a href="a00455.html#details">More...</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a1e7f453bd111f2d0dc24d97e47cd7810"><td class="memItemLeft" align="right" valign="top">virtual std::shared_ptr&lt; <a class="el" href="a00455.html">Delta</a> &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00455.html#a1e7f453bd111f2d0dc24d97e47cd7810">clone</a> () const =0</td></tr>
<tr class="memdesc:a1e7f453bd111f2d0dc24d97e47cd7810"><td class="mdescLeft">&#160;</td><td class="mdescRight">Creates a copy of the object on which delta is to be applied via notification. <a href="#a1e7f453bd111f2d0dc24d97e47cd7810">More...</a><br /></td></tr>
<tr class="separator:a1e7f453bd111f2d0dc24d97e47cd7810"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a722438e8f9011c8943b400d726d784f3"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00455.html#a722438e8f9011c8943b400d726d784f3">fromDelta</a> (<a class="el" href="a00435.html">DataInput</a> &amp;in)=0</td></tr>
<tr class="memdesc:a722438e8f9011c8943b400d726d784f3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Reads in delta information to this object in a user-defined format. <a href="#a722438e8f9011c8943b400d726d784f3">More...</a><br /></td></tr>
<tr class="separator:a722438e8f9011c8943b400d726d784f3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aee49a30db31321cde7673481ff2f3fe5"><td class="memItemLeft" align="right" valign="top">virtual bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00455.html#aee49a30db31321cde7673481ff2f3fe5">hasDelta</a> () const =0</td></tr>
<tr class="memdesc:aee49a30db31321cde7673481ff2f3fe5"><td class="mdescLeft">&#160;</td><td class="mdescRight"><code><a class="el" href="a00455.html#aee49a30db31321cde7673481ff2f3fe5" title="hasDelta( ) is invoked by Geode during Region::put( std::shared_ptr&lt;CacheableKey&gt;,...">hasDelta( )</a></code> is invoked by Geode during <code><a class="el" href="a00815.html#a6d37f770f04349d9c06799ab2ea4329e" title="Places a new value into an entry in this region with the specified key, providing a user-defined para...">Region::put</a>( std::shared_ptr&lt;CacheableKey&gt;, std::shared_ptr&lt;Cacheable&gt; )</code> to determine if the object contains a delta. <a href="#aee49a30db31321cde7673481ff2f3fe5">More...</a><br /></td></tr>
<tr class="separator:aee49a30db31321cde7673481ff2f3fe5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:afa848968dd5ee554afaa0eb33537a7fb"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00455.html#afa848968dd5ee554afaa0eb33537a7fb">toDelta</a> (<a class="el" href="a00439.html">DataOutput</a> &amp;out) const =0</td></tr>
<tr class="memdesc:afa848968dd5ee554afaa0eb33537a7fb"><td class="mdescLeft">&#160;</td><td class="mdescRight">Writes out delta information to out in a user-defined format. <a href="#afa848968dd5ee554afaa0eb33537a7fb">More...</a><br /></td></tr>
<tr class="separator:afa848968dd5ee554afaa0eb33537a7fb"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>This interface is used for delta propagation. </p>
<p>To use delta propagation, an application class must derive from <code>class <a class="el" href="a00455.html" title="This interface is used for delta propagation.">Delta</a></code> as well as <code>class Cacheable</code> publicly. The methods <code><a class="el" href="a00455.html#aee49a30db31321cde7673481ff2f3fe5" title="hasDelta( ) is invoked by Geode during Region::put( std::shared_ptr&lt;CacheableKey&gt;,...">hasDelta( )</a>, <a class="el" href="a00455.html#afa848968dd5ee554afaa0eb33537a7fb" title="Writes out delta information to out in a user-defined format.">toDelta( )</a></code> and <code>fromDelta( )</code> must be implemented by the class, as these methods are used by Geode to detect the presence of delta in an object, to serialize the delta, and to apply a serialized delta to an existing object of the class. </p>
</div><h2 class="groupheader">Member Function Documentation</h2>
<a id="a1e7f453bd111f2d0dc24d97e47cd7810"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1e7f453bd111f2d0dc24d97e47cd7810">&#9670;&nbsp;</a></span>clone()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual std::shared_ptr&lt;<a class="el" href="a00455.html">Delta</a>&gt; apache::geode::client::Delta::clone </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">pure virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Creates a copy of the object on which delta is to be applied via notification. </p>
<p>The region attribute for cloning must be set to 'true' in order to enable cloning. </p>
</div>
</div>
<a id="a722438e8f9011c8943b400d726d784f3"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a722438e8f9011c8943b400d726d784f3">&#9670;&nbsp;</a></span>fromDelta()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual void apache::geode::client::Delta::fromDelta </td>
<td>(</td>
<td class="paramtype"><a class="el" href="a00435.html">DataInput</a> &amp;&#160;</td>
<td class="paramname"><em>in</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">pure virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Reads in delta information to this object in a user-defined format. </p>
<p>This is invoked on an existing application object after Geode determines the presence of delta in <code><a class="el" href="a00435.html" title="Provide operations for reading primitive data values, byte arrays, strings, Serializable objects from...">DataInput</a></code> instance.</p>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname">IOException</td><td></td></tr>
<tr><td class="paramname"><a class="el" href="a00691.html" title="Thrown if Delta could not be applied.">InvalidDeltaException</a></td><td>if the delta in the <code><a class="el" href="a00435.html" title="Provide operations for reading primitive data values, byte arrays, strings, Serializable objects from...">DataInput</a></code> instance cannot be applied to this instance (possible causes may include mismatch of <a class="el" href="a00455.html" title="This interface is used for delta propagation.">Delta</a> version or logic error). </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a id="aee49a30db31321cde7673481ff2f3fe5"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aee49a30db31321cde7673481ff2f3fe5">&#9670;&nbsp;</a></span>hasDelta()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual bool apache::geode::client::Delta::hasDelta </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">pure virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p><code><a class="el" href="a00455.html#aee49a30db31321cde7673481ff2f3fe5" title="hasDelta( ) is invoked by Geode during Region::put( std::shared_ptr&lt;CacheableKey&gt;,...">hasDelta( )</a></code> is invoked by Geode during <code><a class="el" href="a00815.html#a6d37f770f04349d9c06799ab2ea4329e" title="Places a new value into an entry in this region with the specified key, providing a user-defined para...">Region::put</a>( std::shared_ptr&lt;CacheableKey&gt;, std::shared_ptr&lt;Cacheable&gt; )</code> to determine if the object contains a delta. </p>
<p>If <code><a class="el" href="a00455.html#aee49a30db31321cde7673481ff2f3fe5" title="hasDelta( ) is invoked by Geode during Region::put( std::shared_ptr&lt;CacheableKey&gt;,...">hasDelta( )</a></code> returns true, the delta in the object is serialized by invoking <code>Delta::toDelta( DataOutput&amp; )</code>. If <code><a class="el" href="a00455.html#aee49a30db31321cde7673481ff2f3fe5" title="hasDelta( ) is invoked by Geode during Region::put( std::shared_ptr&lt;CacheableKey&gt;,...">hasDelta( )</a></code> returns false, the object is serialized by invoking <code>Cacheable::toData( DataOutput&amp; )</code>. </p>
</div>
</div>
<a id="afa848968dd5ee554afaa0eb33537a7fb"></a>
<h2 class="memtitle"><span class="permalink"><a href="#afa848968dd5ee554afaa0eb33537a7fb">&#9670;&nbsp;</a></span>toDelta()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual void apache::geode::client::Delta::toDelta </td>
<td>(</td>
<td class="paramtype"><a class="el" href="a00439.html">DataOutput</a> &amp;&#160;</td>
<td class="paramname"><em>out</em></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">pure virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Writes out delta information to out in a user-defined format. </p>
<p>This is invoked on an application object after Geode determines the presence of delta in it by calling <code><a class="el" href="a00455.html#aee49a30db31321cde7673481ff2f3fe5" title="hasDelta( ) is invoked by Geode during Region::put( std::shared_ptr&lt;CacheableKey&gt;,...">hasDelta()</a></code> on the object.</p>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname">IOException</td><td></td></tr>
</table>
</dd>
</dl>
</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<HR><address style="align: right;"><small>Apache Geode C++ Cache API Documentation</small></address>