• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: SOAP Parameters
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: SOAP Parameters


  • Subject: Re: SOAP Parameters
  • From: Paul Berkowitz <email@hidden>
  • Date: Tue, 24 Jan 2006 11:22:09 -0800
  • Thread-topic: SOAP Parameters

On 1/24/06 1:08 AM, "Christian Mittendorf" <email@hidden>
wrote:

>
>> As far as I know, a regular AppleScript integer _is_ a long. Or
>> almost: it
>> stops just a couple factors of 2 short of the standard limit:
>> [...]
>> AppleScript's real is the same as Double;  you can use 'small real'
>> for
>> Single. i.e. float.
>
> Yes, that's wright. However, the SOAP Services that I want to use via AS
> have the following description:
>
>    <wsdl:message name='setService0In'>
>      <wsdl:part name='id' type='xsd:long' />
>      <wsdl:part name='service' type='xsd:string' />
>    </wsdl:message>
>
> If I generate an interface from the WSDL in AS I would call the
> service like this:
>
> on setService(in_id, in_service)
> tell application "http://foo.com/soap/fooManager";
> set mn to "setService"
> set sa to "setService"
> set mns to "http://tempuri.org/foo.fooManager";
> set params to {}
> set paramOrder to {}
> set params to params & {id:(in_id as integer)}
> set paramOrder to paramOrder & "id"
> set params to params & {service:(in_service as string)}
> set paramOrder to paramOrder & "service"
> set params to params & {record order:paramOrder}
> return call soap {method name:mn, parameters:params, SOAPAction:sa,
> method namespace uri:mns}
> end tell
> end setService
>
> This call will result in an Exception, because the axis soap server
> on the other side requires in_id to be encoded as integer and not as
> long. But AS won't let me use "in_id as long", because AS doesn't
> know about a type "long"...

But since any AppleScript integer will also fit the terms of what other
languages consider a long, any number you coerce 'as integer' - if it works
- ought be be accepted at the other end as a long, I would have thought. Are
you quite sure that the error is not occurring when you try to coerce the
in_id to integer? Perhaps the in_id is a string that won't coerce to integer
(at least not without some help)? Or how about 'as unsigned integer'?
(Although longs can be signed, this will increase the range for positive
numbers.)

--
Paul Berkowitz


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: SOAP Parameters
      • From: Matt Deatherage <email@hidden>
References: 
 >Re: SOAP Parameters (From: Christian Mittendorf <email@hidden>)

  • Prev by Date: Re: finding files by name (you know, the old-fashioned way...)
  • Next by Date: Re: finding files by name (you know, the old-fashioned way...)
  • Previous by thread: Re: SOAP Parameters
  • Next by thread: Re: SOAP Parameters
  • Index(es):
    • Date
    • Thread