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
extends CdmBase
{
27 private static final long serialVersionUID
= -3033376680593279078L;
28 @SuppressWarnings("unused")
29 private static final Logger logger
= Logger
.getLogger(CdmMetaData
.class);
32 * The database schema version number.
33 * It is recommended to have the first two numbers equal to the CDM Library version number.
34 * But it is not obligatory as there may be cases when the library number changes but the
35 * schema version is not changing.
36 * The third should be incremented if the schema changes in a way that SCHEMA_VALIDATION.UPDATE
37 * will probably not work or will not be enough to transform old data into new data.
38 * The fourth number shoud be incremented when minor schema changes take place that can
39 * be handled by SCHEMA_VALIDATION.UPDATE
40 * The last number represents the date of change.
42 private static final String dbSchemaVersion
= "2.1.2.2.200909301715";
44 public enum MetaDataPropertyName
{
48 private MetaDataPropertyName propertyName
;
52 public static final List
<CdmMetaData
> propertyList(){
53 List
<CdmMetaData
> result
= new ArrayList
<CdmMetaData
>();
54 result
.add(new CdmMetaData(MetaDataPropertyName
.DB_SCHEMA_VERSION
, dbSchemaVersion
));
58 private CdmMetaData() {
62 public CdmMetaData(MetaDataPropertyName propertyName
, String value
) {
64 this.propertyName
= propertyName
;
69 * @return the propertyName
71 public MetaDataPropertyName
getPropertyName() {
76 * @param propertyName the propertyName to set
78 public void setPropertyName(MetaDataPropertyName propertyName
) {
79 this.propertyName
= propertyName
;
85 public String
getValue() {
90 * @param value the value to set
92 public void setValue(String value
) {