1 22 package org.jboss.util.property; 23 24 33 public final class DefaultPropertyReader 34 extends FilePropertyReader 35 { 36 43 44 public static final String DEFAULT_PROPERTY_NAME = "properties"; 45 46 52 public DefaultPropertyReader(final String propertyName) { 53 super(getFilenames(propertyName)); 54 } 55 56 59 public DefaultPropertyReader() { 60 this(DEFAULT_PROPERTY_NAME); 61 } 62 63 69 public static String [] getFilenames(final String propertyName) 70 throws PropertyException 71 { 72 String filenames[]; 73 74 Object filename = PropertyManager.getProperty(propertyName); 76 if (filename != null) { 77 filenames = new String [] { String.valueOf(filename) }; 78 } 79 else { 80 filenames = PropertyManager.getArrayProperty(propertyName); 82 } 83 84 return filenames; 85 } 86 } 87 | Popular Tags |