Jul 14

I recently had a need to call a SOAP service via applescript. Google to the rescue and I found several examples on the web. At first it appeared that there was an older technique which used sort of an Applescript to Perl bridge to call the service. Later it seems that there is a “call soap” routine built into the System framework on OS X and callable directly from applescript. This makes for some pretty simple looking applescript. I am struggling with issues however calling web services that where built on .NET frameworks. Something seems to be missing in terms of passing parameters to the web service.

Ok I put a log into the web service to watch what comes accross the wire, there’s nothing like sniffing your own code :). The service was expecting this:

<?xml version="1.0" encoding="utf-8"?>
   <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
   xmlns:xsd="http://www.w3.org/2001/XMLSchema"
   xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <GetRecordERD xmlns="http://bla.bla.bla/DUWSPSERD">
      <STRRECORD>string</STRRECORD>
    </GetRecordERD>
  </soap:Body>
</soap:Envelope>

And applescript was actually sending something like this:

<?xml version="1.0" encoding="UTF-8"?>
  <SOAP-ENV:Envelope
    xmlns:xsd="http://www.w3.org/1999/XMLSchema"
    xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
    SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
    xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
    xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/">
      <SOAP-ENV:Body>
        <m:GetRecordERD xmlns:m="http://bla.bla.bla/DUWSPSERD">
          <STRRECORD xsi:type="xsd:string">JOB</STRRECORD>
        </m:GetRecordERD>
      </SOAP-ENV:Body>
    </SOAP-ENV:Envelope>

Time for some more research.

Continue reading »

written by Richard Ashwell \\ tags: , ,

Jul 06

I extended a superclass of StyledText to Add support for undo and redo operations.

First lets import a few things we are going to need:

   import java.util.LinkedList;
   import java.util.List;

   import org.eclipse.swt.custom.ExtendedModifyEvent;
   import org.eclipse.swt.custom.ExtendedModifyListener;
   import org.eclipse.swt.custom.StyledText;
   import org.eclipse.swt.widgets.Composite;

The LinkedList and List java.util routines are needed because our undo and redo additions are going to need a place to store on a couple of stacks the data to undo or redo. Lets start by creating a class “MyStyledText” that extends the SWT StyledText class.

public class MyStyledText extends StyledText {

	private class undoRedoItem {
		public Character Action;
		public int Location;
		public String Data;

		public undoRedoItem(Character Action,
		           int Location, String Data) {
			this.Action = Action;
			this.Location = Location;
			this.Data = Data;
		}
	}

Continue reading »

written by Richard Ashwell \\ tags: , ,

Jul 05

I have removed Joomla and gone back to wordpress. It allows me to integrate [Textmate](http://macromates.com/ “TextMate — The Missing Editor for Mac OS X”) with my blog and makes
for a very interesting easy to use system for posting blog entries about the software I am writing.

written by Richard Ashwell

Apr 27

While watching the recent growth (Market Watch) and popularity in the Nth rise of Apple products, is it any wonder that A-List Bloggers focus much of their efforts on the silver backed, candy sweet, tech goodness that comes out of Cupertino, CA? Reviews, comments, dialogs in and around these hot items is pretty much standard fare.  There is even accusations of Apple bias in the tech reporting.

The only bias I see is perhaps towards the “what’s hot”, but isn’t that what technology trend reporting is about?

In addition, an admittedly anecdotal observation is that almost all of the top tech bloggers mainstream and use as their own technology Apple products at least in terms of the computers they use day to day.

Let me pause to define my version of “anecdotal”. My observations are of the tech blogging greats, I’ll drop names in my top 5 just to give you an idea of my warped opinions, Cali Lewis @ Geekbrief.tv , Veronica Belmont @ Tekzilla , and AmberMac @ commandN .

What you want to question my picks? Well get in line, I already argue with the wife over it, frankly I like watching gorgeous, brilliant, and tech smart, women talk about technology. I also watch Dvorak @ Cranky Geeks and Leo @ TWIT as well, and while they might be in the top 10 or even 5 I’ll leave it the reader here to guess my top 3.

While these bloggers avoid the “Apple Bias” as good little objective reporters, I see them either using, talking about, or thriving around, Apple hardware.

What? I must be crazy, how about all of the tech bloggers that love Windows, Linux, etc? Am I even implying that any sort of volume of them also prefer OS X and Apple?

Well I am posting an opinion here, but I just finished loading Ubuntu 8.04 in a VM last night and while there where some hiccups it occurred to me: On a Singular Device (Mac Book Pro): I can run all mainstream OS’s, applications, etc.

If I where to try this on any other hardware without ugly hacks I would be able to do almost the same with the exception of OS X and OS X applications. Well all preferences aside, my version of going green is based on the, “lack of it”, in terms of a budget the wife lets me spend on “toys”. Apple hardware costs more, but it simply does more. Is this a function of Apple’s stranglehold on their OS? Sure. Do I blame them? No. It seems like pretty profitable business sense to me.

You can argue about the creative side of artists, writers, etc and how Apple hardware and software caters too the more creative nature of tech lovers. But the equivalents tend to exists in the PC world as well, so I reject that argument, however I can still simply do more with the Mac than I can a PC.

Continue reading »

written by Richard Ashwell