![JAR search and dependency download from the Maven repository](/logo.png)
com.carrotsearch.junitbenchmarks.db.DbVersions Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of junit-benchmarks Show documentation
Show all versions of junit-benchmarks Show documentation
A framework for writing performance micro-benchmarks using JUnit4 annotations, forked from https://github.com/carrotsearch/junit-benchmarks.
package com.carrotsearch.junitbenchmarks.db;
/**
* Database versions for upgrades.
*/
public enum DbVersions
{
/**
* No tables present.
*/
UNINITIALIZED(0),
/**
* Runs and tests tables, initial.
*/
VERSION_1(1),
/**
* DBVERSION present. Modifications:
*
* ALTER TABLE RUNS ADD CUSTOM_KEY VARCHAR(500);
*
*/
VERSION_2(2);
public final int version;
DbVersions(int v)
{
this.version = v;
}
/**
* Return
*/
public static DbVersions fromInt(int ver)
{
for (DbVersions v : DbVersions.values())
{
if (v.version == ver) return v;
}
throw new RuntimeException("No such DB number: " + ver);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy