com.fullspan.propkeyconst
Class PropertyLoader

java.lang.Object
  extended bycom.fullspan.propkeyconst.PropertyLoader

public class PropertyLoader
extends java.lang.Object

Load one or more Properties objects. The loaded object(s) can then be used, for example, to generate a .java file with constants representing property keys.

Author:
Mitch Stuart
See Also:
ConstantGenerator

Constructor Summary
PropertyLoader(java.util.Properties props)
          Construct an instance which will load a single Properties object
PropertyLoader(java.util.Properties[] propertiesObjArr)
          Construct an instance which will load multiple Properties objects
 
Method Summary
 RootClassDesc getRootClassDesc()
          Call this after calling load() to get the resulting class descriptor.
 void load()
          Load the Properties object(s) that were specified in the constructor.
protected  void loadPropertiesObj(java.util.Properties propertiesObj)
           
protected  void loadPropKey(java.lang.String propKey, java.lang.String propValue)
           
protected  void processComment(CommentDesc commentDesc)
           
protected  void processComments()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PropertyLoader

public PropertyLoader(java.util.Properties props)
Construct an instance which will load a single Properties object

Parameters:
props -

PropertyLoader

public PropertyLoader(java.util.Properties[] propertiesObjArr)
Construct an instance which will load multiple Properties objects

Parameters:
propertiesObjArr -
Method Detail

getRootClassDesc

public RootClassDesc getRootClassDesc()
Call this after calling load() to get the resulting class descriptor.

Returns:
the root class descriptor for the loaded Properties object(s)

load

public void load()
          throws java.io.IOException
Load the Properties object(s) that were specified in the constructor.

Throws:
java.io.IOException

loadPropertiesObj

protected void loadPropertiesObj(java.util.Properties propertiesObj)
                          throws java.io.IOException
Throws:
java.io.IOException

loadPropKey

protected void loadPropKey(java.lang.String propKey,
                           java.lang.String propValue)

processComments

protected void processComments()

processComment

protected void processComment(CommentDesc commentDesc)