FACT++  1.0
int64_t FitsDumper::GetInteger ( const MyColumn it,
size_t  i 
) const
private

Definition at line 307 of file fitsdump.cc.

References MyColumn::col, MyColumn::ptr, and fits::Table::Column::type.

Referenced by Format().

308 {
309  switch (it.col.type)
310  {
311  case 'A':
312  return reinterpret_cast<const char*>(it.ptr)[i];
313 
314  case 'L':
315  return reinterpret_cast<const bool*>(it.ptr)[i];
316 
317  case 'B':
318  return (unsigned int)reinterpret_cast<const uint8_t*>(it.ptr)[i];
319 
320  case 'I':
321  return reinterpret_cast<const int16_t*>(it.ptr)[i];
322 
323  case 'J':
324  return reinterpret_cast<const int32_t*>(it.ptr)[i];
325 
326  case 'K':
327  return reinterpret_cast<const int64_t*>(it.ptr)[i];
328 
329  case 'E':
330  return reinterpret_cast<const float*>(it.ptr)[i];
331 
332  case 'D':
333  return reinterpret_cast<const double*>(it.ptr)[i];
334  }
335 
336  return 0;
337 }
int i
Definition: db_dim_client.c:21
void * ptr
Definition: fitsdump.cc:36
fits::Table::Column col
Definition: fitsdump.cc:31

+ Here is the caller graph for this function: