Class: String

Inherits:
Object
  • Object
show all
Defined in:
lib/cloudformula/string.rb

Instance Method Summary collapse

Instance Method Details

#try_to_jsonString

Returns the string JSON-escaped. If the cloudformula_raw flag is set, returns the string as-is.

Returns:


7
8
9
10
# File 'lib/cloudformula/string.rb', line 7

def try_to_json
  return self if instance_variable_get :@cloudformula_raw
  self.to_json
end