Codota Logo
Recorder.fillSortedRecords
Code IndexAdd Codota to your IDE (free)

How to use
fillSortedRecords
method
in
cn.myperf4j.core.recorder.Recorder

Best Java code snippets using cn.myperf4j.core.recorder.Recorder.fillSortedRecords (Showing top 1 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
BufferedReader b =
  • Codota IconInputStream in;new BufferedReader(new InputStreamReader(in))
  • Codota IconReader in;new BufferedReader(in)
  • Codota IconFile file;new BufferedReader(new FileReader(file))
  • Smart code suggestions by Codota
}
origin: LinShunKang/MyPerf4J

public static MethodMetrics calPerfStats(Recorder recorder, MethodTag methodTag, long startTime, long stopTime) {
  int[] sortedRecords = null;
  try {
    int effectiveCount = recorder.getEffectiveCount();
    sortedRecords = ChunkPool.getInstance().getChunk(effectiveCount * 2);
    recorder.fillSortedRecords(sortedRecords);
    return calPerfStats(methodTag, startTime, stopTime, sortedRecords, effectiveCount);
  } catch (Exception e) {
    Logger.error("MethodMetricsCalculator.calPerfStats(" + recorder + ", " + methodTag + ", " + startTime + ", " + stopTime + ")", e);
  } finally {
    ChunkPool.getInstance().returnChunk(sortedRecords);
  }
  return MethodMetrics.getInstance(methodTag, startTime, stopTime);
}
cn.myperf4j.core.recorderRecorderfillSortedRecords

Javadoc

为了节省内存的使用,利用int[]作为返回结果

Popular methods of Recorder

  • getEffectiveCount
    获取有效的记录的个数
  • getMethodTagId
  • hasRecord
  • recordTime
  • resetRecord

Popular in Java

  • Start an intent from android
  • getResourceAsStream (ClassLoader)
  • scheduleAtFixedRate (ScheduledExecutorService)
    Creates and executes a periodic action that becomes enabled first after the given initial delay, and
  • runOnUiThread (Activity)
  • Menu (java.awt)
  • BufferedWriter (java.io)
    Wraps an existing Writer and buffers the output. Expensive interaction with the underlying reader is
  • System (java.lang)
    Provides access to system-related information and resources including standard input and output. Ena
  • SocketException (java.net)
    This SocketException may be thrown during socket creation or setting options, and is the superclass
  • Random (java.util)
    This class provides methods that return pseudo-random values.It is dangerous to seed Random with the
  • Manifest (java.util.jar)
    The Manifest class is used to obtain attribute information for a JarFile and its entries.
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now