Can the FFI be used with methods that return type NSArray?

LiveCode Builder is a language for extending LiveCode's capabilities, creating new object types as Widgets, and libraries that access lower-level APIs in OSes, applications, and DLLs.

Moderators: LCMark, LCfraser

Post Reply
Simon Knight
Posts: 934
Joined: Wed Nov 04, 2009 11:41 am

Can the FFI be used with methods that return type NSArray?

Post by Simon Knight »

I would like to wrap foreign handlers that return large amounts of data in an array. I can not find any documentation so I just want to confirm that it is not possible.
best wishes
Skids
trevordevore
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 1005
Joined: Sat Apr 08, 2006 3:06 pm
Contact:

Re: Can the FFI be used with methods that return type NSArray?

Post by trevordevore »

Yes, they can. Here are examples from one of my GitHub repos:

https://github.com/trevordevore/lc-maco ... _q=nsarray
Trevor DeVore
ScreenSteps - https://www.screensteps.com

LiveCode Repos - https://github.com/search?q=user%3Atrevordevore+topic:livecode
LiveCode Builder Repos - https://github.com/search?q=user%3Atrevordevore+topic:livecode-builder
Simon Knight
Posts: 934
Joined: Wed Nov 04, 2009 11:41 am

Re: Can the FFI be used with methods that return type NSArray?

Post by Simon Knight »

Thanks again Trevor, I can see that programming using foreign handlers requires a different way of thinking. It feels a little remote as if I'm wearing thick rubber gloves while playing cards.
best wishes
Skids
trevordevore
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 1005
Joined: Sat Apr 08, 2006 3:06 pm
Contact:

Re: Can the FFI be used with methods that return type NSArray?

Post by trevordevore »

That is an apt description :-)
Trevor DeVore
ScreenSteps - https://www.screensteps.com

LiveCode Repos - https://github.com/search?q=user%3Atrevordevore+topic:livecode
LiveCode Builder Repos - https://github.com/search?q=user%3Atrevordevore+topic:livecode-builder
Post Reply