com.threerings.config.dist.data
Class ConfigEntry

java.lang.Object
  extended by com.threerings.io.SimpleStreamableObject
      extended by com.threerings.config.dist.data.ConfigEntry
All Implemented Interfaces:
Streamable, DSet.Entry

public class ConfigEntry
extends SimpleStreamableObject
implements DSet.Entry

Represents an added or updated configuration.


Nested Class Summary
 
Nested classes/interfaces inherited from interface com.threerings.io.Streamable
Streamable.Closure
 
Field Summary
protected  byte[] _bytes
          The exported config.
protected  ManagedConfig _config
          The config object.
protected  ConfigKey _key
          The config key.
 
Constructor Summary
ConfigEntry()
          No-arg constructor for deserialization.
ConfigEntry(ManagedConfig config)
          Creates a new config entry.
 
Method Summary
 boolean equals(Object other)
           
 ManagedConfig getConfig()
          Returns a reference to the config object.
 Class<? extends ManagedConfig> getConfigClass()
          Returns the config class.
 Comparable<?> getKey()
           
 String getName()
          Returns the name of the config.
 void readObject(ObjectInputStream in)
          Custom read method for streaming.
 String toString()
           
 
Methods inherited from class com.threerings.io.SimpleStreamableObject
toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

_key

protected ConfigKey _key
The config key.


_bytes

protected byte[] _bytes
The exported config.


_config

protected transient ManagedConfig _config
The config object.

Constructor Detail

ConfigEntry

public ConfigEntry(ManagedConfig config)
Creates a new config entry.


ConfigEntry

public ConfigEntry()
No-arg constructor for deserialization.

Method Detail

getConfigClass

public Class<? extends ManagedConfig> getConfigClass()
Returns the config class.


getName

public String getName()
Returns the name of the config.


getConfig

public ManagedConfig getConfig()
Returns a reference to the config object.


readObject

public void readObject(ObjectInputStream in)
                throws IOException,
                       ClassNotFoundException
Custom read method for streaming.

Throws:
IOException
ClassNotFoundException

getKey

public Comparable<?> getKey()
Specified by:
getKey in interface DSet.Entry

toString

public String toString()
Overrides:
toString in class SimpleStreamableObject

equals

public boolean equals(Object other)
Overrides:
equals in class Object