| <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> | |
| <!-- NewPage --> | |
| <html lang="en"> | |
| <head> | |
| <!-- Generated by javadoc (1.8.0) on Sun Aug 28 20:43:00 EST 2016 --> | |
| <title>ReliableLog (Apache River v3.0.0 API Documentation (internals))</title> | |
| <meta name="date" content="2016-08-28"> | |
| <link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style"> | |
| <script type="text/javascript" src="../../../../script.js"></script> | |
| </head> | |
| <body> | |
| <script type="text/javascript"><!-- | |
| try { | |
| if (location.href.indexOf('is-external=true') == -1) { | |
| parent.document.title="ReliableLog (Apache River v3.0.0 API Documentation (internals))"; | |
| } | |
| } | |
| catch(err) { | |
| } | |
| //--> | |
| var methods = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10,"i6":10,"i7":10,"i8":10,"i9":10,"i10":10,"i11":10,"i12":10,"i13":10,"i14":10,"i15":10,"i16":10}; | |
| var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],8:["t4","Concrete Methods"]}; | |
| var altColor = "altColor"; | |
| var rowColor = "rowColor"; | |
| var tableTab = "tableTab"; | |
| var activeTableTab = "activeTableTab"; | |
| </script> | |
| <noscript> | |
| <div>JavaScript is disabled on your browser.</div> | |
| </noscript> | |
| <!-- ========= START OF TOP NAVBAR ======= --> | |
| <div class="topNav"><a name="navbar.top"> | |
| <!-- --> | |
| </a> | |
| <div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div> | |
| <a name="navbar.top.firstrow"> | |
| <!-- --> | |
| </a> | |
| <ul class="navList" title="Navigation"> | |
| <li><a href="../../../../overview-summary.html">Overview</a></li> | |
| <li><a href="package-summary.html">Package</a></li> | |
| <li class="navBarCell1Rev">Class</li> | |
| <li><a href="class-use/ReliableLog.html">Use</a></li> | |
| <li><a href="package-tree.html">Tree</a></li> | |
| <li><a href="../../../../deprecated-list.html">Deprecated</a></li> | |
| <li><a href="../../../../index-all.html">Index</a></li> | |
| <li><a href="../../../../help-doc.html">Help</a></li> | |
| </ul> | |
| </div> | |
| <div class="subNav"> | |
| <ul class="navList"> | |
| <li><a href="../../../../org/apache/river/reliableLog/LogOutputStream.html" title="class in org.apache.river.reliableLog"><span class="typeNameLink">Prev Class</span></a></li> | |
| <li>Next Class</li> | |
| </ul> | |
| <ul class="navList"> | |
| <li><a href="../../../../index.html?org/apache/river/reliableLog/ReliableLog.html" target="_top">Frames</a></li> | |
| <li><a href="ReliableLog.html" target="_top">No Frames</a></li> | |
| </ul> | |
| <ul class="navList" id="allclasses_navbar_top"> | |
| <li><a href="../../../../allclasses-noframe.html">All Classes</a></li> | |
| </ul> | |
| <div> | |
| <script type="text/javascript"><!-- | |
| allClassesLink = document.getElementById("allclasses_navbar_top"); | |
| if(window==top) { | |
| allClassesLink.style.display = "block"; | |
| } | |
| else { | |
| allClassesLink.style.display = "none"; | |
| } | |
| //--> | |
| </script> | |
| </div> | |
| <div> | |
| <ul class="subNavList"> | |
| <li>Summary: </li> | |
| <li>Nested | </li> | |
| <li><a href="#field.summary">Field</a> | </li> | |
| <li><a href="#constructor.summary">Constr</a> | </li> | |
| <li><a href="#method.summary">Method</a></li> | |
| </ul> | |
| <ul class="subNavList"> | |
| <li>Detail: </li> | |
| <li><a href="#field.detail">Field</a> | </li> | |
| <li><a href="#constructor.detail">Constr</a> | </li> | |
| <li><a href="#method.detail">Method</a></li> | |
| </ul> | |
| </div> | |
| <a name="skip.navbar.top"> | |
| <!-- --> | |
| </a></div> | |
| <!-- ========= END OF TOP NAVBAR ========= --> | |
| <!-- ======== START OF CLASS DATA ======== --> | |
| <div class="header"> | |
| <div class="subTitle">org.apache.river.reliableLog</div> | |
| <h2 title="Class ReliableLog" class="title">Class ReliableLog</h2> | |
| </div> | |
| <div class="contentContainer"> | |
| <ul class="inheritance"> | |
| <li><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li> | |
| <li> | |
| <ul class="inheritance"> | |
| <li>org.apache.river.reliableLog.ReliableLog</li> | |
| </ul> | |
| </li> | |
| </ul> | |
| <div class="description"> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <hr> | |
| <br> | |
| <pre>public class <span class="typeNameLabel">ReliableLog</span> | |
| extends <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></pre> | |
| <div class="block">This class is a simple implementation of a reliable Log. The | |
| client of a ReliableLog must provide a set of callbacks (via a | |
| LogHandler) that enables a ReliableLog to read and write snapshots | |
| (checkpoints) and log records. This implementation ensures that the | |
| data stored (via a ReliableLog) is recoverable after a system crash. | |
| The implementation is unsynchronized; the client must synchronize | |
| externally. <p> | |
| The secondary storage strategy is to record values in files using a | |
| representation of the caller's choosing. Two sorts of files are | |
| kept: snapshots and logs. At any instant, one snapshot is current. | |
| The log consists of a sequence of updates that have occurred since | |
| the current snapshot was taken. The current stable state is the | |
| value of the snapshot, as modified by the sequence of updates in | |
| the log. From time to time, the client of a ReliableLog instructs | |
| the package to make a new snapshot and clear the log. A ReliableLog | |
| arranges disk writes such that updates are stable (as long as the | |
| changes are force-written to disk) and atomic: no update is lost, | |
| and each update either is recorded completely in the log or not at | |
| all. Making a new snapshot is also atomic. <p> | |
| Normal use for maintaining the recoverable store is as follows: The | |
| client maintains the relevant data structure in virtual memory. As | |
| updates happen to the structure, the client informs the ReliableLog | |
| (call it "log") by calling log.update. Periodically, the client | |
| calls log.snapshot to provide the current complete contents of the | |
| data. On restart, the client calls log.recover to obtain the | |
| latest snapshot and the following sequences of updates; the client | |
| applies the updates to the snapshot to obtain the state that | |
| existed before the crash. <p></div> | |
| <dl> | |
| <dt><span class="simpleTagLabel">Author:</span></dt> | |
| <dd>Sun Microsystems, Inc.</dd> | |
| <dt><span class="seeLabel">See Also:</span></dt> | |
| <dd><a href="../../../../org/apache/river/reliableLog/LogHandler.html" title="class in org.apache.river.reliableLog"><code>LogHandler</code></a></dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| </div> | |
| <div class="summary"> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <!-- =========== FIELD SUMMARY =========== --> | |
| <ul class="blockList"> | |
| <li class="blockList"><a name="field.summary"> | |
| <!-- --> | |
| </a> | |
| <h3>Field Summary</h3> | |
| <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Field Summary table, listing fields, and an explanation"> | |
| <caption><span>Fields</span><span class="tabEnd"> </span></caption> | |
| <tr> | |
| <th class="colFirst" scope="col">Modifier and Type</th> | |
| <th class="colLast" scope="col">Field and Description</th> | |
| </tr> | |
| <tr class="altColor"> | |
| <td class="colFirst"><code>private <a href="http://docs.oracle.com/javase/6/docs/api/java/io/File.html?is-external=true" title="class or interface in java.io">File</a></code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#dir">dir</a></span></code> </td> | |
| </tr> | |
| <tr class="rowColor"> | |
| <td class="colFirst"><code>private int</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#format">format</a></span></code> </td> | |
| </tr> | |
| <tr class="altColor"> | |
| <td class="colFirst"><code>private static int</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#FORMAT_PADDED">FORMAT_PADDED</a></span></code> </td> | |
| </tr> | |
| <tr class="rowColor"> | |
| <td class="colFirst"><code>private static int</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#FORMAT_UNPADDED">FORMAT_UNPADDED</a></span></code> </td> | |
| </tr> | |
| <tr class="altColor"> | |
| <td class="colFirst"><code>private <a href="../../../../org/apache/river/reliableLog/LogHandler.html" title="class in org.apache.river.reliableLog">LogHandler</a></code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#handler">handler</a></span></code> </td> | |
| </tr> | |
| <tr class="rowColor"> | |
| <td class="colFirst"><code>private byte[]</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#intBuf">intBuf</a></span></code> </td> | |
| </tr> | |
| <tr class="altColor"> | |
| <td class="colFirst"><code>private static long</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#intBytes">intBytes</a></span></code> </td> | |
| </tr> | |
| <tr class="rowColor"> | |
| <td class="colFirst"><code>private <a href="http://docs.oracle.com/javase/6/docs/api/java/io/RandomAccessFile.html?is-external=true" title="class or interface in java.io">RandomAccessFile</a></code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#log">log</a></span></code> </td> | |
| </tr> | |
| <tr class="altColor"> | |
| <td class="colFirst"><code>private long</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#logBytes">logBytes</a></span></code> </td> | |
| </tr> | |
| <tr class="rowColor"> | |
| <td class="colFirst"><code>private <a href="http://docs.oracle.com/javase/6/docs/api/java/io/FileDescriptor.html?is-external=true" title="class or interface in java.io">FileDescriptor</a></code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#logFD">logFD</a></span></code> </td> | |
| </tr> | |
| <tr class="altColor"> | |
| <td class="colFirst"><code>private static <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#logfilePrefix">logfilePrefix</a></span></code> </td> | |
| </tr> | |
| <tr class="rowColor"> | |
| <td class="colFirst"><code>private <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#logName">logName</a></span></code> </td> | |
| </tr> | |
| <tr class="altColor"> | |
| <td class="colFirst"><code>private static int</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#MAGIC">MAGIC</a></span></code> </td> | |
| </tr> | |
| <tr class="rowColor"> | |
| <td class="colFirst"><code>private long</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#snapshotBytes">snapshotBytes</a></span></code> </td> | |
| </tr> | |
| <tr class="altColor"> | |
| <td class="colFirst"><code>private static <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#snapshotPrefix">snapshotPrefix</a></span></code> </td> | |
| </tr> | |
| <tr class="rowColor"> | |
| <td class="colFirst"><code>private int</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#version">version</a></span></code> </td> | |
| </tr> | |
| <tr class="altColor"> | |
| <td class="colFirst"><code>private static <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#versionFile">versionFile</a></span></code> </td> | |
| </tr> | |
| <tr class="rowColor"> | |
| <td class="colFirst"><code>private byte[]</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#zeroBuf">zeroBuf</a></span></code> </td> | |
| </tr> | |
| </table> | |
| </li> | |
| </ul> | |
| <!-- ======== CONSTRUCTOR SUMMARY ======== --> | |
| <ul class="blockList"> | |
| <li class="blockList"><a name="constructor.summary"> | |
| <!-- --> | |
| </a> | |
| <h3>Constructor Summary</h3> | |
| <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation"> | |
| <caption><span>Constructors</span><span class="tabEnd"> </span></caption> | |
| <tr> | |
| <th class="colOne" scope="col">Constructor and Description</th> | |
| </tr> | |
| <tr class="altColor"> | |
| <td class="colOne"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#ReliableLog-java.lang.String-org.apache.river.reliableLog.LogHandler-">ReliableLog</a></span>(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> dirPath, | |
| <a href="../../../../org/apache/river/reliableLog/LogHandler.html" title="class in org.apache.river.reliableLog">LogHandler</a> handler)</code> | |
| <div class="block">Creates a ReliableLog to handle snapshots and logging in a | |
| stable storage directory, and sets up to recover any existing data | |
| from the stable storage directory.</div> | |
| </td> | |
| </tr> | |
| </table> | |
| </li> | |
| </ul> | |
| <!-- ========== METHOD SUMMARY =========== --> | |
| <ul class="blockList"> | |
| <li class="blockList"><a name="method.summary"> | |
| <!-- --> | |
| </a> | |
| <h3>Method Summary</h3> | |
| <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation"> | |
| <caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd"> </span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd"> </span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd"> </span></span></caption> | |
| <tr> | |
| <th class="colFirst" scope="col">Modifier and Type</th> | |
| <th class="colLast" scope="col">Method and Description</th> | |
| </tr> | |
| <tr id="i0" class="altColor"> | |
| <td class="colFirst"><code>void</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#close--">close</a></span>()</code> | |
| <div class="block">Closes the stable storage directory in an orderly manner.</div> | |
| </td> | |
| </tr> | |
| <tr id="i1" class="rowColor"> | |
| <td class="colFirst"><code>private void</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#deleteFile-java.lang.String-">deleteFile</a></span>(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name)</code> | |
| <div class="block">Deletes a file.</div> | |
| </td> | |
| </tr> | |
| <tr id="i2" class="altColor"> | |
| <td class="colFirst"><code>private void</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#deleteLogFile-int-">deleteLogFile</a></span>(int ver)</code> | |
| <div class="block">Removes the incremental update log file.</div> | |
| </td> | |
| </tr> | |
| <tr id="i3" class="rowColor"> | |
| <td class="colFirst"><code>void</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#deletePersistentStore--">deletePersistentStore</a></span>()</code> | |
| <div class="block">Closes the incremental update log file, removes all ReliableLog-related | |
| files from the stable storage directory, and deletes the directory.</div> | |
| </td> | |
| </tr> | |
| <tr id="i4" class="altColor"> | |
| <td class="colFirst"><code>private void</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#deleteSnapshot-int-">deleteSnapshot</a></span>(int ver)</code> | |
| <div class="block">Removes the snapshot file.</div> | |
| </td> | |
| </tr> | |
| <tr id="i5" class="rowColor"> | |
| <td class="colFirst"><code>private <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#fName-java.lang.String-">fName</a></span>(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name)</code> | |
| <div class="block">Generates a filename prepended with the stable storage directory path.</div> | |
| </td> | |
| </tr> | |
| <tr id="i6" class="altColor"> | |
| <td class="colFirst"><code>long</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#logSize--">logSize</a></span>()</code> | |
| <div class="block">Returns the current size of the incremental update log file in bytes;</div> | |
| </td> | |
| </tr> | |
| <tr id="i7" class="rowColor"> | |
| <td class="colFirst"><code>private void</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#openLogFile--">openLogFile</a></span>()</code> | |
| <div class="block">Opens the incremental update log file in read/write mode.</div> | |
| </td> | |
| </tr> | |
| <tr id="i8" class="altColor"> | |
| <td class="colFirst"><code>void</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#recover--">recover</a></span>()</code> | |
| <div class="block">Retrieves the contents of the snapshot file by calling the client | |
| supplied recover callback and then applies the incremental updates | |
| by calling the readUpdate callback for each logged updated.</div> | |
| </td> | |
| </tr> | |
| <tr id="i9" class="rowColor"> | |
| <td class="colFirst"><code>void</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#snapshot--">snapshot</a></span>()</code> | |
| <div class="block">Records the client-defined current snapshot by invoking the client | |
| supplied snapshot callback, and then empties the log of incremental | |
| updates.</div> | |
| </td> | |
| </tr> | |
| <tr id="i10" class="altColor"> | |
| <td class="colFirst"><code>long</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#snapshotSize--">snapshotSize</a></span>()</code> | |
| <div class="block">Returns the size of the current snapshot file in bytes;</div> | |
| </td> | |
| </tr> | |
| <tr id="i11" class="rowColor"> | |
| <td class="colFirst"><code>void</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#update-java.lang.Object-">update</a></span>(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> value)</code> | |
| <div class="block">Records this update in the log file and forces the update to disk.</div> | |
| </td> | |
| </tr> | |
| <tr id="i12" class="altColor"> | |
| <td class="colFirst"><code>void</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#update-java.lang.Object-boolean-">update</a></span>(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> value, | |
| boolean forceToDisk)</code> | |
| <div class="block">Records this update in the log file and optionally forces the update | |
| to disk.</div> | |
| </td> | |
| </tr> | |
| <tr id="i13" class="rowColor"> | |
| <td class="colFirst"><code>private <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#versionName-java.lang.String-">versionName</a></span>(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name)</code> | |
| <div class="block">Generates a version filename prepended with the stable storage | |
| directory path with the current version number as a suffix.</div> | |
| </td> | |
| </tr> | |
| <tr id="i14" class="altColor"> | |
| <td class="colFirst"><code>private <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#versionName-java.lang.String-int-">versionName</a></span>(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> prefix, | |
| int ver)</code> | |
| <div class="block">Generates a version filename prepended with the stable storage | |
| directory path with the given version number as a suffix.</div> | |
| </td> | |
| </tr> | |
| <tr id="i15" class="rowColor"> | |
| <td class="colFirst"><code>private void</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#writeInt-java.io.DataOutput-int-">writeInt</a></span>(<a href="http://docs.oracle.com/javase/6/docs/api/java/io/DataOutput.html?is-external=true" title="class or interface in java.io">DataOutput</a> out, | |
| int val)</code> | |
| <div class="block">Write an int value in single write operation.</div> | |
| </td> | |
| </tr> | |
| <tr id="i16" class="altColor"> | |
| <td class="colFirst"><code>private void</code></td> | |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/river/reliableLog/ReliableLog.html#writeVersionFile--">writeVersionFile</a></span>()</code> | |
| <div class="block">Writes the current version number to the version file.</div> | |
| </td> | |
| </tr> | |
| </table> | |
| <ul class="blockList"> | |
| <li class="blockList"><a name="methods.inherited.from.class.java.lang.Object"> | |
| <!-- --> | |
| </a> | |
| <h3>Methods inherited from class java.lang.<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3> | |
| <code><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#clone--" title="class or interface in java.lang">clone</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#equals-java.lang.Object-" title="class or interface in java.lang">equals</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#finalize--" title="class or interface in java.lang">finalize</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#getClass--" title="class or interface in java.lang">getClass</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#hashCode--" title="class or interface in java.lang">hashCode</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notify--" title="class or interface in java.lang">notify</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notifyAll--" title="class or interface in java.lang">notifyAll</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#toString--" title="class or interface in java.lang">toString</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait--" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait-long-" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait-long-int-" title="class or interface in java.lang">wait</a></code></li> | |
| </ul> | |
| </li> | |
| </ul> | |
| </li> | |
| </ul> | |
| </div> | |
| <div class="details"> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <!-- ============ FIELD DETAIL =========== --> | |
| <ul class="blockList"> | |
| <li class="blockList"><a name="field.detail"> | |
| <!-- --> | |
| </a> | |
| <h3>Field Detail</h3> | |
| <a name="snapshotPrefix"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>snapshotPrefix</h4> | |
| <pre>private static final <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> snapshotPrefix</pre> | |
| <dl> | |
| <dt><span class="seeLabel">See Also:</span></dt> | |
| <dd><a href="../../../../constant-values.html#org.apache.river.reliableLog.ReliableLog.snapshotPrefix">Constant Field Values</a></dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="logfilePrefix"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>logfilePrefix</h4> | |
| <pre>private static final <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> logfilePrefix</pre> | |
| <dl> | |
| <dt><span class="seeLabel">See Also:</span></dt> | |
| <dd><a href="../../../../constant-values.html#org.apache.river.reliableLog.ReliableLog.logfilePrefix">Constant Field Values</a></dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="versionFile"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>versionFile</h4> | |
| <pre>private static final <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> versionFile</pre> | |
| <dl> | |
| <dt><span class="seeLabel">See Also:</span></dt> | |
| <dd><a href="../../../../constant-values.html#org.apache.river.reliableLog.ReliableLog.versionFile">Constant Field Values</a></dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="MAGIC"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>MAGIC</h4> | |
| <pre>private static final int MAGIC</pre> | |
| <dl> | |
| <dt><span class="seeLabel">See Also:</span></dt> | |
| <dd><a href="../../../../constant-values.html#org.apache.river.reliableLog.ReliableLog.MAGIC">Constant Field Values</a></dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="FORMAT_UNPADDED"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>FORMAT_UNPADDED</h4> | |
| <pre>private static final int FORMAT_UNPADDED</pre> | |
| <dl> | |
| <dt><span class="seeLabel">See Also:</span></dt> | |
| <dd><a href="../../../../constant-values.html#org.apache.river.reliableLog.ReliableLog.FORMAT_UNPADDED">Constant Field Values</a></dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="FORMAT_PADDED"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>FORMAT_PADDED</h4> | |
| <pre>private static final int FORMAT_PADDED</pre> | |
| <dl> | |
| <dt><span class="seeLabel">See Also:</span></dt> | |
| <dd><a href="../../../../constant-values.html#org.apache.river.reliableLog.ReliableLog.FORMAT_PADDED">Constant Field Values</a></dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="intBytes"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>intBytes</h4> | |
| <pre>private static final long intBytes</pre> | |
| <dl> | |
| <dt><span class="seeLabel">See Also:</span></dt> | |
| <dd><a href="../../../../constant-values.html#org.apache.river.reliableLog.ReliableLog.intBytes">Constant Field Values</a></dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="dir"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>dir</h4> | |
| <pre>private final <a href="http://docs.oracle.com/javase/6/docs/api/java/io/File.html?is-external=true" title="class or interface in java.io">File</a> dir</pre> | |
| </li> | |
| </ul> | |
| <a name="version"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>version</h4> | |
| <pre>private int version</pre> | |
| </li> | |
| </ul> | |
| <a name="format"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>format</h4> | |
| <pre>private int format</pre> | |
| </li> | |
| </ul> | |
| <a name="logName"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>logName</h4> | |
| <pre>private <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> logName</pre> | |
| </li> | |
| </ul> | |
| <a name="log"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>log</h4> | |
| <pre>private <a href="http://docs.oracle.com/javase/6/docs/api/java/io/RandomAccessFile.html?is-external=true" title="class or interface in java.io">RandomAccessFile</a> log</pre> | |
| </li> | |
| </ul> | |
| <a name="logFD"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>logFD</h4> | |
| <pre>private <a href="http://docs.oracle.com/javase/6/docs/api/java/io/FileDescriptor.html?is-external=true" title="class or interface in java.io">FileDescriptor</a> logFD</pre> | |
| </li> | |
| </ul> | |
| <a name="snapshotBytes"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>snapshotBytes</h4> | |
| <pre>private long snapshotBytes</pre> | |
| </li> | |
| </ul> | |
| <a name="logBytes"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>logBytes</h4> | |
| <pre>private long logBytes</pre> | |
| </li> | |
| </ul> | |
| <a name="handler"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>handler</h4> | |
| <pre>private final <a href="../../../../org/apache/river/reliableLog/LogHandler.html" title="class in org.apache.river.reliableLog">LogHandler</a> handler</pre> | |
| </li> | |
| </ul> | |
| <a name="intBuf"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>intBuf</h4> | |
| <pre>private final byte[] intBuf</pre> | |
| </li> | |
| </ul> | |
| <a name="zeroBuf"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockListLast"> | |
| <li class="blockList"> | |
| <h4>zeroBuf</h4> | |
| <pre>private final byte[] zeroBuf</pre> | |
| </li> | |
| </ul> | |
| </li> | |
| </ul> | |
| <!-- ========= CONSTRUCTOR DETAIL ======== --> | |
| <ul class="blockList"> | |
| <li class="blockList"><a name="constructor.detail"> | |
| <!-- --> | |
| </a> | |
| <h3>Constructor Detail</h3> | |
| <a name="ReliableLog-java.lang.String-org.apache.river.reliableLog.LogHandler-"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockListLast"> | |
| <li class="blockList"> | |
| <h4>ReliableLog</h4> | |
| <pre>public ReliableLog(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> dirPath, | |
| <a href="../../../../org/apache/river/reliableLog/LogHandler.html" title="class in org.apache.river.reliableLog">LogHandler</a> handler) | |
| throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre> | |
| <div class="block">Creates a ReliableLog to handle snapshots and logging in a | |
| stable storage directory, and sets up to recover any existing data | |
| from the stable storage directory. If there is no existing data, | |
| snapshot must be called next, otherwise recover must be called next.</div> | |
| <dl> | |
| <dt><span class="paramLabel">Parameters:</span></dt> | |
| <dd><code>dirPath</code> - path to the stable storage directory</dd> | |
| <dd><code>handler</code> - the handler for log callbacks</dd> | |
| <dt><span class="throwsLabel">Throws:</span></dt> | |
| <dd><code><a href="../../../../org/apache/river/reliableLog/LogException.html" title="class in org.apache.river.reliableLog">LogException</a></code> - if the directory cannot be created or | |
| the current version in the directory is corrupted</dd> | |
| <dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if any other I/O error occurs</dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| </li> | |
| </ul> | |
| <!-- ============ METHOD DETAIL ========== --> | |
| <ul class="blockList"> | |
| <li class="blockList"><a name="method.detail"> | |
| <!-- --> | |
| </a> | |
| <h3>Method Detail</h3> | |
| <a name="recover--"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>recover</h4> | |
| <pre>public void recover() | |
| throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre> | |
| <div class="block">Retrieves the contents of the snapshot file by calling the client | |
| supplied recover callback and then applies the incremental updates | |
| by calling the readUpdate callback for each logged updated.</div> | |
| <dl> | |
| <dt><span class="throwsLabel">Throws:</span></dt> | |
| <dd><code><a href="../../../../org/apache/river/reliableLog/LogException.html" title="class in org.apache.river.reliableLog">LogException</a></code> - if recovery fails due to serious log corruption, | |
| or if an exception is thrown by the recover or readUpdate callbacks</dd> | |
| <dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an other I/O error occurs</dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="update-java.lang.Object-"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>update</h4> | |
| <pre>public void update(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> value) | |
| throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre> | |
| <div class="block">Records this update in the log file and forces the update to disk. | |
| The update is recorded by calling the client's writeUpdate callback. | |
| This method must not be called until this log's recover method has | |
| been invoked (and completed).</div> | |
| <dl> | |
| <dt><span class="paramLabel">Parameters:</span></dt> | |
| <dd><code>value</code> - the object representing the update</dd> | |
| <dt><span class="throwsLabel">Throws:</span></dt> | |
| <dd><code><a href="../../../../org/apache/river/reliableLog/LogException.html" title="class in org.apache.river.reliableLog">LogException</a></code> - if an exception is thrown by the writeUpdate | |
| callback, or forcing the update to disk fails</dd> | |
| <dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if any other I/O error occurs</dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="update-java.lang.Object-boolean-"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>update</h4> | |
| <pre>public void update(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> value, | |
| boolean forceToDisk) | |
| throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre> | |
| <div class="block">Records this update in the log file and optionally forces the update | |
| to disk. The update is recorded by calling the client's writeUpdate | |
| callback. This method must not be called until this log's recover | |
| method has been invoked (and completed).</div> | |
| <dl> | |
| <dt><span class="paramLabel">Parameters:</span></dt> | |
| <dd><code>value</code> - the object representing the update</dd> | |
| <dd><code>forceToDisk</code> - true if the update should be forced to disk, false | |
| if the updates should be buffered</dd> | |
| <dt><span class="throwsLabel">Throws:</span></dt> | |
| <dd><code><a href="../../../../org/apache/river/reliableLog/LogException.html" title="class in org.apache.river.reliableLog">LogException</a></code> - if an exception is thrown by the writeUpdate | |
| callback, or forcing the update to disk fails</dd> | |
| <dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if any other I/O error occurs</dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="writeInt-java.io.DataOutput-int-"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>writeInt</h4> | |
| <pre>private void writeInt(<a href="http://docs.oracle.com/javase/6/docs/api/java/io/DataOutput.html?is-external=true" title="class or interface in java.io">DataOutput</a> out, | |
| int val) | |
| throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre> | |
| <div class="block">Write an int value in single write operation.</div> | |
| <dl> | |
| <dt><span class="paramLabel">Parameters:</span></dt> | |
| <dd><code>out</code> - output stream</dd> | |
| <dd><code>val</code> - int value</dd> | |
| <dt><span class="throwsLabel">Throws:</span></dt> | |
| <dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if any other I/O error occurs</dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="snapshot--"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>snapshot</h4> | |
| <pre>public void snapshot() | |
| throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre> | |
| <div class="block">Records the client-defined current snapshot by invoking the client | |
| supplied snapshot callback, and then empties the log of incremental | |
| updates.</div> | |
| <dl> | |
| <dt><span class="throwsLabel">Throws:</span></dt> | |
| <dd><code><a href="../../../../org/apache/river/reliableLog/LogException.html" title="class in org.apache.river.reliableLog">LogException</a></code> - if the snapshot callback throws an exception</dd> | |
| <dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if any other I/O error occurs</dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="close--"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>close</h4> | |
| <pre>public void close() | |
| throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre> | |
| <div class="block">Closes the stable storage directory in an orderly manner.</div> | |
| <dl> | |
| <dt><span class="throwsLabel">Throws:</span></dt> | |
| <dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="deletePersistentStore--"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>deletePersistentStore</h4> | |
| <pre>public void deletePersistentStore()</pre> | |
| <div class="block">Closes the incremental update log file, removes all ReliableLog-related | |
| files from the stable storage directory, and deletes the directory.</div> | |
| </li> | |
| </ul> | |
| <a name="snapshotSize--"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>snapshotSize</h4> | |
| <pre>public long snapshotSize()</pre> | |
| <div class="block">Returns the size of the current snapshot file in bytes;</div> | |
| </li> | |
| </ul> | |
| <a name="logSize--"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>logSize</h4> | |
| <pre>public long logSize()</pre> | |
| <div class="block">Returns the current size of the incremental update log file in bytes;</div> | |
| </li> | |
| </ul> | |
| <a name="fName-java.lang.String-"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>fName</h4> | |
| <pre>private <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> fName(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name)</pre> | |
| <div class="block">Generates a filename prepended with the stable storage directory path.</div> | |
| <dl> | |
| <dt><span class="paramLabel">Parameters:</span></dt> | |
| <dd><code>name</code> - the name of the file (sans directory path)</dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="versionName-java.lang.String-"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>versionName</h4> | |
| <pre>private <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> versionName(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name)</pre> | |
| <div class="block">Generates a version filename prepended with the stable storage | |
| directory path with the current version number as a suffix.</div> | |
| <dl> | |
| <dt><span class="paramLabel">Parameters:</span></dt> | |
| <dd><code>name</code> - version filename prefix</dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="versionName-java.lang.String-int-"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>versionName</h4> | |
| <pre>private <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> versionName(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> prefix, | |
| int ver)</pre> | |
| <div class="block">Generates a version filename prepended with the stable storage | |
| directory path with the given version number as a suffix.</div> | |
| <dl> | |
| <dt><span class="paramLabel">Parameters:</span></dt> | |
| <dd><code>prefix</code> - filename prefix</dd> | |
| <dd><code>ver</code> - version number</dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="deleteFile-java.lang.String-"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>deleteFile</h4> | |
| <pre>private void deleteFile(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name) | |
| throws <a href="../../../../org/apache/river/reliableLog/LogException.html" title="class in org.apache.river.reliableLog">LogException</a></pre> | |
| <div class="block">Deletes a file.</div> | |
| <dl> | |
| <dt><span class="paramLabel">Parameters:</span></dt> | |
| <dd><code>name</code> - the name of the file (complete path)</dd> | |
| <dt><span class="throwsLabel">Throws:</span></dt> | |
| <dd><code><a href="../../../../org/apache/river/reliableLog/LogException.html" title="class in org.apache.river.reliableLog">LogException</a></code> - if file cannot be deleted</dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="deleteSnapshot-int-"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>deleteSnapshot</h4> | |
| <pre>private void deleteSnapshot(int ver) | |
| throws <a href="../../../../org/apache/river/reliableLog/LogException.html" title="class in org.apache.river.reliableLog">LogException</a></pre> | |
| <div class="block">Removes the snapshot file.</div> | |
| <dl> | |
| <dt><span class="paramLabel">Parameters:</span></dt> | |
| <dd><code>ver</code> - the version to remove</dd> | |
| <dt><span class="throwsLabel">Throws:</span></dt> | |
| <dd><code><a href="../../../../org/apache/river/reliableLog/LogException.html" title="class in org.apache.river.reliableLog">LogException</a></code> - if file cannot be deleted</dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="deleteLogFile-int-"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>deleteLogFile</h4> | |
| <pre>private void deleteLogFile(int ver) | |
| throws <a href="../../../../org/apache/river/reliableLog/LogException.html" title="class in org.apache.river.reliableLog">LogException</a></pre> | |
| <div class="block">Removes the incremental update log file.</div> | |
| <dl> | |
| <dt><span class="paramLabel">Parameters:</span></dt> | |
| <dd><code>ver</code> - the version to remove</dd> | |
| <dt><span class="throwsLabel">Throws:</span></dt> | |
| <dd><code><a href="../../../../org/apache/river/reliableLog/LogException.html" title="class in org.apache.river.reliableLog">LogException</a></code> - if file cannot be deleted</dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="openLogFile--"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockList"> | |
| <li class="blockList"> | |
| <h4>openLogFile</h4> | |
| <pre>private void openLogFile() | |
| throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre> | |
| <div class="block">Opens the incremental update log file in read/write mode. If the | |
| file does not exist, it is created.</div> | |
| <dl> | |
| <dt><span class="throwsLabel">Throws:</span></dt> | |
| <dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| <a name="writeVersionFile--"> | |
| <!-- --> | |
| </a> | |
| <ul class="blockListLast"> | |
| <li class="blockList"> | |
| <h4>writeVersionFile</h4> | |
| <pre>private void writeVersionFile() | |
| throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre> | |
| <div class="block">Writes the current version number to the version file.</div> | |
| <dl> | |
| <dt><span class="throwsLabel">Throws:</span></dt> | |
| <dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if an I/O error occurs</dd> | |
| </dl> | |
| </li> | |
| </ul> | |
| </li> | |
| </ul> | |
| </li> | |
| </ul> | |
| </div> | |
| </div> | |
| <!-- ========= END OF CLASS DATA ========= --> | |
| <!-- ======= START OF BOTTOM NAVBAR ====== --> | |
| <div class="bottomNav"><a name="navbar.bottom"> | |
| <!-- --> | |
| </a> | |
| <div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div> | |
| <a name="navbar.bottom.firstrow"> | |
| <!-- --> | |
| </a> | |
| <ul class="navList" title="Navigation"> | |
| <li><a href="../../../../overview-summary.html">Overview</a></li> | |
| <li><a href="package-summary.html">Package</a></li> | |
| <li class="navBarCell1Rev">Class</li> | |
| <li><a href="class-use/ReliableLog.html">Use</a></li> | |
| <li><a href="package-tree.html">Tree</a></li> | |
| <li><a href="../../../../deprecated-list.html">Deprecated</a></li> | |
| <li><a href="../../../../index-all.html">Index</a></li> | |
| <li><a href="../../../../help-doc.html">Help</a></li> | |
| </ul> | |
| </div> | |
| <div class="subNav"> | |
| <ul class="navList"> | |
| <li><a href="../../../../org/apache/river/reliableLog/LogOutputStream.html" title="class in org.apache.river.reliableLog"><span class="typeNameLink">Prev Class</span></a></li> | |
| <li>Next Class</li> | |
| </ul> | |
| <ul class="navList"> | |
| <li><a href="../../../../index.html?org/apache/river/reliableLog/ReliableLog.html" target="_top">Frames</a></li> | |
| <li><a href="ReliableLog.html" target="_top">No Frames</a></li> | |
| </ul> | |
| <ul class="navList" id="allclasses_navbar_bottom"> | |
| <li><a href="../../../../allclasses-noframe.html">All Classes</a></li> | |
| </ul> | |
| <div> | |
| <script type="text/javascript"><!-- | |
| allClassesLink = document.getElementById("allclasses_navbar_bottom"); | |
| if(window==top) { | |
| allClassesLink.style.display = "block"; | |
| } | |
| else { | |
| allClassesLink.style.display = "none"; | |
| } | |
| //--> | |
| </script> | |
| </div> | |
| <div> | |
| <ul class="subNavList"> | |
| <li>Summary: </li> | |
| <li>Nested | </li> | |
| <li><a href="#field.summary">Field</a> | </li> | |
| <li><a href="#constructor.summary">Constr</a> | </li> | |
| <li><a href="#method.summary">Method</a></li> | |
| </ul> | |
| <ul class="subNavList"> | |
| <li>Detail: </li> | |
| <li><a href="#field.detail">Field</a> | </li> | |
| <li><a href="#constructor.detail">Constr</a> | </li> | |
| <li><a href="#method.detail">Method</a></li> | |
| </ul> | |
| </div> | |
| <a name="skip.navbar.bottom"> | |
| <!-- --> | |
| </a></div> | |
| <!-- ======== END OF BOTTOM NAVBAR ======= --> | |
| <p class="legalCopy"><small>Copyright 2007-2013, multiple authors.<br>Licensed under the <a href=http://www.apache.org/licenses/LICENSE-2.0 target=child >Apache License, Version 2.0</a>, see the <a href=../../../../doc-files/NOTICE target=child >NOTICE</a> file for attributions.</small></p> | |
| </body> | |
| </html> |