src/share/vm/gc/g1/heapRegion.hpp
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File
*** old/src/share/vm/gc/g1/heapRegion.hpp	Tue Mar  8 15:19:56 2016
--- new/src/share/vm/gc/g1/heapRegion.hpp	Tue Mar  8 15:19:55 2016

*** 759,776 **** --- 759,791 ---- // Terminates the iteration when the "doHeapRegion" method returns "true". class HeapRegionClosure : public StackObj { friend class HeapRegionManager; friend class G1CollectedHeap; + public: + HeapRegionClosure() {} + + // Typically called on each region until it returns true. + virtual void doHeapRegion(HeapRegion* r) = 0; + }; + + // AbortableHeapRegionClosure is used for iterating over regions. + // Terminates the iteration when the "doHeapRegion" method returns "true". + class AbortableHeapRegionClosure : public StackObj { + friend class HeapRegionManager; + friend class G1CollectedHeap; + bool _complete; void incomplete() { _complete = false; } public: ! AbortableHeapRegionClosure(): _complete(true) {} + + //void doHeapRegion(HeapRegion* r) {} // Typically called on each region until it returns true. ! virtual bool doHeapRegionAbortable(HeapRegion* r) = 0; // True after iteration if the closure was applied to all heap regions // and returned "false" in all cases. bool complete() { return _complete; } };

src/share/vm/gc/g1/heapRegion.hpp
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File