Hello I am trying ti implement my own NumericScaler but am confused by the GetScaledValueList method. It signature looks like this
public virtual void GetScaledValueList(IList<double> unscaledValues, int startIndex, int count, ScalerParams p);
I do not understand why this returns void, where am my supposed to put the scaled values?
Thanks.
I think we must have just missed that one. GetScaledValueList is used in performance critical scenarios, but not so much Unscaled, so it was tuned for high performance while the other method was left untouched. Sorry for the confusion.
Ok that makes sense but then the API is inconsistent because GetUnscaledValueList returns a IList<double> which i assume is where i put the result. Why do it differently here?
I am trying to implement this method myself and I do not need the scaled values, Whatever called me needs them (otherwise why would they call the method) So i calculate the scalled values, but what do I do with them? How can i give them back to the caller?
You are supposed to scale the values in-place in the array that is passed in. It is done this way for performance's sake.
Hello John,
Thank you for your post!
The GetScaledValueList method is used by the XamDataChart's Axes, and it takes that IList<double> unscaledValues and converts it into scaled values. So, while this method does not really return anything, if you would like to retrieve the scaled values, I would recommend that you place the list of unscaled values into this method, and set another list of yours to the scaled value list that results from that method.
Please let me know if you have any other questions or concerns on this matter.
Sincerely,AndrewAssociate DeveloperInfragistics Inc.www.infragistics.com/support