Package edu.ucsb.nceas.metacat.util
Class DatabaseUtil
java.lang.Object
edu.ucsb.nceas.metacat.util.DatabaseUtil
-
Method Summary
Modifier and TypeMethodDescriptionGets the available upgrade versions for metacat by getting a list of upgrade script from properties in metacat.properties that start with "database.upgradeVersion".Gets the available upgrade versions for metacat by getting a list of upgrade script from properties in metacat.properties that start with "database.upgradeVersion".static boolean
Reports whether database is fully configured.
-
Method Details
-
isDatabaseConfigured
Reports whether database is fully configured.- Returns:
- a boolean that is true if database is not unconfigured and false otherwise
- Throws:
MetacatUtilException
-
getUpgradeVersions
public static TreeSet<DBVersion> getUpgradeVersions() throws edu.ucsb.nceas.utilities.PropertyNotFoundExceptionGets the available upgrade versions for metacat by getting a list of upgrade script from properties in metacat.properties that start with "database.upgradeVersion". It then creats a DBVersion object for each upgrade version.- Returns:
- a TreeSet of DBVersion objects holding individual version information
- Throws:
edu.ucsb.nceas.utilities.PropertyNotFoundException
-
getScriptSuffixes
public static Map<String,String> getScriptSuffixes() throws edu.ucsb.nceas.utilities.PropertyNotFoundExceptionGets the available upgrade versions for metacat by getting a list of upgrade script from properties in metacat.properties that start with "database.upgradeVersion". It then creats a DBVersion object for each upgrade version.- Returns:
- a TreeSet of DBVersion objects holding individual version information
- Throws:
edu.ucsb.nceas.utilities.PropertyNotFoundException
-