知识卡片
领域语言与通用语言
领域专用语言以包、文件、服务或云资源等概念直接建模,降低读写该领域代码的距离;通用语言可以跨问题域复用熟悉的编辑器、静态检查和测试生态。内部DSL借宿主语言实现并可能保留其能力;外部DSL有独立语义,不能因工具用某语言编写就直接调用该语言功能。
这张卡片看不懂?
这张卡片已通过人工审查,不再接受失败反馈。
已有反馈 · 0 条
还没有人提交反馈。
在整书笔记中的位置
原书出处 · 1 处
- 基础设施工具与语言 · 查看原书依据
Many infrastructure tools use their own DSL.12 A DSL is a language designed to model a specific domain, in our case infrastructure. This makes it easier to write code and makes the code easier to understand because it closely maps the things you’re defining. Ansible, Chef, and Puppet each have a DSL for configuring servers.
参考来源
- 位置:《Infrastructure As Code》第4章《基础设施工具与语言》(来源项目 book-sources,源文件:extracted/Infrastructure As Code/_epub-src/OEBPS/ch04.html)
- 结论依据:原文对该概念的定义、应用条件与作用机制直接支持上述解释。
- 原始内容:Many infrastructure tools use their own DSL.12 A DSL is a language designed to model a specific domain, in our case infrastructure. This makes it easier to write code and makes the code easier to understand because it closely maps the things you’re defining. Ansible, Chef, and Puppet each have a DSL for configuring servers.