Function getRokuVersion () As Object
vsn = {major: 0, minor: 0, build: 0}
diVsn = CreateObject ("roDeviceInfo").GetVersion ()
majMin = (Mid (diVsn, 3, 4)).Tokenize (".")
If majMin.Count () > 0 Then vsn.major = majMin [0].ToInt ()
If majMin.Count () > 1 Then vsn.minor = majMin [1].ToInt ()
vsn.build = (Mid (diVsn, 9, 4)).ToInt ()
Return vsn
End Function
' Example use:
vsn = getRokuVersion ()
settings.seekSupported = vsn.major >= 5
The global function FindMemberFunction is described to return "Invalid" if the function does not exist, or otherwise a reference to the interface defining the function. I do not know from what version FindMemberFunction is available, though.
FindMemberFunction(object as Object, funName as String) As Interface
FindMemberFunction has been around for many years. To be exact, the old release notes in the SDK documentation says it was added in Roku OS version 6.1 - 12/04/2014.
Generally speaking, for any function that is documented in the current SDK BrightScript reference without any annotation regarding it only being added in a recent firmware version, you can take its availability for granted.