Class FormatableProperties

All Implemented Interfaces:
Externalizable, Serializable, Cloneable, Map<Object,Object>, Formatable, TypedFormat

public class FormatableProperties extends Properties implements Formatable
A formatable holder for a java.util.Properties. Used to avoid serializing Properties.
See Also:
  • Constructor Details

    • FormatableProperties

      public FormatableProperties()
      Niladic constructor for formatable
    • FormatableProperties

      public FormatableProperties(Properties defaults)
      Creates an empty property list with the specified defaults.
      Parameters:
      defaults - the defaults
  • Method Details

    • clearDefaults

      public void clearDefaults()
      Clear the defaults from this Properties set. This sets the default field to null and thus breaks any link with the Properties set that was the default.
    • writeExternal

      public void writeExternal(ObjectOutput out) throws IOException
      Write the properties out. Step through the enumeration and write the strings out in UTF.
      Specified by:
      writeExternal in interface Externalizable
      Parameters:
      out - write bytes here
      Throws:
      IOException - thrown on error
    • readExternal

      public void readExternal(ObjectInput in) throws IOException
      Read the properties from a stream of stored objects.
      Specified by:
      readExternal in interface Externalizable
      Parameters:
      in - read this.
      Throws:
      IOException - thrown on error
    • getTypeFormatId

      public int getTypeFormatId()
      Get the formatID which corresponds to this class.
      Specified by:
      getTypeFormatId in interface TypedFormat
      Returns:
      the formatID of this class