net.sourceforge.addam.ddlrun.utils
Class ClassLoaderReaderFactory

java.lang.Object
  extended by net.sourceforge.addam.ddlrun.utils.ClassLoaderReaderFactory
All Implemented Interfaces:
ResourceReaderFactory

public class ClassLoaderReaderFactory
extends Object
implements ResourceReaderFactory

Used to retrieve a ClassLoaderReader.

Since:
Mar 5, 2005
Author:
TIM3

Field Summary
private  String basePath
           
private static String SEPARATOR
           
 
Constructor Summary
ClassLoaderReaderFactory()
          Constructs a ClassLoaderReaderFactory with no base path
ClassLoaderReaderFactory(String basePath)
          Constructs a ClassLoaderReaderFactory the provided base path, which is prepended to all non-absolute requests (i.e.
 
Method Summary
 ResourceReader getReader(String resource)
           
 ResourceReader getReader(String path, String resource)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SEPARATOR

private static final String SEPARATOR
See Also:
Constant Field Values

basePath

private final String basePath
Constructor Detail

ClassLoaderReaderFactory

public ClassLoaderReaderFactory()
Constructs a ClassLoaderReaderFactory with no base path


ClassLoaderReaderFactory

public ClassLoaderReaderFactory(String basePath)
Constructs a ClassLoaderReaderFactory the provided base path, which is prepended to all non-absolute requests (i.e. those not beginning with '/')

Parameters:
basePath - the path to prepend to relative paths passed to getReader
Method Detail

getReader

public ResourceReader getReader(String resource)
Specified by:
getReader in interface ResourceReaderFactory

getReader

public ResourceReader getReader(String path,
                                String resource)
Specified by:
getReader in interface ResourceReaderFactory


Copyright © 2005-2006 ADDAM Project Team. All Rights Reserved.