result = replace(result);
if (configFileStr != null) { try { is = new FileInputStream(replace(configFileStr)); } catch (IOException e) {
/** * System property replacement in the given string. * * @param str The original string * @return the modified string */ protected String replace(String str) { String result = str; int pos_start = result.indexOf("${"); if (pos_start != -1) { int pos_end = result.indexOf('}'); if (pos_end != -1) { String propName = result.substring(pos_start + 2, pos_end); String replacement = System.getProperty(propName); if (replacement != null) { if(pos_start >0) { result = result.substring(0,pos_start) + replacement + replace(result.substring(pos_end + 1)); } else { result = replacement + replace(result.substring(pos_end + 1)); } } } } return result; }
/** * System property replacement in the given string. * * @param str The original string * @return the modified string */ protected String replace(String str) { String result = str; int pos_start = result.indexOf("${"); if (pos_start != -1) { int pos_end = result.indexOf('}'); if (pos_end != -1) { String propName = result.substring(pos_start + 2, pos_end); String replacement = System.getProperty(propName); if (replacement != null) { if(pos_start >0) { result = result.substring(0,pos_start) + replacement + replace(result.substring(pos_end + 1)); } else { result = replacement + replace(result.substring(pos_end + 1)); } } } } return result; }
/** * System property replacement in the given string. * * @param str The original string * @return the modified string */ protected String replace(String str) { String result = str; int pos_start = result.indexOf("${"); if (pos_start != -1) { int pos_end = result.indexOf('}'); if (pos_end != -1) { String propName = result.substring(pos_start + 2, pos_end); String replacement = System.getProperty(propName); if (replacement != null) { if(pos_start >0) { result = result.substring(0,pos_start) + replacement + replace(result.substring(pos_end + 1)); } else { result = replacement + replace(result.substring(pos_end + 1)); } } } } return result; }
/** * Get the value of the specified property in the classloader local * configuration. * * @param name The property name */ @Override public String getProperty(String name) { // Use a ThreadLocal to work around // https://bugs.openjdk.java.net/browse/JDK-8195096 if (".handlers".equals(name) && !addingLocalRootLogger.get().booleanValue()) { return null; } String prefix = this.prefix.get(); String result = null; // If a prefix is defined look for a prefixed property first if (prefix != null) { result = findProperty(prefix + name); } // If there is no prefix or no property match with the prefix try just // the name if (result == null) { result = findProperty(name); } // Simple property replacement (mostly for folder names) if (result != null) { result = replace(result); } return result; }
/** * Get the value of the specified property in the classloader local * configuration. * * @param name The property name */ @Override public String getProperty(String name) { // Use a ThreadLocal to work around // https://bugs.openjdk.java.net/browse/JDK-8195096 if (".handlers".equals(name) && !addingLocalRootLogger.get().booleanValue()) { return null; } String prefix = this.prefix.get(); String result = null; // If a prefix is defined look for a prefixed property first if (prefix != null) { result = findProperty(prefix + name); } // If there is no prefix or no property match with the prefix try just // the name if (result == null) { result = findProperty(name); } // Simple property replacement (mostly for folder names) if (result != null) { result = replace(result); } return result; }
/** * Get the value of the specified property in the classloader local * configuration. * * @param name The property name */ @Override public String getProperty(String name) { // Use a ThreadLocal to work around // https://bugs.openjdk.java.net/browse/JDK-8195096 if (".handlers".equals(name) && !addingLocalRootLogger.get().booleanValue()) { return null; } String prefix = this.prefix.get(); String result = null; // If a prefix is defined look for a prefixed property first if (prefix != null) { result = findProperty(prefix + name); } // If there is no prefix or no property match with the prefix try just // the name if (result == null) { result = findProperty(name); } // Simple property replacement (mostly for folder names) if (result != null) { result = replace(result); } return result; }
/** * Get the value of the specified property in the classloader local * configuration. * * @param name The property name */ @Override public String getProperty(String name) { // Use a ThreadLocal to work around // https://bugs.openjdk.java.net/browse/JDK-8195096 if (".handlers".equals(name) && !addingLocalRootLogger.get().booleanValue()) { return null; } String prefix = this.prefix.get(); String result = null; // If a prefix is defined look for a prefixed property first if (prefix != null) { result = findProperty(prefix + name); } // If there is no prefix or no property match with the prefix try just // the name if (result == null) { result = findProperty(name); } // Simple property replacement (mostly for folder names) if (result != null) { result = replace(result); } return result; }
result = replace(result);
/** * Get the value of the specified property in the classloader local * configuration. * * @param name The property name */ @Override public String getProperty(String name) { // Use a ThreadLocal to work around // https://bugs.openjdk.java.net/browse/JDK-8195096 if (".handlers".equals(name) && !addingLocalRootLogger.get().booleanValue()) { return null; } String prefix = this.prefix.get(); String result = null; // If a prefix is defined look for a prefixed property first if (prefix != null) { result = findProperty(prefix + name); } // If there is no prefix or no property match with the prefix try just // the name if (result == null) { result = findProperty(name); } // Simple property replacement (mostly for folder names) if (result != null) { result = replace(result); } return result; }
result = replace(result);
result = replace(result);
result = replace(result);
result = replace(result);
/** * Get the value of the specified property in the classloader local * configuration. * * @param name The property name */ @Override public String getProperty(String name) { String prefix = this.prefix.get(); String result = null; // If a prefix is defined look for a prefixed property first if (prefix != null) { result = findProperty(prefix + name); } // If there is no prefix or no property match with the prefix try just // the name if (result == null) { result = findProperty(name); } // Simple property replacement (mostly for folder names) if (result != null) { result = replace(result); } return result; }
/** * Get the value of the specified property in the classloader local * configuration. * * @param name The property name */ @Override public String getProperty(String name) { String prefix = this.prefix.get(); String result = null; // If a prefix is defined look for a prefixed property first if (prefix != null) { result = findProperty(prefix + name); } // If there is no prefix or no property match with the prefix try just // the name if (result == null) { result = findProperty(name); } // Simple property replacement (mostly for folder names) if (result != null) { result = replace(result); } return result; }
if (configFileStr != null) { try { is = new FileInputStream(replace(configFileStr)); } catch (IOException e) {
if (configFileStr != null) { try { is = new FileInputStream(replace(configFileStr)); } catch (IOException e) {
if (configFileStr != null) { try { is = new FileInputStream(replace(configFileStr)); } catch (IOException e) {