David,

> On Jan 10, 2017, at 9:29 PM, David Adams <[email protected]> wrote:

> OB Get type seems to report that they're object arrays, even if you stashed
> something like a longint array. OB GET ARRAY doesn't want to recast them on
> the fly. (I tried putting in a longint array and pulling it out as an
> object array - what 4D tells me it is - and it choked.)

I think you can cast any array type to a text array (including an object 
array), but not much else.

> 
> Am I missing something here? 4D clearly knows the underlying data type of
> arrays stashed in a C_OBJECT, but I'm unclear how to get it out. I've
> bashed on the JSON Stringify command and some other bits I could find, but
> I don't see even an indirect way to figure out the type.

You are not missing anything. If you want a way to properly serialize and 
unserialize all 4D types, the only viable option is to store the type 
information with the value. 

John DeSoi, Ph.D.
**********************************************************************
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[email protected]
**********************************************************************

Reply via email to