[Authentication] Solution to prompting and async operations

Stef Walter stef-list at memberwebs.com
Mon Nov 2 14:24:42 PST 2009


Michael Leupold wrote:
>> I've finally come up with a solution the whole set of problems to do
>> with prompting and long running or asynchronous operations. I believe
>> this covers every requirement. This wasn't an easy task.
>>
>>  * Operations that may require prompting can optionally return
>>    the object path to a 'prompt object'.
>>  * The Prompt() method of the prompt object will then be called
>>    by the client application.
>>  * Prompts objects can be dismissed with the Dismiss() method
>>    of the prompt objects.
>>  * Prompt objects have a 'Completed' signal which is fired when
>>    the prompt and operation completes. A result can be returned.
> 
> Great idea. I think this design will work out nicely.

Thanks for taking a look. Much appreciated!

> Just to get clear. What do you mean by "will optionally return"? Does this 
> mean that the methods will return a variant containing either a prompt object 
> or a "real" value?

The methods have two 'out' values. A good example is the 'Unlock' method
has two out values: 'unlocked' and 'prompt'. 'unlocked' is an array of
object paths that were required no prompt to unlock. 'prompt' is a
prompt object that requires action to complete the operation and unlock
the remainder of the object paths.

Cheers,

Stef



More information about the Authentication mailing list