Class: Realize::Type::String

Inherits:
Base
  • Object
show all
Defined in:
lib/realize/type/string.rb

Overview

Call #to_s on the value and return result.

Instance Attribute Summary

Attributes inherited from Base

#nullable

Instance Method Summary collapse

Methods inherited from Base

#initialize

Constructor Details

This class inherits a constructor from Realize::Type::Base

Instance Method Details

#transform(_resolver, value, _time, _record) ⇒ Object



16
17
18
19
20
# File 'lib/realize/type/string.rb', line 16

def transform(_resolver, value, _time, _record)
  return nil if nullable && value.nil?

  value.to_s
end