Class: VORuby::ADQL::Into

Inherits:
Object show all
Defined in:
lib/voruby/adql/adql.rb,
lib/voruby/adql/transforms.rb

Overview

Represents the SQL INTO expression.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name) ⇒ Into

Returns a new instance of Into.



2264
2265
2266
# File 'lib/voruby/adql/adql.rb', line 2264

def initialize(name)
  self.table_name = name
end

Instance Attribute Details

#table_nameObject

Returns the value of attribute table_name.



2262
2263
2264
# File 'lib/voruby/adql/adql.rb', line 2262

def table_name
  @table_name
end

Class Method Details

.from_xml(node) ⇒ Object



2272
2273
2274
2275
2276
# File 'lib/voruby/adql/adql.rb', line 2272

def self.from_xml(node)
  table_name_node = REXML::XPath.first(node, 'TableName')
  table_name = TableName.from_xml(table_name_node)
  return Into.new(table_name)
end

Instance Method Details

#to_adqlsObject



442
443
444
# File 'lib/voruby/adql/transforms.rb', line 442

def to_adqls
  "INTO #{self.table_name}"
end

#to_sObject



2268
2269
2270
# File 'lib/voruby/adql/adql.rb', line 2268

def to_s
  "{table_name=#{self.table_name}}"
end