18 lines
351 B
Java
18 lines
351 B
Java
package com.qiwenshare.common.util;
|
|
|
|
import org.springframework.core.env.Environment;
|
|
|
|
public class PropertiesUtil {
|
|
|
|
private static Environment env = null;
|
|
|
|
public static void setEnvironment(Environment env) {
|
|
PropertiesUtil.env = env;
|
|
}
|
|
|
|
public static String getProperty(String key) {
|
|
return PropertiesUtil.env.getProperty(key);
|
|
}
|
|
|
|
|
|
} |