3 * Copyright (C) 2007 EDIT
4 * European Distributed Institute of Taxonomy
5 * http://www.e-taxonomy.eu
7 * The contents of this file are subject to the Mozilla Public License Version 1.1
8 * See LICENSE.TXT at the top of this package for the full license terms.
11 package eu
.etaxonomy
.cdm
.model
.common
;
13 import java
.util
.ArrayList
;
14 import java
.util
.List
;
16 import javax
.persistence
.Entity
;
18 import org
.apache
.log4j
.Logger
;
26 public class CdmMetaData
{
27 @SuppressWarnings("unused")
28 private static final Logger logger
= Logger
.getLogger(CdmMetaData
.class);
31 * The database schema version number.
32 * It is recommended to have the first two numbers equal to the CDM Library version number.
33 * But it is not obligatory as there may be cases when the library number changes but the
34 * schema version is not changing.
35 * The third should be incremented if the schema changes in a way that SCHEMA_VALIDATION.UPDATE
36 * will probably not work or will not be enough to transform old data into new data.
37 * The fourth number shoud be incremented when minor schema changes take place that can
38 * be handled by SCHEMA_VALIDATION.UPDATE
39 * The last number represents the date of change.
41 private static final String dbSchemaVersion
= "2.1.0.0.200909071123";
43 public enum MetaDataPropertyName
{
47 private MetaDataPropertyName propertyName
;
50 public static final List
<CdmMetaData
> propertyList(){
51 List
<CdmMetaData
> result
= new ArrayList
<CdmMetaData
>();
52 result
.add(new CdmMetaData(MetaDataPropertyName
.DB_SCHEMA_VERSION
, dbSchemaVersion
));
56 public CdmMetaData(MetaDataPropertyName propertyName
, String value
) {
58 this.propertyName
= propertyName
;
63 * @return the propertyName
65 public MetaDataPropertyName
getPropertyName() {
70 * @param propertyName the propertyName to set
72 public void setPropertyName(MetaDataPropertyName propertyName
) {
73 this.propertyName
= propertyName
;
79 public String
getValue() {
84 * @param value the value to set
86 public void setValue(String value
) {