| <!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 --> |
| <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| <title>AllocationListener (Apache Arrow Java Root POM 17.0.0-SNAPSHOT API)</title> |
| <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="AllocationListener (Apache Arrow Java Root POM 17.0.0-SNAPSHOT API)"; |
| } |
| } |
| catch(err) { |
| } |
| //--> |
| var methods = {"i0":18,"i1":18,"i2":18,"i3":18,"i4":18,"i5":18}; |
| var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],16:["t5","Default 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/AllocationListener.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>Prev Class</li> |
| <li><a href="../../../../org/apache/arrow/memory/AllocationManager.html" title="class in org.apache.arrow.memory"><span class="typeNameLink">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../index.html?org/apache/arrow/memory/AllocationListener.html" target="_top">Frames</a></li> |
| <li><a href="AllocationListener.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>Constr | </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>Constr | </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.arrow.memory</div> |
| <h2 title="Interface AllocationListener" class="title">Interface AllocationListener</h2> |
| </div> |
| <div class="contentContainer"> |
| <div class="description"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <hr> |
| <br> |
| <pre>public interface <span class="typeNameLabel">AllocationListener</span></pre> |
| <div class="block">An allocation listener being notified for allocation/deallocation |
| |
| <p>It might be called from multiple threads if the allocator hierarchy shares a listener, in which |
| case, the provider should take care of making the implementation thread-safe.</div> |
| </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>static <a href="../../../../org/apache/arrow/memory/AllocationListener.html" title="interface in org.apache.arrow.memory">AllocationListener</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/arrow/memory/AllocationListener.html#NOOP">NOOP</a></span></code> </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="t5" class="tableTab"><span><a href="javascript:show(16);">Default 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>default void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/arrow/memory/AllocationListener.html#onAllocation-long-">onAllocation</a></span>(long size)</code> |
| <div class="block">Called each time a new buffer has been allocated.</div> |
| </td> |
| </tr> |
| <tr id="i1" class="rowColor"> |
| <td class="colFirst"><code>default void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/arrow/memory/AllocationListener.html#onChildAdded-org.apache.arrow.memory.BufferAllocator-org.apache.arrow.memory.BufferAllocator-">onChildAdded</a></span>(<a href="../../../../org/apache/arrow/memory/BufferAllocator.html" title="interface in org.apache.arrow.memory">BufferAllocator</a> parentAllocator, |
| <a href="../../../../org/apache/arrow/memory/BufferAllocator.html" title="interface in org.apache.arrow.memory">BufferAllocator</a> childAllocator)</code> |
| <div class="block">Called immediately after a child allocator was added to the parent allocator.</div> |
| </td> |
| </tr> |
| <tr id="i2" class="altColor"> |
| <td class="colFirst"><code>default void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/arrow/memory/AllocationListener.html#onChildRemoved-org.apache.arrow.memory.BufferAllocator-org.apache.arrow.memory.BufferAllocator-">onChildRemoved</a></span>(<a href="../../../../org/apache/arrow/memory/BufferAllocator.html" title="interface in org.apache.arrow.memory">BufferAllocator</a> parentAllocator, |
| <a href="../../../../org/apache/arrow/memory/BufferAllocator.html" title="interface in org.apache.arrow.memory">BufferAllocator</a> childAllocator)</code> |
| <div class="block">Called immediately after a child allocator was removed from the parent allocator.</div> |
| </td> |
| </tr> |
| <tr id="i3" class="rowColor"> |
| <td class="colFirst"><code>default boolean</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/arrow/memory/AllocationListener.html#onFailedAllocation-long-org.apache.arrow.memory.AllocationOutcome-">onFailedAllocation</a></span>(long size, |
| <a href="../../../../org/apache/arrow/memory/AllocationOutcome.html" title="class in org.apache.arrow.memory">AllocationOutcome</a> outcome)</code> |
| <div class="block">Called whenever an allocation failed, giving the caller a chance to create some space in the |
| allocator (either by freeing some resource, or by changing the limit), and, if successful, |
| allowing the allocator to retry the allocation.</div> |
| </td> |
| </tr> |
| <tr id="i4" class="altColor"> |
| <td class="colFirst"><code>default void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/arrow/memory/AllocationListener.html#onPreAllocation-long-">onPreAllocation</a></span>(long size)</code> |
| <div class="block">Called each time a new buffer has been requested.</div> |
| </td> |
| </tr> |
| <tr id="i5" class="rowColor"> |
| <td class="colFirst"><code>default void</code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/arrow/memory/AllocationListener.html#onRelease-long-">onRelease</a></span>(long size)</code> |
| <div class="block">Informed each time a buffer is released from allocation.</div> |
| </td> |
| </tr> |
| </table> |
| </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="NOOP"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>NOOP</h4> |
| <pre>static final <a href="../../../../org/apache/arrow/memory/AllocationListener.html" title="interface in org.apache.arrow.memory">AllocationListener</a> NOOP</pre> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| <!-- ============ METHOD DETAIL ========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="method.detail"> |
| <!-- --> |
| </a> |
| <h3>Method Detail</h3> |
| <a name="onPreAllocation-long-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>onPreAllocation</h4> |
| <pre>default void onPreAllocation(long size)</pre> |
| <div class="block">Called each time a new buffer has been requested. |
| |
| <p>An exception can be safely thrown by this method to terminate the allocation.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>size</code> - the buffer size being allocated</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="onAllocation-long-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>onAllocation</h4> |
| <pre>default void onAllocation(long size)</pre> |
| <div class="block">Called each time a new buffer has been allocated. |
| |
| <p>An exception cannot be thrown by this method.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>size</code> - the buffer size being allocated</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="onRelease-long-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>onRelease</h4> |
| <pre>default void onRelease(long size)</pre> |
| <div class="block">Informed each time a buffer is released from allocation. |
| |
| <p>An exception cannot be thrown by this method.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>size</code> - The size of the buffer being released.</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="onFailedAllocation-long-org.apache.arrow.memory.AllocationOutcome-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>onFailedAllocation</h4> |
| <pre>default boolean onFailedAllocation(long size, |
| <a href="../../../../org/apache/arrow/memory/AllocationOutcome.html" title="class in org.apache.arrow.memory">AllocationOutcome</a> outcome)</pre> |
| <div class="block">Called whenever an allocation failed, giving the caller a chance to create some space in the |
| allocator (either by freeing some resource, or by changing the limit), and, if successful, |
| allowing the allocator to retry the allocation.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>size</code> - the buffer size that was being allocated</dd> |
| <dd><code>outcome</code> - the outcome of the failed allocation. Carries information of what failed</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>true, if the allocation can be retried; false if the allocation should fail</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="onChildAdded-org.apache.arrow.memory.BufferAllocator-org.apache.arrow.memory.BufferAllocator-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>onChildAdded</h4> |
| <pre>default void onChildAdded(<a href="../../../../org/apache/arrow/memory/BufferAllocator.html" title="interface in org.apache.arrow.memory">BufferAllocator</a> parentAllocator, |
| <a href="../../../../org/apache/arrow/memory/BufferAllocator.html" title="interface in org.apache.arrow.memory">BufferAllocator</a> childAllocator)</pre> |
| <div class="block">Called immediately after a child allocator was added to the parent allocator.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>parentAllocator</code> - The parent allocator to which a child was added</dd> |
| <dd><code>childAllocator</code> - The child allocator that was just added</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="onChildRemoved-org.apache.arrow.memory.BufferAllocator-org.apache.arrow.memory.BufferAllocator-"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>onChildRemoved</h4> |
| <pre>default void onChildRemoved(<a href="../../../../org/apache/arrow/memory/BufferAllocator.html" title="interface in org.apache.arrow.memory">BufferAllocator</a> parentAllocator, |
| <a href="../../../../org/apache/arrow/memory/BufferAllocator.html" title="interface in org.apache.arrow.memory">BufferAllocator</a> childAllocator)</pre> |
| <div class="block">Called immediately after a child allocator was removed from the parent allocator.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>parentAllocator</code> - The parent allocator from which a child was removed</dd> |
| <dd><code>childAllocator</code> - The child allocator that was just removed</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/AllocationListener.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>Prev Class</li> |
| <li><a href="../../../../org/apache/arrow/memory/AllocationManager.html" title="class in org.apache.arrow.memory"><span class="typeNameLink">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../index.html?org/apache/arrow/memory/AllocationListener.html" target="_top">Frames</a></li> |
| <li><a href="AllocationListener.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>Constr | </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>Constr | </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 © 2023 <a href="https://www.apache.org/">The Apache Software Foundation</a>. All rights reserved.</small></p> |
| </body> |
| </html> |