Morfik supports three high-level programming language syntaxes: Pascal, Basic and C#. This guide will provide a quick guide to all the supported languages, with emphasis on language features which have been introduced by Morfik in addition to the standard language specification and where we have differed from the specification for some reason.
Why Support Multiple Languages?
Many people have asked why Morfik chose to support multiple languages. Well the answer is simple: we want everyone to be as comfortable as possible when working with Morfik. We believe that many people have shied away from developing web based applications because they can’t take their skills with them; they are required to learn not only new technologies, but new languages.
In creating the technology behind Morfik, it has taken steps to welcome to the world of Web-based application development those millions of developers of desktop applications that haven’t taken the next step to creating Web applications. In actuality, Morfik supports a single programming language, but that language does not have syntax of its own; only a set of semantic rules. On top of these rules, Morfik implements three syntaxes – Pascal, Basic and C# – so that you can use the language syntax of your choice.
Note: It is important that you be aware that supporting the syntax of a language is not the same as supporting that language’s run-time library. Morfik has its own run-time library and it, as well as the Morfik Framework (the class library) is shared by all languages. When you are writing an application in C# in Morfik, you are not writing an application that will run inside the .net Framework. Your application will be compiled in the same manner as a Basic or Pascal application would be, with the same results.
Towards the goal of supporting developers who have extensive programming experience with languages that do not necessarily target Web development, Morfik has taken language support a step further. New features have been added to all languages to support all the possibilities available in the underlying semantic rules of the Morfik programming language. These features have been added with great care to so that they "blend in" well with the language. Why add these features? Why not just presume that each programming language has its specific quirks and that what can be done with a language feature in one is implemented through a class in another?
By making sure that all language syntaxes support all the features available in the underlying Morfik semantic rule set, it can implement a feature that no other programming tool has implemented before. Code written in one language’s syntax can be immediately translated into another language’s syntax. This allows you to take an example which was written in Pascal and, supposing you prefer to read it in Basic, convert the whole project with a few mouse clicks.
The scope of usage of this feature is huge. Developers can download examples done by other people, using other syntaxes than their preferred one and in a minute be reading it in their language of choice. Companies, who have developed a system in language A and in normal personal turnover, lost their specialists in that language, if the project was created with Morfik, can more easily hire replacement personnel.
Independent of which language syntax you have chosen for your usage, as I mentioned, you will work with the same concepts. One of these concepts is the Document. A document is a module created in one of the supported language syntaxes. They go from the most generic, which is actually called module, to very specific ones which represent the Tables, Queries, Forms, Reports and WebMethods which are part of your application. At source level, all of these documents are exactly like the simple module, but the Morfik knows that they are special and treat them differently according to what each one represents.
Other basic concepts which are shared are the basics of Object Oriented Programming which are generally covered by all the supported languages though each has its own specific variations.
Some concepts of the underlying Morfik language were not supported by some languages and were added to them. One example of this is the C# language which were created for a pure object environment and do not support constructs like functions which are not class methods. The Morfik language, however, is a hybrid object-oriented-procedural language as such supports these constructs which were added to the C# language syntax using method-like declaration syntax.
Morfik Languages Guide
This guide covers in detail all the language syntaxes supported by Morfik. It is not intended as the definitive reference in programming with Object Pascal, Basic and C# but as a guide as to how these languages have been implemented by Morfik.
The language guide makes no effort to teach the reader how to program, so basic knowledge of programming is a requirement. Some familiarity with your language of choice is desirable but not required as all the basic language constructs are described for each language. It is written for the developer who is coming to Morfik and wants to know how his language of choice is supported in the product. No Web application development techniques are discussed in this guide; its focus is solely to describe programming languages and the details of their support within Morfik.
Morfik implements several different syntaxes for the Morfik language in order to ease the learning curve of developing web application for developers with previous experience. Morfik Pascal is an implementation of a Pascal language syntax for the Morfik language.
In the following articles a complete overview of the Morfik Pascal language syntax is provided.
- Pascal Overview
- Pascal Data Types and Variables
- Pascal Subroutines and Scope
- Pascal Object Oriented Programming
Morfik implements several different syntaxes for the Morfik language in order to ease the learning curve of developing web application for developers with previous experience. Morfik Basic is an implementation of a Basic language syntax for the Morfik language.
In the following articles a complete overview of the Morfik Basic language syntax is provided.
- Basic Overview
- Basic Data Types and Variables
- Basic Subroutines and Scope
- Basic Object Oriented Programming
Morfik implements several different syntaxes for the Morfik language in order to ease the learning curve of developing web application for developers with previous experience. Morfik C# is an implementation of a C# language syntax for the Morfik language.
In the following articles a complete overview of the Morfik C# language syntax is provided.