Package gavo :: Package utils :: Module typeconversions
[frames] | no frames]

Module typeconversions

source code

Conversions between type systems.

The DC software has to deal with a quite a few type systems (see base.typesystems). In general, we keep metadata in the SQL type system; in particular, column's and param's type attribute takes values in that.

In fact, we use a couple of extensions:

This module contains a base class and the VOTable type system conversion, as the VOTable module (that should not depend on base) depends on it. The remaining actual converters are in base.typesystems, as they may depend on details of base. Even the SQL converters should be taken from there when code can rely on gavo.base; this module should be considered an implementation detail.

Classes
  ConversionError
  FromSQLConverter
is an abstract base class for type converters from the SQL type system.
  ToVOTableConverter
  FromVOTableConverter
Functions
 
sqltypeToVOTable(sqlType) source code
 
voTableToSQLType(type, arraysize, xtype=None) source code
Variables
  __package__ = 'gavo.utils'