. .

st4u

ST 4U 269: Creating a Web Service in VA Smalltalk

August 10, 2012 11:08:56.368

Today's Smalltalk 4 You starts creating a simple web service in VA Smalltalk. Before you get this far, you'll need to load the required support. If you have trouble viewing it here in the browser, you can also navigate directly to YouTube. To watch now, click on the image below:

WS*.

If you have trouble viewing that directly, you can click here to download the video directly. If you need the video in a Windows Media format, then download that here.

You can also watch it on YouTube:


Today we'll start setting up a Web Service for a simple application. To get started, here's the simple application: a counter application with one variable, and two methods that we want to advertise. If you need to see what code to load first (the basic VA support code for all of this), then watch this screencast first.

WS* Support

Notice that the methods we want to advertise are in the @WS-API category. That's important; the VA tools that generate the XML look for methods in that category. The next thing to note is the following lines in your ini file (abt.ini if you have not changed the name of your image):

ini

The XML stanza in that file tells you where VA will drop (and where it will look for) any XML files used by the Web Services system. To create the XML files we need, use this:


"Generate XML"
SstWSXmlGeneration  forClass: Counter

There are other variations on that where you can specify other options; we'll leave that aside for now. Once you execute that, look in the directory specified in your ini file:

XML

We'll look at those files in detail next time, and go over the changes you'll want to make to the boilerplate before you use them.

Need more help? There's a screencast for other topics like this which you may want to watch. Questions? Try the "Chat with James" Google gadget over in the sidebar.

Technorati Tags: , ,

Enclosures:
[st4u269-iPhone.m4v ( Size: 4906908 )]

posted by James Robertson

 Share Tweet This