Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Domain Specific Language (DSL) vs. Frameworks

Tags:

frameworks

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!

like image 645
Amir Jalilifard Avatar asked Jul 13 '14 17:07

Amir Jalilifard


People also ask

What is DSL framework?

A Domain Specific Language is a programming language with a higher level of abstraction optimized for a specific class of problems. A DSL uses the concepts and rules from the field or domain.

Is Python a DSL?

A Domain Specific Language, or DSL for short, is a language that's specialized to a particular application domain. In other words, it's a programming language that's used for a more specific application or use case than a general-purpose language like Python.

Is SQL a DSL?

We also learned that a Domain Specific Language (DSL) is a specialized programming language that's used for a single purpose. DSLs include: SQL (used for database queries and data manipulation) HTML (web application development)

Is HTML a DSL?

A good example of a DSL is HTML. It is a language for the web application domain. It can't be used for, say, number crunching, but it is clear how widely used HTML is on the web.


1 Answers

Good question. This is the simplest explanation I see:

A DSL can have its own concrete syntax. A framework cannot have its own syntax since it is used in the same language in which it was created. Domain Specific Languages versus Frameworks

For example: HTML is a DSL, whereas directives in the AngularJS framework are written in HTML syntax so do not constitute a separate language.

like image 155
Sridhar Sarnobat Avatar answered Sep 17 '22 19:09

Sridhar Sarnobat