Class CreateVersionHistory
- java.lang.Object
-
- org.linuxforhealth.fhir.database.utils.version.CreateVersionHistory
-
public class CreateVersionHistory extends java.lang.Object
We don't add the version_history to thePhysicalDataModel
because it's a schema management table, and the model shouldn't really care about it.
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
ADMIN_GROUP
static java.lang.String
SCHEMA_GROUP_TAG
-
Constructor Summary
Constructors Constructor Description CreateVersionHistory()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
createTableIfNeeded(java.lang.String adminSchemaName, ISchemaAdapter target)
Create the version history table in the given (admin) schema.static Table
generateTable(PhysicalDataModel dataModel, java.lang.String adminSchemaName, boolean addTags)
Generates the Table
-
-
-
Field Detail
-
SCHEMA_GROUP_TAG
public static final java.lang.String SCHEMA_GROUP_TAG
- See Also:
- Constant Field Values
-
ADMIN_GROUP
public static final java.lang.String ADMIN_GROUP
- See Also:
- Constant Field Values
-
-
Method Detail
-
generateTable
public static Table generateTable(PhysicalDataModel dataModel, java.lang.String adminSchemaName, boolean addTags)
Generates the Table- Parameters:
dataModel
-adminSchemaName
-addTags
-- Returns:
-
createTableIfNeeded
public static void createTableIfNeeded(java.lang.String adminSchemaName, ISchemaAdapter target)
Create the version history table in the given (admin) schema. This table is used to determine the current version of the schema, and hence which changes should be applied in order to migrate the schema to the latest version.
As this is the version table itself, it is assigned a version id of 0 which is used to indicate that versioning doesn't apply.- Parameters:
adminSchemaName
-target
-
-
-