Class: Embulk::Input::InputBigquery::LocalFile

Inherits:
Object
  • Object
show all
Defined in:
lib/embulk/input/bigquery.rb

Overview

support config by file path or content which supported by org.embulk.spi.unit.LocalFile keyfile:

content: |

Class Method Summary collapse

Class Method Details

.load(v) ⇒ Object

return JSON string



15
16
17
18
19
20
21
# File 'lib/embulk/input/bigquery.rb', line 15

def self.load(v)
  if v.is_a?(String)
    v
  elsif v.is_a?(Hash)
    JSON.parse(v['content'])
  end
end