2017년 1월 7일 토요일

what computer programming language is the app builder?


what computer programming language is the app builder?

--
There are lots of programming languages involved in App Inventor. MIT App Inventor 2 blocks code is a new programming language that doesn't have a name, but you could think of it as the "App Inventor Language". We're developing a textual version of this language called TAIL = Textual App Inventor Language. The blocks editor is top of the Blockly blocks language framework so that it runs in a web browser. (In the first version of App Inventor, the blocks editor was implemented in Java on top of the OpenBlocks blocks framework.) The Designer window is implemented in Java using the Google Web Toolkit (GWT), which is translated to JavaScript so that it, too, runs in the browser. When you execute App Inventor blocks code in live development mode on an Android device, the blocks code is translated into Young Android Intermediate Language (YAIL), a Scheme-like language with parenthesized syntax. YAIL code is interpreted on the device by a YAIL interpreter in the MIT AI2 Companion. The YAIL interpreter is written in Kawa, a version of Scheme implemented in Java. The interpreter loads Android libraries so that it has access to all the device features. When you package an App Inventor app to make a .apk file, the YAIL-interpreter-with-YAIL-program is compiled to Java bytecodes and then to Dalvik executable code (DEX). 

--
I'm not sure if you got the question correctly.
I wasn't asking which programming language is use to build the MIT app.

in the app builder. If I click on block, and I drag and drop those blocks to form block codes.
What programming language is the output?
What programming language structure is it following?
C ? or Java?

--
Also, is it possible for me to view my source code?
the source code of my program will be in Javascript? or C?

--
This is hard for many users to understand, but the blocks code you seen on your screen *is* the source code of your language. It describes the syntax tree of your App Inventor program in the same way that traditional text programs describe the syntax trees of their languages. 

When you save a .aia file (which is really just a .zip file), the blocks are saved in an XML textual format that describes exactly the same nested tree structure you see on your screen with the blocks. So if you're more comfortable with thinking of text as source code, this XML format is the source code of App Inventor programs. 

When your blocks program is executed on your phone, it is *not* translated to a traditional language like Java/C/JavaScript etc. It is translated to Scheme-like YAIL code and executed in an interpreter on the phone. Ultimately all Android apps are running a version of Java, but App Inventor code is never converted to Java in live development mode. Rather, it's YAIL code that runs in an interpreter implemented on top of Java. So there's no way to "see" the Java code associated with your app. 

Dave Wolber at USF has a Java Bridge that translates App Inventor programs to Android SKD projects in Java: https://code.google.com/p/appinventor-java-translation. However, this is not how App Inventor works; it's just a way for you to first prototype Android projects in App Inventor. 

--

댓글 없음:

댓글 쓰기