Question

What is an embedded scripting language? What are some advantages it would have over the domain specific language?

"A number of languages have been designed for the purpose of replacing application-specific scripting languages by being embeddable in application programs." -Scripting language (wiki)

Javascript.NET is one such example. It can be used in place of c# for example. However, what constitutes the difference between a scripting language, and an embedded scripting language? Moreover, why would javascript be more desirable than C# - or any other domain specific language?

Was it helpful?

Solution

For your core business, you probably should not use an embedded language, but there are other upsides of using an embedded language. Most importantly, in my experience, it is beneficial to have an easy-to-use language on which other users can build against your system. While theoretically it is possible to build against your system with proper definition of interfaces, it is a lot more user-friendly to let inexperienced people play with JavaScript and Lua, instead of having to set-up an entire environment to deploy in .NET.

Of course, it is easy to hot-swap embedded languages and it can speed up your testing considerably; it is also possible to see your changes immediately without reloading your application, because you just reload a small virtual machine for that embedded language.

I personally employed this to allow people to write assisting scripts against a game.

OTHER TIPS

An embedded scripting language would be a scripting language (or more specifically an interpreter for such a language) that can be embedded into applications. Thus, the interpreter has an API that can be used to integrate it into the application, allowing scripts to control all or parts of the application.

the advantage is that application developers only have to provide the interfacing with the language; they don't have to implement the actual language. This allows more complex and feature-rich languages to be used, since there's no development time (from the application developer point of view).

For users, it means they know the pros and cons, the quirks and benefits of the scripting language, provided we are talking about a commonly used one.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top