Ernest Micklei's Blog

things I create and problems I solve, to remember and share

Using renderSnake to build the presentation layer in Spring-MVC

renderSnake is a open-source library for creating components that produce HTML using only Java. By defining Java classes for HTML components and pages you can exploit all the language features (e.g. inheritance, composition, type-checking) and IDE tooling (e.g. refactoring, unit-testing, references search, debugging,…). In addition, renderSnake is designed to produce compact HTML in an memory efficient way. The "V" in MVC Basically, renderSnake is responsible for the presentation layer of a Web application.

Soek.goodies.st improved

The site soek.goodies.st gives access to the sources of open-source Smalltalk libraries and frameworks. A big advantage to developers is that they can explore Smalltalk classes without having to successfully load them into one of the Smalltalk dialect platforms. Recently, I have changed much of the Smalltalk generator and HTML/Javascript generated code. Formerly, all Smalltalk source was highlighted using a client-side Javascript library. This resulted in long page loading times because it had to iterate through all DOM elements and replace the HTML content by a post-processing (using regex) result.

Melissa for VA Smalltalk

Melissa is a simple tool that can help in building development and runtime images in a continous integration environment. It is being used extensively to create daily builds for Smalltalk images. This post describes the steps to use Melissa for VA Smalltalk 8+. The intended way to use Melissa is to start with a clean VA image, load the Melissa config app and save it as melissa.im. In order to tell Melissa what to build, you need to start that image passing the command line parameter “-melissa buildscript.

Google API access from Smalltalk using JNIPort

JNIPort for VisualWorks provides a way to use Java and its huge number of available libraries directly from Smalltalk. For example, to access the Google Spreadsheets APIs and Tools, you need to download the Java client libraries and all its dependencies. The paths to there Jars must be known to the JVM and can be set through JNIPort. For easy deployment, I put together a single jar using an Ant build script such that the Runtime settings could be:

JQTouch library support for Seaside

One way to build applications for the iPhone is to create a Web application that tries to look and behave like a native one. Currently, many Javascript libraries are being developed that try to accomplish just that. One of the big reasons for choosing this route is that developing such applications is so much easier compared to the Apple-way (learn Objective-C, build and test on the local emulator and try to get it accepted by AppleStore).

soek.goodies.st - exploring open-source Smalltalk libraries

Soek is a Smalltalk application that provides a different way to navigate through documentation and source code of a Smalltalk library. Instead of the classic multi-list browser view in an image, Soek offers a flat view on all methods and classes and is build using the Seaside Web framework. missing image /2009/11/screen-shot-2009-11-13-at-6-33-24-pm.png I discovered this way of publishing a framework when I worked with Rails and did most of my searches on Railsbrain.

Making a package visible to WebVelocity

If you want an existing package to register as a WebVelocity one and as a result make it visible to the browser page, you can evaluate this script: (Store.Registry packageNamed: 'Your-Package-Name') propertyAt: #application put: true; propertyAt: #namespace put: 'Your-Namespace'; propertyAt: #velocityThemeName put: 'Default'. which I found when looking for the newApplication functionality in the image.

HypertextLogger for server application logs

Logging can be very helpful in analyzing the (faulty) behavior of a server application in response to client requests. HypertextLogger is a simple component that produces HTML in response to logging instructions. Its main purpose it to provide a better readable log file. By choosing you favorite CSS, you can highlight what is important and leave other information unfocused (timestamps). missing image /2009/06/hypertextlogger.png Upon creation of the logger, it produces a new .

Getting started with Glare-DataServices

Glare-DataServices is a framework for building Flex Remoting services in VisualWorks Smalltalk. In this post, I will guide you through the steps for creating a small application that demonstrates the use of the framework. Install the bundle First, you have to connect to the Cincom Public Store Repository. Then open the list of Published Items and load the bundle GlareDataServices. It includes the Glare bundle and Glare-DataServices packages. The required dependencies AT MetaNumerics and Opentalk are automatically loaded if not present.

VAStGoodies.com services API

To make the VAStGoodies client work right from the VA image, I needed a service API in addition to the Seaside application that is running on VAStGoodies.com. Requirements for that service include “get all available configuration map names” and “get a download url for a particular version of a configuration map”. Instead of implementing a full-blown end-to-end SOAP based Webservice, I decided to implement a much leaner RPC-style design that simply returns Smalltalk expressions.