Skip to content

Instantly share code, notes, and snippets.

@zzorn
zzorn / SimpleFrame.java
Created August 9, 2013 13:03
SimpleFrame
import javax.swing.*;
import java.awt.*;
/**
* A Swing JFrame with sensible default settings.
*/
public class SimpleFrame extends JFrame {
private static final int DEFAULT_WIDTH = 800;
/**
* Start of a framework for measuring perfromance and reporting the results.
*/
// TODO: Some tool for iterating through classes in source dirs and running the ones inheriting the performance test trait.
// TODO: Refactor this to be unit test like instead with an overrideable setup method and reflection found test methods, this current approach seems clumsy to use
final case class PerformanceProfiler[T]( subject : String ) {
var warmupRounds = 5
var testRounds = 10