public class Config extends Object
| 限定符和类型 | 方法和说明 |
|---|---|
String |
get(String path) |
String |
get(String path,
boolean escape) |
String |
get(String path,
String defaultValue) |
boolean |
getBool(String path,
boolean defaultValue) |
int |
getInt(String path,
int defaultValue) |
List<String> |
getSubKeys(String path) |
List<String> |
getSubTags(String path) |
static Config |
parse(InputStream in) |
static Config |
parse(InputStream in,
Charset charset) |
static Config |
parse(Reader in) |
static Config |
parse(String content) |
static Config |
parseFile(String file) |
static Config |
parseFile(String file,
Charset charset) |
String |
toString() |
public int getInt(String path, int defaultValue)
public boolean getBool(String path, boolean defaultValue)
public static Config parse(Reader in) throws IOException
IOExceptionpublic static Config parse(InputStream in) throws IOException
IOExceptionpublic static Config parse(InputStream in, Charset charset) throws IOException
IOExceptionpublic static Config parseFile(String file, Charset charset) throws FileNotFoundException, IOException
public static Config parseFile(String file) throws FileNotFoundException, IOException
Copyright © 2020. All Rights Reserved.