hotspot/src/share/vm/services/memoryService.cpp
// for a subclass to create then initialize an instance before invoking
// the MemoryService
void TraceMemoryManagerStats::initialize(bool fullGC,
                                         GCCause::Cause cause,
                                         bool recordGCBeginTime,
                                         bool recordPreGCUsage,
                                         bool recordPeakUsage,
                                         bool recordPostGCUsage,
                                         bool recordAccumulatedGCTime,
                                         bool recordGCEndTime,
                                         bool countCollection) {
  {- -------------------------------------------
  (1) 各種フィールドの値をセットした後, MemoryService::gc_begin() を呼び出すだけ.
      ---------------------------------------- -}
      _fullGC = fullGC;
      _recordGCBeginTime = recordGCBeginTime;
      _recordPreGCUsage = recordPreGCUsage;
      _recordPeakUsage = recordPeakUsage;
      _recordPostGCUsage = recordPostGCUsage;
      _recordAccumulatedGCTime = recordAccumulatedGCTime;
      _recordGCEndTime = recordGCEndTime;
      _countCollection = countCollection;
      _cause = cause;
      MemoryService::gc_begin(_fullGC, _recordGCBeginTime, _recordAccumulatedGCTime,
                              _recordPreGCUsage, _recordPeakUsage);
    }
This document is available under the GNU GENERAL PUBLIC LICENSE Version 2.