Clojure 的 Python StringIO
Clojure 是否有相当于 Python 的 StingIO 的东西?
我正在尝试编写一个类似于 Sweave 和 Clojure 的 Pweave。我目前正在使用临时文件,但我更喜欢使用类似于 StringIO 的文件。
Is there something equivalent to Python's StingIO for Clojure?
I'm trying to write a report generating/literate programming system similar to Sweave and Pweave for Clojure. I'm currently using a temp file, but I'd prefer using something similar to StringIO.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
with-out-str 非常方便。
更多文档此处
with-out-str is pretty handy.
More documentation here
java.io.StringWriter: http://download.oracle .com/javase/6/docs/api/java/io/StringWriter.html
java.io.StringWriter: http://download.oracle.com/javase/6/docs/api/java/io/StringWriter.html