Class ConfigProxyItem

All Implemented Interfaces:
JaloOnlyItem, JaloOnlySingletonItem, Serializable, Comparable
Direct Known Subclasses:
LDAPConfigProxyItem

public class ConfigProxyItem extends Item implements JaloOnlySingletonItem
A singleton used to manage config properties. Uses ConfigItem iternally to read/store config properties.
See Also:
  • Constructor Details

    • ConfigProxyItem

      public ConfigProxyItem()
  • Method Details

    • providePK

      public PK providePK()
      Description copied from interface: JaloOnlyItem
      Should provide a fixed PK for this item.
      Specified by:
      providePK in interface JaloOnlyItem
      Returns:
      PK of this item
    • provideComposedType

      public ComposedType provideComposedType()
      Description copied from interface: JaloOnlyItem
      Should provide the composed type of this item.
      Specified by:
      provideComposedType in interface JaloOnlyItem
      Returns:
      ComposedType of this item
    • createItem

      public Item createItem(SessionContext ctx, ComposedType type, Item.ItemAttributeMap allAttributes) throws JaloBusinessException
      Returns an instance of this class.
      Specified by:
      createItem in class Item
      Parameters:
      ctx - the current session context which this item is created within
      type - the actual item type ( since subtypes may not provide a own jalo class this may be different from the type which this method was implemented for )
      Returns:
      the new item instance
      Throws:
      JaloBusinessException - indicates an error during creation - any changes will be rollbacked
    • removeJaloOnly

      public void removeJaloOnly() throws ConsistencyCheckException
      no-op
      Specified by:
      removeJaloOnly in interface JaloOnlyItem
      Throws:
      ConsistencyCheckException - to signal that this item removal failed
    • provideCreationTime

      public Date provideCreationTime()
      Description copied from interface: JaloOnlyItem
      Should provide a fixed creation time for this item.
      Specified by:
      provideCreationTime in interface JaloOnlyItem
      Returns:
      creation time date of this item
    • provideModificationTime

      public Date provideModificationTime()
      Description copied from interface: JaloOnlyItem
      Should provide a modification time for this item.
      Specified by:
      provideModificationTime in interface JaloOnlyItem
      Returns:
      modification time date of this item
    • doGetAttribute

      public Object doGetAttribute(SessionContext ctx, String qualifier)
      Description copied from interface: JaloOnlyItem
      Should get the value of the given attribute if no AttributeAccess has been registered for it. Otherwise the value is read from the access instance.
      Specified by:
      doGetAttribute in interface JaloOnlyItem
      Parameters:
      ctx - the session context
      qualifier - the qualifier of the requested attribute
      Returns:
      the attribute value
    • getInt

      public int getInt(String qualifier, int def)
    • getValue

      public Object getValue(String qualifier)
    • getValue

      public Object getValue(SessionContext ctx, String qualifier)
    • doSetAttribute

      public void doSetAttribute(SessionContext ctx, String qualifier, Object value) throws JaloBusinessException
      Description copied from interface: JaloOnlyItem
      Should set the value of the given attribute if no AttributeAccess has been registered for it. Otherwise the value is read from the access instance.
      Specified by:
      doSetAttribute in interface JaloOnlyItem
      Parameters:
      ctx - the session context
      qualifier - the qualifier of the requested attribute
      value - the new attribute value
      Throws:
      JaloSecurityException - in case the session user is not allowed to write this attribute
      JaloBusinessException - in case any other error occured
    • setValue

      public void setValue(String qualifier, Object value)
    • setValue

      public void setValue(SessionContext ctx, String qualifier, Object value)
    • setTransientValue

      protected void setTransientValue(String qualifier, String value)
    • getTransientValue

      protected String getTransientValue(String qualifier)
    • setPersistentValue

      protected void setPersistentValue(String qualifier, String value)
    • getPersistentValue

      protected Serializable getPersistentValue(String qualifier)
    • storeInDatabase

      protected boolean storeInDatabase(String qualifier)
      Returns:
      true if the attribute should be stored in database
    • getExternalQualifier

      protected String getExternalQualifier(String qualifier)
      Returns:
      the external qualifier of this attribute which is used to get/set the attribute via Config
    • booleanValue

      public static boolean booleanValue(String value)
    • integerValue

      public static Integer integerValue(String value)
    • longValue

      public static Long longValue(String value)