Hi Chanaka Thank you for your reply and I am sorry if my earlier mail was confusing.
Currently the compare operator consists of greater than and less than functions. Usually these operators are used for numeric comparisons. But when two Strings are given for greater than or less than function, it is also compared. In native javascript this kind of comparison is doable which is the underlining language used for the Data Mapper. My concern is that even-though such a comparison is doable in javascript, should we ship the data mapper in the exact same manner? Since we are providing an enhanced mechanism for data conversion and mapping and not a graphical UI for javascript through Data Mapper, shouldn't we add validations where appropriate in scenarios similar to above to maintain our own standard for the WSO2 Data Mapper? Thank You Erandi On Thu, Jul 21, 2016 at 8:31 PM, Chanaka Fernando <[email protected]> wrote: > Hi Erandi, > > Appreciate your feedback on improving the DM. The existing compare > operator checks for the equality (==) of the values passed into the > operator. If you passed in 2 String values, it will check the equality of > strings. If it is integer values, it will check for the equality of integer > values. > > Are you talking about adding ">" (greater than) and "<" (less than) as new > operators? > > Basically, you can do this kind of operations with a custom function. > > Please correct me If I understood your suggestion in a different manner. > > On Thu, Jul 21, 2016 at 4:51 PM, Chathurika De Silva <[email protected] > > wrote: > >> Hi >> >> Currently the data mapper compares (compare operator) String values for > >> (greater than), < (less than). The native javascript too does the same >> which is the underlining engine of data mapper. >> >> Since we are providing data mapper to the user to enhance conversion and >> mapping, rather than a graphical UI for javascript itself, it would be >> better if we should add UI (ESB tooling) validations for similar scenarios >> as $subject. >> >> WDYT??? >> >> >> Best Regards >> Erandi >> >> -- >> *Chathurika Erandi* >> Senior Software Engineer, >> WSO2 Inc. >> >> *E-mail:* [email protected] >> *Mobile: *+94714 328 612 >> *Blog*: chathurikaerandi.blogspot.com >> > > > > -- > Thank you and Best Regards, > Chanaka Fernando > Senior Technical Lead > m: +94 773337238 > https://wso2.com <https://wso2.com/signature> > > > > > > > -- *Chathurika Erandi* Senior Software Engineer, WSO2 Inc. *E-mail:* [email protected] *Mobile: *+94714 328 612 *Blog*: chathurikaerandi.blogspot.com
_______________________________________________ Dev mailing list [email protected] http://wso2.org/cgi-bin/mailman/listinfo/dev
