voruby 1.1 → 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/REQUIREMENTS +3 -3
- data/Rakefile.rb +6 -2
- data/lib/voruby/active_votable/active_votable.rb +61 -6
- data/lib/voruby/adql/adql.rb +64 -12
- data/lib/voruby/adql/ext.rb +2 -3
- data/lib/voruby/adql/loader.rb +1 -0
- data/lib/voruby/resources/voresource/voresource_v0_10.rb +7 -2
- data/lib/voruby/services/gestalt/footprint.rb +2 -2
- data/lib/voruby/services/gestalt/wesix.rb +1 -1
- data/lib/voruby/services/resolver/resolver.rb +1 -1
- data/lib/voruby/services/schema/schema.rb +644 -0
- data/lib/voruby/simple/sap.rb +2 -2
- data/lib/voruby/votables/chandra.rb +194 -231
- data/lib/voruby/votables/galex.rb +229 -242
- data/lib/voruby/votables/int.rb +193 -230
- data/lib/voruby/votables/nsa.rb +299 -282
- data/lib/voruby/votables/rexml_votable.rb +1 -1
- data/lib/voruby/votables/sdss.rb +194 -231
- data/lib/voruby/votables/transforms.rb +3 -3
- data/lib/voruby/votables/votable.rb +338 -281
- data/test/active_votable/unittest.rb +18 -4
- data/test/plastic/test.rb +1 -1
- data/test/resources/voresource/unittest_v1_0.rb +2 -2
- data/test/stc/unittest_v1_20.rb +2 -2
- metadata +52 -54
- data/lib/voruby/votables/cnoc.rb +0 -393
- data/lib/voruby/votables/hst.rb +0 -391
- data/lib/voruby/votables/nsar3.rb +0 -410
- data/lib/voruby/votables/xmm.rb +0 -394
@@ -9,7 +9,7 @@ module VORuby
|
|
9
9
|
|
10
10
|
module VOTable
|
11
11
|
class CHANDRAVOTable < VOTable
|
12
|
-
|
12
|
+
|
13
13
|
# Our object's contructor
|
14
14
|
# [_votable:_]
|
15
15
|
# The VOTable object
|
@@ -18,7 +18,7 @@ module VORuby
|
|
18
18
|
votable.definitions, votable.coosys, votable.params,
|
19
19
|
votable.info, votable.resources)
|
20
20
|
end
|
21
|
-
|
21
|
+
|
22
22
|
# Find the column number(s) associated with a Name.
|
23
23
|
# Returns a list of column positions.
|
24
24
|
# [_res_:]
|
@@ -27,7 +27,7 @@ module VORuby
|
|
27
27
|
# The resource from which to extract the table in question.
|
28
28
|
def find_columns(name, res=0, tbl=0)
|
29
29
|
columns = []
|
30
|
-
|
30
|
+
|
31
31
|
col_count = 0
|
32
32
|
fields = fields(res, tbl)
|
33
33
|
if fields
|
@@ -40,14 +40,14 @@ module VORuby
|
|
40
40
|
end
|
41
41
|
return columns
|
42
42
|
end
|
43
|
-
|
43
|
+
|
44
44
|
# Find a field in CHANDRA configuration file given a key.
|
45
45
|
# Returns a hash with the field's attributes
|
46
46
|
# [_key_:]
|
47
47
|
# The key indexing on field's attribute
|
48
48
|
def find_field_in_conf_file(key)
|
49
49
|
chandra_field = {'id'=> nil, 'name'=> nil, 'ucd'=> nil}
|
50
|
-
|
50
|
+
|
51
51
|
if key != nil
|
52
52
|
CHANDRA_ARCHIVE_CONFIG.each do |archive|
|
53
53
|
archive['votable_fields'].each do |field|
|
@@ -62,347 +62,310 @@ module VORuby
|
|
62
62
|
end
|
63
63
|
return chandra_field
|
64
64
|
end
|
65
|
-
|
65
|
+
|
66
66
|
def image_access_reference_columns()
|
67
67
|
access_key = find_field_in_conf_file('URL')['name']
|
68
|
-
|
68
|
+
|
69
69
|
if find_columns(access_key).first != nil
|
70
70
|
find_columns(access_key).first
|
71
71
|
end
|
72
72
|
end
|
73
|
-
|
73
|
+
|
74
74
|
def image_ra_columns
|
75
75
|
ra_key = find_field_in_conf_file('RA')['name']
|
76
|
-
|
76
|
+
|
77
77
|
if find_columns(ra_key).first != nil
|
78
78
|
find_columns(ra_key).first
|
79
79
|
end
|
80
80
|
end
|
81
|
-
|
81
|
+
|
82
82
|
def image_dec_columns
|
83
83
|
dec_key = find_field_in_conf_file('Dec')['name']
|
84
|
-
|
84
|
+
|
85
85
|
if find_columns(dec_key).first != nil
|
86
86
|
find_columns(dec_key).first
|
87
87
|
end
|
88
88
|
end
|
89
|
-
|
89
|
+
|
90
90
|
def image_filter_columns
|
91
91
|
#filter_key = find_field_in_conf_file('')['name']
|
92
|
-
|
92
|
+
|
93
93
|
#if find_columns(filter_key).first != nil
|
94
94
|
# find_columns(filter_key).first
|
95
95
|
#end
|
96
96
|
end
|
97
|
-
|
97
|
+
|
98
98
|
def image_date_obs_columns
|
99
99
|
#date_obs_key = find_field_in_conf_file('')['name']
|
100
|
-
|
100
|
+
|
101
101
|
#if find_columns(date_obs_key).first != nil
|
102
102
|
# find_columns(date_obs_key).first
|
103
103
|
#end
|
104
104
|
end
|
105
|
-
|
105
|
+
|
106
106
|
def image_telescope_columns
|
107
107
|
#telescope_key = find_field_in_conf_file('')['name']
|
108
|
-
|
108
|
+
|
109
109
|
#if find_columns(telescope_key).first != nil
|
110
110
|
# find_columns(telescope_key).first
|
111
111
|
#end
|
112
112
|
end
|
113
|
-
|
113
|
+
|
114
114
|
def image_survey_columns
|
115
115
|
survey_key = find_field_in_conf_file('Object')['name']
|
116
|
-
|
116
|
+
|
117
117
|
if find_columns(survey_key).first != nil
|
118
118
|
find_columns(survey_key).first
|
119
119
|
end
|
120
120
|
end
|
121
|
-
|
121
|
+
|
122
122
|
def image_instrument_columns
|
123
123
|
instrument_key = find_field_in_conf_file('Instrument')['name']
|
124
|
-
|
124
|
+
|
125
125
|
if find_columns(instrument_key).first != nil
|
126
126
|
find_columns(instrument_key).first
|
127
127
|
end
|
128
128
|
end
|
129
|
-
|
129
|
+
|
130
130
|
def image_sky_columns
|
131
131
|
#sky_key = find_field_in_conf_file('')['name']
|
132
|
-
|
132
|
+
|
133
133
|
#if find_columns(sky_key).first != nil
|
134
134
|
# find_columns(sky_key).first
|
135
135
|
#end
|
136
136
|
end
|
137
|
-
|
137
|
+
|
138
138
|
def image_zeropoint_columns
|
139
139
|
#zeropoint_key = find_field_in_conf_file('')['name']
|
140
|
-
|
140
|
+
|
141
141
|
#if find_columns(zeropoint_key).first != nil
|
142
142
|
# find_columns(zeropoint_key).first
|
143
143
|
#end
|
144
144
|
end
|
145
|
-
|
145
|
+
|
146
146
|
def image_seeing_columns
|
147
147
|
#seeing_key = find_field_in_conf_file('')['name']
|
148
|
-
|
148
|
+
|
149
149
|
#if find_columns(seeing_key).first != nil
|
150
150
|
# find_columns(seeing_key).first
|
151
151
|
#end
|
152
152
|
end
|
153
|
-
|
153
|
+
|
154
154
|
def image_depth_columns
|
155
155
|
#depth_key = find_field_in_conf_file('')['name']
|
156
|
-
|
156
|
+
|
157
157
|
#if find_columns(depth_key).first != nil
|
158
158
|
# find_columns(depth_key).first
|
159
159
|
#end
|
160
160
|
end
|
161
|
-
|
161
|
+
|
162
162
|
def image_exptime_columns
|
163
163
|
#exptime_key = find_field_in_conf_file('')['name']
|
164
|
-
|
164
|
+
|
165
165
|
#if find_columns(exptime_key).first != nil
|
166
166
|
# find_columns(exptime_key).first
|
167
167
|
#end
|
168
168
|
end
|
169
|
-
|
170
|
-
# Create headers for HTML table
|
171
|
-
# [
|
172
|
-
# The resource from which to extract the table in question.
|
173
|
-
# [_tbl_:]
|
174
|
-
# The table inside the resource from which to extract the rows in question.
|
175
|
-
# [_infer_add_to_cart_ref_:]
|
176
|
-
#
|
177
|
-
# [_add_to_cart_header_value_:]
|
178
|
-
#
|
179
|
-
# [_infer_access_ref_:]
|
180
|
-
# Link the access reference URL associated with a row.
|
181
|
-
# [_access_ref_header_value_:]
|
182
|
-
# For the access reference column, place this value in the header.
|
183
|
-
# [_access_ref_col_:]
|
169
|
+
|
170
|
+
# Create the headers for HTML table
|
171
|
+
# [_access_ref_index_:]
|
184
172
|
# A valid SIA VOTable will only ever have one VOX:Image_AccessReference.
|
185
|
-
# [
|
186
|
-
#
|
187
|
-
def create_headers(
|
188
|
-
|
189
|
-
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
thead = "<thead class=\"#{header_class}\">\n"
|
194
|
-
|
195
|
-
thead << "<tr>\n"
|
196
|
-
if infer_add_to_cart_ref
|
197
|
-
thead << "<th>#{add_to_cart_header_value}</th>\n"
|
198
|
-
headers.push("<a href=\"javascript:void(0);\" onclick=\"siap.addAllRowsToCart('#{id}');\">*</a>")
|
199
|
-
end
|
200
|
-
if infer_access_ref
|
201
|
-
thead << "<th>#{access_ref_header_value}</th>\n"
|
202
|
-
headers.push(' ')
|
173
|
+
# [_options_:]
|
174
|
+
#
|
175
|
+
def create_headers(access_ref_index, options)
|
176
|
+
thead, thead_2row = create_header_cart_links(options)
|
177
|
+
|
178
|
+
if options[:infer_access_ref] and access_ref_index
|
179
|
+
thead << "<th>#{options[:access_ref_header_label]}</th>\n"
|
180
|
+
thead_2row.push(' ')
|
203
181
|
end
|
182
|
+
|
204
183
|
col_count = 0
|
205
|
-
fields(res, tbl).each do |field|
|
184
|
+
fields(options[:res], options[:tbl]).each do |field|
|
206
185
|
field_archive = find_field_in_conf_file(field.name())
|
207
186
|
field_ucd = field_archive['ucd']
|
208
|
-
if infer_access_ref and col_count ==
|
209
|
-
|
187
|
+
if options[:infer_access_ref] and col_count == access_ref_index
|
188
|
+
thead_2row[1] = field_ucd if field_ucd != 'nil'
|
210
189
|
else
|
211
190
|
thead << "<th>#{field_archive['name']}</th>\n"
|
212
191
|
if field_ucd != 'nil'
|
213
|
-
|
192
|
+
thead_2row.push(field_ucd)
|
214
193
|
else
|
215
|
-
|
194
|
+
thead_2row.push(' ')
|
216
195
|
end
|
217
196
|
end
|
218
197
|
col_count += 1
|
219
198
|
end
|
199
|
+
|
220
200
|
thead << " </tr>\n"
|
221
|
-
|
201
|
+
|
222
202
|
thead << "<tr>\n"
|
223
|
-
|
203
|
+
thead_2row.each do |h|
|
224
204
|
thead << "<th>#{h}</th>\n"
|
225
205
|
end
|
226
206
|
thead << "</tr>\n"
|
227
|
-
|
207
|
+
|
228
208
|
thead << "</thead>"
|
229
|
-
|
209
|
+
|
230
210
|
return thead
|
231
211
|
end
|
232
|
-
|
233
|
-
|
234
|
-
|
235
|
-
|
236
|
-
|
237
|
-
|
238
|
-
|
239
|
-
|
240
|
-
|
241
|
-
|
242
|
-
|
243
|
-
|
244
|
-
|
245
|
-
|
246
|
-
|
247
|
-
|
248
|
-
|
249
|
-
|
250
|
-
|
251
|
-
|
252
|
-
|
253
|
-
|
254
|
-
|
255
|
-
|
256
|
-
|
257
|
-
|
258
|
-
|
259
|
-
|
260
|
-
|
261
|
-
|
212
|
+
|
213
|
+
# Creates the cart parameters
|
214
|
+
# [_cart_params:_]
|
215
|
+
#
|
216
|
+
# [_columns:_]
|
217
|
+
#
|
218
|
+
def create_item_cart_params(cart_params, columns)
|
219
|
+
link_ref_array = []
|
220
|
+
|
221
|
+
cart_params.each do |key, value|
|
222
|
+
link_ref_array.push("#{key}=#{value}")
|
223
|
+
end
|
224
|
+
|
225
|
+
access_ref_index = image_access_reference_columns()
|
226
|
+
link_ref_array.push("resource=#{CGI.escape(columns[access_ref_index].value).to_s}") if access_ref_index
|
227
|
+
ra_index = image_ra_columns()
|
228
|
+
link_ref_array.push("rac=#{columns[ra_index].value.to_s}") if ra_index
|
229
|
+
dec_index = image_dec_columns()
|
230
|
+
link_ref_array.push("decc=#{columns[dec_index].value.to_s}") if dec_index
|
231
|
+
filter_index = image_filter_columns()
|
232
|
+
link_ref_array.push("filter=#{columns[filter_index].value.to_s}") if filter_index
|
233
|
+
date_obs_index = image_date_obs_columns()
|
234
|
+
link_ref_array.push("date_obs=#{columns[date_obs_index].value.to_s}") if date_obs_index
|
235
|
+
teles_index = image_telescope_columns()
|
236
|
+
link_ref_array.push("telescop=#{columns[teles_index].value.to_s}") if teles_index
|
237
|
+
survey_index = image_survey_columns()
|
238
|
+
link_ref_array.push("survey=#{columns[survey_index].value.to_s}") if survey_index
|
239
|
+
instrum_index = image_instrument_columns()
|
240
|
+
link_ref_array.push("instrument=#{columns[instrum_index].value.to_s}") if instrum_index
|
241
|
+
sky_index = image_sky_columns()
|
242
|
+
link_ref_array.push("sky=#{columns[sky_index].value.to_s}") if sky_index
|
243
|
+
zerop_index = image_zeropoint_columns()
|
244
|
+
link_ref_array.push("zeropoint=#{columns[zerop_index].value.to_s}") if zerop_index
|
245
|
+
seeing_index = image_seeing_columns()
|
246
|
+
link_ref_array.push("seeing=#{columns[seeing_index].value.to_s}") if seeing_index
|
247
|
+
depth_index = image_depth_columns()
|
248
|
+
link_ref_array.push("depth=#{columns[depth_index].value.to_s}") if depth_index
|
249
|
+
exptime_index = image_exptime_columns()
|
250
|
+
link_ref_array.push("exptime=#{columns[exptime_index].value.to_s}") if exptime_index
|
251
|
+
|
252
|
+
return link_ref_array.join('&')
|
262
253
|
end
|
263
|
-
|
254
|
+
|
264
255
|
# Create body for HTML table
|
265
|
-
# [
|
266
|
-
# The resource from which to extract the table in question.
|
267
|
-
# [_tbl_:]
|
268
|
-
# The table inside the resource from which to extract the rows in question.
|
269
|
-
# [_infer_add_to_cart_ref_:]
|
270
|
-
#
|
271
|
-
# [_add_to_cart_link_value_:]
|
272
|
-
#
|
273
|
-
# [_add_to_cart_link_ref_:]
|
274
|
-
#
|
275
|
-
# [_infer_access_ref_:]
|
276
|
-
# Link the access reference URL associated with a row.
|
277
|
-
# [_access_ref_link_value_:]
|
278
|
-
# For the access reference column, link this word.
|
279
|
-
# [_access_ref_col_:]
|
256
|
+
# [_access_ref_index_:]
|
280
257
|
# A valid SIA VOTable will only ever have one VOX:Image_AccessReference.
|
281
|
-
# [
|
282
|
-
#
|
283
|
-
|
284
|
-
|
285
|
-
def create_body(res, tbl,
|
286
|
-
infer_add_to_cart_ref, add_to_cart_link_value, add_to_cart_link_ref,
|
287
|
-
infer_access_ref, access_ref_link_value, access_ref_col,
|
288
|
-
body_class, row_classes)
|
289
|
-
|
290
|
-
tbody = "<tbody class=\"#{body_class}\">\n"
|
258
|
+
# [_options_:]
|
259
|
+
#
|
260
|
+
def create_body(access_ref_index, options)
|
261
|
+
tbody = "<tbody class=\"#{options[:body_class]}\" align=\"center\">\n"
|
291
262
|
row_count = 0
|
292
|
-
rows(res, tbl)
|
293
|
-
|
294
|
-
|
295
|
-
|
296
|
-
|
297
|
-
|
298
|
-
|
299
|
-
|
300
|
-
|
301
|
-
|
302
|
-
|
303
|
-
|
304
|
-
|
305
|
-
|
306
|
-
|
307
|
-
|
308
|
-
|
309
|
-
|
310
|
-
|
311
|
-
|
312
|
-
|
313
|
-
|
314
|
-
|
315
|
-
|
316
|
-
|
317
|
-
|
318
|
-
|
319
|
-
|
263
|
+
rows_data = rows(options[:res], options[:tbl])
|
264
|
+
if rows_data
|
265
|
+
rows_data.each do |tr|
|
266
|
+
tbody << "<tr class=\"#{options[:row_classes][row_count % 2]}\">\n"
|
267
|
+
|
268
|
+
# Specially mark up the first column to link to the image.
|
269
|
+
columns = tr.tds()
|
270
|
+
|
271
|
+
if options[:infer_add_to_cart_ref] and access_ref_index
|
272
|
+
tbody << "<td><input type=\"checkbox\" " +
|
273
|
+
"id=\"checkbox_add_#{options[:cart_params][:archive]}_#{row_count.to_s}\" " +
|
274
|
+
"value=\"#{create_item_cart_params(options[:cart_params], columns)}\"/></td>\n"
|
275
|
+
end
|
276
|
+
|
277
|
+
if options[:infer_access_ref] and access_ref_index
|
278
|
+
tbody << "<td><a href=\"#{columns[access_ref_index].value}\">#{options[:access_ref_link_label]}</a></td>\n"
|
279
|
+
end
|
280
|
+
|
281
|
+
col_count = 0
|
282
|
+
#ra_index = image_ra_columns()
|
283
|
+
#dec_index = image_dec_columns()
|
284
|
+
columns.each do |td|
|
285
|
+
if col_count != access_ref_index
|
286
|
+
#if ra_index and col_count == ra_index
|
287
|
+
# tbody << "<td>#{convert_ra_to_degrees(td.value)}</td>\n"
|
288
|
+
#elsif dec_index and col_count == dec_index
|
289
|
+
# tbody << "<td>#{convert_dec_to_degrees(td.value)}</td>\n"
|
290
|
+
#else
|
291
|
+
tbody << "<td>#{td.value}</td>\n"
|
292
|
+
#end
|
293
|
+
end
|
294
|
+
col_count += 1
|
295
|
+
end
|
296
|
+
|
297
|
+
tbody << "</tr>\n"
|
298
|
+
row_count += 1
|
320
299
|
end
|
321
|
-
tbody << "</tr>\n"
|
322
|
-
row_count += 1
|
323
300
|
end
|
324
301
|
tbody << "</tbody>"
|
325
|
-
|
302
|
+
|
326
303
|
return tbody
|
327
304
|
end
|
328
|
-
|
305
|
+
|
329
306
|
# Convert the specified table in the specified resource into an HTML
|
330
307
|
# table.
|
331
|
-
# [
|
332
|
-
# The
|
333
|
-
|
334
|
-
|
335
|
-
|
336
|
-
|
337
|
-
|
338
|
-
|
339
|
-
|
340
|
-
|
341
|
-
|
342
|
-
|
343
|
-
|
344
|
-
|
345
|
-
|
346
|
-
|
347
|
-
|
348
|
-
|
349
|
-
|
350
|
-
|
351
|
-
|
352
|
-
|
353
|
-
|
354
|
-
|
355
|
-
|
356
|
-
|
357
|
-
|
358
|
-
|
359
|
-
|
360
|
-
|
361
|
-
|
362
|
-
|
363
|
-
|
364
|
-
|
365
|
-
|
366
|
-
|
367
|
-
|
368
|
-
|
369
|
-
|
370
|
-
|
371
|
-
|
372
|
-
|
308
|
+
# [_options_:]
|
309
|
+
# The options for this VOTable.
|
310
|
+
def to_html(options={})
|
311
|
+
# The ID to assign to the HTML table as a whole.
|
312
|
+
options[:id] = options[:id] || "#{votable}_#{Time.now.to_i}_#{rand(10000)}"
|
313
|
+
|
314
|
+
options[:infer_add_to_cart_ref] = true if options[:infer_add_to_cart_ref] == nil
|
315
|
+
options[:add_to_cart_header_label] = options[:add_to_cart_header_label] || 'Add to Cart'
|
316
|
+
options[:cart_params] = {} if options[:cart_params] == nil
|
317
|
+
#options[:add_to_cart_url] = options[:add_to_cart_url] || nil
|
318
|
+
|
319
|
+
options[:throbber_src] = options[:throbber_src] || '/images/general/indicator.gif'
|
320
|
+
options[:throbber_size] = options[:throbber_size] || '16x16'
|
321
|
+
options[:throbber_class] = options[:throbber_class] || 'throbber'
|
322
|
+
options[:throbber_id] = options[:throbber_id] || "#{options[:id]}_throbber_id"
|
323
|
+
|
324
|
+
options[:flash_notice_class] = options[:flash_notice_class] || 'flash_notice'
|
325
|
+
options[:flash_notice_id] = options[:flash_notice_id] || "#{options[:id]}_flash_notice_id"
|
326
|
+
|
327
|
+
# Link the access reference URL associated with a row.
|
328
|
+
options[:infer_access_ref] = true if options[:infer_access_ref] == nil
|
329
|
+
#options[:retrieve_link_ref] = options[:retrieve_link_ref] || nil
|
330
|
+
# For the access reference column, place this value in the header.
|
331
|
+
options[:access_ref_header_label] = options[:access_ref_header_label] || 'URL'
|
332
|
+
# For the access reference column, link this word.
|
333
|
+
options[:access_ref_link_label] = options[:access_ref_link_label] || 'Retrieve'
|
334
|
+
options[:ssl] = false if options[:ssl] == nil
|
335
|
+
#options[:resource_link] = options[:resource_link]
|
336
|
+
|
337
|
+
# The resource from which to extract the table in question.
|
338
|
+
options[:res] = options[:res] || 0
|
339
|
+
# The table inside the resource from which to extract the rows in question.
|
340
|
+
options[:tbl] = options[:tbl] || 0
|
341
|
+
|
342
|
+
# The boolean value to show HTML table border
|
343
|
+
options[:show_border] = false if options[:show_border] == nil
|
344
|
+
# The class to assign the HTML table as a whole.
|
345
|
+
options[:table_class] = options[:table_class] || 'votable'
|
346
|
+
# The class to assign the header of the HTML table.
|
347
|
+
options[:header_class] = options[:header_class] || 'header'
|
348
|
+
# The class to assign the body of the HTML table.
|
349
|
+
options[:body_class] = options[:body_class] || 'body'
|
350
|
+
# The class to assign the HTML table body rows.
|
351
|
+
options[:row_classes] = options[:row_classes] || ['row1', 'row2']
|
352
|
+
|
373
353
|
begin
|
374
354
|
# A valid SIA VOTable will only ever have one VOX:Image_AccessReference.
|
375
|
-
|
376
|
-
|
377
|
-
|
378
|
-
|
379
|
-
|
380
|
-
|
381
|
-
infer_access_ref, access_ref_header_value, access_ref_col,
|
382
|
-
header_class, id)
|
383
|
-
|
384
|
-
# Create body
|
385
|
-
tbody = create_body(res, tbl,
|
386
|
-
infer_add_to_cart_ref, add_to_cart_link_value, add_to_cart_link_ref,
|
387
|
-
infer_access_ref, access_ref_link_value, access_ref_col,
|
388
|
-
body_class, row_classes)
|
389
|
-
|
390
|
-
return create_table(id, show_border, table_class, thead, tbody)
|
391
|
-
else
|
392
|
-
title = 'No Data'
|
393
|
-
message = 'VOTable not contains data.'
|
394
|
-
return create_message_table(table_class, header_class,
|
395
|
-
body_class, row_classes, title, message)
|
396
|
-
end
|
397
|
-
|
355
|
+
access_ref_index = image_access_reference_columns()
|
356
|
+
|
357
|
+
return create_votable(create_headers(access_ref_index, options),
|
358
|
+
create_body(access_ref_index, options),
|
359
|
+
options)
|
360
|
+
|
398
361
|
rescue Exception => e
|
399
|
-
title = 'Error'
|
400
|
-
message =
|
401
|
-
|
402
|
-
|
362
|
+
title = 'Error...'
|
363
|
+
message = "VORuby error: #{e.message}<br>#{e.backtrace}"
|
364
|
+
message << "<br>#{@resources[0].info[0].text().to_s()}" if @resources[0].info[0]
|
365
|
+
create_message(title, message, options)
|
403
366
|
end
|
404
367
|
end
|
405
|
-
|
368
|
+
|
406
369
|
end
|
407
370
|
end
|
408
371
|
|