Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我需要从 .yml 文件中读取一些值和变量,仅此而已,将它们写入字符串,这就是我所需要的?我该怎么做?
Yaml yaml = new Yaml(); Map<String, Object> config = (Map<String, Object>) yaml.load("Your input");
“你的输入”可以是 InputStream、Reader 或 String。