Reporter: dmorissette Date: 2007/08/30 - 17:43 Trac URL:http://trac.osgeo.org/mapserver/ticket/2279
We need a msGetVersionInt() function that returns the current MapServer version number in an integer format easy to use for version checks. This is necessary for MapScript code that has to deal with changes between releases of MapServer. Since MapServer 5.0 introduced a good round of changes and we expect there may be more changes in 5.2 related to rendering, now would be a good time to introduce this function.
I propose that we create a msGetVersionInt() function in the mapserver core that returns the current version number (x.y.z) as an integer (x_0x10000 + y_0x100 + z). For instance, v5.0.0 would be 0x050000 and v4.10.3 would have been 0x040a03.
The function would be exposed to MapScript via SWIG.
It would be called ms_GetVersionInt() in PHP MapScript for consistency with the existing ms_GetVersion() function name.
Author: dmorissette Date: 2007/08/30 - 21:12
Both Steve and Tom made comments about the use of hex notation for the verison number. they have convinced me and I have decided to revert to using real decimals instead of hex notation.
The function now returns version number (x.y.z) as an integer (x_10000 + y_100 + z).
For instance, v5.0.0 would be 50000 and v4.10.3 would have been 41003.
Activity
mapserver-bot commented on Apr 3, 2012
Author: dmorissette
Date: 2007/08/30 - 20:40
Done in 4b53a7f (r6749)
mapserver-bot commented on Apr 3, 2012
Author: dmorissette
Date: 2007/08/30 - 21:12
Both Steve and Tom made comments about the use of hex notation for the verison number. they have convinced me and I have decided to revert to using real decimals instead of hex notation.
Changed in 0653d86 (r6752)
The function now returns version number (x.y.z) as an integer (x_10000 + y_100 + z).
For instance, v5.0.0 would be 50000 and v4.10.3 would have been 41003.