David Palmer

consultant, technical architect.

XMPP/Jabber: blinder.dave@gmail.com

AIM: b1inder

Posts written by David Palmer

November 18

Java Becoming a Functional Programming Language?

There is a formal proposal to introduce closures to the Java programming language. For those of us who have been in the Java world for a while (10+ years for yours truly) this could really open up a lot of interesting possibilities to express solutions to really complicated problems, the way the functional programmers have been doing things, which can mean, less and cleaner code.

For example, anonymous functions, and first-class functions would be introduced as well as incorporating some of the more interesting features of languages like ruby (think blocks and yield) and scala will make for more concise code and, as an example, provide the developer with the ability to write your own control structures.

From the (current) specification:

Modern programming languages provide a mixture of primitives for composing programs. Most notably Scheme, Smaltalk, Ruby, and Scala have direct language support for parameterized delayed-execution blocks of code, variously called lambda, anonymous functions, or closures. These provide a natural way to express some kinds of abstractions that are currently quite awkward to express in Java. For programming in the small, anonymous functions allow one to abstract an algorithm over a piece of code; that is, they allow one to more easily extract the common parts of two almost-identical pieces of code. For programming in the large, anonymous functions support APIs that express an algorithm abstracted over some computational aspect of the algorithm.”

This is pretty exciting for Java, and as a fan of functional programming, this is a real bonus for the Java platform.

March 17

Inversion of Control/Dependency Injection with PHP

Over the last several years the design paradigm of inversion of control/dependency injection has gone from an interesting design exercise to major league time savings and making complex things less complex (and at the same when done wrong, making complex things even more complex.) Developers in the Java world have enjoyed Spring, the de facto library that makes all of the promises of IoC/DI possible and rather straight forward.

However, with the continual maturity of OOP in PHP the concept of inversion of control/dependency injection has been slow to catch on. There have been attempts at providing IoC/DI functionality to PHP but many have just withered away and died. One such framework that may show some significant promise is Flow3, produced by the community of developers who have been slaving away at Typo3, a long running, incredibly feature-rich open source enterprise CMS. However, to date, Flow3 is very much like vaporware. Oh sure you can download it, but documentation is scarce to non existent and its missing one thing that I believe would slow its adoption, its similarity to Spring.

Spring got it right, by my estimation. The notion of wiring an application together via an XML file is spot on and truly enables developers to “write to interfaces” without ever having to concern themselves with the concrete implementations. The better code design, testing and time savings become very apparent once fully in practice. This shouldn’t just be something that Java (or .NET) developers enjoy. PHP is a major piece of technology, so with that said, I’ve taken the time and out of a graduate school project I recently finished devised a rudimentary IoC/DI container written in PHP. Currently it only supports a limited set of features, but uses the same concepts as used by Spring. Enter, phpBoing, which right now is quite simple and is just an academic curiosity, but with some work it could grow into a full fledged mature application development framework. No it is NOT meant to be another MVC framework. There are too many of those already, in fact, this system simply provides an object registry that lives in memory, defined through an “application context” XML where you can “inject” object dependencies via XML syntax, thus enabling you to “wire” your PHP applications together in XML (as opposed to doing so in actual PHP code).

In invite you to take a look, stab around at it, and if so inclined, contribute code.

September 28

Appcelerator: RIA Made (pretty) Easy

We (that is, “we” developers) all have our favorite secret weapons when it comes to making the complicated (read: RIA) applications seem easy, stuff like JQuery, YUI, Flex, mootools (hahaha, funny right?) Flash, ZK, Openlazlo, etc. But allow me to introduce a new discovery, Appcelerator.

What is it? Well, its not just a collection of javascripts and CSS snippets, its more like a fully integrated development platform with its own (very ant-like) build system and (perl-like) updating system. Appcelerator, an open source (using the more friendly, flexible and down-to-earth license of Apache) system provides developers (not so much designers) with tools to make RIA applications less of a chore.

(more…)

July 30

Say Good Bye To Database Schemas

Fast on the heels of Craig’s last post, I bring you a new tool which is currently undergoing Apache incubation, which has the potential to radically change how you think about databases. Google kick- started this by publishing a paper on their “BigTable” system, and just a short while back Facebook released Cassandra out into Google Code, but along comes CouchDB.

(more…)

April 29

The Main Street Web?

Interesting article on ReadWriteWeb today, The Main Street Web.

Its an interesting spin in how the Web/Internet/Digital-whatever will save us from a recession. A lot of interesting topics covered, and perhaps a bit on the (foolishly?) optimistic side, but at the same time, the piece actually makes a considerable amount of sense. Especially for outfits like Molecular who make all that stuff (mentioned in this piece) possible.

Read the comments as well, some good discussion (so far) happening.

Technorati Profile

Browse posts by month

Browse by author

We're always looking for rockstars

Come take a look at careers with Molecular