ds_Preferences


ds_Preferences (selector; value) <- errorCode
Parameter Type Description
-> prefSelector Integer Value to Get/Set
-> prefValue Long Integer New value
<-   Current value
<- errorCode Long Integer Error Code (0 = no error)


This routine allows the developer get/set preferenecs of the plugin. In version 1.1 there are only 2 possible values for prefSelector

1 Change the frequency's calls to 4D's Scheduler while loading arrays

-1 Get the frequency's calls to 4D's Scheduler while loading arrays.

This selector changes the behavior of 2 routines : ds_GetMethodNames and ds_GetObjectMethodIDs. Because on slow computers and when loading a hunge number of methods, loading arrays could take several seconds. During the loading loop, in version 1.0 of DynamicStructure, the 4D's scheduler was never called. The user could think that his/her computer was freezed. Under 4D Server, other processes did not get a chance to have some CPU time. In version 1.1, by default, the plugin uses internally a call similar to IDLE every 30 times in a loop (for those 2 routines only). This can be changed. Setting this value to 0 => "load arrays with no call to IDLE". In this case, the arrays will be loaded faster, but the plugin will not give hand to the 4D's scheduler. Beyond 0, the more the value is, the less 4D has the hand.