org.opengts.db.tables
Class SystemProps

java.lang.Object
  extended by org.opengts.dbtools.DBRecord<SystemProps>
      extended by org.opengts.db.tables.SystemProps

public class SystemProps
extends DBRecord<SystemProps>


Nested Class Summary
static class SystemProps.Key
           
 
Nested classes/interfaces inherited from class org.opengts.dbtools.DBRecord
DBRecord.DBChangeListener
 
Field Summary
static java.lang.String DMTP_VERSION
           
static java.lang.String FLD_dataType
           
static java.lang.String FLD_propertyID
           
static java.lang.String FLD_value
           
static java.lang.String GTS_VERSION
           
static java.lang.String[] READ_ONLY_PROPS
           
static java.lang.String TYPE_DOUBLE
           
static java.lang.String TYPE_ENUM_
           
static java.lang.String TYPE_INTEGER
           
static java.lang.String TYPE_LONG
           
static java.lang.String TYPE_STRING
           
 
Fields inherited from class org.opengts.dbtools.DBRecord
errorDescription, excludedUpdateFields, FLD_creationMillis, FLD_creationTime, FLD_description, FLD_lastUpdateAccount, FLD_lastUpdateTime, FLD_lastUpdateUser, hasError, ID_SIZE, isValidating, lastSQLException, NOTIFY_GROUP, PSEUDO_FIELD_CHAR, tempProps
 
Constructor Summary
SystemProps()
           
SystemProps(SystemProps.Key key)
           
 
Method Summary
static SystemProps createNewProperty(java.lang.String propID, java.lang.String type, java.lang.String desc)
          Creates/Saves a new SystemProps key
 java.lang.String getDataType()
           
static java.lang.String getDMTPVersion()
           
static java.lang.String getDMTPVersion(java.lang.String dft)
           
 double getDoubleValue(double dft)
          Gets the property value as a Double
static double getDoubleValue(java.lang.String propID, double dft)
           
static DBFactory<SystemProps> getFactory()
           
 float getFloatValue(float dft)
          Gets the property value as a Float
static float getFloatValue(java.lang.String propID, float dft)
           
static java.lang.String getGTSVersion()
           
static java.lang.String getGTSVersion(java.lang.String dft)
           
 int getIntValue(int dft)
          Gets the property value as an Integer
static int getIntValue(java.lang.String propID, int dft)
           
 long getLongValue(long dft)
          Gets the property value as a Long
static long getLongValue(java.lang.String propID, long dft)
           
static SystemProps getProperty(java.lang.String propKey)
          Returns the record instance for the specified property key
static SystemProps getProperty(java.lang.String propID, boolean create)
          Gets/Creates the SystemProps instance for specified property key
 java.lang.String getPropertyID()
           
static RTProperties getRTProperties()
          Return an RTProperties instance of the properties in the SystemProps table
 java.lang.String getStringValue()
          Gets the property String value
static java.lang.String getStringValue(java.lang.String propID, java.lang.String dft)
           
static java.lang.String[] getSystemPropsKeyArray()
          Returns an array of SystemProps keys
static java.util.Collection<java.lang.String> getSystemPropsKeyList()
          Return list of SystemProps keys
static java.lang.String getTableDescription(java.util.Locale loc)
           
 java.lang.String getValue()
           
static boolean hasProperty(java.lang.String propID)
          Returns true if the specified property key exists
 boolean isReadOnly()
          Returns true if this propertyID is in the "Read-Only" list
static boolean IsReadOnlyProperty(java.lang.String propID)
           
static void main(java.lang.String[] argv)
           
 void setCreationDefaultValues()
          Override to set default values
 void setDataType(java.lang.String v)
           
 void setDoubleValue(double v)
          Sets the property value as a Double
static boolean setDoubleValue(java.lang.String propID, double v)
           
 void setFloatValue(float v)
          Sets the property value as a Float
static boolean setFloatValue(java.lang.String propID, float v)
           
 void setIntValue(int v)
          Sets the property value as an Integer
static boolean setIntValue(java.lang.String propID, int v)
           
 void setLongValue(long v)
          Sets the property value as a Long
static boolean setLongValue(java.lang.String propID, long v)
           
static boolean setProperty(java.lang.String propID, java.lang.String value)
          Sets the String value for specified property ID, creating the property-ID if it does not already exist.
 void setStringValue(java.lang.String v)
          Sets the property String value
static boolean setStringValue(java.lang.String propID, java.lang.String value)
           
 void setValue(java.lang.String v)
           
static java.lang.String TABLE_NAME()
           
static java.lang.String TYPE_ENUM(java.lang.String[] E)
           
static void updateVersions()
           
 
Methods inherited from class org.opengts.dbtools.DBRecord
_getFactory, _reload, addChangedNotification, addExcludedUpdateFields, adjustStringLength_1, adjustStringLength, appendFieldValues, clearChanged, clearError, clearExcludedUpdateFields, clearLastCaughtSQLException, equals, excludeFieldFromUpdate, excludeFieldFromUpdate, fireChangeNotification, geKeyValue, getCreationDateTime, getCreationMillis, getCreationTime, GetCurrentAccount, GetCurrentUser, getDefaultFieldValueKey, getDescription, getErrorDescription, getFactory, getFactory, getField, getFieldBoolean, getFieldDateTime, getFieldDouble, getFieldFloat, getFieldInt, getFieldLong, getFieldName, getFieldString, getFieldValue, getFieldValue, getFieldValue, getFieldValue, getFieldValue, getFieldValue, getFieldValue, getFieldValue, getFieldValue, getKeyValue, getLastCaughtSQLException, getLastUpdateAccount, getLastUpdateTime, getLastUpdateTime, getLastUpdateUser, getNextGroup, getOptionalFieldValue, getOptionalFieldValue, getOptionalFieldValue, getOptionalFieldValue, getOptionalFieldValue, getOptionalFieldValue, getOptionalFieldValue, getOptionalFieldValue, getOptionalFieldValue, getRecordCount, getRecordCount, getRecordCount, getRecordCount, getRecordCount, getRecordKey, getRecords, getRecords, getTemporaryProperties, getValue, getVirtual, hasChanged, hasError, hasField, hasFieldValue, hasOptionalFieldValue, hasTemporaryProperties, insert, isFieldUnsigned, isLastCaughtSQLExceptionErrorCode, isOkToReload, isOkToSave, isValidating, isVirtual, lock, lockRead, lockWrite, newField_creationMillis, newField_creationTime, newField_creationTime, newField_description, newField_description, newField_lastUpdateAccount, newField_lastUpdateAccount, newField_lastUpdateTime, newField_lastUpdateUser, newField_lastUpdateUser, printXML, printXML, printXML, printXML, printXML, printXML, recordDidInsert, recordDidUpdate, recordWillInsert, recordWillUpdate, reload, reload, removeChangedNotification, save, select, select, select, setAllFieldValues, setAllFieldValues, setAllFieldValues, setAllFieldValues, setChanged, setChanged, setCreationMillis, setCreationTime, SetCurrentAccount, SetCurrentUser, setDescription, setError, setError, setFieldValue, setFieldValue, setFieldValue, setFieldValue, setFieldValue, setFieldValue, setFieldValue, setIgnoreInvalidFields, setKeyValue, setLastCaughtSQLException, setLastUpdateAccount, setLastUpdateTime, setLastUpdateUser, setOptionalFieldValue, setOptionalFieldValue, setOptionalFieldValue, setOptionalFieldValue, setOptionalFieldValue, setOptionalFieldValue, setOptionalFieldValue, setOptionalFieldValue, setRuntimeDefaultValues, setValidating, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setVirtual, toString, toXML, toXML, toXML, toXML, toXML, unlock, update, update, update
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

GTS_VERSION

public static final java.lang.String GTS_VERSION
See Also:
Constant Field Values

DMTP_VERSION

public static final java.lang.String DMTP_VERSION
See Also:
Constant Field Values

READ_ONLY_PROPS

public static final java.lang.String[] READ_ONLY_PROPS

TYPE_STRING

public static final java.lang.String TYPE_STRING
See Also:
Constant Field Values

TYPE_INTEGER

public static final java.lang.String TYPE_INTEGER
See Also:
Constant Field Values

TYPE_LONG

public static final java.lang.String TYPE_LONG
See Also:
Constant Field Values

TYPE_DOUBLE

public static final java.lang.String TYPE_DOUBLE
See Also:
Constant Field Values

TYPE_ENUM_

public static final java.lang.String TYPE_ENUM_
See Also:
Constant Field Values

FLD_propertyID

public static final java.lang.String FLD_propertyID
See Also:
Constant Field Values

FLD_dataType

public static final java.lang.String FLD_dataType
See Also:
Constant Field Values

FLD_value

public static final java.lang.String FLD_value
See Also:
Constant Field Values
Constructor Detail

SystemProps

public SystemProps()

SystemProps

public SystemProps(SystemProps.Key key)
Method Detail

IsReadOnlyProperty

public static boolean IsReadOnlyProperty(java.lang.String propID)

TYPE_ENUM

public static final java.lang.String TYPE_ENUM(java.lang.String[] E)

TABLE_NAME

public static java.lang.String TABLE_NAME()

getFactory

public static DBFactory<SystemProps> getFactory()

getTableDescription

public static java.lang.String getTableDescription(java.util.Locale loc)

getPropertyID

public java.lang.String getPropertyID()

getDataType

public java.lang.String getDataType()

setDataType

public void setDataType(java.lang.String v)

getValue

public java.lang.String getValue()

setValue

public void setValue(java.lang.String v)

setCreationDefaultValues

public void setCreationDefaultValues()
Description copied from class: DBRecord
Override to set default values

Overrides:
setCreationDefaultValues in class DBRecord<SystemProps>

isReadOnly

public boolean isReadOnly()
Returns true if this propertyID is in the "Read-Only" list


getStringValue

public java.lang.String getStringValue()
Gets the property String value


getIntValue

public int getIntValue(int dft)
Gets the property value as an Integer


getLongValue

public long getLongValue(long dft)
Gets the property value as a Long


getFloatValue

public float getFloatValue(float dft)
Gets the property value as a Float


getDoubleValue

public double getDoubleValue(double dft)
Gets the property value as a Double


setStringValue

public void setStringValue(java.lang.String v)
Sets the property String value


setIntValue

public void setIntValue(int v)
Sets the property value as an Integer


setLongValue

public void setLongValue(long v)
Sets the property value as a Long


setFloatValue

public void setFloatValue(float v)
Sets the property value as a Float


setDoubleValue

public void setDoubleValue(double v)
Sets the property value as a Double


getSystemPropsKeyArray

public static java.lang.String[] getSystemPropsKeyArray()
                                                 throws DBException
Returns an array of SystemProps keys

Throws:
DBException

getSystemPropsKeyList

public static java.util.Collection<java.lang.String> getSystemPropsKeyList()
                                                                    throws DBException
Return list of SystemProps keys

Throws:
DBException

getRTProperties

public static RTProperties getRTProperties()
                                    throws DBException
Return an RTProperties instance of the properties in the SystemProps table

Throws:
DBException

hasProperty

public static boolean hasProperty(java.lang.String propID)
                           throws DBException
Returns true if the specified property key exists

Throws:
DBException

getProperty

public static SystemProps getProperty(java.lang.String propKey)
                               throws DBException
Returns the record instance for the specified property key

Throws:
DBException

getProperty

public static SystemProps getProperty(java.lang.String propID,
                                      boolean create)
                               throws DBException
Gets/Creates the SystemProps instance for specified property key

Parameters:
propID - The property key
create - True to create new propID entry, false to read existing.
Throws:
DBException - if create specified and propID already exists, or if create not specified and propID not found.

createNewProperty

public static SystemProps createNewProperty(java.lang.String propID,
                                            java.lang.String type,
                                            java.lang.String desc)
                                     throws DBException
Creates/Saves a new SystemProps key

Parameters:
propID - The property key
type - The property data type (defaults to "String" is blank)
desc - The property description (defaults to propID if blank)
Returns:
The new SystemProps instance (saved)
Throws:
DBException - If propID already exists, or unable to create new key

setProperty

public static boolean setProperty(java.lang.String propID,
                                  java.lang.String value)
Sets the String value for specified property ID, creating the property-ID if it does not already exist.

Returns:
True if the property ID was successfully saved, false otherwise

getStringValue

public static java.lang.String getStringValue(java.lang.String propID,
                                              java.lang.String dft)

getIntValue

public static int getIntValue(java.lang.String propID,
                              int dft)

getLongValue

public static long getLongValue(java.lang.String propID,
                                long dft)

getFloatValue

public static float getFloatValue(java.lang.String propID,
                                  float dft)

getDoubleValue

public static double getDoubleValue(java.lang.String propID,
                                    double dft)

setStringValue

public static boolean setStringValue(java.lang.String propID,
                                     java.lang.String value)

setIntValue

public static boolean setIntValue(java.lang.String propID,
                                  int v)

setLongValue

public static boolean setLongValue(java.lang.String propID,
                                   long v)

setFloatValue

public static boolean setFloatValue(java.lang.String propID,
                                    float v)

setDoubleValue

public static boolean setDoubleValue(java.lang.String propID,
                                     double v)

getGTSVersion

public static java.lang.String getGTSVersion(java.lang.String dft)

getGTSVersion

public static java.lang.String getGTSVersion()

getDMTPVersion

public static java.lang.String getDMTPVersion(java.lang.String dft)

getDMTPVersion

public static java.lang.String getDMTPVersion()

updateVersions

public static void updateVersions()

main

public static void main(java.lang.String[] argv)