DSLs in Boo: Domain Specific Languages in .NET by Ayende Rahien

By Ayende Rahien

A general-purpose language like C# is designed to deal with all programming projects. in contrast, the constitution and syntax of a Domain-Specific Language are designed to compare a selected functions sector. A DSL is designed for clarity and straightforward programming of repeating difficulties. utilizing the leading edge Boo language, it's a breeze to create a DSL to your software area that works on .NET and doesn't sacrifice performance.

DSLs in Boo indicates you ways to layout, expand, and evolve DSLs for .NET by way of concentrating on ways and styles. You discover ways to outline an app in phrases that fit the area, and to take advantage of Boo to construct DSLs that generate effective executables. and also you won't take care of the awkward XML-laden syntax many DSLs require. The publication concentrates on writing inner (textual) DSLs that let effortless extensibility of the appliance and framework. And when you don't be aware of Boo, don't worry-you'll study the following all of the concepts you need.

Show description

Read Online or Download DSLs in Boo: Domain Specific Languages in .NET PDF

Similar .net books

ASP.NET 2.0 Illustrated

This publication is an outstanding commence for somebody new to ASP. web, in addition to an entire advisor to the hot positive aspects of model 2. zero for programmers accustomed to an previous model. the start chapters aspect strategies utilizing a hypothetical corporation, studying the myriad kinds of requests and events usually asked via consumers.

Essential ASP.NET 2.0

"No one is aware ASP. web like Fritz Onion. And nobody is aware . web defense like Keith Brown. mix the 2 and what do you get? the main accomplished and enlightening publication on ASP. internet 2. zero industrywide. i am convinced you can find the publication you are conserving used to be worthy each penny. - Aaron Skonnard, member of technical employees and cofounder, Pluralsight"Essential ASP.

Professional DotNetNuke Module Programming

Convinced, there's a few scope for development the following. however it is ridiculous to criticize the writer for no longer making the e-book longer. My cabinets are groaning less than the burden of big laptop books, bloated with info that's on hand in different places.

Instead of padding out his e-book, Mitchel tells you the place to get the data you need.

What Mitchel does offer, that i have not noticeable wherever else (except his site), is an entire therapy of the internet program initiatives (WAP) path to module improvement. WAP vs WSP is a type of silly spiritual wars.

What Mitchel does not say (but most likely should still) is that the choice website initiatives (WSP)route would possibly not get you the place you need to move. He in basic terms observes that "there are how you can create compiled assemblies from WSP tasks yet they're very complicated to complete". yet, when you have a fancy module or suite of modules, you'll easily be not able to bring together them as a WSP. i've got learnt that the difficult way.

His publication is not only the simplest therapy of WAP improvement in DotNetNuke, however the just one. For that by myself it's definitely worth the dollars.

.NET e-Business Architecture

This booklet is written for architects and builders getting ready to layout and construct enterprise-scale e-business functions utilizing Microsoft's visible Studio. internet and . internet Framework. it's going to advisor technical architects and software program builders in the course of the layout and improvement of a fully-featured e-commerce software, the gasTIX on-line ticketing approach, utilizing the .

Additional info for DSLs in Boo: Domain Specific Languages in .NET

Sample text

When I wrote Brail, a templating language using Boo, the whitespace issue was a major issue. I wanted to use the usual HTML formatting, but that messed up the formatting that Boo required. Fortunately, Boo comes with a whitespace-agnostic mode, which you can utilize by flipping a compiler switch. Finish() else: lives-print "${lives} more lives" end The only difference that you’ll notice is the end at the end of the statement. This is because Boo will now use the structure of the code to figure out where control blocks begin and end.

If not, you’ll need to provide a far richer environment in your DSLs. We usually call this type of DSL a business DSL. 2 Business DSLs A business DSL needs to be (at the very least) readable to a businessperson with no background in programming. This type of DSL is mainly expressive in terms of the domain, and it has a lot less emphasis on the programming features that may still exist. It also tends to be more declarative than technical DSLs. The emphasis is placed on the declarative nature of the DSL and on matching it to the way the businesspeople think about the tasks at hand, so the programming features are not necessary in most cases.

Because the syntax flows more naturally, the DSL lets the user express intention more clearly and easily. Suppose you wanted to perform some action when a new message arrives. WhenMessageArrives: print "message arrived" In this instance, it’s just another way to perform event registration, but I’m sure you can see the potential. It allows you to turn method calls into full-fledged keywords. 5 Statement modifiers Statement modifiers are another tool for producing clearer code. By using them, you can turn several statements into a single sentence.

Download PDF sample

Rated 4.13 of 5 – based on 37 votes