public final class ConfigHelper extends Object
| Modifier and Type | Method and Description | 
|---|---|
static URL | 
findAsResource(String path)
Try to locate a local URL representing the incoming path. 
 | 
static Properties | 
getConfigProperties(String path)
Loads a properties instance based on the data at the incoming config location. 
 | 
static InputStream | 
getConfigStream(String path)
Open an InputStream to the URL represented by the incoming path. 
 | 
static Reader | 
getConfigStreamReader(String path)
Open an Reader to the URL represented by the incoming path. 
 | 
static InputStream | 
getResourceAsStream(String resource)  | 
static InputStream | 
getUserResourceAsStream(String resource)  | 
static URL | 
locateConfig(String path)
Try to locate a local URL representing the incoming path. 
 | 
public static URL locateConfig(String path)
path - The path representing the config location.public static URL findAsResource(String path)
path - The path representing the config location.public static InputStream getConfigStream(String path) throws HibernateException
locateConfig(java.lang.String) in order to find an appropriate URL.
 URL.openStream() is then called to obtain the stream.path - The path representing the config location.HibernateException - Unable to open stream to that resource.public static Reader getConfigStreamReader(String path) throws HibernateException
locateConfig(java.lang.String) in order to find an appropriate URL.
 URL.openStream() is then called to obtain a stream, which is then
 wrapped in a Reader.path - The path representing the config location.HibernateException - Unable to open reader to that resource.public static Properties getConfigProperties(String path) throws HibernateException
path - The path representing the config location.HibernateException - Unable to load properties from that resource.public static InputStream getResourceAsStream(String resource)
public static InputStream getUserResourceAsStream(String resource)
Copyright © 2001-2015 Red Hat, Inc. All Rights Reserved.