asia.redact.bracket.properties.mgmt
Class LoadList

java.lang.Object
  extended by asia.redact.bracket.properties.mgmt.LoadList

public class LoadList
extends Object

 Our list of references from which to load properties. The list can contain
 externalized files, internal files within the classpath (such as in a jar
 file) and even direct name value pairs.
 
 Localization is supported, just set attributes.locale to the appropriate locale.
 
 

Author:
Dave

Field Summary
protected  Attributes attribs
           
protected  List<PropertiesReference> list
           
protected  Properties props
           
 
Constructor Summary
LoadList()
           
LoadList(Attributes attribs)
           
 
Method Summary
 void addReference(File file)
          This is understood as a shortcut for PropertiesReference(ReferenceType.EXTERNAL,fileloc);
 void addReference(PropertiesReference ref)
           
 void addReference(ReferenceType type, String path)
           
 Attributes getAttribs()
           
 List<PropertiesReference> getList()
           
 Properties getProps()
           
 void load()
           
private  void loadFromClasspath(String path)
           
private  void loadFromDirect(String data)
           
private  void loadFromFile(String path)
           
private  void loadFromSystemProps(String key)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

list

protected final List<PropertiesReference> list

props

protected final Properties props

attribs

protected final Attributes attribs
Constructor Detail

LoadList

public LoadList()

LoadList

public LoadList(Attributes attribs)
Method Detail

addReference

public void addReference(File file)
This is understood as a shortcut for PropertiesReference(ReferenceType.EXTERNAL,fileloc);

Parameters:
file -

addReference

public void addReference(ReferenceType type,
                         String path)

addReference

public void addReference(PropertiesReference ref)

load

public void load()

loadFromSystemProps

private void loadFromSystemProps(String key)

loadFromClasspath

private void loadFromClasspath(String path)

loadFromDirect

private void loadFromDirect(String data)

loadFromFile

private void loadFromFile(String path)

getList

public List<PropertiesReference> getList()

getProps

public Properties getProps()

getAttribs

public Attributes getAttribs()


Copyright © 2011-2013 David R. Smith. All Rights Reserved.