Real Software Forums

The forum for Real Studio and other Real Software products.
[ REAL Software Website | Board Index ]
It is currently Tue Dec 12, 2017 1:17 am
xojo

All times are UTC - 5 hours




Post new topic Reply to topic  [ 1 post ] 
Author Message
 Post subject: App wide instances vs session instances
PostPosted: Fri May 31, 2013 12:28 am 
Offline

Joined: Sat Oct 01, 2005 12:51 am
Posts: 248
Location: Monterrey, Mexico
I am writing an app that uses parse.com as its data back end. I am using a subclass of HTTPSocket.

This class I am creating is supposed to be programmatically instantiated in a web page or web view.

Every time I do a query for instance I create an instance of my parse class engine, and hit a query and set some method addresses in pointers in the subclass to callback a finished method in my webpage.

How do I know if I am running the instance of my class in the server (the server asking parse.com for the data) or the client (where it was instantiated but since HTTPsocket is not a webcontrol subclass I don't know who manages the underlying connections of the class).

I do this to allow my app to instantiate several queries for instance to parse.com at the same time and get notified once the transaction finishes and deliver the payload). I want this to be ran client side so I can have multiple connections to parse.com to get different data. I of course limit the amount if connections that can happen at a time.

Keep in mind that parse.com is a REST API. So every connection once it finishes it disconnects and gets destroyed.

Any clues on how to control that? I am a littlebit puzzled. And sometimes I loose instances of my classes when created via code and is hard to keep the pointers to the parent webpage where the my parse class was programmatically instantiated.

Any clues welcomed!!

_________________
------------------
Do what you can with what you have.
Its often more than enough.


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC - 5 hours


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group