blog
HOME · CREATIVE · WEB · TECH · BLOG

Wednesday, October 8th, 2008

4D for Flex (v11)

Tim Kaufman giving a talk about 4D for Flex at 4D Summit 2008[These are notes from 4D Summit 2008]

Presenter: Tim Kaufman, 4D Inc.

One of the problems with Flash was that the development environment felt alien to programmers. Flex fixes that - it provides an IDE which feels natural to developers, but compiles down to .swf files. Flash Player 9 is required to run Flex because it uses ActionScript 3.

The upside to Flash being proprietary is that runs in the Flash player which works the same across all platforms. Technically it's now an open standard...

Flex Builder is a full-featured IDE based on/compatible with Eclipse. It has a hybrid language of MXML and ActionScript. MXML looks sorta like HTML or XML, ActionScript 3 is a cousin of Javascript (both are versions of ECMAScript) though it has strongly typed variables.

It has VBoxes which are similar in concept to divs in HTML and one of the basic building blocks of Flex.

Flex gives you a lot of powerful features like sliders, drag and drop, etc...

Flex is completely object oriented (not just object based like Javascript). ActionScript has classes with properties and methods, for example. It's also asynchronous. Even the events are objects.

Data binding reduces the coding. So a destination object can listen for changes in a source object.

In terms of connecting to 4D. You can connect via web services. Flex is used more for presentation and less for business logic. Now with Flex for 4D you have a direct SQL connection and it brings it back into a dataset you can manipulate. This moves the business logic to Flex and out of 4D.

Using 4D for Flex to connect to 4D Server requires a fair amount (but not a huge amount) of object oriented programming - it's not a design/GUI type of thing.

4D for Flex is just a data provider, so you can use a number of different ways to handle the data once it's been returned.

Flex has a built in data grid which you can bind the data to. 4D for Flex has a data grid which extends the Flex data grid and gives you more functionality.

Once you get the hang of it he finds it incredibly productive and powerful - especially for prototyping. He prefers it over Ajax. An audience member said Flex thinks more like 4D than Ajax. ActionScript is the ideal intermediary between Javascript and Java.

It can't be run on mobile devices.

In the future they're planning on using HTTPS to do authentication, then they get a ticket, then pass the ticket in the SQL call.

Tags: ,
Categories: 4D, Flex

Next Post: SVG in 4D v11.3 »
Previous Post: « 4D v11 Server in Depth

Leave a Reply

HOME · CREATIVE · WEB · TECH · BLOG