Class: GoogleDataSource::DataSource::InvalidData

Inherits:
Base
  • Object
show all
Defined in:
lib/google_data_source/invalid_data.rb

Instance Attribute Summary

Attributes inherited from Base

#callback, #column_labels, #errors, #export_filename, #formatters, #reporting, #virtual_columns, #xml_class

Instance Method Summary collapse

Methods inherited from Base

#[], #[]=, #add_error, #column_ids, #columns, #columns=, #data, #data=, #format, #formatter, from_gdata_params, from_params, #guess_columns, #has_formatter?, #is_virtual_column?, #required_columns, #response, #set, #set_required_columns, #valid?, #virtual_column

Constructor Details

#initialize(gviz_params) ⇒ InvalidData

Returns a new instance of InvalidData.



4
5
6
# File 'lib/google_data_source/invalid_data.rb', line 4

def initialize(gviz_params)
  super(gviz_params)
end

Instance Method Details

#validateObject



8
9
10
11
# File 'lib/google_data_source/invalid_data.rb', line 8

def validate
  super
  add_error(:out, "Invalid output format: #{@params[:out]}. Valid ones are json,csv,html")
end