rubyconstant(
VALUE
)

The rubyconstant( function encodes a value for use as a constant in a Ruby program.


Parameters

This function has one parameter:

value – the value to be encoded. This value may be text, in which case it will be properly quoted. Any special characters in the text will be escaped. The value may also be numeric, in which case it is passed thru “as-is”.


Description

This function encodes a value for use as a constant in a Ruby program.

rubyconstant("Hello World") ☞  'Hello World'
rubyconstant("He said 'hello' before leaving.") ☞ 'He said \'hello\' before leaving.'
rubyconstant(3264) ☞ 3264

See Also


History

VersionStatusNotes
10.0No ChangeCarried over from Panorama 6.0.