Skip to content

Instantly share code, notes, and snippets.

@scottmarlow
Created July 8, 2014 12:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save scottmarlow/cef93b0b4a018d2c9d74 to your computer and use it in GitHub Desktop.
Save scottmarlow/cef93b0b4a018d2c9d74 to your computer and use it in GitHub Desktop.
test main for QueryName class for testing perf
public static void main(String[] args) {
String test = "select * from employee e (where e.id <> 0 and e.name ='foo' and e.other != 'other'";
long start = System.currentTimeMillis();
for ( int looper = 0; looper < 500000; looper ++) {
QueryName name = new QueryName(test);
}
long end = System.currentTimeMillis();
System.out.println("took " + (end- start) + "ms, input= " + test + ", displayable =" + new QueryName(test).getDisplayName());
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment