public class GrouperConfigHibernate extends GrouperAPI implements Hib3GrouperVersioned, Comparable<GrouperConfigHibernate>, GrouperCacheDatabaseClear
| Modifier and Type | Field and Description |
|---|---|
static String |
COLUMN_CONFIG_COMMENT
comment of the property
|
static String |
COLUMN_CONFIG_ENCRYPTED
if this is a password or for whatever other reason is encrypted
|
static String |
COLUMN_CONFIG_FILE_HIERARCHY
config file hierarchy, e.g.
|
static String |
COLUMN_CONFIG_FILE_NAME
config file, e.g.
|
static String |
COLUMN_CONFIG_KEY
key of the property
|
static String |
COLUMN_CONFIG_SEQUENCE
if there is more data than fits in the column this is the 0 indexed order
|
static String |
COLUMN_CONFIG_VALUE
value of the property
|
static String |
COLUMN_CONFIG_VALUE_BYTES
size of the config value
|
static String |
COLUMN_CONFIG_VALUE_CLOB
value when it's too big for config_value
|
static String |
COLUMN_CONFIG_VERSION_INDEX
for built in configs, this is the index that will identify if the database configs should be replaced from the java code
|
static String |
COLUMN_HIBERNATE_VERSION_NUMBER
hibernate version
|
static String |
COLUMN_ID
db uuid for this row
|
static String |
COLUMN_LAST_UPDATED
millis since 1970 this row was last updated
|
static String |
ESCAPED_PASSWORD |
static String |
FIELD_CONFIG_COMMENT
constant for field name for: configComment
|
static String |
FIELD_CONFIG_ENCRYPTED
constant for field name for: configEncrypted
|
static String |
FIELD_CONFIG_FILE_HIERARCHY
constant for field name for: configFileHierarchy
|
static String |
FIELD_CONFIG_FILE_NAME
constant for field name for: configFileName
|
static String |
FIELD_CONFIG_KEY
constant for field name for: configKey
|
static String |
FIELD_CONFIG_SEQUENCE
constant for field name for: configSequence
|
static String |
FIELD_CONFIG_VALUE
constant for field name for: configValue
|
static String |
FIELD_CONFIG_VALUE_BYTES
constant for field name for: configValueBytes
|
static String |
FIELD_CONFIG_VALUE_CLOB
constant for field name for: configValueClob
|
static String |
FIELD_CONFIG_VERSION_INDEX
constant for field name for: configVersionIndex
|
static String |
FIELD_CONTEXT_ID
constant for field name for: contextId
|
static String |
FIELD_ID
constant for field name for: id
|
static String |
FIELD_LAST_UPDATED_DB
constant for field name for: lastUpdatedDb
|
static String |
TABLE_GROUPER_CONFIG
name of the table in the database.
|
dbVersion, FIELD_DB_VERSION, FIELD_HIBERNATE_VERSION_NUMBER, INITIAL_VERSION_NUMBER| Constructor and Description |
|---|
GrouperConfigHibernate() |
| Modifier and Type | Method and Description |
|---|---|
void |
clear(GrouperCacheDatabaseClearInput grouperCacheDatabaseClearInput)
clear the cache when the database tells us to
|
static void |
clearConfigsInMemory()
clear the cache when the database tells us to
|
GrouperConfigHibernate |
clone()
deep clone the fields in this object
|
int |
compareTo(GrouperConfigHibernate otherConfig) |
static void |
createNewPITGrouperConfigHibernate(String auditEntryId,
String newActiveStatus,
GrouperConfigHibernate config,
String previousConfigValue,
String previousConfigValueClob)
create a new PIT grouper config entry in the database based on the grouper config
|
Set<String> |
dbVersionDifferentFields(boolean failIfNull) |
void |
dbVersionReset()
take a snapshot of the data since this is what is in the db
|
void |
delete()
delete this object
|
boolean |
equals(Object other) |
String |
getConfigComment() |
String |
getConfigEncryptedDb()
if this is a password or for whatever other reason is encrypted, T|F
|
ConfigFileHierarchy |
getConfigFileHierarchy() |
String |
getConfigFileHierarchyDb() |
ConfigFileName |
getConfigFileName() |
String |
getConfigFileNameDb()
config file, e.g.
|
String |
getConfigKey()
key of the property
|
int |
getConfigSequence()
if there is more data than fits in the column this is the 0 indexed order
|
Long |
getConfigValueBytes()
size of config value in bytes
|
String |
getConfigValueClob()
clob value of the property
|
String |
getConfigValueClobDb()
clob value of the property
|
String |
getConfigValueDb()
value of the property
|
int |
getConfigVersionIndex()
for built in configs, this is the index that will identify if the database configs should be replaced from the java code
|
String |
getContextId() |
String |
getId() |
Timestamp |
getLastUpdated()
when last updated
|
Long |
getLastUpdatedDb()
when last updated
|
int |
hashCode() |
boolean |
isConfigEncrypted()
if this is a password or for whatever other reason is encrypted
|
static boolean |
isPassword(ConfigFileName configFileName,
ConfigItemMetadata configItemMetadata,
String key,
String value,
boolean hasValue,
Boolean userSelectedPassword)
see if password based on various factors
|
static boolean |
isPasswordHelper(ConfigFileName configFileName,
ConfigItemMetadata configItemMetadata,
String key,
String value,
boolean hasValue,
Boolean userSelectedPassword)
see if password based on various factors
|
static boolean |
isPasswordHelper(ConfigItemMetadata configItemMetadata)
see if password based on various factors
|
static boolean |
isPasswordHelper(ConfigItemMetadata configItemMetadata,
String propertyValueString)
if the value is a file and it exists, then this is not a password to be escaped
|
void |
onPreSave(HibernateSession hibernateSession)
before a save (insert) occurs
|
void |
onPreUpdate(HibernateSession hibernateSession)
before an update occurs
|
static void |
registerDatabaseCache() |
String |
retrieveValue()
retrieve value.
|
void |
saveOrUpdate(boolean addNew)
save or update this object
|
void |
setConfigComment(String configComment1) |
void |
setConfigEncrypted(boolean configEncrypted1)
if this is a password or for whatever other reason is encrypted
|
void |
setConfigEncryptedDb(String theConfigEncrypted)
if this is a password or for whatever other reason is encrypted
|
void |
setConfigFileHierarchy(ConfigFileHierarchy configFileHierarchyEnum) |
void |
setConfigFileHierarchyDb(String configFileHierarchy) |
void |
setConfigFileName(ConfigFileName configFileName)
config file, e.g.
|
void |
setConfigFileNameDb(String configFileName)
config file, e.g.
|
void |
setConfigKey(String configKey1)
key of the property
|
void |
setConfigSequence(int configSequence1)
if there is more data than fits in the column this is the 0 indexed order
|
void |
setConfigValueBytes(Long configValueBytes)
size of config value in bytes
|
void |
setConfigValueClob(String configValueClob1)
clob value of the property
|
void |
setConfigValueClobDb(String configValueClob1)
value of the property
|
void |
setConfigValueDb(String configValue1)
value of the property
|
void |
setConfigVersionIndex(int configVersionIndex1)
for built in configs, this is the index that will identify if the database configs should be replaced from the java code
|
void |
setContextId(String contextId1)
set context id
|
void |
setId(String id1) |
void |
setLastUpdated(Timestamp lastUpdated1)
when last updated
|
void |
setLastUpdatedDb(Long lastUpdated1)
when last updated
|
void |
setValueToSave(String value)
set config value to save.
|
void |
truncate()
make sure this object will fit in the DB
|
static void |
updateLastUpdated()
update last updated if something changed
|
dbVersion, dbVersionClear, dbVersionDifferentFields, dbVersionIsDifferent, fieldValue, getHibernateVersionNumber, onDelete, onLoad, onPostDelete, onPostSave, onPostUpdate, onPreDelete, onSave, onUpdate, setHibernateVersionNumberpublic static final String ESCAPED_PASSWORD
public static final String COLUMN_ID
public static final String FIELD_CONFIG_COMMENT
public static final String FIELD_CONFIG_ENCRYPTED
public static final String FIELD_CONFIG_FILE_HIERARCHY
public static final String FIELD_CONFIG_FILE_NAME
public static final String FIELD_CONFIG_KEY
public static final String FIELD_CONFIG_SEQUENCE
public static final String FIELD_CONFIG_VALUE
public static final String FIELD_CONFIG_VALUE_CLOB
public static final String FIELD_CONFIG_VALUE_BYTES
public static final String FIELD_CONFIG_VERSION_INDEX
public static final String FIELD_CONTEXT_ID
public static final String FIELD_ID
public static final String FIELD_LAST_UPDATED_DB
public static final String COLUMN_HIBERNATE_VERSION_NUMBER
public static final String COLUMN_CONFIG_KEY
public static final String COLUMN_CONFIG_VALUE
public static final String COLUMN_CONFIG_VALUE_CLOB
public static final String COLUMN_CONFIG_VALUE_BYTES
public static final String COLUMN_CONFIG_COMMENT
public static final String COLUMN_CONFIG_SEQUENCE
public static final String COLUMN_CONFIG_FILE_NAME
public static final String COLUMN_CONFIG_FILE_HIERARCHY
public static final String COLUMN_LAST_UPDATED
public static final String COLUMN_CONFIG_VERSION_INDEX
public static final String COLUMN_CONFIG_ENCRYPTED
public static final String TABLE_GROUPER_CONFIG
public void onPreSave(HibernateSession hibernateSession)
HibGrouperLifecycleonPreSave in interface HibGrouperLifecycleonPreSave in class GrouperAPIGrouperAPI.onPreSave(edu.internet2.middleware.grouper.hibernate.HibernateSession)public void onPreUpdate(HibernateSession hibernateSession)
HibGrouperLifecycleonPreUpdate in interface HibGrouperLifecycleonPreUpdate in class GrouperAPIGrouperAPI.onPreUpdate(edu.internet2.middleware.grouper.hibernate.HibernateSession)public Timestamp getLastUpdated()
public Long getLastUpdatedDb()
public void setLastUpdated(Timestamp lastUpdated1)
lastUpdated1 - public void setLastUpdatedDb(Long lastUpdated1)
lastUpdated1 - public int getConfigVersionIndex()
public void setConfigVersionIndex(int configVersionIndex1)
configVersionIndex1 - the configVersionIndex to setpublic String getConfigValueDb()
public String retrieveValue()
public void setValueToSave(String value)
value - public void setConfigValueDb(String configValue1)
configValue1 - the configValue to setpublic String getConfigValueClobDb()
public String getConfigValueClob()
public void setConfigValueClobDb(String configValueClob1)
configValueClob1 - the configValueClob to setpublic Long getConfigValueBytes()
public void setConfigValueBytes(Long configValueBytes)
the - configValueBytespublic int getConfigSequence()
public void setConfigSequence(int configSequence1)
configSequence1 - the configSequence to setpublic String getConfigKey()
public void setConfigKey(String configKey1)
configKey1 - the configKey to setpublic String getConfigFileNameDb()
public void setConfigFileNameDb(String configFileName)
configFileName - the configFileName to setpublic String getConfigFileHierarchyDb()
public void setConfigFileHierarchyDb(String configFileHierarchy)
configFileHierarchy - the configFileHierarchy to setpublic ConfigFileHierarchy getConfigFileHierarchy()
public void setConfigFileHierarchy(ConfigFileHierarchy configFileHierarchyEnum)
configFileHierarchyEnum - the configFileHierarchy to setpublic String getConfigComment()
public void setConfigComment(String configComment1)
configComment1 - the configComment to setpublic String getConfigEncryptedDb()
public void setConfigEncryptedDb(String theConfigEncrypted)
theConfigEncrypted - public boolean isConfigEncrypted()
public void setConfigEncrypted(boolean configEncrypted1)
configEncrypted1 - the configEncrypted to setpublic void setId(String id1)
id1 - the id to setpublic String getId()
public String getContextId()
public void setContextId(String contextId1)
contextId1 - public static void createNewPITGrouperConfigHibernate(String auditEntryId, String newActiveStatus, GrouperConfigHibernate config, String previousConfigValue, String previousConfigValueClob)
auditEntryId - config - public void saveOrUpdate(boolean addNew)
public static boolean isPassword(ConfigFileName configFileName, ConfigItemMetadata configItemMetadata, String key, String value, boolean hasValue, Boolean userSelectedPassword)
configFileName - if known or null if notconfigItemMetadata - if known or null if notkey - or null if not knownvalue - if there is one at this point or null if nothasValue - true if there is a value, false if notuserSelectedPassword - true if the user selected that this is a password. null if NApublic static boolean isPasswordHelper(ConfigItemMetadata configItemMetadata)
configItemMetadata - public static boolean isPasswordHelper(ConfigItemMetadata configItemMetadata, String propertyValueString)
configItemMetadata - propertyValueString - public static boolean isPasswordHelper(ConfigFileName configFileName, ConfigItemMetadata configItemMetadata, String key, String value, boolean hasValue, Boolean userSelectedPassword)
configFileName - configItemMetadata - key - value - hasValue - userSelectedPassword - public void delete()
public static void registerDatabaseCache()
public static void updateLastUpdated()
public void truncate()
public void setConfigValueClob(String configValueClob1)
configValueClob1 - the configValueClob to setpublic Set<String> dbVersionDifferentFields(boolean failIfNull)
failIfNull - GrouperAPI.dbVersionDifferentFields()public void dbVersionReset()
dbVersionReset in class GrouperAPIpublic GrouperConfigHibernate clone()
clone in interface GrouperCloneableclone in class GrouperAPIObject.clone()public boolean equals(Object other)
equals in class ObjectObject.equals(java.lang.Object)public int compareTo(GrouperConfigHibernate otherConfig)
compareTo in interface Comparable<GrouperConfigHibernate>Comparable.compareTo(java.lang.Object)public int hashCode()
hashCode in class ObjectObject.hashCode()public void setConfigFileName(ConfigFileName configFileName)
configFileName - the configFileName to setpublic ConfigFileName getConfigFileName()
public void clear(GrouperCacheDatabaseClearInput grouperCacheDatabaseClearInput)
clear in interface GrouperCacheDatabaseClearpublic static void clearConfigsInMemory()
Copyright © 2016 Internet2. All rights reserved.