领域特定语言(DSL)与框架 [英] Domain Specific Language (DSL) vs. Frameworks
本文介绍了领域特定语言(DSL)与框架的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
DSL和框架的主要思想之间的主要区别是什么?这两个问题令我非常困惑,我无法通过互联网找到合适的答案!
What is the main difference between the main idea of DSL and Frameworks? These two issues are very confusing to me and i couldn't find a proper answer through internet!
推荐答案
好问题。这是我看到的最简单的解释:
Good question. This is the simplest explanation I see:
DSL可以具有自己的具体语法。框架不能具有自己的语法,因为
所用的语言与创建时所用的语言相同。 领域特定语言与框架
例如:HTML是DSL,而AngularJS框架中的指令是用HTML语法编写的,因此不构成单独的语言。
For example: HTML is a DSL, whereas directives in the AngularJS framework are written in HTML syntax so do not constitute a separate language.
这篇关于领域特定语言(DSL)与框架的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文