org.jmythapi.database.impl
Class Setting

java.lang.Object
  extended by org.jmythapi.impl.AData<E>
      extended by org.jmythapi.database.impl.ADatabaseRow<ISetting.Props>
          extended by org.jmythapi.database.impl.Setting
All Implemented Interfaces:
Cloneable, IPropertyAware<ISetting.Props>, ISetting, IVersionable

public class Setting
extends ADatabaseRow<ISetting.Props>
implements ISetting


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.jmythapi.ISetting
ISetting.Props
 
Field Summary
 
Fields inherited from class org.jmythapi.impl.AData
logger, propsClass, protoVersion, respArgs
 
Constructor Summary
Setting(ProtocolVersion protoVersion, int dbVersion, List<String> data)
           
 
Method Summary
 String getData()
          Gets the settings value
<T> T
getData(Class<T> dataType)
          Gets the settings value and converts it into the given data type.
 String getHostname()
          Gets the backends hostname this settings belongs to.
 String getName()
          The name of the setting.
 
Methods inherited from class org.jmythapi.database.impl.ADatabaseRow
clone, decodeProperty, encodeProperty, equals, getDatabaseVersion, getProperties, getProperty, getPropertyIndex
 
Methods inherited from class org.jmythapi.impl.AData
getPropertyClass, getPropertyCount, getPropertyMap, getPropertyValue, getPropertyValue, getPropertyValueObject, getPropertyValueObject, getPropertyValues, getVersionNr, hashCode, init, postProcessArguments, setPropertyValue, setPropertyValue, setPropertyValueObject, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.jmythapi.IVersionable
getVersionNr
 
Methods inherited from interface org.jmythapi.IPropertyAware
getProperties, getProperty, getPropertyClass, getPropertyCount, getPropertyIndex, getPropertyMap, getPropertyValue, getPropertyValue, getPropertyValueObject, getPropertyValues, setPropertyValue, setPropertyValue, setPropertyValueObject
 

Constructor Detail

Setting

public Setting(ProtocolVersion protoVersion,
               int dbVersion,
               List<String> data)
Method Detail

getData

public String getData()
Description copied from interface: ISetting
Gets the settings value

Specified by:
getData in interface ISetting
Returns:
The value of the setting.
See Also:
ISetting.Props.DATA

getData

public <T> T getData(Class<T> dataType)
Description copied from interface: ISetting
Gets the settings value and converts it into the given data type.

Specified by:
getData in interface ISetting
Type Parameters:
T - the data type
Parameters:
dataType - the data type
Returns:
the settings value

getHostname

public String getHostname()
Description copied from interface: ISetting
Gets the backends hostname this settings belongs to.

Specified by:
getHostname in interface ISetting
Returns:
the name of the host or null

getName

public String getName()
Description copied from interface: ISetting
The name of the setting.

Specified by:
getName in interface ISetting
Returns:
the settings name


Copyright © 2008-2013. All Rights Reserved.