Hi,
I'm trying to communicate with a Linux-based device that sits on the
local network from multiple Macs (also on the local network).
Documentation for the Linux device claims that it provides an XML-RPC
server and that it responds to SOAP requests. However, XML-RPC and
SOAP AppleScripts result in repeated failure. "do shell script curl",
however, works every time. I suspect that the device doesn't actually
respond to tree-based XML with tags, but it does respond when the full
message (which consists of a method name and 0-5 parameters, depending
on the method) are all posted in a single string.
Given this, I'm suspecting it responds to HTTP Posts, rather than XML-
RPC or SOAP requests. I've seen references to a Cocoa wrapper for
curl, but they're from 2002. Looking through Apple's documentation
for a more up-to-date method for sending HTTP Posts, it appears that I
could make HTTP Posts from CFNetwork (CFHTTPMessage with a POST
method) or through NSURLRequest. The strings I'll be sending will be
less than 50 characters long. The device will also be sending
response strings of approximately the same length that will need to be
parsed in the Cocoa app. Again, it doesn't appear that the responses
are XML (they're all in a single string, no tags).
Messaging to the device will be driven by button presses in the UI. A
single button press could invoke up to 5 or 6 messages at once, but
the button presses will likely be infrequent. A single instance of
the app could be running on multiple machines, with each machine
making requests to the device simultaneously.
Given this information, what would be the most efficient and robust
method for sending HTTP Posts, CF Network, NSURLRequest or something
completely different?
Thanks in advance.
Brad
_______________________________________________
Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com
This email sent to [EMAIL PROTECTED]