本文整理了Java中io.konig.yaml.Yaml
类的一些代码示例,展示了Yaml
类的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Yaml
类的具体详情如下:
包路径:io.konig.yaml.Yaml
类名称:Yaml
暂无
代码示例来源:origin: io.konig/konig-gcp-deploy-model
public String toString() {
return Yaml.toString(this);
}
代码示例来源:origin: io.konig/konig-yaml
public static String toString(Object object) {
StringWriter buffer = new StringWriter();
write(buffer, object);
return buffer.toString();
}
代码示例来源:origin: io.konig/konig-yaml
public static <T> T read(Class<T> type, InputStream input) throws YamlParseException, IOException {
InputStreamReader reader = new InputStreamReader(input);
return read(type, reader);
}
代码示例来源:origin: io.konig/konig-yaml
public static String toString(YamlWriterConfig config, Object object) {
StringWriter buffer = new StringWriter();
write(buffer, config, object);
return buffer.toString();
}
代码示例来源:origin: io.konig/konig-yaml
public static <T> T read(Class<T> type, String yamlText) throws YamlParseException, IOException {
return read(type, new StringReader(yamlText));
}
代码示例来源:origin: io.konig/konig-maven-common
public String toString() {
return Yaml.toString(this);
}
public MetadataInfo getMetadata() {
代码示例来源:origin: io.konig/konig-yaml
public static void write(File outFile, Object object) throws IOException {
outFile.getParentFile().mkdirs();
try (FileWriter writer = new FileWriter(outFile)) {
write(writer, object);
}
}
代码示例来源:origin: io.konig/konig-yaml
public static <T> T read(Class<T> type, File file) throws YamlParseException {
try (FileReader reader = new FileReader(file)) {
return read(type, reader);
} catch (Throwable e) {
String msg = MessageFormat.format("Failed to read file: {0}", file.toString());
throw new YamlParseException(msg, e);
}
}
代码示例来源:origin: io.konig/konig-maven-common
public String toString() {
return Yaml.toString(this);
}
代码示例来源:origin: io.konig/konig-dao-core
public String toString() {
return Yaml.toString(this);
}
代码示例来源:origin: io.konig/konig-dao-core
public String toString() {
return Yaml.toString(this);
}
内容来源于网络,如有侵权,请联系作者删除!