![]() |
#1
|
|||
|
|||
![]() Hi,
We're investigating ability to migrate our software to Synthesis SyncML server (now we use Nexthaus). We're planning to implement database plug-in for our existing database structure. Current version of SDK covers all our needs except by one - it's really critical for us to have an ability to extract server uri from client in our database plug-in, i.e. making authentication we should use login, password and specified server uri. And the question is - is it possible to get client's server uri at database plug-in? |
#2
|
||||
|
||||
![]() Quote:
For example: Code:
<logininitscript> string user_and_uri; // make string of the form "user@http://my.sync.server/sync" user_and_uri = AUTHUSER() + "@" + LOCALURI(); // set this as user name to be passed to login routine SETUSERNAME(user_and_uri); </logininitscript> The mechanism used for this is the same as for settings in the new Client SDK - a tree with named "keys" and "values" (similar to Windows registry). Plugins can query and set sync session variables this way. BTW: The same mechanism will also get available in 3.1 for the database access routines - instead of passing content data in the text-based "name:value" list format, developers can choose to access fields one using callback routines to access them as "values" from an "item key". The value accessors have useful transformations built-in (charsets, timestamp scales, integers etc.) helping to get and put data directly in the format the plugin needs.
__________________
Lukas Zeller, plan44.ch |
#3
|
|||
|
|||
![]() Thank you very much for this irrefragable answer!
|
![]() |
Thread Tools | |
Display Modes | |
|
|